thientung / winforms-geplugin-control-library

Automatically exported from code.google.com/p/winforms-geplugin-control-library
GNU General Public License v3.0
0 stars 0 forks source link

BearingInitial() is incorrect #48

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
To reproduce:
start = 43.60336, -110.7362
dest = 43.59431, -110.8273
Expected result = 262.22
Actual result = 277.84

The first two lines of the function BearingInitial() are as follows:
double lat1 = ConvertDegreesToRadians(destination.Latitude);
double lat2 = ConvertDegreesToRadians(start.Latitude);

I believe they should be:
double lat1 = ConvertDegreesToRadians(start.Latitude);
double lat2 = ConvertDegreesToRadians(destination.Latitude);

Original issue reported on code.google.com by joe.wake...@gmail.com on 22 Aug 2011 at 2:23

GoogleCodeExporter commented 9 years ago
Great stuff, I knew something was wrong with the Bearing code, thanks for 
catching this!

Original comment by fraser.c...@gmail.com on 26 Aug 2011 at 8:56

GoogleCodeExporter commented 9 years ago
This is fixed in the latest commit

Original comment by fraser.c...@gmail.com on 8 Oct 2011 at 12:45