Haversine formula to calculate the great-circle distance between two pairs of latitude and longitude coordinates.