![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgwizjCoVUpQJcoC3a5HuuRPHfDzn-G-DBODkM-F5Wz9wmDNcR2PllErYF63aCzzUC7pwo0ahyphenhyphenT8GrD4gztwL2YGAhg3YGMDMEz3LVFFDLlbKMXHXk1x4UklH4kF4LhtL5_d7I9X-lU0PuY/s400/earth.jpg)
Now we all know the shortest path between two points is a straight line. Unfortunately, unless you believe the Flat Earth Society, any journey between two points on Earth usually requires you to make a bit of an arc in your journey. Therefore, when you measure a distance on a two dimensional map, your calculations are likely to be wrong, unless you allow for the curvature of the Earth.
Luckily Chris Veness has created a JavaScript that uses the 'Haversine' formula to calculate great-circle distances between two points and view the result on a Google Map. The script can do a few other things as well, such as work out the destination point given a distance and a bearing from a start point, work out a rhumb line and even show the intersection of two paths given the start points and bearings.
To top it all off the script is available for free under a Creative Commons license.
_____________
0 comments:
Post a Comment