Guide
Solving triangles: right triangles, SSS, SAS and ASA
Triangles are the basic shape of surveying, roofing, navigation and trigonometry, and most real problems give you only some of the measurements. This calculator takes whatever combination you have, six modes in all, and completes the triangle: all three sides, all three angles, the area, the perimeter, the three altitudes, the inscribed and circumscribed circles and a drawing made to scale.
Choosing the mode
Under I know, choose a right triangle from both legs, from a leg and the hypotenuse, or from one leg and one acute angle, or a general triangle from three sides (SSS), two sides and the angle between them (SAS), or two angles and the side between them (ASA). Only the relevant fields appear. In the right-triangle modes the right angle is at C, the legs are a and b and c is the hypotenuse; in the general modes angle A is opposite side a, B opposite b and C opposite c.
The mathematics
For right triangles the tool uses Pythagoras, a² + b² = c², and the angle from atan(a/b). For SSS it applies the law of cosines to find each angle, A = arccos((b² + c² − a²) / 2bc), and Heron’s formula for the area, √(s(s − a)(s − b)(s − c)) with s the half-perimeter. SAS finds the third side by the law of cosines and then solves as SSS, and ASA uses the third angle, 180° minus the two given, and the law of sines for the sides.
Reading the results
The rows show the sides, the angles in degrees, the type (equilateral, isosceles or scalene, and acute, right or obtuse), the area, the perimeter, the altitudes to each side, the inradius, the circumradius and, when all sides are whole numbers that satisfy a² + b² = c², a note that they form a Pythagorean triple. A drawing places C at the left, B along the base and A above, labelled with the sides, and downloads as SVG or PNG.
Worked examples
Legs 3 and 4 give c = 5, angles 36.869898° and 53.130102°, area 6, perimeter 12, altitudes 4, 3 and 2.4, inradius 1 and circumradius 2.5. A leg of 5 with hypotenuse 13 gives the other leg 12, angles 22.619865° and 67.380135° and area 30. A leg of 10 opposite a 75° angle gives the other leg 2.67949 and hypotenuse 10.3528, which is useful for a ladder or ramp. Sides 5, 6 and 7 give an acute triangle of area 14.6969 with angles 44.415309°, 57.12165° and 78.463041°. Sides 8 and 5 with a 60° angle between them give the third side 7 and area 17.3205.
Edge cases
Angles in the right-triangle angle mode must be between 0° and 90°, and for ASA the two angles must add to less than 180°. A hypotenuse must be longer than either leg. The case with two sides and an angle that is not between them (SSA) can have zero, one or two solutions, so it is not included. Tiny or huge values work, but very different sizes make an unreadable drawing.
Using it for real jobs
A roofer who knows the run and the pitch angle can find the rafter length with the leg-and-angle mode, a surveyor with three measured distances can use SSS to find the angle at a corner, and a navigator with two bearings and a distance can use ASA. Remember that the results are as exact as the inputs: measure to the precision you need and keep the same unit for every length. The area comes out in that unit squared.
Limits
The tool solves flat (Euclidean) triangles only, not triangles on a sphere. It does not solve the ambiguous SSA case and it does not check that measured angles from a real survey are consistent. For three sides it trusts the triangle inequality, and angles are shown to eight significant digits. Results are rounded for display but computed in double precision.
Related tools
- Circle Calculator takes over when the shape is round, with arcs and chords.
- Volume Calculator builds solids from triangular and circular faces.
- Scientific Calculator offers sine, cosine and tangent for checking an angle by hand.
- Golden Ratio Calculator uses the same side-ratio thinking for design.
Checked against the current version of the Triangle Calculator on .

