Triangle Long Side Calculator: Find Hypotenuse
- Angle opposite a
- deg
- Result
- Area
- m^2
- Result
- Side a
- 3 m
- You entered
This calculator finds the longest side of a right triangle — the hypotenuse — when you enter the lengths of the other two sides. It uses the Pythagorean theorem (a² + b² = c²) and returns the hypotenuse in the same unit you used for the inputs. If you have a non‑right triangle, the longest side is found with the law of cosines, which this page also explains.
Formula
For a right triangle with legs a and b, the hypotenuse c is:
c = √(a² + b²)
Where:
- a = length of one leg (any unit, as long as both legs use the same unit)
- b = length of the other leg
- c = hypotenuse, the side opposite the right angle and the longest side
This formula works only for right triangles (one angle exactly 90°). For other triangles, use the law of cosines: c² = a² + b² − 2ab·cos(C), where C is the angle between sides a and b.
Worked Example
Using the default values from the calculator: a = 3 m, b = 4 m.
- Square both legs: 3² = 9, 4² = 16.
- Add: 9 + 16 = 25.
- Take the square root: √25 = 5.
The hypotenuse is 5 m — exactly what the calculator shows. This is the classic 3‑4‑5 triangle, often used in construction to check right angles.
When to Use This Calculator
Use it any time you need the longest side of a right triangle:
- Finding the length of a ramp, ladder, or diagonal brace.
- Computing the diagonal of a rectangle or square (the diagonal divides the rectangle into two right triangles).
- Checking if a corner is square by measuring 3 and 4 units along the edges and verifying the diagonal is 5 units.
- Solving geometry homework or design problems where two sides of a right triangle are known.
If you have a triangle that is not right‑angled, you need the included angle between the two known sides and the law of cosines. Many online triangle calculators handle that case; this one is specifically for right triangles.
How to Read the Result
The result is the length of the hypotenuse in the same unit you entered. If you enter meters, you get meters; if you enter feet, you get feet. The calculator also shows the angle opposite side a (in degrees) and the area of the triangle, which can be useful for checking your work or for follow‑up calculations.
Remember that the hypotenuse is always the longest side, so your answer should be larger than both inputs. If it isn’t, you likely entered the wrong values or the triangle is not right‑angled.
Common Mistakes to Avoid
- Using different units for the two legs. Both sides must be in the same unit. Convert first if needed.
- Applying the Pythagorean theorem to non‑right triangles. It only works when one angle is exactly 90°.
- Confusing legs and hypotenuse. The hypotenuse is always opposite the right angle; the two shorter sides are the legs.
- Forgetting to take the square root. The sum of squares gives c², not c.
- Rounding too early. If you round intermediate values, the final result can be off. Keep full precision until the end.
Limits of the Formula
The Pythagorean theorem is exact and simple, but it has limits:
- It applies only to Euclidean (flat) geometry. On a sphere or curved surface, the relationship changes.
- It gives the length of the hypotenuse, not the angles (except indirectly). For angles, you need trigonometric functions.
- It assumes the triangle is perfectly right‑angled. In real‑world measurements, small errors can make the angle slightly off, so the result is an approximation.
For non‑right triangles, the law of cosines is the correct tool. It requires knowing the angle between the two known sides, which adds a measurement step.
Alternatives and Related Calculations
If you have different information, other calculators may be more useful:
- One leg and one angle: Use sine or cosine to find the hypotenuse. For example, if you know angle A and adjacent leg b, then c = b / cos(A).
- Hypotenuse and one leg: To find the missing leg, rearrange the theorem: a = √(c² − b²).
- Non‑right triangle: Use the law of cosines with the included angle.
- Area of a right triangle: Area = (a × b) / 2, which the calculator already shows.
Frequently Asked Questions
Q: Can I use this for any triangle?
No. The Pythagorean theorem only works for right triangles. For other triangles, use the law of cosines, which requires the angle between the two known sides.
Q: What if I only know the hypotenuse and one leg?
Rearrange the formula: missing leg = √(hypotenuse² − known leg²). You can use the same calculator by entering the known leg as a and the hypotenuse as b — but the result will be the other leg, not the hypotenuse. Better to use a dedicated missing‑side calculator.
Q: Does the unit matter?
Only that both legs use the same unit. The result will be in that unit. If you mix meters and centimeters, convert first.
Q: How do I find the longest side of a non‑right triangle?
Use the law of cosines: c² = a² + b² − 2ab·cos(C). You need the lengths of two sides and the included angle. The longest side is opposite the largest angle.
Q: Why is the hypotenuse always the longest side?
In a right triangle, the hypotenuse is opposite the 90° angle, which is the largest angle. The side opposite the largest angle is always the longest side.
Q: What is a 3‑4‑5 triangle?
A right triangle with legs 3 and 4 and hypotenuse 5. It’s a common example because all sides are whole numbers. Construction workers use it to verify right angles by measuring 3 and 4 along two edges and checking that the diagonal is 5.
Related
Formula used
in a | Side a | m | 3 | 0 in b | Side b | m | 4 | 0 out c | Hypotenuse | m | sqrt(a^2 + b^2) | 2 out angle | Angle opposite a | deg | atand(a/b) | 1 out area | Area | m^2 | (a * b) / 2 | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.