Geographic Distance Calculator

Geographic Distance and Radius Calculator

Object Library

The Geographic Distance and Radius Library is an object oriented class library that provides multiple methods to accurately calculate the distances between any two latitude and longitude coordinate pair.

  • Great Circle Distance formula
  • Sinnott's (Haversine) distance formula
  • Polar coordinate flat-earth formula

Determine what locations fall within a given distance from a particular coordinate and in what direction with optimized radius inclusion testing and compass bearing and directional methods.

Available in the Perl, PHP, and C++ programming languages. All versions share a common definition and naming convention for the coordinate object therefore we use a single description for each method.

The Perl version is designed for and requires Perl version 5 or above. The PHP version is designed for and requires PHP version 4 or above. The C++ version has no platform specific requirements and can be compiled with virtually any C++ compiler.


Perl Edition
Price: $29.95 USD

C++ Edition
Price: $29.95 USD

PHP Edition
Price: $29.95 USD


PDF Formatted Document Programmer's reference

Requires Acrobat Reader
Get Acrobat Reader