Sine and cosine rules

Trigonometry is often aligned with right-angled triangles only. However, an understanding of trigonometry can also be extended to non right-angle triangles to find unknown sides or angles. The Sine and Cosine rules can be applied to find any unknown side or angle of any triangle.


Use this page to revise the following concepts within Sine and Cosine rules:


The Sine and Cosine Rules for calculating the measurements of non-right-angled triangles are obtained through the application of trigonometry. The derivation of each rule is provided at the end of this section.

Law of Sines:

\[ \frac{a}{\sin A}=\frac{b}{\sin B}=\frac{c}{\sin C}\]

Law of Cosines:

\[\begin{align} &a^2=b^2+c^2-2bc\cos A \\ &b^2=a^2+c^2-2ac \cos B \\ & c^2=a^2+b^2-2ab \cos C \end{align}\]

Where:

  • \(a,b,c\) are the side lengths of the triangle.
  • \(A,B,C\) are the angles opposite those sides.

A triangle with angles ABC. Side a faces angle A, side b faces angle B and side c faces angle C.

Sine Rule Cosine Rule

Allows finding an unknown angle given two known sides and an angle opposite one of the known sides

Allows finding an unknown side given two known angles and one known side.

Allows finding an unknown angle given all three sides are known

Allows finding an unknown side given two sides and the angle between them.

Sine Rule

Worked Example

State the lengths of the sides \(a,b,c\) for the pictured triangle with angles \(A, B, C\).

A triangle ABC. Length of AB=14, length of BC=13, length of AC=15.

Solution:

Side lengths are opposite the corresponding angle.

\(a = 13, b=15, c=14\)

To solve for unknown sides or angles it is important to remember that an angle/side pair is required to be known.

Consider the following worked examples before testing for your own understanding.

Worked Example

A triangle ABC. Internal angle at vertex B is 110°.. Length of side AC is 14. Length of side BC is 12.

Determine the size of angle \(A\) to the nearest degree.

1. Set up Sine Rule and identify known sides and angles.

\(\dfrac{a}{\sin(A)}=\dfrac{b}{\sin(B)}\)

\(B = 110^\circ, b = 14, a = 12\)

2. Substitute and rearrange to make sin(A) the subject.

\[\begin{align} \frac{14}{\sin(110)}&=\frac{12}{\sin(A)} \\ \sin(A)&=\frac{12\sin(110^{\circ})}{14} \\ A&=\sin^{-1}\left(\frac{12\sin(110^{\circ})}{14}\right) \\ &=54^{\circ} \end{align}\]

Invisible break text

Worked Example

A triangle ABC. Internal angle at vertex A is 30°. Internal angle at vertex B is 100°. Length of side BC is 13.

Determine the length of  the unknown side \(c\).

1. Set up Sine Rule and identify known sides and angles.

\(\dfrac{a}{\sin(A)}=\dfrac{c}{\sin(C)}\)

\(B = 110^\circ, \sin(A)=\sin(30), a = 13\)

To find unknown side length \(c\), \(\sin(C)\) is required.

As all triangles have an interior angle sum of \(180^\circ\) then

\(\begin{align}100^{\circ}+30^{\circ}+C &=180^\circ \\ C &= 50^\circ\end{align}\)

2. Substitute and rearrange to make \(c\) the subject.

\[\begin{align} \frac{c}{\sin(50^{\circ})}&=\frac{13}{\sin(30^{\circ})} \\ c &=\frac{13\times \sin(50^{\circ})}{\sin(30^{\circ})} \\ &=20 \end{align}\]

Ambiguous case

The ambiguous case of the Sine Rule occurs when there are two possible solutions for the same information. An example is drawn below.

Two triangles. One triangle ABC, with an obtuse angle at C. Second equilateral triangle BCC-prime shares the side BC; BC and BC-prime are equivalent in length.

As the side length \(BC = BC’ \), the two triangles share the same information in regard to the side lengths \(AB\) and angle size \(A\). However the positions of points \(C\) and \(C^\prime\) are different.

For this ambiguous case, th angle size you calculate could correspond to either the angle \(C\), of triangle \(ABC\), or the angle \(C\), of triangle \(ABC^\prime\). To determine which is correct, you need to examine the apparent size of the angle: is it larger than a right angle (angle \(C\)) or an acute angle (angle \(C’\))?

The ambiguous case arises as a result of triangle \(BCC’\) being an isosceles triangle. Therefore, \(C\) and \(C^\prime\) are supplementary angles, that is \(C+C^\prime = 180^\circ\).  Therefore, one solution can be used to determine the other solution.

Once you have solved for an unknown angle, you must check that your answer makes sense with the given information in context. If not, the supplementary angle would be the correct answer.

