[Proj] Distance between pair of lat / lons

Charles Karney charles.karney at sri.com
Wed Dec 26 13:16:05 PST 2012


On 12/25/2012 11:46 AM, Jayesh Chaudhary wrote:
> Folks,
>
> We have been using GeoographicLib and it had a convenient function to
> calculate distance between two points with an error in the range of nm.
> I am familiar with PROJ4 but I don't see any such function in PROJ4. We
> do care about accuracy and therefore I am not willing to use simple
> methods that consider earth as perfect to compute such distance.
>
> Please let me know if there is such functionality exists in PROJ4.
>
> Thanks


The geod program in proj.4 version 4.8.0 is based on the work of Thomas
(1970).  The accuracy of this method is limited and the inverse method
fails for nearly antipodal points.

In the next(?) version of proj.4, geod will use the geodesic routines
from GeographicLib which cures the defects in Thomas' method.

I hope that this version will also add the geodesic routines in the
proj.4 library so that you can incorporate geodesic calculations into
any code which links against proj.4.

-- 
Charles Karney <charles.karney at sri.com>
SRI International, Princeton, NJ 08543-5300

Tel: +1 609 734 2312
Fax: +1 609 734 2662




More information about the Proj mailing list