Astronomy and Space Exploration ES

Higher Education / Spherical astronomy and time

Spherical trigonometry and celestial coordinates

The cosine and sine formulas, the astronomical triangle, the equatorial → horizontal transformation, sidereal time, risings and settings, and the stereographic projection of a planisphere.

⏱ 180 min spherical trigonometrydot and cross productsrotation matricesinversionconformal mapsnumerical conditioning revision

By the end you will be able to:
  • Prove the cosine formula, the sine formula and the five-part formula for a spherical triangle.
  • Derive the transformation from equatorial coordinates (H, δ) to horizontal coordinates (h, A) from the astronomical triangle.
  • Compute the local sidereal time and the hour angle of a celestial body.
  • Obtain the semi-diurnal arc and the azimuth of rising, and classify stars as circumpolar, rising-and-setting, or never visible.
  • Prove that the stereographic projection is conformal and maps circles on the sphere to circles in the plane.
  • Analyze the numerical conditioning of the cosine formula for small separations and use the haversine or the vector formula instead.

1. The spherical triangle

Illustration: The spherical triangle

On the unit sphere, a great circle is the intersection with a plane through the center OO; it is the geodesic of the sphere. Three points A,B,CA, B, C not lying on the same great circle, joined by arcs of great circles shorter than π\pi, form a spherical triangle.

  • The sides a,b,ca, b, c are central angles: a=∠BOCa = \angle BOC, b=∠COAb = \angle COA, c=∠AOBc = \angle AOB.
  • The angles A,B,CA, B, C are the dihedral angles between the planes of the sides meeting at each vertex (equivalently, the angle between the tangents to the two sides at the vertex).

Unlike the plane triangle, A+B+C>πA + B + C > \pi; the spherical excess E=A+B+C−πE = A + B + C - \pi equals the area of the triangle (Girard’s theorem).

We write a^,b^,c^\hat{\mathbf a}, \hat{\mathbf b}, \hat{\mathbf c} for the unit vectors OA→,OB→,OC→\overrightarrow{OA}, \overrightarrow{OB}, \overrightarrow{OC}. Then b^⋅c^=cos⁡a\hat{\mathbf b}\cdot\hat{\mathbf c} = \cos a, c^⋅a^=cos⁡b\hat{\mathbf c}\cdot\hat{\mathbf a} = \cos b and a^⋅b^=cos⁡c\hat{\mathbf a}\cdot\hat{\mathbf b} = \cos c.

2. The cosine formula

Illustration: The cosine formula

Theorem.

cos⁡a=cos⁡b cos⁡c+sin⁡b sin⁡c cos⁡A.\cos a = \cos b\,\cos c + \sin b\,\sin c\,\cos A .

Proof. The tangent at AA to the arc ABAB is the component of b^\hat{\mathbf b} perpendicular to a^\hat{\mathbf a}, normalized:

u=b^−(a^⋅b^) a^sin⁡c,v=c^−(a^⋅c^) a^sin⁡b,\mathbf u = \frac{\hat{\mathbf b} - (\hat{\mathbf a}\cdot\hat{\mathbf b})\,\hat{\mathbf a}}{\sin c},\qquad \mathbf v = \frac{\hat{\mathbf c} - (\hat{\mathbf a}\cdot\hat{\mathbf c})\,\hat{\mathbf a}}{\sin b},

where the denominators are the norms: ∥b^−cos⁡c a^∥2=1−2cos⁡2c+cos⁡2c=sin⁡2c\lVert\hat{\mathbf b} - \cos c\,\hat{\mathbf a}\rVert^2 = 1 - 2\cos^2 c + \cos^2 c = \sin^2 c. The angle AA is the angle between u\mathbf u and v\mathbf v:

cos⁡A=u⋅v=b^⋅c^−cos⁡ccos⁡b−cos⁡bcos⁡c+cos⁡bcos⁡csin⁡b sin⁡c=cos⁡a−cos⁡bcos⁡csin⁡b sin⁡c.■\cos A = \mathbf u\cdot\mathbf v = \frac{\hat{\mathbf b}\cdot\hat{\mathbf c} - \cos c\cos b - \cos b\cos c + \cos b\cos c}{\sin b\,\sin c} = \frac{\cos a - \cos b\cos c}{\sin b\,\sin c}. \qquad\blacksquare

For small sides, cos⁡x≈1−x2/2\cos x \approx 1 - x^2/2 and sin⁡x≈x\sin x \approx x give a2≈b2+c2−2bccos⁡Aa^2 \approx b^2 + c^2 - 2bc\cos A: the plane law of cosines (problem 1).

3. The sine formula

Illustration: The sine formula

Theorem.

sin⁡Asin⁡a=sin⁡Bsin⁡b=sin⁡Csin⁡c.\frac{\sin A}{\sin a} = \frac{\sin B}{\sin b} = \frac{\sin C}{\sin c}.

Proof. From the cosine formula,

