Pythagorean Theorem Calculator
a² + b² = c², where c is always the longest side. Leave whichever side you do not know at zero and it solves for that one.
Hypotenuse
5.0000
- Side a
- 3.0000
- Side b
- 4.0000
- Hypotenuse
- 5.0000
- Area
- 6.0000
- Perimeter
- 12.0000
- a² + b² = c², where c is always the longest side — the one opposite the right angle. Putting the hypotenuse in as a short side is the usual slip.
- It works both ways: given the hypotenuse and one side, subtract rather than add. Leave a side at zero here and it solves for that one.
- The reverse is also useful. If three measured sides satisfy a² + b² = c², the corner is square — which is how a 3-4-5 triangle squares up a foundation without a set square.
About the Pythagorean theorem
The rule holds for every right-angled triangle and only for right-angled ones: the squares on the two shorter sides add up to the square on the longest. Sides of 3 and 4 give a hypotenuse of 5, because 9 plus 16 is 25.
It works backwards just as well. Given the hypotenuse and one side, subtract instead of adding — a 5 hypotenuse with a 3 side gives 25 less 9, which is 16, so the other side is 4. Leaving a field at zero here is what tells it which way to solve.
The most practical use is checking a corner is square. Measure 3 along one wall and 4 along the other; if the diagonal between those marks is exactly 5, the corner is a right angle. Any multiple works — 6, 8 and 10 is easier on a large foundation — and it needs nothing but a tape measure.
Sets of whole numbers that satisfy it are called Pythagorean triples. 3-4-5 is the smallest, and 5-12-13, 8-15-17 and 7-24-25 are the next few. They are worth recognising because a problem built on one usually has a tidy answer.
The hypotenuse is always the longest side, so a hypotenuse shorter than one of the others is impossible. The calculator says so rather than returning the square root of a negative number.
What it works out
- The hypotenuse from two sides
- A missing side from the hypotenuse and one other
- Area and perimeter of the triangle
The formula
a² + b² = c² c = √(a² + b²) a = √(c² − b²)
Three squared is 9, four squared is 16, and together they make 25. The square root of 25 is 5, so the hypotenuse is 5.
Rearranged for a short side, it subtracts: a = √(c² − b²). With a hypotenuse of 5 and a side of 3, that is √(25 − 9), which is 4.
The subtraction is why the hypotenuse must be the longest side. If it were shorter, c² − b² would be negative and there would be no real square root — a triangle that cannot exist.
The reverse use is the one that earns its keep on site. If three measured lengths satisfy a² + b² = c², the corner between the two short sides is exactly 90 degrees. Marking 3 along one wall and 4 along another and checking the diagonal is 5 squares a room with no instrument at all.
For a right-angled triangle the area is also simple, because the two short sides are the base and height: half of 3 × 4, which is 6.
- a, b
- The two shorter sides, meeting at the right angle.
- c
- The hypotenuse — opposite the right angle, and always the longest.
A worked example
A right-angled triangle with sides of 3 and 4.
That works out to 5.0000 .
- Side a
- 3.0000
- Side b
- 4.0000
- Hypotenuse
- 5.0000
- Area
- 6.0000
- Perimeter
- 12.0000
Questions
What is the Pythagorean theorem?
In a right-angled triangle, the squares on the two shorter sides add up to the square on the longest. Sides of 3 and 4 give a hypotenuse of 5.
How do I find a missing side?
Subtract rather than add. Given a hypotenuse of 5 and a side of 3, the other is √(25 − 9) = 4. Leave the unknown field at zero here and it solves for it.
Which side is the hypotenuse?
The one opposite the right angle, and always the longest. Putting it in as a short side is the usual mistake and produces the square root of a negative number.
How do I check a corner is square?
Measure 3 units along one side and 4 along the other. If the diagonal between those marks is exactly 5, the corner is 90 degrees. Any multiple works — 6-8-10 is easier on a large space.
What is a Pythagorean triple?
Three whole numbers that satisfy the theorem. 3-4-5 is the smallest, then 5-12-13, 8-15-17 and 7-24-25. Any multiple of a triple is also one.
Does it work for triangles without a right angle?
No — it is specific to right angles. For other triangles the law of cosines does the same job, and it reduces to Pythagoras exactly when one angle is 90 degrees.
How do I find the diagonal of a rectangle?
The same way. The diagonal splits it into two right-angled triangles, so the diagonal is √(length² + width²). A 12 by 8 rectangle has a diagonal of 14.42.