Skip to content
CalcWorld

Browse all tools

Triangle Calculator

This triangle calculator solves a triangle from three known parts, at least one of them a side, with the law of sines and the law of cosines. Sides of 7, 8 and 9 give angles of 48.19°, 58.41° and 73.40° and an area of 26.833.

Sources: OpenStax Algebra and Trigonometry 2e Updated

Calculate all properties of a triangle by entering known values. Select your calculation method below based on what information you have.

Select Calculation Method

Which rule finds the missing sides and angles of a triangle

You knowCaseStart with
Three sidesSSSLaw of cosines for the angles
Two sides and the angle between themSASLaw of cosines for the third side
Two angles and the side between themASAAngle sum, then the law of sines
Two angles and another sideAASAngle sum, then the law of sines
Two sides and an angle not between themSSALaw of sines (may have two answers or none)

The law of cosines is c² = a² + b² − 2ab cos C. The law of sines is a ÷ sin A = b ÷ sin B = c ÷ sin C.

How to solve a triangle from three sides: 7, 8 and 9

  1. Check it is a triangle: 7 + 8 = 15 is more than 9.
  2. Angle A: cos A = (8² + 9² − 7²) ÷ (2 × 8 × 9) = 96 ÷ 144 = 0.6667, so A = 48.19°.
  3. Angle B: cos B = (7² + 9² − 8²) ÷ (2 × 7 × 9) = 66 ÷ 126 = 0.5238, so B = 58.41°.
  4. Angle C: 180° − 48.19° − 58.41° = 73.40°.
  5. Area by Heron's formula: s = (7 + 8 + 9) ÷ 2 = 12, and A = √(12 × 5 × 4 × 3) = √720 ≈ 26.833.
  6. Perimeter: 7 + 8 + 9 = 24.
Triangle calculator example drawn to scale: sides a = 7, b = 8 and c = 9, angles A = 48.19°, B = 58.41° and C = 73.4°, half-perimeter s = 12 and area √720 = 26.833.
The largest angle, C, is opposite the longest side, c = 9. That is a quick check on any solved triangle.

With a base and a perpendicular height instead of three sides, the triangle area calculator is quicker. If one angle is 90°, the right triangle calculator uses Pythagoras directly.

Why SSA can have two answers or none

With two sides and an angle that is not between them, the unknown side can sometimes swing to two positions that both fit, or be too short to reach at all.

The calculator shows a "no solution" message when the sine it needs comes out above 1, or when the third angle would be zero or negative. When two triangles fit, it reports one of them, so check the other if your problem allows it.

Reading the diagram

The diagram under the results scales the triangle so its longest side fits in 200 pixels and places C using the angle at A. It is a quick check that the shape looks right, not a measured drawing.

For a shape with more than three corners, enter the coordinates in the polygon area calculator instead.

Questions about solving triangles

How many values do I need to solve a triangle?

Three, and at least one of them must be a side. Three angles fix the shape but not the size, so they are not enough.

When do I use the law of cosines instead of the law of sines?

Use the law of cosines when you know three sides (SSS) or two sides and the angle between them (SAS). Use the law of sines when you know an angle and the side opposite it, as in ASA, AAS and SSA.

Do the angles of a triangle always add up to 180°?

Yes, in a flat triangle. Once two angles are known, the third is 180° minus their sum: 180° − 48.19° − 58.41° = 73.40°.

How do you find the missing side of a triangle?

It depends on what you know. In a right triangle, Pythagoras gives it: c² = a² + b², where c is the side opposite the right angle. With two angles and a side, find the third angle from the 180° sum, then use the law of sines.

With two sides and the angle between them, use the law of cosines. Sides 7 and 8 with 73.40° between them give c² = 7² + 8² − 2 × 7 × 8 × cos 73.40° ≈ 81, so c ≈ 9.

How do you find the height of a triangle?

Double the area and divide by the side you take as the base: h = 2 × area ÷ base. For the triangle with sides 7, 8 and 9, the area is 26.833, so the height onto the side of 9 is 2 × 26.833 ÷ 9 ≈ 5.963. The calculator gives the area, so this works for any triangle it solves.

Sources