php Programming Glossary: londelta
Measuring the distance between two coordinates in PHP http://stackoverflow.com/questions/10053358/measuring-the-distance-between-two-coordinates-in-php lonTo deg2rad longitudeTo latDelta latTo latFrom lonDelta lonTo lonFrom angle 2 asin sqrt pow sin latDelta 2 2 cos latFrom.. sqrt pow sin latDelta 2 2 cos latFrom cos latTo pow sin lonDelta 2 2 return angle earthRadius Edit As TreyA correctly pointed.. latTo deg2rad latitudeTo lonTo deg2rad longitudeTo lonDelta lonTo lonFrom a pow cos latTo sin lonDelta 2 pow cos latFrom..
|