The sine rule and the cosine rule

a / sin A = b / sin B = c / sin C, and a² = b² + c² − 2bc · cos A: which one to use, how to solve any triangle, and a solver that draws the result.

High school Lesson 9 of 9 Interactive figure Practice

First, the rules

For triangles that are not right-angled

Side a is across from angle A, b from B, c from C. Pythagoras and SOH-CAH-TOA need a right angle; these two rules work in every triangle.

★ The sine rule
Example 2
asin A = bsin B = csin C
Each side divided by the sine of its opposite angle gives the same number (the diameter of the circumscribed circle, 2R).
Use it when…
you know two angles and one side (ASA, AAS), or two sides and the angle opposite one of them (SSA — beware, two triangles may fit).
Angles add to 180°
Example 2
A + B + C = 180°
Two angles given means the third is free.
★ The cosine rule
Example 1
a² = b² + c² − 2bc · cos A
Also b² = a² + c² − 2ac cos B and c² = a² + b² − 2ab cos C. With A = 90°, cos A = 0 and it is Pythagoras.
Use it when…
you know two sides and the angle between them (SAS), or all three sides (SSS — solve for the cosine of an angle).
Angle from three sides
Example 1
cos A = b² + c² − a²2bc
A negative cosine means an obtuse angle.

See it

Solve a triangle and watch it drawn to scale

Pick what you know — three sides, two sides and the included angle, or two angles and a side — type the numbers and the rest is computed with the rules above and drawn to scale. Impossible triangles are refused with the reason.

Step by step

Worked examples

1

A side across an obtuse angle

cosine rule twice

D is on AB and E on AC with |AD| = 3, |AE| = 2, |DE| = 4; |AB| = 6, |AC| = 8. Find |BC|.

ABCDE32468x

Drawn with the real measurements: angle A really is obtuse.

Ask yourself: Are the triangles similar? Check 3/6 against 2/8 — they differ, so no. Both triangles share angle A: find cos A in the small one, use it in the big one.

Show the solution
  1. Cosine rule in ADE: 4² = 3² + 2² − 2 · 3 · 2 · cos A, so 16 = 13 − 12 cos A and cos A = −14 (A is obtuse).
  2. Cosine rule in ABC with |AB| = 6, |AC| = 8: x² = 6² + 8² − 2 · 6 · 8 · (−14) = 100 + 24 = 124.
  3. x = √124 = √4 · 31 = 2√31 ≈ 11.1.

Answer |BC| = 2√31

2

A side from two angles and a side

sine rule

In triangle ABC, B = 75°, C = 60° and c = 4√3. Find a.

75°60°BCA4√3a

Ask yourself: Which angle is opposite a? Do you know it? (A, from the angle sum.)

Show the solution
  1. A = 180° − 75° − 60° = 45°.
  2. Sine rule, side over the sine of its opposite angle: asin 45° = 4√3sin 60°.
  3. Insert the values: a√2/2 = 4√3√3/2 = 8.
  4. a = 8 · √22

Answer a = 4√2

3

Which rule?

choosing

You are given (i) sides 5, 7 and the 60° angle between them; (ii) sides 4, 6, 8; (iii) angles 40°, 65° and the side between them 10. Which rule solves each, and what comes out first?

Ask yourself: Count what you have: two sides + included angle, three sides, or two angles + a side.

Show the solution
  1. (i) SAS → cosine rule for the third side: a² = 25 + 49 − 2 · 5 · 7 · 12 = 39, a = √39.
  2. (ii) SSS → cosine rule for an angle, say the one opposite 8: cos = 16 + 36 − 642 · 4 · 6 = −14, an obtuse angle.
  3. (iii) ASA → third angle 75°, then the sine rule: asin 40° = 10sin 75° and the same for the other side.

Answer cosine · cosine · sine

Practice: sine and cosine rules

0 / 0

Special angles only, so every answer is exact — a side like 4√2, or a cosine like −1/4. Your best score is kept in this browser only.

About this lesson

The law of sines and the law of cosines for triangles that are not right-angled: when to use each, how the cosine rule contains Pythagoras as the special case A = 90°, and how to solve a triangle from three sides, two sides and the included angle, or two angles and a side. Enter your values, see the solved triangle drawn to scale, and practise with exact values.

Part of Learn mathematics · unit Triangles. Check a number with the scientific calculator or draw a function with the function plotter. Everything on this page runs in your browser; nothing you type is sent or stored, and your practice score stays in this browser only. Spotted an error? Tell us.