This article will derive fundamental equations for a spherical triangle. These equations express the ratio between the angles and curved sides of the triangle drawn on a celestial sphere. We will need these formulas for calculating the primary directions.

Consider a right-angled triangle on a sphere with sides α\alpha, β\beta, and γ\gamma, as well as interior angles AA, BB, and CC.

How will its sides and angles be related to each other?

A B α γ β

Rotated Coordinate Systems

First, we introduce a cartesian vector v\vec{v} in XYZ\textbf{XYZ} coordinate system.

B α γ β X Z v X' Y'

From the conversion equation (1) it follows that v\vec{v} has coordinates

v=(x=Rcosβ y=0 z=Rsinβ)\vec{v} = \left( \begin{aligned} & x = R\cos\beta \\\ & y = 0 \\\ & z = R\sin\beta \end{aligned} \right)

Now, let’s use the rotation matrix to rotate XYZ\textbf{XYZ} by angle α\alpha along XY\textbf{XY} and express this vector in XYZ\textbf X' \textbf Y' \textbf Z' axis. As a result, we have the following:

v=Rcosαcosβ X Rsinαcosβ Y +Rsinβ Z \begin{aligned} \vec{v} & = R \cos\alpha \cos\beta~ \textbf X' \\\ & - R \sin\alpha \cos\beta~ \textbf Y' \\\ & + R\sin\beta~ \textbf Z' \\\ \end{aligned}

But on the other hand, the same xx' component of the vector v\vec{v} is just a projection of that vector to the X\textbf X'-axis in the γ\gamma-angle plane.

b α γ β X Z v X' Y'
x=Rcosγx' = R\cos{\gamma}

It gives us the first equation:

cosγ=cosαcosβ(1)\cos\gamma = \cos\alpha\cos\beta\tag{1}

Now we move to the next step and introduce a new coordinate system XYZ\textbf X'' \textbf Y'' \textbf Z'', which is XYZ\textbf X' \textbf Y' \textbf Z', rotated by angle B-B (minus B) in YZ\textbf Y' \textbf Z' plane.

B α β Z v X'' Y' Z'' Y''

If we apply rotation matrix to XYZ\textbf X' \textbf Y' \textbf Z' coordinate system, we will have a zz''-component of the vector v\vec{v} to be equal to

z=sinB y+cosB z= RsinBsinαcosβ +RcosBsinβ\begin{aligned} z'' & = \sin B~ y' + \cos B~ z' = \\\ & - R \sin B \sin\alpha \cos\beta \\\ & + R \cos B \sin \beta \end{aligned}

On the other hand, zz''-component of vector v\vec{v} is equal to zero. It means that

sinα=tanβtanB(2)\sin\alpha = \frac{\tan\beta}{\tan B} \tag{2}

The exact ratio applies to β\beta angle:

B α β A γ B α β A γ
sinβ=tanαtanA(3)\sin \beta = \frac{\tan \alpha} {\tan A }\tag{3}

Other Equations

We have set the main equations for spherical triangles:

