Updated:  19 April 2007

Calculating Distances Between Two Points

There are many ways to calculate the distance between two points on the earth's surface, defined by their latitude and longitude. The methods vary in complexity and accuracy.

Generally the simpler the method, the less accurate it is.


[back to top]

Explanation of terms

L1 = latitude at the first point (degrees)
L2 = latitude at the second point (degrees)
G1 = longitude at the first point (degrees)
G2 = longitude at the second point (degrees)
DG = longitude of the second point minus longitude of the first point (degrees)
DL = latitude of the second point minus latitude of the first point (degrees)
D = computed distance (km)

[back to top]

Definitions


[back to top]

Great Circle Distance (Based on Spherical trigonometry)

This method calculates the great circle distance, and is based on spherical trigonometry, and assumes that:

D = 1.852 * 60 * ARCOS ( SIN(L1) * SIN(L2) + COS(L1) * COS(L2) * COS(DG))

Note: If your calculator returns the ARCOS result as radians you will have to convert the radians to degrees before multiplying by 60 and 1.852 degrees = (radians/PI)*180, where PI=3.141592654...


[back to top]

Spheroidal model for the earth

This method assumes a spheroidal model for the earth with an average radius of 6364.963 km. It has been derived for use within Australia.

The formula is estimated to have an accuracy of about 200 metres over 50 km, but may deteriorate with longer distances.

TERM1 = 111.08956 * (DL + 0.000001)
TERM2 = COS(L1 + (DL/2)
TERM3 = (DG + 0.000001) / (DL + 0.000001)
D = TERM1 / COS(ARCTAN(TERM2 * TERM3))

[back to top]

Comparison of methods

The table below shows distances calculated by each of the methods above. Vincenty's formulae (method 3), is the "best" answer and can be used for comparison with the others.

However, remember that the different methods compute different types of distance (great circle, geodesic etc), and you must decide which type of system (distance) you wish to use.

The test lines shown are neither exhaustive nor complete, but are indicative of the accuracies which may be obtained. Method 4 uses the GRS80 ellipsoid that is used with Geocentric Datum of Australia (GDA) coordinate system. This ellipsoid is effectively the same as the WGS84 ellipsoid used with GPS. All distances are in kilometres.

From Method 1 Method 2 Method 3
To Great Circle Approx. ellip. Vincenty's
A A 0.000 0.000 0.000
A B 111.120 111.089 110.861
A C 146.677 146.645 146.647
A D 241.787 241.728 241.428
A E 346.556 346.469 345.929
A F 454.351 454.237 453.493
A G 563.438 563.294 562.376
A H 1114.899 1114.616 1113.142
A I 2223.978 2223.420 2222.323
A J 3334.440 3333.612 3334.804
A K 4445.247 4444.156 4449.317
A L 5556.190 5554.843 5565.218

Point Latitude Longitude
A -30 150
B -31 150
C -31 151
D -32 151
E -33 151
F -34 151
G -35 151
H -40 151
I -50 151
J -60 151
K -70 151
L -80 151

[back to top]

For more information contact: geodesy@ga.gov.au