sin⁡2A=1−(cos⁡a−cos⁡bcos⁡c)2sin⁡2b sin⁡2c=sin⁡2b sin⁡2c−(cos⁡a−cos⁡bcos⁡c)2sin⁡2b sin⁡2c.\sin^2 A = 1 - \frac{(\cos a - \cos b\cos c)^2}{\sin^2 b\,\sin^2 c} = \frac{\sin^2 b\,\sin^2 c - (\cos a - \cos b\cos c)^2}{\sin^2 b\,\sin^2 c}.

Expanding the numerator with sin⁡2x=1−cos⁡2x\sin^2 x = 1 - \cos^2 x:

N=1−cos⁡2a−cos⁡2b−cos⁡2c+2cos⁡acos⁡bcos⁡c,N = 1 - \cos^2 a - \cos^2 b - \cos^2 c + 2\cos a\cos b\cos c,

which is symmetric in a,b,ca, b, c. Therefore

sin⁡2Asin⁡2a=Nsin⁡2a sin⁡2b sin⁡2c\frac{\sin^2 A}{\sin^2 a} = \frac{N}{\sin^2 a\,\sin^2 b\,\sin^2 c}

does not depend on which vertex we choose. Since all angles and sides lie in (0,π)(0, \pi), the sines are positive and we may take the square root. ■\blacksquare

(Geometrically, N=[a^ b^ c^]2N = [\hat{\mathbf a}\,\hat{\mathbf b}\,\hat{\mathbf c}]^2, the square of the scalar triple product: the volume of the parallelepiped, which favors no vertex.)

Five-part formula. Applying the cosine formula to bb and substituting cos⁡c\cos c again, one obtains

sin⁡acos⁡B=cos⁡b sin⁡c−sin⁡b cos⁡c cos⁡A,\sin a\cos B = \cos b\,\sin c - \sin b\,\cos c\,\cos A ,

which we will use for the azimuth.

3.1 The polar triangle and the cosine formula for the angles

Given a triangle ABCABC, its polar triangle A′B′C′A'B'C' has as vertices the poles of the sides: A′A' is the pole of the great circle BCBC lying on the same side as AA, and so on. One proves (Todhunter, ch. II) that its sides and angles are the supplements of the angles and sides of the original: a′=π−Aa' = \pi - A, A′=π−aA' = \pi - a. Applying the cosine formula to the polar triangle and substituting:

cos⁡A=−cos⁡Bcos⁡C+sin⁡Bsin⁡Ccos⁡a.\cos A = -\cos B\cos C + \sin B\sin C\cos a .

This is the cosine formula for the angles: it yields a side from the three angles, something impossible in the plane (where the three angles fix only the shape, not the size). On the sphere the size is determined because the spherical excess is the area.

3.2 Numerical conditioning: when the cosine formula fails

The angular separation dd between two celestial bodies is often computed with cos⁡d=sin⁡δ1sin⁡δ2+cos⁡δ1cos⁡δ2cos⁡Δα\cos d = \sin\delta_1\sin\delta_2 + \cos\delta_1\cos\delta_2\cos\Delta\alpha (problem 2). For small dd this is an ill-conditioned formula: cos⁡d≈1−d2/2\cos d \approx 1 - d^2/2 is computed with an absolute error of the order of the machine epsilon, ϵ≈1.1×10−16\epsilon \approx 1.1\times10^{-16} in double precision, and on inverting,

δd=δ(cos⁡d)sin⁡d≈ϵd.\delta d = \frac{\delta(\cos d)}{\sin d} \approx \frac{\epsilon}{d}.

For d=1′′d = 1'' (4.8×10−64.8\times10^{-6} rad) the error is 2×10−112\times10^{-11} rad =5×10−6 ′′= 5\times10^{-6}\,'', tolerable; but for d=1d = 1 mas (milliarcsecond, the precision of Gaia), δd≈2×10−8\delta d \approx 2\times10^{-8} rad =5= 5 mas: the error exceeds the result. The cure is a formula that does not subtract nearly equal quantities. With the haversine hav⁡ x=sin⁡2(x/2)=(1−cos⁡x)/2\operatorname{hav}\,x = \sin^2(x/2) = (1 - \cos x)/2, the cosine formula is rewritten (problem 8) as

hav⁡ d=hav⁡ Δδ+cos⁡δ1cos⁡δ2 hav⁡ Δα,\operatorname{hav}\,d = \operatorname{hav}\,\Delta\delta + \cos\delta_1\cos\delta_2\,\operatorname{hav}\,\Delta\alpha,

in which all terms are small and positive when dd is, and d=2arcsin⁡hav⁡ dd = 2\arcsin\sqrt{\operatorname{hav}\,d} is obtained with relative error O(ϵ)O(\epsilon). Equivalent, and even more robust over the whole range, is the vector form: with a^\hat{\mathbf a} and b^\hat{\mathbf b} the unit vectors, d=atan2⁡ ⁣(∥a^×b^∥, a^⋅b^)d = \operatorname{atan2}\!\left(\lVert\hat{\mathbf a}\times\hat{\mathbf b}\rVert,\ \hat{\mathbf a}\cdot\hat{\mathbf b}\right), which is exact at the level ϵ\epsilon both for d→0d \to 0 and for d→πd \to \pi (where the haversine, in turn, degrades). It is the one used by SOFA and Astropy.

