Skip to content
Math

Right Triangle Calculator

A right triangle has one 90 degree angle, so any two values fully determine it. Enter any two of leg a, leg b, hypotenuse c, acute angle A, angle B, or an area plus one side, and this solver returns every side, angle, area, perimeter, semiperimeter, all three altitudes, the inscribed circle radius, and the circumscribed circle radius. Or pick a special triangle preset (45-45-90, 30-60-90, 3-4-5) to explore its exact ratios.

Your details

Load a well-known right triangle. You can then scale it by changing leg a.
A leg meeting the right angle. Leave blank if unknown.
units
The other leg meeting the right angle. Leave blank if unknown.
units
The longest side, opposite the right angle. Leave blank if unknown.
units
Acute angle facing leg a. Leave blank if unknown.
Acute angle facing leg b. Leave blank if unknown.
Supply the area with one side instead of a second side or angle.
units squared
StatusScalene right triangle
Solved
Leg a3units
Leg b4units
Hypotenuse c5units
Angle A (opposite a)36.8699deg
Angle B (opposite b)53.1301deg
Area6units squared
Perimeter12units
Semiperimeter (s)6units
Altitude to hypotenuse (h_c)2.4units
Altitude to leg a (h_a)4units
Altitude to leg b (h_b)3units
Inradius (r)1units
Circumradius (R)2.5units

Hypotenuse 5 units, area 6 sq units, inradius 1 units.

  • The two acute angles are 36.87 deg and 53.13 deg, which always sum to 90 deg in any right triangle.
  • The circumscribed circle has radius R = c/2 = 2.5 units because the hypotenuse is always the diameter of that circle (Thales theorem).
  • The inscribed circle has radius r = (a + b - c) / 2 = 1 units, where a and b are the legs and c is the hypotenuse.
  • You can solve the same triangle from a single leg plus one acute angle using SOHCAHTOA - no second measurement needed.

Next stepTry a preset (45-45-90 or 30-60-90) to explore special right triangles, or enter an area plus one side.

Formula

c=a2+b2,  B=90A,  Area=12ab,  s=a+b+c2,  hc=abc,  ha=2Ka,  hb=2Kb,  r=a+bc2,  R=c2c = \sqrt{a^{2}+b^{2}}, \; B = 90^{\circ}-A, \; \text{Area}=\tfrac{1}{2}ab, \; s=\tfrac{a+b+c}{2}, \; h_c=\tfrac{ab}{c}, \; h_a=\tfrac{2K}{a}, \; h_b=\tfrac{2K}{b}, \; r=\tfrac{a+b-c}{2}, \; R=\tfrac{c}{2}

Worked example

Given leg a = 3 and leg b = 4: c = sqrt(9+16) = 5, A = arctan(3/4) = 36.87 deg, B = 53.13 deg, area = 6, perimeter = 12, s = 6, h_c = 12/5 = 2.4, h_a = 12/3 = 4, h_b = 12/4 = 3, r = (3+4-5)/2 = 1, R = 5/2 = 2.5.

Enter any two values - the solver fills in the rest

A right triangle is locked by any two independent values because its third angle is always 90 degrees. This solver accepts any two of leg a, leg b, hypotenuse c, acute angle A, or acute angle B. It also accepts an area paired with one side to cover the common real-world case where you measured a triangular floor and one wall. Two angles on their own are rejected: angles fix the shape but not the size, so without at least one length the solver cannot pin down a unique triangle. Once it has two valid inputs it returns all three sides, both acute angles, the area, perimeter, semiperimeter, all three altitudes, the inradius, and the circumradius.

Special triangle presets: 45-45-90 and 30-60-90

Pick a preset from the dropdown to load a well-known right triangle. The 45-45-90 triangle is the diagonal of a square: the two legs are equal and the hypotenuse is leg times the square root of 2. The 30-60-90 triangle is half of an equilateral triangle: its sides are in the ratio 1 to root-3 to 2. These are the two triangles at the heart of most trigonometry problems, and they produce exact square-root values rather than long decimals. You can scale either preset by typing a value for leg a. The classic Pythagorean triple presets (3-4-5, 5-12-13) are also available for integer-side problems.

