Skip to content
Daily Dose of Utilities

Pythagorean Theorem & Right Triangle Calculator

In a right triangle, a² + b² = c², where c is the hypotenuse. With legs of 3 and 4, c = √(9 + 16) = √25 = 5. The angles are 36.87° and 53.13°.

a² + b² = c²

Enter any two sides and leave the third empty.

a

3

b

4

c

5

Angle A

36.87°

Angle B

53.13°

Area

6

Perimeter

12

abcA 36.9°B 53.1°

Show the math

  1. 1

    Hypotenuse: c = √(a² + b²)

    √(3² + 4²) = √(9 + 16) = √25 = 5

    Pythagoras' theorem: the squares of the two shorter sides add up to the square of the longest side.

    = c = 5

Read the steps as text
  1. Hypotenuse: c = √(a² + b²). √(3² + 4²) = √(9 + 16) = √25 = 5 Pythagoras' theorem: the squares of the two shorter sides add up to the square of the longest side.
  2. Angles. A = sin⁻¹(a ÷ c) = sin⁻¹(3 ÷ 5) = 36.8699° · B = 90° − 36.8699° = 53.1301° The two acute angles of a right triangle always add up to 90°.
  3. Area = ½ × a × b. ½ × 3 × 4 = 6 The two legs are the base and height.
  4. Perimeter = a + b + c. 3 + 4 + 5 = 12

Pythagoras' theorem

In any right triangle, the square of the hypotenuse (the longest side, opposite the right angle) equals the sum of the squares of the other two sides: a² + b² = c². To find the hypotenuse, add the squares of the legs and take the square root. To find a missing leg, subtract the known leg's square from the hypotenuse's square, then take the square root.

Some whole-number combinations work out exactly, and are called Pythagorean triples: 3-4-5, 5-12-13, 8-15-17 and 7-24-25 are the best known. Builders use 3-4-5 to check corners are square: measure 3 feet along one wall and 4 along the other, and the diagonal should be exactly 5.

Angles, area and perimeter

Once all three sides are known, trigonometry gives the angles. Angle A, opposite side a, is sin⁻¹(a ÷ c); the other acute angle is 90° minus that, since a triangle's angles add up to 180° and one is already 90°.

The two legs are perpendicular, so they are the base and height: area = ½ × a × b. The perimeter is simply a + b + c.

Frequently asked questions

How do I find the hypotenuse?
Square both legs, add them and take the square root. With legs of 5 and 12: √(25 + 144) = √169 = 13.
How do I find a missing leg?
Subtract the square of the known leg from the square of the hypotenuse, then take the square root. With a hypotenuse of 17 and a leg of 8: √(289 − 64) = √225 = 15.
Does the Pythagorean theorem work for every triangle?
Only for right triangles, with one 90° angle. For other triangles, use the law of cosines, c² = a² + b² − 2ab·cos(C), which reduces to Pythagoras when C = 90°.
How do I find the diagonal of a rectangle or TV screen?
The diagonal is the hypotenuse of a right triangle formed by the width and height. A 16 × 9 rectangle has a diagonal of √(256 + 81) = 18.36.

Related tools