# Law of cosines

### From Math Images

(Difference between revisions)

(New page: The law of cosines is a formula that helps in triangulation when two or three side lengths of a triangle are known. The formula relates all three side lengths of a triangle to the cosine o...) |
|||

Line 5: | Line 5: | ||

When to use it: SAS, SSS. | When to use it: SAS, SSS. | ||

+ | |||

+ | ==Proof== | ||

+ | Let <math> \vartriangle ABC </math> be oriented so that <math> C</math> is at the origin, and <math> B</math> is at the point<math> (a,0)</math>. | ||

+ | |||

+ | [[Image:Law_of_cosines_proof.jpg]] | ||

+ | |||

+ | ===Distance Formula=== | ||

+ | |||

+ | <math> distance = \sqrt {(x_{2}-x_{1})^{2} + (y_{2}-y_{1})^{2}}</math> | ||

+ | |||

+ | <math>c</math> is the distance from <math> A</math> to <math> B</math>. | ||

+ | |||

+ | Substituting the appropriate points into the distance formula gives us | ||

+ | |||

+ | <math> c = \sqrt {(a-b \cos C)^{2} + (0-b \sin C)^{2}}</math> | ||

+ | |||

+ | Squaring the inner terms, we have | ||

+ | |||

+ | <math> c = \sqrt {(a^{2}-2ab \cos C+b^{2} \cos^{2} C) + (b^{2} \sin^{2} C)}</math> | ||

+ | |||

+ | Since <math> \cos^{2} C + \sin^{2} C = 1</math>, | ||

+ | |||

+ | <math> c = \sqrt {(a^{2}+b^{2}-2ab \cos C+b^{2}}</math> | ||

+ | |||

+ | Square both sides for | ||

+ | |||

+ | <math> c^{2} = (a^{2}+b^{2}-2ab \cos C+b^{2}</math> |

## Revision as of 15:40, 26 May 2011

The law of cosines is a formula that helps in triangulation when two or three side lengths of a triangle are known. The formula relates all three side lengths of a triangle to the cosine of a particular angle.

When to use it: SAS, SSS.

## Proof

Let be oriented so that is at the origin, and is at the point.

### Distance Formula

is the distance from to .

Substituting the appropriate points into the distance formula gives us

Squaring the inner terms, we have

Since ,

Square both sides for