Geometry & Measurement

Pythagorean Theorem Calculator

Enter any two sides of a right triangle and leave the third blank. The calculator picks the right rearrangement of a² + b² = c², shows each substitution, and checks the result. Fill all three to test whether a triangle is right-angled.

Leave blank to solve for a
Leave blank to solve for b
Leave blank to solve for c
Try an example:
Answerc = 5
  • Area of the triangle: 6
  • Perimeter: 12
Step-by-step working 4 steps
  1. 1
    The theorem
    a² + b² = c²

    a and b are the two shorter sides (legs); c is the hypotenuse, opposite the right angle.

  2. 2
    Square the legs and add
    3² + 4² = 9 + 16 = 25
  3. 3
    Take the square root
    c = √25 = 5
  4. 4
    Check
    3² + 4² = 25  and  5² = 25

How to use the pythagorean theorem calculator

  1. Enter the two sides you know.
  2. Leave the unknown side blank.
  3. Press Solve and read the substitution steps.
  4. Enter all three sides to test whether they make a right triangle.

The Pythagorean theorem

a² + b² = c²
c = √(a² + b²)
a = √(c² − b²)

It only applies to right triangles, and c is always the longest side.

Worked examples

Each example below is generated by the same calculator you used above, so the working always matches the answer.

Legs 3 and 4
Answerc = 5
  • Area of the triangle: 6
  • Perimeter: 12
Step-by-step working 4 steps
  1. 1
    The theorem
    a² + b² = c²

    a and b are the two shorter sides (legs); c is the hypotenuse, opposite the right angle.

  2. 2
    Square the legs and add
    3² + 4² = 9 + 16 = 25
  3. 3
    Take the square root
    c = √25 = 5
  4. 4
    Check
    3² + 4² = 25  and  5² = 25
Hypotenuse 13, leg 12
Answera = 5
  • Area of the triangle: 30
  • Perimeter: 30
Step-by-step working 4 steps
  1. 1
    The theorem
    a² + b² = c²

    a and b are the two shorter sides (legs); c is the hypotenuse, opposite the right angle.

  2. 2
    Rearrange for the missing leg
    a² = c² − b²
    a² = 13² − 12² = 169 − 144 = 25
  3. 3
    Take the square root
    a = √25 = 5
  4. 4
    Check
    5² + 12² = 169  and  13² = 169
Legs 5 and 7
Answerc = 8.602325
  • Area of the triangle: 17.5
  • Perimeter: 20.6023
Step-by-step working 4 steps
  1. 1
    The theorem
    a² + b² = c²

    a and b are the two shorter sides (legs); c is the hypotenuse, opposite the right angle.

  2. 2
    Square the legs and add
    5² + 7² = 25 + 49 = 74
  3. 3
    Take the square root
    c = √74 = 8.602325
  4. 4
    Check
    5² + 7² = 74  and  8.6023² = 74
Test 6, 8, 10
AnswerYes — a right triangle
Step-by-step working 3 steps
  1. 1
    The theorem
    a² + b² = c²

    a and b are the two shorter sides (legs); c is the hypotenuse, opposite the right angle.

  2. 2
    Test the sides
    a² + b² = 6² + 8² = 100
    c² = 10² = 100
  3. 3
    Compare

    Both sides are equal, so the sides satisfy the theorem.

Common mistakes to avoid

Treating the hypotenuse as a leg

c must be the longest side. When solving for a leg you subtract squares; adding them would give a length longer than the hypotenuse.

Forgetting the final square root

a² + b² gives c², not c. Take the square root at the end.

Using it on a non-right triangle

The theorem only holds when one angle is exactly 90°.

Frequently asked questions

What are Pythagorean triples?

Sets of whole numbers that satisfy the theorem, such as 3-4-5, 5-12-13 and 8-15-17. Multiples of a triple also work, like 6-8-10.

Can I use decimals?

Yes. Any positive numbers work; results are shown to six decimal places.