Is It a Right Triangle? Checker and Triangle Classifier

Type three side lengths in any order. The checker uses the converse of the Pythagorean theorem to tell you whether the triangle is right, acute or obtuse, finds all three angles and shows every step.

By the PythagoreanTheorem.net teamUpdated Free · no sign-up

Enter the three sides in any order, all in the same unit. Decimals, fractions and roots such as √2 are fine.

Right triangle

202 + 212 = 841 = 292. By the converse of the Pythagorean theorem, the angle opposite the longest side is exactly 90°. 20, 21, 29 is a Pythagorean triple, and a primitive one.

  • Angle A43.6°
  • Angle B46.4°
  • Angle C90°
  • Area210
  • Perimeter70
  • By sidesscalene
a = 20b = 21c = 29CAB

Step-by-step check

  1. Sort the sides so that c is the longest: a = 20, b = 21, c = 29
  2. Triangle inequality: the two shorter sides must add up to more than the longest: a + b = 20 + 21 = 41 > 29 ✓
  3. Square the two shorter sides and add: a2 + b2 = 400 + 441 = 841
  4. Square the longest side: c2 = 292 = 841
  5. Compare: a2 + b2 = c2, so the angle opposite c is exactly 90°
  6. Largest angle, by the law of cosines: C = arccos a2 + b2 − c2 over 2ab = arccos 0 over 840 = 90°
  7. The other two angles: A = arccos b2 + c2 − a2 over 2bc ≈ 43.6°, B = 180° − A − C ≈ 46.4°
Try 3, 4, 5, then 3, 4, 6, then 3, 4, 8.

Three lengths form a right triangle exactly when the squares of the two shorter ones add up to the square of the longest: a2 + b2 = c2. That test is the converse of the Pythagorean theorem. If a2 + b2 is larger than c2, the triangle is acute; if it is smaller, the triangle is obtuse.

How the checker decides

  1. Sort the sides. Call the longest one c. Only the angle opposite the longest side can be 90° or more.
  2. Test the triangle inequality. The two shorter sides must add up to more than the longest. If they don't, there is no triangle to classify.
  3. Compare the squares. a2 + b2 = c2 means right, greater means acute, and less means obtuse.
  4. Find the angles. The law of cosines turns three sides into angles: cosC = a2 + b2 − c2 over 2ab.

Look at the top of that last fraction, a2 + b2 − c2. When it is zero, cosC = 0 and C = 90°; when it is positive, C is acute; when it is negative, C is obtuse. The squares test and the law of cosines are the same idea seen two ways.

The converse of the Pythagorean theorem

The Pythagorean theorem says that in a right triangle, a2 + b2 = c2. The converse turns it around: if the sides of a triangle satisfy a2 + b2 = c2, then the angle opposite c is a right angle. Both statements are true. Euclid proved the converse immediately after the theorem, as Proposition 48 of Book I of the Elements, and the converse of the Pythagorean theorem page walks through the proof.

60°: c ≈ 3.61120°: c ≈ 6.08b = 4a = 3CThe legs stay 3 and 4. Onlythe angle between them changes.Angle C = 90°c² = 25 = a² + b²Right triangleAngle C < 90°c² < a² + b²Acute triangleAngle C > 90°c² > a² + b²Obtuse triangle
Keep the legs at 3 and 4 and open the hinge. The third side is 5, with c2 = a2 + b2, only when the angle is exactly 90°. A smaller angle gives c2 < a2 + b2 (acute), a wider one c2 > a2 + b2 (obtuse).

The hinge shows why the test works. Keep two sides fixed and open the angle between them: the third side grows steadily, so exactly one opening, 90°, gives c2 = a2 + b2. Narrower openings are acute and wider ones obtuse. The acute, obtuse and right triangles lesson covers the three types in detail.

The triangle inequality comes first

Not every three numbers make a triangle. The two shorter sides have to reach each other across the longest one, so together they must be longer than it. Checking that single inequality is enough, because the other two (the longest side plus either short side, compared with the remaining side) are then automatic.