{cosγ=cosαcosβ sinα=tanβ/tanB sinβ=tanα/tanA\begin{cases} \cos \gamma = \cos \alpha \cos\beta \\\ \sin \alpha = \tan\beta/ \tan B \\\ \sin \beta = \tan\alpha/ \tan A \end{cases}

All the rest is just a consequence of these three equations.

First, let’s multiply (1)(1) by (2)(2), and we will get

cosγ=1tanAtanB(4)\cos \gamma = \frac{1} {\tan A\tan B} \tag{4}

Now, let’s consider sin2γ\sin^2 \gamma:

sin2γ=1cos2γ =cos2α+sin2αcos2αcos2β =sin2α+cos2αsin2β\begin{aligned} \sin^2 \gamma & = 1 - \cos^2 \gamma \\\ & = \cos^2\alpha + \sin^2\alpha - \cos^2\alpha \cos^2\beta \\\ & = \sin^2\alpha + \cos^2\alpha \sin^2\beta \end{aligned}

Similarly, we can write

sin2γ=sin2β+cos2αsin2β(5)\sin^2\gamma = \sin^2\beta + \cos^2\alpha \sin^2\beta\tag{5}

Now, let’s divide both sides of the equation by cos2(γ)\cos^2(\gamma):

tan2γ=tan2α1cos2β+tan2β =tan2βtan2A+sin2αtan2B =sin2αtan2B[tan2A+1] =sinαtanBcosA\begin{aligned} \tan^2\gamma & = \tan^2\alpha \frac {1} {\cos^2\beta} + \tan^2\beta \\\ & = \tan^2\beta \tan^2A + \sin^2\alpha\tan^2B \\\ & = \sin^2\alpha\tan^2B \left[ \tan^2A + 1\right] \\\ & = \frac{\sin\alpha \tan B } {\cos A} \end{aligned}

which gives

sinγ=sinαsinA(6)\sin\gamma = \frac{\sin\alpha} {\sin A}\tag{6}

With the same approach, we get from the equation (5)(5)

sinγ=sinβsinB(7)\sin\gamma = \frac{\sin\beta} {\sin B}\tag{7}

This equality

sinαsinA=sinβsinB\frac{\sin\alpha} {\sin A} = \frac{\sin\beta} {\sin B}

is also called the sine theorem.

Now from (3)(3) it follows

sinA=tanαsinβcosA\sin A = \frac{\tan\alpha} {\sin\beta}\cos A

If we sunstitude sinA\sin A from (6)(6) we will get

cosA=cosαsinβsinγ(8)\cos A = \frac{\cos\alpha\sin\beta}{\sin\gamma}\tag{8}

or

cosA=tanβtanγ(9)\cos A = \frac{\tan\beta} {\tan\gamma}\tag{9}

In a similar manner from (2) follows that

cosB=tanαtanγ(10)\cos B = \frac{\tan\alpha} {\tan\gamma}\tag{10}

If we substitute (8) with (7), we will get

cosA=sinBcosα(11)\cos A = \sin B \cos\alpha\tag{11}

Similarly,

cosB=sinAcosβ(12)\cos B = \sin A \cos\beta\tag{12}

Bottom Line

We have derived a set of handy equations necessary for calculating the primary directions. Here is the recap of what we got

B α β A γ B α β A γ

Spherical triangle.

γ,α,β:cosγ=cosαcosβ α,β,B:tanβ=sinαtanB β,α,A:tanα=sinβtanA γ,A,B:cosγ=1tanAtanB γ,α,A:sinα=sinγsinA γ,β,B:sinβ=sinγsinB A,β,γ:tanβ=cosAtanγ B,α,γ:tanα=cosBtanγ A,B,α:cosA=sinBcosα B,A,β:cosB=sinAcosβ\begin{gather*} \gamma, \alpha, \beta: & \cos\gamma = \cos\alpha\cos\beta\tag{1}\\\ \alpha, \beta, B: & \tan\beta = \sin\alpha \tan B\tag{2}\\\ \beta, \alpha, A: & \tan \alpha = \sin \beta \tan A \tag{3}\\\ \gamma, A, B: & \cos \gamma = \frac{1} {\tan A\tan B} \tag{4}\\\ \gamma, \alpha, A: & \sin\alpha = \sin\gamma \sin A\tag{6}\\\ \gamma, \beta, B: & \sin\beta = \sin\gamma \sin B\tag{7}\\\ A, \beta, \gamma: & \tan\beta = \cos A \tan\gamma\tag{9}\\\ B, \alpha, \gamma: & \tan\alpha = \cos B \tan\gamma\tag{10}\\\ A, B, \alpha: & \cos A = \sin B \cos\alpha\tag{11}\\\ B, A, \beta: & \cos B = \sin A \cos\beta\tag{12} \end{gather*}