Every formula the solver uses

With two legs: hypotenuse c = sqrt(a squared + b squared) from the Pythagorean theorem. With leg a and angle A: c = a / sin(A), b = a / tan(A). With the hypotenuse and angle A: a = c times sin(A), b = c times cos(A). The angle opposite a is arctan(a / b), and the complementary angle is 90 minus that. The area is half times a times b, since the two legs are the base and height. The perimeter is the sum of all three sides, and the semiperimeter is half that. The altitude to the hypotenuse is h_c = a times b / c. The altitudes to the legs are h_a = 2 times area / a and h_b = 2 times area / b. The inradius of the inscribed circle uses the right-triangle shortcut r = (a + b - c) / 2. By Thales theorem the hypotenuse is the diameter of the circumscribed circle, so R = c / 2.

Inradius, circumradius, and the two circles

Every triangle has exactly one inscribed circle (tangent to all three sides) and one circumscribed circle (passing through all three vertices). For a right triangle these simplify beautifully: the circumradius is always exactly half the hypotenuse, because the angle-in-a-semicircle theorem guarantees that the right-angle vertex lies on the circle whose diameter is the hypotenuse. The inradius formula r = (a + b - c) / 2 is a special case of the general r = area / s, where s is the semiperimeter. Plugging in area = ab/2 and s = (a + b + c)/2 and simplifying gives the tidy result. Both radii are listed in the results so you can draw accurate geometry diagrams or verify constructions.

Special right triangles and Pythagorean triples

NameLeg aLeg bHypotenuse cAngle AInradius r
45-45-9011sqrt(2) = 1.414245 deg(2 - sqrt(2)) / 2 = 0.2929
30-60-901sqrt(3) = 1.7321230 deg(sqrt(3) - 1) / 2 = 0.3660
3-4-5 triple34536.87 deg1
5-12-13 triple5121322.62 deg2
8-15-17 triple8151728.07 deg3
7-24-25 triple7242516.26 deg3
9-40-41 triple9404112.68 deg4

Exact ratios and integer sets that satisfy a squared + b squared = c squared.

Frequently asked questions

Can I solve a right triangle from one side and one angle?

Yes. Enter a single leg or the hypotenuse together with one acute angle and the solver uses SOHCAHTOA. For example, leg a = 5 with angle A = 30 deg gives c = 5 / sin(30) = 10 and b = 5 / tan(30) = 8.660, and angle B = 60 deg.

Why can two angles alone not solve the triangle?

Angles set the shape but not the size. A 30-60-90 triangle with 1-cm sides and one with 1-km sides share the same angles, so you must supply at least one side length for the solver to find a unique answer.

How do I find a leg when I know the hypotenuse and the other leg?

Rearrange the Pythagorean theorem: a = sqrt(c squared - b squared). Enter the known leg and hypotenuse and the solver returns the missing leg. The hypotenuse must be strictly longer than either leg.

What is the inradius and why does the formula simplify for a right triangle?

The inradius r is the radius of the circle that fits inside the triangle touching all three sides. For any triangle r = area / s, where s is the semiperimeter. Substituting area = ab/2 and s = (a+b+c)/2 and simplifying gives the right-triangle shortcut r = (a + b - c) / 2, which only requires arithmetic on the three sides.

Why is the circumradius always half the hypotenuse?

Thales theorem states that any angle inscribed in a semicircle is a right angle. So if you draw a circle whose diameter equals the hypotenuse, the right-angle vertex of the triangle lies exactly on that circle. The radius is therefore c / 2.

What are the 45-45-90 and 30-60-90 special triangles?

The 45-45-90 triangle is the triangle you get by cutting a square along its diagonal. Its legs are equal and the hypotenuse is leg times root 2. The 30-60-90 triangle appears when you cut an equilateral triangle in half: the sides are in the ratio 1 to root-3 to 2. Both triangles produce exact square-root values and appear constantly in geometry and trigonometry.

Sources

Written by Dr. Elena Vasquez, PhD Mathematician · Lisbon, Portugal

Translating rigorous geometric theory into accurate, reliable calculation tools trusted by engineers, students, and researchers worldwide.

Search 3,500+ calculators

Loading search…