b = 4a = 3c = 93, 4, 9: no triangle3 + 4 = 7 is less than 9b = 4a = 3c = 73, 4, 7: flat3 + 4 = 7 exactly
Each short side can swing through the dashed arc. If the arcs never meet (left) there is no triangle; if they meet only on the base (right) the "triangle" is flat. They meet above the base only when a + b > c.

A set like 3, 4, 9 fails outright. A set like 3, 4, 7 is a borderline case: the "triangle" collapses into a straight line, which is called degenerate. Neither has angles worth classifying, so the checker stops at this step.

Worked examples

Example 1: 8, 15, 17

82 + 152 = 64 + 225 = 289 = 172

Right triangle. The sides form a primitive Pythagorean triple.

Example 2: 6, 7, 9

62 + 72 = 85 > 81 = 92

Acute triangle. The largest angle is arccos85 − 81 over 2 · 6 · 7 = arccos4 over 84 ≈ 87.27°.

Example 3: 5, 8, 10

52 + 82 = 89 < 100 = 102

Obtuse triangle. The largest angle is arccos89 − 100 over 80 = arccos(−11 over 80) ≈ 97.90°.

Example 4: decimals, 2.5, 6, 6.5

2.52 + 62 = 6.25 + 36 = 42.25 = 6.52

Right triangle: it is the 5-12-13 triangle at half size.

Example 5: measured sides, 1.2 m, 1.6 m and 2.01 m

1.22 + 1.62 = 4 < 4.0401 = 2.012

Strictly, this is obtuse, with a largest angle of about 90.60°. The gap is 0.0401 ÷ 4.0401 ≈ 0.99%, so with the 1% tolerance the checker reports a right triangle, a sensible verdict for everyday tape measurements.

Measurements and tolerance

Real measurements are rounded, so a corner that really is square rarely passes an exact test. The tolerance setting compares the gap between c2 and a2 + b2 as a percentage of c2. Builders use the same idea with the 3-4-5 rule: mark 3 ft along one wall and 4 ft along the other, and if the diagonal is 5 ft the corner is square. See the 3-4-5 triangle and the Pythagorean theorem in construction.

Watch outA tolerance can pass a triangle that is not right. The sides 8, 9 and 12 are within 1% (145 against 144), yet the largest angle is 89.60°. Use the smallest tolerance that fits how carefully the lengths were measured, and type exact values such as sqrt(2) when you have them.

Table: is it a right triangle?

Sidesa2 + b2c2TypeLargest angle
3, 4, 52525Right90°
6, 8, 10100100Right90°
9, 40, 411,6811,681Right90°
12, 35, 371,3691,369Right90°
1, 1, √222Right90°
4, 5, 64136Acute82.82°
7, 8, 911381Acute73.40°
8, 9, 12145144Acute89.60°
5, 6, 86164Obtuse92.87°
5, 12, 14169196Obtuse103.00°
2, 3, 41316Obtuse104.48°
3, 4, 62536Obtuse117.28°

For practice spotting these without a calculator, try the converse worksheet. To list every whole-number right triangle up to a size you choose, use the Pythagorean triples generator.

Frequently asked questions

How do you know if three sides make a right triangle?

Square all three. If the two smaller squares add up to the largest square, it is a right triangle. For 5, 12 and 13: 25 + 144 = 169, so yes.

Which side should be c?

Always the longest. The right angle, if there is one, is opposite the longest side, so testing with a shorter side as c proves nothing. The checker sorts the sides for you, so you can type them in any order.

Can a triangle have sides 3, 4 and 8?

No. The two shorter sides add up to 7, which is less than 8, so they cannot meet. This is the triangle inequality, and it is checked before anything else.

What is the difference between the Pythagorean theorem and its converse?

The theorem starts with a right angle and concludes a2 + b2 = c2. The converse starts with a2 + b2 = c2 and concludes there is a right angle. You use the theorem to find a side and the converse to test an angle.

Is 6, 8, 10 a Pythagorean triple?

Yes: 36 + 64 = 100. It is not primitive, because it is 3-4-5 doubled. Any whole-number multiple of a triple is also a triple.

What do acute and obtuse mean?

An acute triangle has all three angles less than 90°. An obtuse triangle has one angle greater than 90°. A triangle can have at most one angle of 90° or more.

Keep exploring