Skip to content

Pythagorean Theorem Calculator

Enter the two sides you know of a right triangle to find the third with a² + b² = c². Choose whether the missing side is the hypotenuse c or one of the legs a and b.

Calculator Details

Area:6 sq unitsSee results ↓

Use when you know two sides of a right triangle

Pythagorean method only: the hypotenuse c, or leg a or b

One leg of the right triangle

Other leg of the right triangle

Your Results

Area: 6 sq units

Area

6 sq units

Scalene right triangle, perimeter 12 units

Perimeter

12 units

By angles

Right Triangle

By sides

Scalene

Compare scenarios

Save these inputs as a scenario, change them, and compare the results side by side.

Loading, available in a moment

Detailed Breakdown

Sides and angles of your triangle
VertexAngleOpposite side
A36.87° (solved)a = 3 (given)
B53.13° (solved)b = 4 (given)
C90° (solved)c = 5, hypotenuse (solved)
Total180°Perimeter 12

Area 6 square units; semiperimeter 6.

How This Calculator Works

How It's Calculated

Your triangle (PYTHAGOREAN)

c = √(a² + b²) = √(3² + 4²) = 5
Area = a × b ÷ 2 = 6
  • Pythagorean theorem (right triangles): a² + b² = c², where c is the hypotenuse.
  • Law of cosines: c² = a² + b² − 2ab·cos(C). Finds a side from two sides and the angle between them (SAS), or the angles from three sides (SSS).
  • Law of sines: a/sin(A) = b/sin(B) = c/sin(C). Finds the sides once two angles are known (ASA, AAS).
  • Heron's formula: Area = √[s(s − a)(s − b)(s − c)] with s = (a + b + c)/2.
  • Shoelace formula (from coordinates): Area = |x1(y2 − y3) + x2(y3 − y1) + x3(y1 − y2)| / 2; the sign of the sum shows whether the corners run counter-clockwise (+) or clockwise (−).

Frequently Asked Questions

How do I find a leg when I know the hypotenuse?

Rearrange the theorem to b = √(c² − a²). With a hypotenuse of 10 and one leg of 6, the other leg is √(100 − 36) = √64 = 8. Choose leg b as the unknown side and enter c and a; the hypotenuse must be longer than the leg you give, or no right triangle exists.

Does the Pythagorean theorem work for every triangle?

No, only for triangles with a 90° angle. For any other triangle the law of cosines, c² = a² + b² − 2ab·cos C, takes its place; when C is 90° the cosine is 0 and it reduces to the Pythagorean theorem. The triangle calculator handles the general case.

How do builders use 3-4-5 to check a square corner?

Measure 3 units along one wall from the corner and 4 units along the other, then measure between the two marks. If the diagonal is exactly 5, the corner is 90°, because 3² + 4² = 5². Bigger multiples of the same triple, such as 6-8-10 or 9-12-15 feet, are more accurate on large slabs and decks. Other whole-number triples, like 5-12-13 and 8-15-17, work the same way.

Can I use the theorem to find a distance on a map or screen?

Yes. The straight-line distance between two points is the hypotenuse of a right triangle whose legs are the horizontal and vertical differences. Moving 3 blocks east and 4 north puts you 5 blocks from where you started, and a screen 16 inches wide and 9 tall has a diagonal of √337 ≈ 18.36 inches.

Solves flat (Euclidean) triangles from two sides of a right triangle, SSS, SAS, ASA or AAS, or the coordinates of the three corners (shoelace formula), with angles in degrees. Results are rounded to 10 significant digits. Not included: the ambiguous SSA case (two sides and a non-included angle), spherical triangles, radians, and units (sides are in whatever unit you use).

Pythagorean Theorem Calculator: Find the Missing Side

By FindMySum · Last reviewed

The Pythagorean theorem says that in a right triangle the square on the hypotenuse equals the sum of the squares on the two legs: a² + b² = c². This Pythagorean theorem calculator uses it to find whichever side is missing, then works out the two acute angles, the area and the perimeter, so you can check a homework answer, a roof pitch or a carpentry layout in one step.

Worked example

Take the classic triangle with legs a = 3 and b = 4, and solve for the hypotenuse c:

  1. Square the legs: 3² = 9 and 4² = 16.
  2. Add them: 9 + 16 = 25.
  3. Take the square root: c = √25 = 5.

With all three sides known, the rest follows. The area of a right triangle is half the product of the legs, 3 × 4 ÷ 2 = 6 square units, and the perimeter is 3 + 4 + 5 = 12 units. The angle opposite the leg of 3 is arctan(3/4) ≈ 36.87°, the angle opposite the leg of 4 is about 53.13°, and the two add to 90° as they must.

Which side is which

The hypotenuse is always the side opposite the right angle and always the longest. The legs are the two sides that form the right angle, and it does not matter which one you call a. Mixing them up is the most common error: if you put the longest side in as a leg and solve for "c", you get a number that is too large, and the check that c is longer than both legs fails.

Answers are usually irrational. Legs of 1 and 1 give a hypotenuse of √2 ≈ 1.4142, which is why the calculator shows decimals. For the angle-based shortcuts of 30-60-90 and 45-45-90 triangles, see the special right triangles calculator; for triangles without a right angle, use the triangle calculator.

Sources

This article explains how the calculator works and is general information, not financial, tax, legal or medical advice. Rules change; check the sources above or a qualified professional before you act.

Spotted a wrong result or a bug? Report a problem

May we count your visits with Invoker Analytics? It keeps a random visitor number in your browser. Your calculator inputs are never sent. Privacy policy