1. Home
  2. Calculate
  3. Pythagorean Theorem Calculator

Pythagorean Theorem Calculator

Find the missing side, angles and area, or test for a right triangle.

Runs in your browser · No upload
Hypotenuse c
5
c = √(a² + b²)
Area
6
Perimeter
12
Angle A (opposite a)
36.869898°
Angle B (opposite b)
53.130102°
Altitude to the hypotenuse
2.4
Inradius
1
The three integer sides satisfy a² + b² = c², a Pythagorean triple. They share no common factor, so it is a primitive triple.

Use any unit (cm, m, in), as long as all sides use the same one.

How to use

  1. In Find a missing side, choose which side you want: the hypotenuse c, side a or side b.
  2. Enter the other two sides. Any unit works (cm, m, inches), as long as all sides use the same one.
  3. Along with the missing side you get the area, perimeter, both acute angles, the altitude to the hypotenuse and the inradius.
  4. If you only know three side lengths and want to know whether they form a right triangle, switch to Is it a right triangle?. It also tells you whether the triangle is acute or obtuse.

The Pythagorean theorem

In a right triangle, call the two sides that meet at the right angle a and b, and the longest side (the hypotenuse) c. Then:

a² + b² = c²

To find Formula
Hypotenuse c √(a² + b²)
Side a √(c² − b²)
Side b √(c² − a²)
Area a × b ÷ 2
Angle A (opposite a) arctan(a ÷ b)
Altitude to the hypotenuse a × b ÷ c
Inradius (a + b − c) ÷ 2

The hypotenuse is always longer than either leg, so when you solve for a or b the hypotenuse you enter must be larger than the other side. If it is equal or smaller, no right triangle exists and you get an error.

Examples

Situation Working Result
Legs 3 and 4 √(9 + 16) Hypotenuse 5
Hypotenuse 13, one leg 5 √(169 − 25) Other leg 12
Legs 1.5 and 2 √(2.25 + 4) Hypotenuse 2.5
Hypotenuse 10, one leg 6 √(100 − 36) Other leg 8
Screen 1920 wide, 1080 tall √(1920² + 1080²) Diagonal about 2,202.91

The angles of a 3-4-5 triangle are about 36.87° and 53.13°, with area 6 and perimeter 12. A 55-inch 16:9 TV is roughly 47.94 inches wide and 26.96 inches tall (the 55-inch diagonal split in a 16:9 ratio).

Pythagorean triples

A set of three whole numbers that satisfy a² + b² = c² is called a Pythagorean triple. (3, 4, 5), (5, 12, 13), (8, 15, 17) and (7, 24, 25) are the best known, and multiples such as (6, 8, 10) count too. When the three numbers share no common factor the triple is called primitive, and the tool tells you when your result is one.

Things to keep in mind

  • The theorem only holds for right triangles. For other triangles you need the law of cosines.
  • Angles are shown in degrees. Very large or very small lengths are computed within floating-point limits, and results show up to 6 decimal places.
  • The right-triangle check allows a relative tolerance of one part in a billion, so decimal sides like 0.3, 0.4, 0.5 are recognised as a right triangle.
  • If all three sides are already known, use the check mode instead of the solver.

For areas and perimeters of other shapes see the shape area calculator, and for expressions with trigonometry use the scientific calculator.

FAQ

Which side is the hypotenuse?

The longest side, opposite the right angle. The two sides that form the right angle are a and b, and the hypotenuse is c.

Can I get the angles from two sides?

Yes. Angle A is arctan(a ÷ b) and angle B is arctan(b ÷ a). They always add up to 90°.

Is 3, 4, 6 a right triangle?

No. 9 + 16 = 25, but 6² = 36. Because the square of the longest side is bigger, the triangle is obtuse.

Is my input stored anywhere?

No. Your numbers are processed in your browser only and never sent to a server.

Can't find the tool you need?

Tell us what you want to do. We build the most requested tools first.