4. The astronomical triangle

Illustration: The astronomical triangle

For an observer at latitude φ\varphi we consider three points on the celestial sphere:

  • PP, the north celestial pole (taking φ\varphi with its sign, negative in the south, the formulas also hold in the southern hemisphere),
  • ZZ, the zenith,
  • XX, the celestial body, with declination δ\delta and hour angle HH (measured westward from the meridian).

Its sides are

PZ=π2−φ(colatitude),PX=π2−δ(polar distance),ZX=z=π2−h,PZ = \tfrac{\pi}{2} - \varphi \quad(\text{colatitude}),\qquad PX = \tfrac{\pi}{2} - \delta\quad(\text{polar distance}),\qquad ZX = z = \tfrac{\pi}{2} - h,

and its angles at PP and at ZZ are ∠ZPX=H\angle ZPX = H and ∠PZX=2π−A\angle PZX = 2\pi - A if the body is in the west (0<H<π0 < H < \pi), with the azimuth AA measured from north through east. (If it is in the east, ∠ZPX=2π−H\angle ZPX = 2\pi - H and ∠PZX=A\angle PZX = A; the final formulas are the same.) That the altitude of the pole equals φ\varphi is immediate: the arc PZPZ is the colatitude.

4.1 Derivation of the equatorial → horizontal transformation

Altitude. Cosine formula for the side ZXZX, opposite PP:

cos⁡z=cos⁡PZcos⁡PX+sin⁡PZsin⁡PXcos⁡H  ⟹  sin⁡h=sin⁡φ sin⁡δ+cos⁡φ cos⁡δ cos⁡H.\cos z = \cos PZ\cos PX + \sin PZ\sin PX\cos H \;\Longrightarrow\; \boxed{\sin h = \sin\varphi\,\sin\delta + \cos\varphi\,\cos\delta\,\cos H .}

Azimuth, sine. Sine formula with the pairs (H,ZX)(H, ZX) and (2π−A,PX)(2\pi - A, PX):

sin⁡(2π−A)sin⁡(π/2−δ)=sin⁡Hsin⁡z  ⟹  cos⁡h sin⁡A=−cos⁡δ sin⁡H.\frac{\sin(2\pi - A)}{\sin(\pi/2 - \delta)} = \frac{\sin H}{\sin z} \;\Longrightarrow\; \cos h\,\sin A = -\cos\delta\,\sin H .

Azimuth, cosine. Five-part formula (or the cosine formula for the side PXPX, substituting sin⁡h\sin h):

cos⁡h cos⁡A=sin⁡δ cos⁡φ−cos⁡δ sin⁡φ cos⁡H.\cos h\,\cos A = \sin\delta\,\cos\varphi - \cos\delta\,\sin\varphi\,\cos H .

Dividing, and using the two-argument function to obtain the correct quadrant,

A=atan2⁡ ⁣(−cos⁡δsin⁡H,  sin⁡δcos⁡φ−cos⁡δsin⁡φcos⁡H).A = \operatorname{atan2}\!\big(-\cos\delta\sin H,\; \sin\delta\cos\varphi - \cos\delta\sin\varphi\cos H\big).

These are exactly the formulas of equatorialToHorizontal in src/lib/math/coordinates.ts (Meeus eqs. 13.5–13.6, with azimuth from north instead of from south).

Matrix form. The three equations are equivalent to a rotation by the angle π2−φ\tfrac{\pi}{2} - \varphi about the east–west axis that carries the pole to the zenith (problem 3); in practice the rotations of precession, nutation and sidereal time are chained in this way.

5. Sidereal time

Illustration: Sidereal time

The hour angle of a celestial body is H=θ−αH = \theta - \alpha, where θ\theta is the local sidereal time: the hour angle of the vernal equinox. It is obtained from that of Greenwich by adding the longitude λ\lambda (positive eastward):

θ=θ0+λ.\theta = \theta_0 + \lambda .

The Greenwich mean sidereal time as a function of the Julian date JD\mathrm{JD} (UT1; time scales are treated in the next lesson) is (Meeus eq. 12.4)

θ0=280.46061837°+360.98564736629° (JD−2451545.0)+0.000387933° T2−T338 710 000,\theta_0 = 280.46061837° + 360.98564736629°\,(\mathrm{JD} - 2451545.0) + 0.000387933°\,T^2 - \frac{T^3}{38\,710\,000},

with TT in Julian centuries since J2000.0. The coefficient 360.9856…°360.9856…° per mean solar day reflects the fact that in one solar day the Earth turns slightly more than one full revolution with respect to the stars: the sidereal day lasts 86 164.09 s=23 h 56 min 4.09 s86\,164.09\ \text{s} = 23\ \text{h}\ 56\ \text{min}\ 4.09\ \text{s}. This is why each star rises about 3 min 56 s earlier every night, and the sky seen at a given hour changes with the seasons.

6. Rising and setting of the stars

Illustration: Rising and setting of the stars

