Trigonometry

Law of Cosines and Law of Sines: Arbitrary Triangles

How did ancient Egyptians measure the height of pyramids without a tape measure? How does GPS determine a position to within a meter? How do 3D engines compute distances between objects? The laws of sines and cosines.

  • Surveying and cartography: triangulation - measuring distances through angles
  • GPS: computing position from signal delays - generalized triangulation
  • 3D graphics: ray-triangle intersection uses the Law of Cosines
  • Astronomy: stellar distances via parallax and the Law of Sines

Предварительные знания

  • Law of Sines and Cosines
  • Trigonometry in Physics

Law of Cosines: generalizing the Pythagorean theorem

The Pythagorean theorem only works for right triangles. The Law of Cosines generalizes it to any triangle: c² = a² + b² - 2ab·cos(C), where C is the angle between sides a and b.

**Law of Cosines:** For a triangle with sides a, b, c and opposite angles A, B, C: c² = a² + b² - 2ab·cos C **Special case:** When C = 90°: cos 90° = 0, giving the Pythagorean theorem c² = a² + b². **Usage:** Know three sides → find any angle: cos C = (a² + b² - c²) / (2ab)

In a triangle a=5, b=7, angle C=60°. What is side c?

Law of Sines and area formulas

**Law of Sines:** a/sin A = b/sin B = c/sin C = 2R, where R is the circumradius. All three ratios equal the same number - the diameter of the circumscribed circle.

**Ambiguous case:** In the SSA configuration (two sides and a non-included angle) there can be 0, 1, or 2 solutions. Always check whether sin fits in [-1, 1].

In a triangle a/sin A = b/sin B. If a=8, A=30°, B=45°, then b=?

Applications: triangulation and 3D computation

The laws of sines and cosines underpin triangulation: determining the position of a point from angles to known landmarks. Used in GPS, surveying, and computer vision.

Why does computing the distance between two GPS coordinates require the spherical Law of Cosines rather than the Pythagorean theorem?

Key ideas

  • Law of Cosines: c² = a² + b² - 2ab·cos C (generalization of Pythagoras)
  • SSS → angles: cos C = (a²+b²-c²)/(2ab)
  • Law of Sines: a/sin A = b/sin B = c/sin C = 2R
  • Area = (1/2)ab·sin C = √(s(s-a)(s-b)(s-c)) (Heron's formula)
  • SSA - ambiguous case: 0, 1, or 2 triangles

Related topics

Triangle theorems unite all trigonometric knowledge:

  • Triangle trigonometry — Basic definitions of sin/cos via right triangles
  • Applications of trigonometry — Practical problems computing distances and angles

Вопросы для размышления

  • Prove the Law of Cosines using coordinates: place vertex C at the origin.
  • SSA problem: given a=5, b=7, A=30°. How many triangles exist? Find all solutions.
  • How is the area formula S = (1/2)ab·sin C related to the determinant of a 2×2 matrix?

Связанные уроки

  • la-03-cross-product
Law of Cosines and Law of Sines: Arbitrary Triangles

0

1

Sign In