← All guides

Law of sines and law of cosines, with examples

Solve any triangle, not just right ones: when to use the law of sines and when to use the law of cosines, with worked examples.

Video lesson: The law of sines (free, with subtitles)

SOH CAH TOA only works in right triangles. These two laws work in any triangle (side a is opposite angle A, and so on).

Law of sines

a / sin A = b / sin B = c / sin C

Use it when you know an angle and its opposite side, plus one more piece.

A = 40°, B = 60°, a = 10. Then C = 180° − 40° − 60° = 80°.

Law of cosines

c² = a² + b² − 2ab cos C

Use it when you know two sides and the angle between them, or all three sides.

a = 7, b = 9, C = 50°: c² = 49 + 81 − 126 × cos 50° ≈ 130 − 80.99 = 49.01, so c ≈ 7.00.

A check that it makes sense

If C = 90°, cos C = 0 and the law of cosines becomes a² + b² = c². It's Pythagoras with a correction for non-right angles.

Which one?

Practice it free

Watch the full lesson and try questions with new numbers every time, with the worked steps shown if you get one wrong.

Practice: The law of sines All courses