Law of tangents



In trigonometry, the law of tangents or tangent rule is a statement about the relationship between the tangents of two angles of a triangle and the lengths of the opposing sides.

In Figure 1, $α$, $β$, and $γ$ are the lengths of the three sides of the triangle, and $a$, $b$, and $c$ are the angles opposite those three respective sides. The law of tangents states that



\frac{a-b}{a+b} = \frac{\tan\tfrac12(\alpha-\beta)} {\tan\tfrac12(\alpha+\beta)}. $$

The law of tangents, although not as commonly known as the law of sines or the law of cosines, is equivalent to the law of sines, and can be used in any case where two sides and the included angle, or two angles and a side, are known.

Proof
To prove the law of tangents one can start with the law of sines:


 * $$\frac{a}{\sin\alpha} = \frac{b}{\sin\beta} = d,$$

where $d$ is the diameter of the circumcircle, so that $a = d \sin\alpha$ and $b = d \sin\beta$.

It follows that



\frac{a-b}{a+b} = \frac{d \sin \alpha - d\sin\beta} {d \sin\alpha + d\sin\beta} = \frac{\sin \alpha - \sin\beta} {\sin\alpha + \sin\beta}. $$

Using the trigonometric identity, the factor formula for sines specifically



\sin\alpha \pm \sin\beta = 2 \sin\tfrac12(\alpha \pm \beta) \, \cos\tfrac12( \alpha \mp \beta), $$

we get


 * $$\frac{a-b}{a+b}

= \frac{2\sin\tfrac12(\alpha-\beta) \, \cos\tfrac12(\alpha+\beta)} {2\sin\tfrac12(\alpha+\beta) \, \cos\tfrac12(\alpha-\beta)} = \frac{\sin\tfrac12(\alpha-\beta)} {\cos\tfrac12(\alpha-\beta)} \Bigg/ \frac{\sin\tfrac12(\alpha+\beta)} {\cos\tfrac12(\alpha+\beta)} = \frac{\tan\tfrac12(\alpha-\beta)} {\tan\tfrac12(\alpha+\beta)}. $$

As an alternative to using the identity for the sum or difference of two sines, one may cite the trigonometric identity



\tan \tfrac12 (\alpha \pm \beta) = \frac{\sin\alpha \pm \sin\beta} {\cos\alpha + \cos\beta} $$

(see tangent half-angle formula).

Application
The law of tangents can be used to compute the angles of a triangle in which two sides $a$ and $b$ and the enclosed angle $c$ are given.

From



\tan\tfrac12(\alpha-\beta) = \frac{a-b}{a+b} \tan\tfrac12(\alpha+\beta) = \frac{a-b}{a+b} \cot\tfrac12\gamma $$ compute the angle difference $α$; use that to calculate $β$ and then $γ$.

Once an angle opposite a known side is computed, the remaining side $a$ can be computed using the law of sines.

In the time before electronic calculators were available, this method was preferable to an application of the law of cosines $b$, as this latter law necessitated an additional lookup in a logarithm table, in order to compute the square root. In modern times the law of tangents may have better numerical properties than the law of cosines: If $γ$ is small, and $α − β = Δ$ and $β = (180° − γ − Δ)/2$ are almost equal, then an application of the law of cosines leads to a subtraction of almost equal values, incurring catastrophic cancellation.

Spherical version
On a sphere of unit radius, the sides of the triangle are arcs of great circles. Accordingly, their lengths can be expressed in radians or any other units of angular measure. Let $α = β + Δ$, $c$, $c = √a2 + b2 − 2ab cos γ$ be the angles at the three vertices of the triangle and let $γ$, $a$, $b$ be the respective lengths of the opposite sides. The spherical law of tangents says



\frac{\tan\tfrac12(A-B)}{\tan\tfrac12(A+B)} = \frac{\tan\tfrac12(a-b)} {\tan\tfrac12(a+b)}. $$

History
The law of tangents for planar triangles was described in the 11th century by Ibn Muʿādh al-Jayyānī.

The law of tangents for spherical triangles was described in the 13th century by Persian mathematician Nasir al-Din al-Tusi (1201–1274), who also presented the law of sines for plane triangles in his five-volume work Treatise on the Quadrilateral.

Cyclic quadrilateral
A generalization of the law of tangents holds for a cyclic quadrilateral $$\square ABCD.$$ Denote the lengths of sides $$|AB| = a,$$ $$|BC| = b,$$ $$|CD| = c,$$ and $$|DA| = d$$ and angle measures $$\angle{DAB} = \alpha,$$ $$\angle{ABC} = \beta$$ .Then:


 * $$\begin{align}

\frac{(a - c)(b - d)}{(a + c)(b + d)} = \frac {\tan\tfrac12(\alpha - \beta)} {\tan\tfrac12(\alpha + \beta)}. \end{align}$$

This formula reduces to the law of tangents for a triangle when $$c=0$$.