Parallel transport around a latitude of the unit sphere (source code)

= Parallel transport around a latitude of the unit sphere

On the unit <sphere> with <Riemannian metric>
$$
ds^2=d\theta^2+\sin^2\theta\,d\phi^2,
$$
fix a latitude $0<\theta<\pi$ and follow increasing $\phi$ through one circuit. In the <orthonormal frame> $e_\theta=\partial_\theta$, $e_\phi=(\sin\theta)^{-1}\partial_\phi$, the components $u,v$ of a parallel <tangent vector> satisfy
$$
\frac{du}{d\phi}=\cos\theta\,v,\qquad \frac{dv}{d\phi}=-\cos\theta\,u.
$$
For the initial <tangent vector> with <coordinate> components $(V^\theta,V^\phi)=(1,0)$, solving this constant-coefficient <ordinary differential equation> and converting $v$ back to a <coordinate> component gives
$$
(V^\theta,V^\phi)=\left(\cos(2\pi\cos\theta),-\frac{\sin(2\pi\cos\theta)}{\sin\theta}\right).
$$
The <parallel transport> is a rotation through $-2\pi\cos\theta$ in the <orthonormal frame>. Modulo $2\pi$, this equals the area $2\pi(1-\cos\theta)$ of the polar cap, as predicted by the <Gauss-Bonnet theorem>. The <coordinate> formula excludes the poles because $\partial_\phi$ degenerates there.