# Do geodesics close on an ellipsoid?

I want to calculate the shortest distance between two points (Point A and Point B) on the ellipsoid surface. For this I need to use geodetic passing through these two points. Well, if I continue this geodesic that I defined between 2 points along the ellipsoid, will the geodetic converge at point A again?

In some sources it was said that only meridians and equator are closed geodesics, this confused me.

• en.wikipedia.org/wiki/Geodesics_on_an_ellipsoid has lots of good info and plenty of diagrams. FWIW, a major contributor to the Wikipedia ellipsoid articles is Dr C. F. F. Karney, author of the excellent free geographiclib. Jun 7 at 13:24
• @PM2Ring this appears to be a python wrapper for it pypi.org/project/geographiclib Cool!
– uhoh
Jun 8 at 0:26
• @uhoh Indeed! I used geographiclib in Python here: math.stackexchange.com/a/1340899/207316 See the end of that answer for a GitHub link. Jun 8 at 9:05
• @PM2Ring as my copy of Smart's Spherical Astrometry is currently on the other side of the Earth, knowing that will come in very handy, in fact I can now use python to calculate just how far it is away from be including Earth's oblateness :-) Speaking of Math SE I've been having some fun recently 1 and now 2
– uhoh
Jun 8 at 9:35

No, in general, they don't close. (Though, as you say, some geodesics do.) Consider, for example, an oblate ellipsoid of revolution, and take two points on its equator such that the angle $$\alpha$$ between them is not a rational multiple of $$\pi$$. On a sphere, the only geodesic passing through tho points on the equator is the equator; but in our case, since the ellipsoid is oblate, if $$\alpha$$ is large enough (i.e., close enough to $$\pi$$), then there are shorter paths connecting the two points, so there are other geodesics passing through the two points. If we take one of these geodesics — let's say the one going through the northern hemisphere — and continue it past one of the two points into the southern hemisphere, it will behave symmetrically there and intersect the equator after another angle $$\alpha$$. And then after another $$\alpha$$, and so on. Since $$\alpha$$ is not a rational multiple of $$\pi$$, there will be infinitely many points where this geodesic intesects the equator, so it will never close.

• I understand very well, thank you @Litho.
– Sun
Jun 7 at 8:43
• The key is the word rational. On other surfaces, the same thing holds: only those curves which are in some way rational close. The simplest mathematician's torus (donut) is flat (so it's embedded in 4 dimensions, not 3), and is obtained by identifying (that is, declaring that they are identical) opposite sides of the unit square, so geodesics are straight lines, but only those with rational slope close. Jun 7 at 15:28