Imposing h=0h = 0 in the altitude equation:

cos⁡H0=−tan⁡φ tan⁡δ.\cos H_0 = -\tan\varphi\,\tan\delta .

H0∈[0,π]H_0 \in [0, \pi] is the semi-diurnal arc: the star is above the horizon for 2H02H_0 (in sidereal time, 2H0/15°2H_0/15° hours). It rises when θ=α−H0\theta = \alpha - H_0 and sets when θ=α+H0\theta = \alpha + H_0.

  • If −tan⁡φtan⁡δ≤−1-\tan\varphi\tan\delta \le -1, it never sets: circumpolar. This is equivalent to ∣φ+δ∣≥π/2|\varphi + \delta| \ge \pi/2 (problem 4).
  • If −tan⁡φtan⁡δ≥1-\tan\varphi\tan\delta \ge 1, it never rises.

With h=0h = 0 in the cosine equation for the side PXPX, sin⁡δ=cos⁡φcos⁡A\sin\delta = \cos\varphi\cos A: the azimuth of rising is

cos⁡Arise=sin⁡δcos⁡φ,\cos A_{\text{rise}} = \frac{\sin\delta}{\cos\varphi},

and setting is symmetric, at 2π−Arise2\pi - A_{\text{rise}}. For Sirius (δ=−16.72°\delta = -16.72°) from Bogotá (φ=4.71°\varphi = 4.71°): cos⁡A=−0.2886\cos A = -0.2886, A=106.8°A = 106.8°, between east and southeast.

