A *great circle* is a circle obtained by intersecting a sphere with a plane through the sphere's center.
The radius of a great circle is equal to the radius of the sphere. So it has the largest value possible for the radius of a circle
on the surface of the sphere. The shortest distance of two points on the surface is always part of a great circle.

In the drawing, the sphere is shown with some circles of longitude and latitude (parallel projection). In addition, the given points and the great-circle arc between them are highlighted (in red).

In the first line of the control panel radii from 1 000 km to 1 000 000 km can be inserted (don't forget the enter key!), whereby the earth radius is preset. Further input and selection fields allow the definition of two points on the surface of the sphere. The distance calculated from this information is displayed as an angle (in degrees) and as length (in km). By using the five small buttons, you can vary the direction of projection.

The following expression for the searched distance results from the *cosine rule* of the spherical trigonometry:

d = r · arccos (sin φ_{A} sin φ_{B}
+ cos φ_{A} cos φ_{B} cos (λ_{B} - λ_{A}))

r .... radius of the sphere

λ_{A} ... geographic longitude of point A

φ_{A} ... geographic latitude of point A

λ_{B} ... geographic longitude of point B

φ_{B} ... geographic latitude of point B

Practical hint for recalculation: The function arccos appearing here is the inverse function of the cosine function,
usually denoted cos^{−1} on pocket calculators. If you use the calculator
with the setting for degrees (usually DEG), you must be aware that the arccos value is displayed
in degrees. Only after you have converted the degrees into radians, you may multiply with the radius of the sphere.