Cosine Rules

The Cosine Rule states that the square of one side is equal to the sum of the squares of the two other sides minus twice the product of the two other sides with the angle between them.

\(b^{2}=a^{2}+c^{2}-2ac\cos(B)\)

Worked Example

Find the angle \(B\), to the nearest degree, of the following triangle.

Triangle ABC. Side AB is length 4; side BC is length 6; side AC is length 8.

1. Identify 3 known sides and an unknown angle

\(b^{2}=a^{2}+c^{2}-2ac\cos(B)\)

\(b=8, a=6, c=4\)

2. Make substitution and rearrange to make \(\cos(B)\) the subject

\[\begin{align} 8^{2}&=4^{2}+6^{2}-2\times 4\times 6\times cos(B)\\  64&=16+36-48\cos(B) \\ 12 &=-48cos(B) \\ cos(B)&=\frac{12}{-48}=-\frac{1}{4} \end{align}\]

3. Solve for \(B\)

\[\begin{align} B&=\cos^{-1}(-\frac{1}{4})\\ &\approx 104^{\circ} \end{align}\]

Invisible break text

Worked Example

Find the side length \(c\), to the nearest whole number, of the following triangle.

Triangle ABC. Length of side AC is 22, BC is 24. Internal angle at C is 70°

1. Identify 3 known sides and an unknown angle

\(c^{2}=a^{2}+b^{2}-2ab\cos(C)\)

\(a=24, b=22, C=70^\circ\)

2. Make substitution and rearrange to make \(\cos(C)\) the subject

\[\begin{align} c^{2}&=24^{2}+22^{2}-2\times 24\times 22\times \cos(70^{\circ})\\ &=576+484-1056\cos(70^{\circ})\end{align}\]

3. As \(\cos(70)\approx0.342\), solve for \(c\)

\[\begin{align} c^{2}& =1060-1056\times 0.342\\ &=698.848  \\ c&\approx 26.43\end{align}\]

Derivation of the Sine and Cosine Rules

Consider a triangle ABC.

Triangle ABC. Side opposite A is labelled lowercase a; side opposite B is labelled lowercase b; side opposite C is labelled lowercase c. Line perpendicular to lowercase-a to intersect vertex A is labelled h.

By creating a perpendicular line from the base \(a\) to the tip of the triangle, two right-angle triangles are formed.

It can be shown that:

\(\sin(B)=\dfrac{h}{c}\) and \(\sin(C)=\dfrac{h}{b}\)

\(\therefore c\times \sin(B)=h=b\times \sin(C)\)

Or

\(c\times \sin(B)=b\times \sin(C)\)

\(\frac{b}{\sin(B)}=\frac{c}{\sin(C)}\)

By considering a different perpendicular line drawn from either \(c\) or \(b\) as base it can also be shown that

\(\dfrac{a}{\sin(A)}=\dfrac{b}{\sin(B)}=\dfrac{c}{\sin(C)}\)

Hence the Sine Rule.

Now let’s consider the Cosine Rule.

Triangle ABC. Side opposite A is labelled lowercase a; side opposite B is labelled lowercase b; side opposite C is labelled lowercase c. Line perpendicular to lowercase-a to intersect vertex A is labelled h. The point where this line intersect lowercase a is now labelled D, and forms to triangles - ABD and ACD. Length of BD is labelled x; length of CD is labelled lowercase a-x.

The length \(a\) can be considered as the sum of \(x\) and \(a-x\).

So \(BD\) (the distance from \(B\) to \(D\)) is \(x\) and  \(DC\) is \(a-x\)

As \(BA\) is \(c\)

\[\begin{align} \cos(B)&=\frac{x}{c}\\ x&=c\times \cos(B)\end{align}\]

By Pythagoras’ Theorem in the triangle \(BAD\)

\[\begin{align}x^{2}+h^{2}&=c^{2}\\ (c\times cos(B))^{2}+h^{2}&=c^{2}\end{align}\]

By Pythagoras’ Theorem in the triangle \(CAD\)

\[\begin{align}(a-x)^{2}+h^{2}&=b^{2}\\ a^{2}-2ax+x^{2}+h^{2}&=b^{2}\end{align}\]

As \(x=c\times \cos(B)\)

\[\begin{align}a^{2}-2ac\cos(B)+x^{2}+h^{2}&=b^{2}; x^{2}+h^{2}=c^{2}\\ b^{2}&=a^{2}+c^{2}-2ac\cos(B)\end{align}\]

Hence the Cosine Rule for unknown side \(b\).

This can be applied to the other two sides giving the derivation of the Cosine Rule.