Computing great circle distance between points P1 and P2 on a sphere width Radius R:
The points are given in polar coordinates latitude
(1) | |||||||
(2) | |||||||
where' |
|
Converting into cartesian vector format using the center of the sphere as (0,0,0):
(3) | ||||||||||
(4) | ||||||||||
width | ||||||||||
where' |
|
The unit vectors to the 2 points are:
(5) | ||||||||||
(6) | ||||||||||
where' |
|
The cosine of the angle
(7) |
And the great circle distance
(8) |
| ||||||||||||
where' |
|