Great-circle navigation

Strange but true: if you keep flying to the west from the Netherlands, you will eventually reach Canada, but not along the shortest path. The shortest track first heads for the northwest, and follows a so-called great circle. On many maps, depending on their projection method, such a great circle is not a straight line, but an arc.

The flight path between Seattle in the northwest of the United States and Amsterdam in the Netherlands (both a long way south of the polar circle) has its northernmost point off the west coast of Greenland, with Baffin Land facing it at the other side of that sea. This is at 69.5 degrees north, well north of the polar circle. Along the way, the heading changes from northeast to east and then southeast.

The journey from Cape Town to Hawaii (Honolulu), contrary to intuition passes over Antarctica, well south of the South Shetland Islands.

It‘s also amusing to go almost straight north. Close to the north pole the northerly course suddenly begins to change to southerly, although the journey continues in a straight line.
The magnetic heading is quite a different matter, because the magnetic and geographical north pole do not coincide, and their position relative to each other even changes over the years. (The magnetic north is not supported by the program below.)


Here is a program to calculate headings and distances:

Modifications 31 March 2006:


The program prompts for a point of departure, expressed in geographical coordinates: the latitude, for example 52.6.30 means 52 degrees and 6 and a half minutes north. South latitude is indicated by a negative number.
Then follows the geographical longitude, eastern longitude is positive, western is negative.
The next entries that can be made is the heading of departure and a distance in nautical miles. A nautical mile is equal to a minute of arc along the surface of the earth, or 1852 meters.
The program responds with the geographical position of arrival.

The other possibility is to press the enter key immediately after specifying the point of departure. The program then prompts for the destination, and responds with distance and the headings of departure and arrival. After the next press enter of the enter key a list appears of intermediate locations, at distances of 10 nautical miles, each with the distance, position and course. Because this is usually a rather long list, it is often more convenient to redirect the output, and perhaps also the input, from/to a file, by invoking the program as follows:

grcirnav < in > out
or:
grcirnav in > out

Example of the contents of an input file:

52
6
(Enter)
60
-174
(Enter)

Positions of some prominent locations on the globe:

-41°15′  174°46′  Wellington
-33°55′  151°12′  Sydney
 -7°15′  112°45′  Surabaya
 -6°10′  106°49′  Jakarta
 25° 3′  121°34′  Taipei
 35°43′  139°45′  Tokyo
 40° 0′  116°30′  Beijing
 45°30′  -73°36′  Montreal
 40°45′  -74° 0′  New York
 42°25′  -71° 5′  Boston
 47°38′ -122°20′  Seattle
 33°56′ -118°24′  Los Angeles
 37°25′ -122°30′  San Francisco
 21°25′ -157°50′  Honolulu
  5°50′  -55°10′  Paramaribo
  4°30′  -74°30′  Bogotá
-34°40′  -58°30′  Buenos Aires
-54°48′  -68°18′  Ushuaia
-23°40′  -46°35′  São Paulo
 10°54′  106°50′  Saigon
 55°45′   37°36′  Moscow
 52°22′    4°55′  Amsterdam
 51°30′   -0°05′  London
 38°42′   -9°10′  Lisbon
 19° 0′   72°55′  Bombay
 26° 0′   32°40′  Maputo (Lourenço Marques)
  6°30′    3°20′  Lagos
-33°58′   18°26′  Cape Town
-27° 9′ -110°27′  Easter Island
 30° 1′   31°13′  Cairo
 43° 8′  131°58′  Vladivostok
 61°13′ -149°54′  Anchorage
 51°10′ -114°02′  Calgary
 64° 9′  -21°50′  Reykjavik
 -4°     -38°     Fortaleza (Brazil)
 33°     -17°     Funchal (Madeira)

 36°56′7″ -25°08′9″ Vila do Porto (Santa Maria, Açores)
 37°44′1″ -25°40′3″ Ponta Delgada (São Miguel, Açores)
 38°39′0″ -27°13′4″ Angra do Heroísmo (Terceira, Açores)
 38°32′0″ -28°37′3″ Horta (Faial, Açores)
 39°05′   -27°59′9″ Santa Cruz (Graciosa, Açores)
 39°27′2″ -31°07′2″ Santa Cruz (Flores, Açores)
 39°40′1″ -31°06′5″ Corvo (Açores)

Calculations in the program are based on spherical trigonometry.
Spherical triangles are triangles that aren't in a plane surface, but on a sphere. The total of the angles in such a triangle is not 180 degrees, as in the case with plane triangles, but always more. It can be only slightly more than 180, if the triangle is very small in comparison with the size of the sphere. For example, a spherical triangle with three right angles is perfectly possible, giving a total of 270 degrees. One of these right angles can "fold open" to become 180 degrees (the total is then 360), and then the other two right angles can be widened too, eventually resulting in a total 540 degrees in the extreme case of a spherical triangle which every great circle also is.

When applied to flight paths, the sphere is the earth (which approaches the ideal spherical shape reasonably well), but such calculations also occur in astronomy and astrology, on an projected imaginary sphere, the celestial globe. Yet the calculations can be for real, even if the celestial globe itself does not really exist.

Formulas for the spherical trigonometry calculations were taken from "Mathematical Tables and Formulas" by Robert D. Carmichael and Edwin R. Smith, © 1931, 1962. Published by Dover Books, New York.
Chapter: Formulas from trigonometry, spherical triangles in general.


This is another site about the same subject.


See also World Dist.jar by Lee Sau Dan. To be run with the command
java -jar WorldDist.jar
or
java -cp WorldDist.jar WorldDist

Note that java is a case-sensitive language, so enter uppercase and lowercase letters as shown. Also, under Windows, depending on path settings, you may need to replace "java" by something like c:\windows\java.