How this is calculated
Heron's formula gives the area from the sides alone. Let s be the semi-perimeter, (a + b + c) ÷ 2. Then area = √(s(s−a)(s−b)(s−c)).
The law of cosines gives each angle: cos(A) = (b² + c² − a²) ÷ (2bc), and similarly for the others. The three angles must sum to 180 degrees, which is a useful check on any hand calculation.
Worked example on sides 3, 4 and 5: s is 6, so the area is √(6 × 3 × 2 × 1) = √36 = 6. The angle opposite the side of length 5 has cosine (9 + 16 − 25) ÷ 24 = 0, so it is exactly 90 degrees — this is the familiar right triangle.
Why some side lengths cannot form a triangle
The triangle inequality states that the sum of any two sides must exceed the third. Sides of 1, 2 and 10 fail it: the two short sides laid end to end reach only 3, and cannot bridge the gap to close against a side of 10.
The boundary case is degenerate. Sides of 3, 4 and 7 satisfy the inequality only as an equality, producing a flattened triangle with zero area and one angle of exactly 180 degrees. Heron's formula returns zero, which is arithmetically correct and geometrically the signal that you have a straight line rather than a triangle.
Right, acute and obtuse
Compare the square of the longest side against the sum of the squares of the other two. If they are equal the triangle is right — that is the Pythagorean theorem. If the longest side squared is smaller, all angles are under 90 degrees and the triangle is acute. If larger, one angle exceeds 90 degrees and it is obtuse.
A triangle can have at most one right or obtuse angle, since the three must total 180 degrees. This is why the classification depends entirely on the longest side: only the angle opposite it can possibly be 90 degrees or more.
How to use the triangle calculator
- Enter the three side lengths. Any consistent unit. The results are in those units, with area in units squared.
- Check the classification. Right, acute or obtuse follows from comparing the longest side squared against the sum of the other two squared.
- Verify the angles sum to 180. They always will here, but it is the standard check when working a triangle by hand.