4
$\begingroup$

So I know that all the geodesics on the sphere ($\mathbb{S}^2\subseteq\mathbb{R}^3$) lie on great circles. However, I have been having a bit of trouble coming up with a time parameterization of these great circle arcs. Specifically, if I have 2 points $(\theta_1,\phi_1)$ and $(\theta_2,\phi_2)$ that lie on $\mathbb{S}^2$ what is the function $\gamma:[0,1]\to\mathbb{S}^2$ such that $\gamma([0,1])$ is the geodesic that connects these two points?

This doesn't seem like it should be terribly difficult; however, I've been getting stuck. The reason that I care about this parameterization is that I am trying to get some visualization working in Mathematica.

$\endgroup$
  • $\begingroup$ Maybe use spherical coordinates? $\endgroup$ – IAmNoOne Aug 6 '16 at 0:32
  • $\begingroup$ What do you mean? If I just take $\gamma(t)=(1-t)(\theta_1,\phi_1)+t(\theta_2,\phi_2)$ I don't get a curve that lies on the great circle. $\endgroup$ – yousuf soliman Aug 6 '16 at 0:40
  • $\begingroup$ Well you are parametrizing a straight line. I think if you just fix one of the coordinates, you would get your great circle. $\endgroup$ – IAmNoOne Aug 6 '16 at 2:03
  • 1
    $\begingroup$ The coordinate function $\mathbf{x} = (\cos\theta \sin \phi, \sin\theta \sin \phi, \cos\phi )$ describes 1 patch of $S^2$. So if I fix $\theta$, I get one great circle was my idea. But I guess that isn't what you really want since you want to map from $[0,1]$. So actually we mayhave to do this in Euclidean coordinates. The idea should be the same. $\endgroup$ – IAmNoOne Aug 6 '16 at 2:13
  • $\begingroup$ @Nameless that makes a lot of sense and gives me the intuition on how to come up with what John Hughes answered below. $\endgroup$ – yousuf soliman Aug 6 '16 at 3:42
3
$\begingroup$

Use $$ \mathbf{x} = (\cos\theta \sin \phi, \sin\theta \sin \phi, \cos\phi ) $$

to get vector forms $v_1$, $v_2$ for your two points.

Let $$ w = v_2 - (v_2 \cdot v_1) v_1 \\ u = \frac{1}{\|w\|} w $$

(This is basically just Gram-Schmidt on the basis $\{v_1, v_2 \}$.)

Now let $$ \alpha(t) = \cos(t) v_1 + \sin(t) u $$ As $t$ goes from $0$ to $2\pi$, you'll traverse the great circle containing $v_1$ and $v_2$, starting from $v_1$, passing through $v_2$ before you get to angle $\pi$, and continuing on back to $v_1$.

If you want to stop at $v_2$, just let $t$ run from $0$ to $c$, where $$ c = \cos^{-1} (v_2 \cdot v_1). $$

$\endgroup$
  • $\begingroup$ Why did you need to normalize $w$? It doesn't seem that you use $u$ anywhere else. Should I use $u$ instead of $w$ in the definition of $\alpha$? $\endgroup$ – yousuf soliman Aug 6 '16 at 3:47
  • $\begingroup$ Sorry 'bout that. Yes, use $u$ instead of $w$. I'll edit. Normalizing $w$ is to put it back on the unit sphere, rather than being a much shorter vector. Notice that the whole thing fails if $v_2 = \pm v_1$, but in the case where $v_2 = v_1$, the constant path works, and when $v_2 = -v_1$, there's no single geodesic between them, so there's no easy way to pick just one. (Example: from north pole to south pole, any line of longitude will suffice as a great-circle arc.) $\endgroup$ – John Hughes Aug 6 '16 at 11:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.