For the Sun and the Moon one must use h0=−0.833°h_0 = -0.833° (refraction of 34′34' plus semidiameter of 16′16') or h0≈+0.125°h_0 \approx +0.125° for the Moon (which also has a parallax of ∼57′\sim 57'). The general formula is cos⁡H0=(sin⁡h0−sin⁡φsin⁡δ)/(cos⁡φcos⁡δ)\cos H_0 = (\sin h_0 - \sin\varphi\sin\delta)/(\cos\varphi\cos\delta) (Meeus ch. 15).

7. The stereographic projection of the planisphere

Illustration: The stereographic projection of the planisphere
Bogotá (4.71° N, 74.07° W) · local sidereal time 1 h 46 min · Sun at -15.7° (astronomical twilight) · Moon at 47.6° · 66 of 150 stars above the horizon

The simulator draws the visible hemisphere by projecting it from the nadir NN onto the plane of the horizon (which passes through the center OO of the sphere). A point of zenith distance zz goes to a point at distance

r=tan⁡z2=tan⁡ ⁣(π4−h2)r = \tan\frac{z}{2} = \tan\!\left(\frac{\pi}{4} - \frac{h}{2}\right)

from the center, in the direction of its azimuth. Proof: the central angle between ZZ and XX is zz; the inscribed angle ∠ZNX\angle ZNX subtending the same arc equals z/2z/2, and in the right triangle NOX′NOX' (with ∣NO∣=1|NO| = 1) we have r=tan⁡(z/2)r = \tan(z/2). The zenith goes to r=0r = 0 and the horizon to r=1r = 1. Since the sky is viewed from below, the plane is drawn with north at the top and east on the left: x=−rsin⁡Ax = -r\sin A, y=rcos⁡Ay = r\cos A (src/lib/math/proyeccion.ts).

7.1 Conformality

In coordinates (z,A)(z, A) the metric of the sphere is ds2=dz2+sin⁡2z dA2ds^2 = dz^2 + \sin^2 z\,dA^2, and in the plane, in polar coordinates, dσ2=dr2+r2dA2d\sigma^2 = dr^2 + r^2 dA^2. With r=tan⁡(z/2)r = \tan(z/2):

drdz=12cos⁡2(z/2),rsin⁡z=tan⁡(z/2)2sin⁡(z/2)cos⁡(z/2)=12cos⁡2(z/2).\frac{dr}{dz} = \frac{1}{2\cos^2(z/2)},\qquad \frac{r}{\sin z} = \frac{\tan(z/2)}{2\sin(z/2)\cos(z/2)} = \frac{1}{2\cos^2(z/2)} .

The scale factors in the radial and in the azimuthal direction are equal, k(z)=12sec⁡2(z/2)k(z) = \tfrac{1}{2}\sec^2(z/2), hence dσ2=k2 ds2d\sigma^2 = k^2\,ds^2: the projection is conformal (it preserves angles, and therefore the shape of small figures: the constellations are not distorted, they only grow toward the edge, up to k=1k = 1 at the horizon versus k=12k = \tfrac12 at the zenith).

7.2 Circles go to circles

Theorem. The image of every circle on the sphere not passing through NN is a circle in the plane; if it passes through NN, it is a straight line.

Proof. Let ι\iota be the inversion of space with center NN and radius 2\sqrt2: X↦X′X \mapsto X' on the ray NXNX with ∣NX∣ ∣NX′∣=2|NX|\,|NX'| = 2. An inversion of radius kk maps a sphere through its center, of diameter 2ρ2\rho, to the plane perpendicular to that diameter at distance k2/(2ρ)k^2/(2\rho) from the center. Here k2=2k^2 = 2 and 2ρ=∣NZ∣=22\rho = |NZ| = 2, so the celestial sphere goes to the plane at distance 1 from NN: the plane of the horizon through OO. Since each point moves along the line NXNX, ι\iota restricted to the sphere is the stereographic projection (check: Z↦OZ \mapsto O because ∣NZ∣=2|NZ| = 2, and the horizon, at distance 2\sqrt2 from NN, stays fixed). Now:

  1. a circle on the sphere is the intersection of the sphere with a plane Π\Pi;
  2. the inversion maps Π\Pi to a sphere through NN (or to itself if N∈ΠN \in \Pi);
  3. therefore the image of the circle is the intersection of the horizon plane with a sphere (a circle) or with a plane (a line, when N∈ΠN \in \Pi). ■\blacksquare

Consequences for the planisphere: the circles of constant altitude are concentric circles; the celestial equator and the parallels of declination (circles on the sphere) are circular arcs, which is what one sees when animating the simulator: each star traces a circular arc around the image of the pole.

Problems

1. Prove that for a small spherical triangle the cosine formula reduces to the plane law of cosines, and estimate the relative error for sides of 10°10°.

Show solution

With cos⁡x=1−x2/2+x4/24+O(x6)\cos x = 1 - x^2/2 + x^4/24 + O(x^6) and sin⁡x=x−x3/6+O(x5)\sin x = x - x^3/6 + O(x^5): 1−a2/2=(1−b2/2)(1−c2/2)+bccos⁡A+O(4)1 - a^2/2 = (1 - b^2/2)(1 - c^2/2) + bc\cos A + O(4), whence a2=b2+c2−2bccos⁡A+O(4)a^2 = b^2 + c^2 - 2bc\cos A + O(4), where O(4)O(4) denotes terms of fourth order in the sides. The neglected terms are of order x4x^4 against x2x^2, so the relative error is of order x2/12x^2/12: for x=10°=0.1745x = 10° = 0.1745 rad, a few tenths of a percent.

2. Compute the angular separation between Acrux (α=12h26m36s\alpha = 12^{\mathrm h}26^{\mathrm m}36^{\mathrm s}, δ=−63°05′57′′\delta = -63°05'57'') and Gacrux (α=12h31m10s\alpha = 12^{\mathrm h}31^{\mathrm m}10^{\mathrm s}, δ=−57°06′48′′\delta = -57°06'48'').

Show solution

In the triangle pole–Acrux–Gacrux the sides meeting at the pole are the polar distances 90°−δi90° - \delta_i and the angle at the pole is Δα\Delta\alpha. Cosine formula: cos⁡d=sin⁡δ1sin⁡δ2+cos⁡δ1cos⁡δ2cos⁡Δα\cos d = \sin\delta_1\sin\delta_2 + \cos\delta_1\cos\delta_2\cos\Delta\alpha. With δ1=−63.099°\delta_1 = -63.099°, δ2=−57.113°\delta_2 = -57.113°, Δα=4m34s=1.142°\Delta\alpha = 4^{\mathrm m}34^{\mathrm s} = 1.142°: cos⁡d=0.74888+0.24567⋅0.99980≈0.99450\cos d = 0.74888 + 0.24567\cdot 0.99980 \approx 0.99450, so d≈6.0°d \approx 6.0°: the “long arm” of the Southern Cross.

3. Write the rotation that carries the local equatorial system (axes: meridian–equator intersection toward the south, west, north pole) to the horizontal system (south, west, zenith) and recover from it the three formulas of §4.1.

Show solution

Both systems share the west axis. The pole is at altitude φ\varphi, so one must rotate by the angle π2−φ\tfrac{\pi}{2} - \varphi about the west axis. With e=(cos⁡δcos⁡H,  cos⁡δsin⁡H,  sin⁡δ)\mathbf e = (\cos\delta\cos H,\; \cos\delta\sin H,\; \sin\delta) and n=(−cos⁡hcos⁡A,  −cos⁡hsin⁡A,  sin⁡h)\mathbf n = (-\cos h\cos A,\; -\cos h\sin A,\; \sin h) (south =−= -north, west =−= -east):

n=(sin⁡φ0−cos⁡φ010cos⁡φ0sin⁡φ)e.\mathbf n = \begin{pmatrix} \sin\varphi & 0 & -\cos\varphi\\ 0 & 1 & 0\\ \cos\varphi & 0 & \sin\varphi\end{pmatrix}\mathbf e .

The third row gives sin⁡h=cos⁡φcos⁡δcos⁡H+sin⁡φsin⁡δ\sin h = \cos\varphi\cos\delta\cos H + \sin\varphi\sin\delta; the second, −cos⁡hsin⁡A=cos⁡δsin⁡H-\cos h\sin A = \cos\delta\sin H; the first, −cos⁡hcos⁡A=sin⁡φcos⁡δcos⁡H−cos⁡φsin⁡δ-\cos h\cos A = \sin\varphi\cos\delta\cos H - \cos\varphi\sin\delta. They are those of §4.1. Check: for δ=π/2\delta = \pi/2 one obtains sin⁡h=sin⁡φ\sin h = \sin\varphi.

4. Prove that −tan⁡φtan⁡δ≤−1  ⟺  ∣φ+δ∣≥π/2-\tan\varphi\tan\delta \le -1 \iff |\varphi + \delta| \ge \pi/2 for φ,δ∈(−π/2,π/2)\varphi, \delta \in (-\pi/2, \pi/2), and conclude which stars are circumpolar in Bogotá (φ=4.71°\varphi = 4.71°).

Show solution

If φδ≤0\varphi\delta \le 0, the product tan⁡φtan⁡δ≤0<1\tan\varphi\tan\delta \le 0 < 1 and moreover ∣φ+δ∣≤max⁡(∣φ∣,∣δ∣)<π/2|\varphi + \delta| \le \max(|\varphi|, |\delta|) < \pi/2: neither condition holds. If φ,δ>0\varphi, \delta > 0 (the negative case is symmetric): tan⁡φtan⁡δ≥1  ⟺  tan⁡δ≥cot⁡φ=tan⁡(π/2−φ)  ⟺  δ≥π/2−φ\tan\varphi\tan\delta \ge 1 \iff \tan\delta \ge \cot\varphi = \tan(\pi/2 - \varphi) \iff \delta \ge \pi/2 - \varphi, by the monotonicity of the tangent on (0,π/2)(0, \pi/2). In Bogotá, δ≥85.29°\delta \ge 85.29°: among the stars with V<3V < 3 only Polaris satisfies it (δ≈89.4°\delta \approx 89.4° in 2026).

5. Compute the length of the day in Bogotá at the June solstice (δ⊙=+23.44°\delta_\odot = +23.44°), first with the mathematical horizon and then with h0=−0.833°h_0 = -0.833°.

Show solution

Mathematical horizon: cos⁡H0=−tan⁡4.71°tan⁡23.44°=−0.08239⋅0.43357=−0.03572\cos H_0 = -\tan 4.71°\tan 23.44° = -0.08239\cdot 0.43357 = -0.03572, H0=92.05°H_0 = 92.05°, day =2H0/15°=12.27 h≈12 h 16 min= 2H_0/15° = 12.27\ \text{h} \approx 12\ \text{h}\ 16\ \text{min}. With h0=−0.833°h_0 = -0.833°: cos⁡H0=(sin⁡(−0.833°)−sin⁡4.71°sin⁡23.44°)/(cos⁡4.71°cos⁡23.44°)=(−0.01454−0.03267)/0.91439=−0.05163\cos H_0 = (\sin(-0.833°) - \sin 4.71°\sin 23.44°)/(\cos 4.71°\cos 23.44°) = (-0.01454 - 0.03267)/0.91439 = -0.05163, H0=92.96°H_0 = 92.96°, day ≈12.39 h≈12 h 24 min\approx 12.39\ \text{h} \approx 12\ \text{h}\ 24\ \text{min}. Refraction and semidiameter add about 8 minutes, more than the entire seasonal variation in Bogotá (about 33 min between solstices).

6. Prove that in the stereographic projection the area is magnified by a factor k2=14sec⁡4(z/2)k^2 = \tfrac14\sec^4(z/2) and compute how much larger a constellation appears at the horizon than at the zenith.

Show solution

By §7.1 the map is conformal with linear factor kk in all directions, so the area element is multiplied by k2k^2: dSplane=r dr dA=14sec⁡4(z/2) sin⁡z dz dAdS_{\text{plane}} = r\,dr\,dA = \tfrac14\sec^4(z/2)\,\sin z\,dz\,dA. At the zenith k2=1/4k^2 = 1/4; at the horizon, k2=14sec⁡4(45°)=1k^2 = \tfrac14\sec^4(45°) = 1. A constellation is drawn with 4 times more area (twice the linear size) near the horizon. It is an effect of the projection, unrelated to the “Moon illusion,” which is perceptual.

7. (Simulator) In Bogotá, set the time at which Sirius rises and check with the pointer that its azimuth is close to 107°107°. Then switch to Buenos Aires (φ=−34.6°\varphi = -34.6°) and first predict the new azimuth of rising with the formula.

Show solution

cos⁡A=sin⁡(−16.72°)/cos⁡(−34.6°)=−0.2876/0.8231=−0.3494\cos A = \sin(-16.72°)/\cos(-34.6°) = -0.2876/0.8231 = -0.3494, A≈110.4°A \approx 110.4°. The star rises somewhat farther south than in Bogotá, and its diurnal arc, being closer to the elevated pole (the south one), is longer: cos⁡H0=−tan⁡(−34.6°)tan⁡(−16.72°)=−0.2072\cos H_0 = -\tan(-34.6°)\tan(-16.72°) = -0.2072, 2H0≈13.62H_0 \approx 13.6 sidereal hours above the horizon, versus about 11.8 h in Bogotá.

8. (Computational) Prove the haversine identity of §3.2 from the cosine formula and check the conditioning numerically: compute the separation between (α,δ)=(0,0)(\alpha, \delta) = (0, 0) and (α,δ)=(x,0)(\alpha, \delta) = (x, 0) for x=1°,1′,1′′,1 mas,1 μasx = 1°, 1', 1'', 1\ \text{mas}, 1\ \mu\text{as} with the three formulas (cosine, haversine, vector) and tabulate the relative error against the exact value xx.

Show solution

Identity. cos⁡d=sin⁡δ1sin⁡δ2+cos⁡δ1cos⁡δ2cos⁡Δα\cos d = \sin\delta_1\sin\delta_2 + \cos\delta_1\cos\delta_2\cos\Delta\alpha. Using cos⁡Δα=1−2hav⁡Δα\cos\Delta\alpha = 1 - 2\operatorname{hav}\Delta\alpha and sin⁡δ1sin⁡δ2+cos⁡δ1cos⁡δ2=cos⁡Δδ=1−2hav⁡Δδ\sin\delta_1\sin\delta_2 + \cos\delta_1\cos\delta_2 = \cos\Delta\delta = 1 - 2\operatorname{hav}\Delta\delta: cos⁡d=1−2hav⁡Δδ−2cos⁡δ1cos⁡δ2hav⁡Δα\cos d = 1 - 2\operatorname{hav}\Delta\delta - 2\cos\delta_1\cos\delta_2\operatorname{hav}\Delta\alpha, and since cos⁡d=1−2hav⁡d\cos d = 1 - 2\operatorname{hav} d, we get hav⁡d=hav⁡Δδ+cos⁡δ1cos⁡δ2hav⁡Δα\operatorname{hav} d = \operatorname{hav}\Delta\delta + \cos\delta_1\cos\delta_2\operatorname{hav}\Delta\alpha. ■\blacksquare

Program (Python):

import numpy as np
def cosenos(a1, d1, a2, d2):
    return np.arccos(np.sin(d1)*np.sin(d2) + np.cos(d1)*np.cos(d2)*np.cos(a2 - a1))
def haversine(a1, d1, a2, d2):
    h = np.sin((d2-d1)/2)**2 + np.cos(d1)*np.cos(d2)*np.sin((a2-a1)/2)**2
    return 2*np.arcsin(np.sqrt(h))
def vectorial(a1, d1, a2, d2):
    u = np.array([np.cos(d1)*np.cos(a1), np.cos(d1)*np.sin(a1), np.sin(d1)])
    v = np.array([np.cos(d2)*np.cos(a2), np.cos(d2)*np.sin(a2), np.sin(d2)])
    return np.arctan2(np.linalg.norm(np.cross(u, v)), np.dot(u, v))
for nombre, x in [("1°", np.radians(1)), ("1'", np.radians(1/60)), ('1"', np.radians(1/3600)),
                  ("1 mas", np.radians(1e-3/3600)), ("1 µas", np.radians(1e-6/3600))]:
    print(nombre, [abs(f(0, 0, x, 0) - x)/x for f in (cosenos, haversine, vectorial)])

Typical results (relative error): for 1°1° all three formulas give ∼10−15\sim 10^{-15}; for 1′′1'' the cosine formula already has ∼10−6\sim 10^{-6} while the other two stay at ∼10−16\sim 10^{-16}; for 1 mas and 1 µas the cosine formula returns exactly 0 (an error of 100 %) because cos⁡d\cos d rounds to 1, whereas the haversine and the vector formula remain at ≲10−16\lesssim 10^{-16} (checked with our code in double precision). The haversine only degrades at the opposite extreme, d→πd \to \pi, where the vector formula remains exact. Conclusion: for astrometry, arccos⁡\arccos is never used.

✦ Self-assessment

  1. 1. In a spherical triangle, the sum of the angles…
  2. 2. The altitude h of a body with declination δ and hour angle H for an observer at latitude φ satisfies…
  3. 3. A star is circumpolar for an observer at latitude φ if…
  4. 4. Why does a star rise about 3 min 56 s earlier each night than the night before?
  5. 5. The stereographic projection of the planisphere…
  6. 6. To compute the separation of two bodies at 1 milliarcsecond one should avoid…
Answer all the questions to check.

Further reading

  • Smart (1977), Textbook on Spherical Astronomy, chs. I–II: the classical development of the formulas and of the astronomical triangle. Todhunter (1886): polar triangle and all the identities, with complete proofs.
  • Green (1985), Spherical Astronomy, chs. 1–3: modern treatment with vectors and rotation matrices.
  • Meeus (1998), chs. 12, 13 and 15: the formulas as they are programmed, with numerical examples.
  • Snyder (1987), §21, and Needham (1997), ch. 3: the stereographic projection from cartography and from complex analysis.
  • Sinnott (1984), Sky & Telescope 68, 159: the article that popularized the haversine in computational astronomy.
🍎 Teacher guide
Time
3 classes of 90 min
Learning outcome
On completion, the student proves the fundamental formulas of spherical trigonometry, derives the equatorial → horizontal transformation from the astronomical triangle, computes sidereal times, risings and settings, proves the properties of the stereographic projection and chooses the numerically appropriate formula for angular separations.
Evidence of learning
Submission of problems 3 (matrix form), 6 (area in the projection) and 8 (program with conditioning table), and a planisphere computed by hand for the student's latitude with three stars and their rising azimuths.

Materials

  • A sphere (ball or globe) and adhesive tape to trace great circles
  • Python 3 or a scientific calculator
  • The portal's interactive Planisphere simulator
  • Catalog of bright stars (e.g. those brighter than magnitude 2 with J2000 coordinates)

Suggested sequence

Class 1 (90 min). Opening (15 min): great circles on the ball; the spherical excess measured on an octant. Development (60 min): vector proof of the cosine formula, the sine formula and the five-part formula; polar triangle (§3.1). Closing (15 min): problem 1 (plane limit).

Class 2 (90 min). Opening (10 min): “how do I point to the zenith from the pole?”: the astronomical triangle. Development (60 min): derivation of the equatorial → horizontal transformation, matrix form (problem 3), sidereal time, risings and settings, circumpolar stars (problems 4 and 5). Closing (20 min): simulator: check the computed rising azimuths.

Class 3 (90 min). Opening (10 min): numerical conditioning (§3.2) with the 1 mas example. Development (55 min): stereographic projection: conformality and inversion (§7), problem 6; workshop on problem 8. Closing (25 min): problem 7 and mini-quiz.

Common mistakes

  • Measuring the sides of the spherical triangle as lengths instead of central angles. Trace the three great circles on the ball and measure with a protractor from the center.
  • Forgetting the sign of the latitude in the southern hemisphere. Do problem 7 (Buenos Aires) explicitly.
  • Using the cosine formula with arccos for small separations. Problem 8 shows it with numbers; always ask for atan2.
  • Confusing azimuth from north (the portal's convention) with azimuth from south (Meeus). Point out the sign change in the formulas.
  • Believing that the stereographic projection distorts the constellations. It is conformal: only the size changes, not the shape; problem 6 quantifies by how much.
Key terms in this lesson (12)

Glossary terms that appear in the text. Each one links to its full entry.

  • Sidereal time A clock that keeps time by the stars instead of the Sun. It gains almost 4 minutes a day on our clocks; that is why each night the stars rise a little earlier.
  • Azimuth The compass direction in which a celestial object lies: 0° is north, 90° east, 180° south and 270° west.
  • Horizon The line where the sky seems to touch the land or the sea. A celestial object "rises" when it crosses the horizon going up and "sets" when it crosses it going down.
  • Zenith The point in the sky directly above your head. The opposite point, beneath your feet, is called the nadir.
  • Sidereal day The time it takes Earth to make one full turn with respect to the stars: 23 h 56 min 4 s. The 24 h day is a little longer because Earth also moves along its orbit around the Sun.
  • Constellation A group of stars that, joined by imaginary lines, form a picture: Orion, Ursa Major, Scorpius. Its stars are usually very far from one another; they only look close together from Earth.
  • Celestial pole The point in the sky around which all the stars seem to turn. It is where Earth's axis points; in the northern hemisphere it is marked by Polaris, the North Star.
  • Celestial sphere A giant imaginary sphere, with Earth at the center, onto which we "pin" the stars. It does not really exist, but it helps locate any celestial object with two angles, like latitude and longitude on a map.
  • Declination The "latitude" of a star in the sky: how many degrees it is north (+) or south (−) of the celestial equator. Polaris has almost +90°.
  • Equinox The two days of the year (around March 20 and September 22) when day and night last the same everywhere in the world. On those days the Sun rises exactly in the east.
  • Seasons of the year Spring, summer, fall and winter. They do not happen because Earth gets closer to the Sun, but because its axis is tilted: for half the year one hemisphere receives sunlight more directly and for more hours.
  • Solstice The days when the Sun reaches farthest north (around June 21) or farthest south (around December 21) in the sky. They are the longest and the shortest day of the year in each hemisphere.

See the whole glossary →

References

  • Smart, W. M. (1977). Textbook on Spherical Astronomy, 6th ed. (rev. R. M. Green), Cambridge University Press: chs. I–II.
  • Green, R. M. (1985). Spherical Astronomy, Cambridge University Press: chs. 1–3.
  • Meeus, J. (1998). Astronomical Algorithms, 2nd ed., Willmann-Bell: chs. 12 (sidereal time), 13 (transformation of coordinates), 15 (rising and setting), 21 (precession).
  • Snyder, J. P. (1987). Map Projections — A Working Manual, U.S. Geological Survey Professional Paper 1395: §21 (stereographic projection).
  • Needham, T. (1997). Visual Complex Analysis, Oxford University Press: ch. 3 (inversion and stereographic projection).
  • Sinnott, R. W. (1984). Virtues of the haversine. Sky & Telescope 68, 159.
  • Todhunter, I. (1886). Spherical Trigonometry, 5th ed., Macmillan: chs. II–IV (fundamental formulas and the polar triangle).

Simulators for this lesson: Interactive planisphere