If we assume that the altitude is held constant, the great circle distance is correct. However if the radius of the circle is not constant how can the distance be calculated? In my case the altitude changes linearly from point1 to point2.

What is the correct way then, to calculate the distance between two Lat Long points with different altitudes?

closed as off-topic by Andre Silva, Kadir Şahbaz, Vince, LaughU, whyzar Apr 8 at 13:10

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This problem cannot or can no longer be reproduced. Changes to the system or to the asker's circumstances may have rendered the question obsolete, or the question does not include a procedure to enable potential answerers to reproduce the same symptoms. Such questions are off-topic as they are unlikely to help future readers, but editing them to include more details can lead to re-opening." – Andre Silva, Kadir Şahbaz, Vince, LaughU, whyzar
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 2
    You may get more error by treating the coordinates as spherical and including Z change than by using spheroidal computations and ignoring Z. The US Geodetic Survey has both 2D and 3D algorithms posted for both geodetic problems – Vince Dec 24 '16 at 1:44
  • 1
    First you should ask yourself how you are travelling. Are on flying or on he ground ? – radouxju Dec 24 '16 at 13:06
  • 1
    That is a good question to ask. As I didn't want to get into orbital dynamics, I use a simple interpolation for the altitude and an existing great circle distance. The interpolation reduces to using the average altitude for the great circle calculation. And that worked perfectly well for my application. – esdanol Aug 21 '18 at 17:10