Hypotenuse Calculator: Find Side c Easily
- Angle A (opposite a)
- degrees
- Result
- Angle B (opposite b)
- degrees
- Result
- Side a
- 3 m
- You entered
This hypotenuse calculator works out the longest side of a right-angled triangle using the Pythagorean theorem. You enter the lengths of the two shorter sides (a and b), and it returns the hypotenuse (c) in the same unit you used. The calculator also shows the formula and a step-by-step example so you can check your own working.
Formula
The Pythagorean theorem states that in a right-angled triangle, the square of the hypotenuse (the side opposite the right angle) equals the sum of the squares of the other two sides. The formula is:
c² = a² + b²
To find the hypotenuse itself, take the square root of both sides:
c = √(a² + b²)
Where:
- c = hypotenuse (the longest side, opposite the 90° angle) – in metres (m) or any unit you choose
- a = one leg (short side) – same unit as c
- b = the other leg (short side) – same unit as c
The calculator also gives the two acute angles using inverse tangent: angle A = tan�¹(a/b) and angle B = tan�¹(b/a). These are useful if you need the full triangle, not just the hypotenuse.
Worked Example
Using the default values from the calculator (a = 3 m, b = 4 m):
- Square each side: a² = 3² = 9, b² = 4² = 16
- Add them: 9 + 16 = 25
- Take the square root: √25 = 5
- So c = 5 m
The calculator shows c = 5.00 m, which matches. The angles are: A = atan(3/4) ≈ 36.9°, B = atan(4/3) ≈ 53.1°. Notice that A + B = 90°, as expected for a right triangle.
When to Use a Hypotenuse Calculator
You need the hypotenuse whenever you know two sides of a right triangle and want the third. Common real-world situations include:
- Finding the length of a ladder needed to reach a certain height against a wall (ladder = hypotenuse, wall height = a, distance from wall = b)
- Calculating the diagonal of a TV screen, monitor, or photo frame from its width and height
- Determining the shortest distance across a rectangular field or room (the diagonal)
- Checking if a corner is square – if a² + b² = c², the angle is exactly 90°
- Construction and carpentry: laying out foundations, roofs, or stair stringers
The theorem only works for right triangles. If your triangle does not have a 90° angle, you need the law of cosines instead: c² = a² + b² − 2ab·cos(C).
How to Read the Result
The hypotenuse is always the longest side, so the result should be larger than both a and b. If it isn’t, you likely entered the wrong numbers or the triangle isn’t right-angled. The unit of c is the same as the units you used for a and b – if you enter feet, you get feet; if you enter centimetres, you get centimetres. The calculator does not convert units, so make sure both inputs are in the same unit before you press calculate.
The angles are given in degrees. Angle A is opposite side a, and angle B is opposite side b. They will always sum to 90° because the third angle is 90°.
Common Mistakes and Pitfalls
Even with a calculator, errors happen. Watch out for:
- Mixing units: Entering a in metres and b in centimetres gives a nonsense result. Convert first.
- Using the wrong sides: The hypotenuse is always opposite the right angle. If you enter the hypotenuse as one of the legs, the square root of a negative number appears (or an error).
- Rounding too early: If you round a and b before squaring, the final c can be off. Keep full precision until the end.
- Forgetting the square root: Some people stop at a² + b². That gives c², not c. Always take the square root.
- Assuming any triangle: The Pythagorean theorem only applies to right triangles. For acute or obtuse triangles, it fails.
Also note that the formula works for any positive numbers, but if a = 0 or b = 0, the triangle degenerates into a line – the calculator will still return the other side as the hypotenuse, which is mathematically correct but not a real triangle.
Comparison with Other Triangle Calculators
This hypotenuse calculator is a subset of a right-triangle calculator. A full right-triangle calculator typically lets you enter any two values (sides or angles) and finds the rest. Our calculator focuses on the most common case: you have both legs and want the hypotenuse. If you have one leg and the hypotenuse, you can rearrange the formula to find the missing leg: a = √(c² − b²). You can use this calculator by entering the known leg and the hypotenuse as a and b, but note that the output will be labelled as the hypotenuse – so it’s better to do the rearrangement manually or use a dedicated leg calculator.
For non-right triangles, use a law of cosines calculator. For circles, you might need a different tool entirely. Always match the calculator to the triangle type.
Limits of the Formula
The Pythagorean theorem is exact for ideal Euclidean geometry. In the real world, measurements have errors, and a physical “right angle� is rarely perfect. The calculator gives a theoretical result based on the numbers you enter – it cannot account for measurement uncertainty or material properties. For construction, always add a safety margin (e.g., for a ladder, add extra length for overhang). Also, the theorem assumes a flat plane; on a curved surface (like the Earth’s surface over long distances), it does not apply.
For very large numbers, the squares can become huge, but the calculator handles them within normal floating-point limits. For very small numbers, rounding may occur – the output shows two decimal places by default, but you can change that in the calculator block if you need more precision.
Frequently Asked Questions
Can I use this calculator if I only know one leg and the hypotenuse?
Yes, but you need to rearrange the formula. If you know a and c, then b = √(c² − a²). You can enter a as the known leg and b as the hypotenuse, but the output will be labelled as the hypotenuse – which is not what you want. Better to do the calculation manually: square the hypotenuse, subtract the square of the known leg, and take the square root.
What if my triangle is not a right triangle?
Then the Pythagorean theorem does not apply. Use the law of cosines: c² = a² + b² − 2ab·cos(C), where C is the angle between sides a and b. You need to know that angle.
Why is the hypotenuse always the longest side?
Because the sum of the squares of the two legs equals the square of the hypotenuse. Since squares are always positive, c² is larger than either a² or b², so c is larger than a and b. This is a direct consequence of the theorem.
What units should I use?
Any unit you like – metres, feet, inches, miles, etc. Just make sure both a and b are in the same unit. The result will be in that same unit. The calculator does not convert between units.
Can I use this for a 3D diagonal?
No, for a rectangular box, the space diagonal is √(l² + w² + h²) – you need three dimensions. You can use this calculator twice: first find the diagonal of a face (e.g., √(l² + w²)), then use that as one leg and the height as the other leg to find the space diagonal.
Does the order of a and b matter?
No, because addition is commutative – a² + b² is the same as b² + a². The hypotenuse will be the same regardless of which leg you call a and which you call b. The angles, however, will swap: angle A is opposite side a, so if you swap, the angles swap too.
Related
Formula used
in a | Side a | m | 3 | 0 in b | Side b | m | 4 | 0 out c | Hypotenuse (c) | m | sqrt(a^2 + b^2) | 2 out angle_a | Angle A (opposite a) | degrees | atand(a / b) | 1 out angle_b | Angle B (opposite b) | degrees | atand(b / a) | 1
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.