Home · Geometry · The law of cosines and examples

# The law of cosines and examples

The law of cosines is very useful for solving various tasks with not right triangles.

The law of cosines works for any triangle. The only important thing is that side a faces angle A, side b faces angle B and side c faces angle C. It helps for correct using of formulas.

$$\text{c}^2=\text{a}^2+\text{b}^2-2\text{a}\text{b}\cos{\text{C}}$$

The formula above can be rewritten into these formulas, if we need to find other sides of triangle.

$$\text{a}^2=\text{b}^2+\text{c}^2-2\text{b}\text{c}\cos{\text{A}}$$ $$\text{b}^2=\text{a}^2+\text{c}^2-2\text{a}\text{c}\cos{\text{B}}$$

It is not very necessary but for easier finding of triangle angles we can use these formulas below:

$$\cos{\text{C}}=\frac{\text{a}^2+\text{b}^2-\text{c}^2}{2\text{a}\text{b}}$$ $$\cos{\text{B}}=\frac{\text{a}^2+\text{c}^2-\text{b}^2}{2\text{a}\text{c}}$$ $$\cos{\text{A}}=\frac{\text{b}^2+\text{c}^2-\text{a}^2}{2\text{b}\text{c}}$$

## Solved examples

For triangle below find the side a. Round your answer to the nearest tenth.

$$\text{a}^2=\text{b}^2+\text{c}^2-2\text{b}\text{c}\cos{\text{A}}$$ $$\text{a}^2=\text{17}^2+\text{21}^2-2\text{17}\cdot\text{21}\cdot\cos{\text{55°}}$$ $$a\approx 17.9$$

For triangle below find the angle A. Round your answer to the nearest one.

$$\cos{\text{A}}=\frac{\text{b}^2+\text{c}^2-\text{a}^2}{2\text{b}\text{c}}$$ $$\cos{\text{A}}=\frac{\text{29}^2+\text{39}^2-\text{35}^2}{2\cdot\text{29}\cdot\text{39}}=0.5026...$$ $$\angle \text{A}=\cos^{-1}(0.5026...)\approx 60°$$