📘 Lesson 7 of 8 · Trigonometry

📐 Law of Cosines

The Law of Cosines generalizes the Pythagorean theorem to work with ANY triangle, not just right triangles — essential when you know sides but not a convenient right angle.

Course progress: 88%

01 Key Concepts

The Law of Cosines Formula

c^2 = a^2 + b^2 - 2ab*cos(C), where C is the angle opposite side c.

Relation to the Pythagorean Theorem

If C = 90°, cos(C) = 0, and the formula reduces exactly to the Pythagorean theorem: c^2 = a^2 + b^2.

When to Use It

Use the Law of Cosines when you know: all three sides (SSS), or two sides and the included angle (SAS).

Finding a Missing Side

Plug the two known sides and included angle directly into the formula to solve for the third side.

Finding a Missing Angle

Rearrange the formula to solve for cos(C), then take the inverse cosine to find the angle.

02 Key Formulas

03 Solved Examples

Example 1 A triangle has sides a=7, b=10, and included angle C=60°. Find side c.
  1. Apply the formula: c^2 = 7^2+10^2-2*7*10*cos(60°).
  2. = 49+100-140*0.5.
  3. = 149-70.
Answer: c^2=79, so c is approximately 8.89
Example 2 A triangle has sides a=5, b=6, c=7. Find angle C (opposite side c) using the Law of Cosines.
  1. Rearrange: cos(C) = (a^2+b^2-c^2)/(2ab) = (25+36-49)/(2*5*6).
  2. = 12/60.
Answer: cos(C)=0.2, so C = arccos(0.2), approximately 78.5°
Example 3 Show that the Law of Cosines matches the Pythagorean theorem when C=90°.
  1. At C=90°, cos(90°)=0.
  2. The formula c^2=a^2+b^2-2ab*cos(C) becomes c^2=a^2+b^2-2ab*0.
Answer: c^2 = a^2+b^2, exactly the Pythagorean theorem

04 Practice Questions

1A triangle has a=6, b=8, C=90°. Find c using the Law of Cosines.
c=10 (matches the Pythagorean theorem)
2A triangle has a=4, b=5, C=60°. Find c^2.
c^2=16+25-2*4*5*0.5=21
3When should you use the Law of Cosines instead of the Law of Sines?
When you know SSS or SAS (not a matching angle-side pair)
4A triangle has sides 3,4,5. Verify it's a right triangle using the Law of Cosines idea.
3^2+4^2=5^2, confirming a 90° angle opposite the side of length 5
5What does the Law of Cosines reduce to when the included angle is 90°?
The Pythagorean theorem

📄 Law of Cosines — Downloadable Worksheet

10 questions with a full answer key. Grab the PDF to print, or try the interactive version in your browser.