Right Triangle Calculator — Solve Any Right Triangle
Enter any two known values of a right triangle and calculate all remaining sides, angles, area, perimeter, and altitude to the hypotenuse. See also Trigonometry Calculator and Pythagorean Theorem Calculator.
How to Solve a Right Triangle
A right triangle has one 90° angle and two acute angles that sum to 90°. To solve it completely, you need at least two known values (besides the right angle). Enter two sides, a side and an angle, or the hypotenuse with a side or angle. The calculator uses the Pythagorean theorem (a² + b² = c²) and trigonometric ratios (sin, cos, tan) to find all missing values including area, perimeter, and the altitude from the right angle to the hypotenuse.
Right Triangle Formulas
Pythagorean theorem: a² + b² = c²
Angle A = arctan(a / b) or arcsin(a / c)
Angle B = 90° − Angle A
Area = ½ × a × b
Perimeter = a + b + c
Altitude to hypotenuse h = (a × b) / c
sin A = a / c, cos A = b / c, tan A = a / b
Example: The Classic 3-4-5 Triangle
Given: a = 3, b = 4
c = √(3² + 4²) = √(9 + 16) = √25 = 5
Angle A = arctan(3/4) ≈ 36.87°
Angle B = 90° − 36.87° ≈ 53.13°
Area = ½ × 3 × 4 = 6
Perimeter = 3 + 4 + 5 = 12
Altitude to hypotenuse = (3 × 4) / 5 = 2.4
Common Right Triangles Reference
| a | b | c | Angle A | Angle B | Area |
|---|---|---|---|---|---|
| 3 | 4 | 5 | 36.87° | 53.13° | 6 |
| 5 | 12 | 13 | 22.62° | 67.38° | 30 |
| 8 | 15 | 17 | 28.07° | 61.93° | 60 |
| 7 | 24 | 25 | 16.26° | 73.74° | 84 |
| 1 | 1 | 1.4142 | 45° | 45° | 0.5 |
| 1 | 1.7321 | 2 | 30° | 60° | 0.87 |
Right Triangle Diagram
Right triangle: side a (opposite), side b (adjacent), side c (hypotenuse), with the right angle between sides a and b.
Solved Examples
Example 1: Finding the Hypotenuse Given Two Legs
A right triangle has legs a = 6 and b = 8. Find the hypotenuse.
c² = a² + b²
c² = 6² + 8² = 36 + 64 = 100
c = √100
c = 10
Example 2: Finding a Leg Given Hypotenuse and One Leg
A right triangle has hypotenuse c = 15 and one leg a = 9. Find side b.
b² = c² - a²
b² = 15² - 9² = 225 - 81 = 144
b = √144
b = 12
Example 3: Finding Angles Given Two Sides
A right triangle has legs a = 7 and b = 10. Find angles A and B.
Angle A = arctan(a / b) = arctan(7 / 10)
Angle A = arctan(0.7)
Angle A = 34.99°
Angle B = 90° - 34.99°
Angle B = 55.01°
Example 4: Shadow Problem - Finding Building Height
A building casts a 25-meter shadow when the sun is at a 58° elevation angle. How tall is the building?
The shadow is the adjacent side (b = 25), the building height is the opposite side (a).
tan 58° = opposite / adjacent = height / 25
height = 25 × tan 58°
height = 25 × 1.6003
height = 40.01 meters
Practice Questions
1. A right triangle has legs a = 5 and b = 12. Find the hypotenuse and both acute angles.
Answer: c = √(25 + 144) = √169 = 13. Angle A = arctan(5/12) = 22.62°. Angle B = 67.38°.
2. The hypotenuse of a right triangle is 20 and one leg is 16. Find the other leg.
Answer: b = √(20² - 16²) = √(400 - 256) = √144 = 12
3. In a right triangle, angle A = 40° and the hypotenuse is 18. Find both legs.
Answer: a = 18 × sin 40° = 18 × 0.6428 = 11.57. b = 18 × cos 40° = 18 × 0.7660 = 13.79.
4. A 6-meter pole casts a 4.5-meter shadow. What is the angle of elevation of the sun?
Answer: tan θ = 6 / 4.5 = 1.333, so θ = arctan(1.333) = 53.13°
5. Find the area and perimeter of a right triangle with legs 9 and 40.
Answer: c = √(81 + 1600) = √1681 = 41. Area = (1/2)(9)(40) = 180. Perimeter = 9 + 40 + 41 = 90.
6. A right triangle has angle B = 72° and leg a = 10 (opposite angle A). Find all missing parts.
Answer: Angle A = 18°. c = a / sin A = 10 / sin 18° = 10 / 0.3090 = 32.36. b = 10 / tan 18° = 10 / 0.3249 = 30.78.
Common Mistakes to Avoid
Forgetting which side is the hypotenuse
The hypotenuse is always the longest side and always opposite the 90° angle. If you accidentally label a leg as the hypotenuse in the Pythagorean theorem, you will get a negative value under the square root or an incorrect answer.
Using the wrong trigonometric ratio
Before choosing sin, cos, or tan, clearly identify which sides are opposite and adjacent relative to the angle you are working with. The "opposite" and "adjacent" labels change depending on which angle is the reference.
Calculator set to wrong mode (radians instead of degrees)
When solving right triangles with angles in degrees, your calculator must be in degree mode. If it is in radian mode, arctan(1) will give 0.7854 instead of 45°, leading to incorrect angles throughout the solution.
Key Takeaways
- A right triangle is fully determined by any two known measurements (besides the right angle) -- two sides, or one side and one acute angle.
- The Pythagorean theorem (a² + b² = c²) relates the three sides, while trig ratios (SOH-CAH-TOA) relate sides to angles.
- The hypotenuse is always the longest side and is opposite the right angle. Never use it as a leg in your formulas.
- The two acute angles in a right triangle always sum to 90°, so knowing one immediately gives you the other.
- The altitude to the hypotenuse (h = ab/c) creates two smaller triangles that are each similar to the original triangle.
- Special right triangles (30-60-90 and 45-45-90) have fixed side ratios that allow exact solutions without a calculator.
Frequently Asked Questions
What is a right triangle?
A right triangle is a triangle with one angle exactly equal to 90°. The side opposite the right angle is called the hypotenuse and is always the longest side. The other two sides are called legs (a and b).
How many values do I need to solve a right triangle?
You need exactly two known values besides the right angle. This can be two sides, one side and one acute angle, or the hypotenuse and one leg. With any two values, all remaining sides and angles can be calculated.
What is the altitude to the hypotenuse?
The altitude to the hypotenuse is the perpendicular line drawn from the right angle vertex to the hypotenuse. Its length equals (a × b) / c. It divides the hypotenuse into two segments and creates two smaller triangles that are similar to the original.
What are special right triangles?
The two most common special right triangles are the 45-45-90 triangle (isosceles, sides in ratio 1:1:√2) and the 30-60-90 triangle (sides in ratio 1:√3:2). These appear frequently in geometry, trigonometry, and standardized tests.
Can a right triangle have two equal sides?
Yes — a 45-45-90 triangle has two equal legs. It is both a right triangle and an isosceles triangle. The hypotenuse is √2 times the length of each leg. However, a right triangle cannot be equilateral since all angles in an equilateral triangle are 60°.