Timeline for Shift a lat/lon coordinate based on a distance and direction?
Current License: CC BY-SA 4.0
8 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Feb 2, 2021 at 19:12 | comment | added | Daniel Connelly | I was assuming "moving in the direction of a compass bearing" implied following a constant bearing (neglecting magnetic compass issues). You're right -- if you're going to find a geodesic instead (a "great circle route") then that's different, and is more easily solved. | |
Feb 1, 2021 at 22:19 | comment | added | FSimardGIS | The type of path that you calculate here is called a rhumb line (loxodrome), a path with constant bearing, which is very different from a geodesic. For the very small distances mentioned in the OP, and away from the poles, the difference should be negligible, but increases quickly when the distance gets longer. A 10,000 km loxodrome starting at (0,0) lands you in northern siberia, while a 10,000 km geodesic with the same start point and bearing will land you in China. | |
Feb 1, 2021 at 19:21 | comment | added | Daniel Connelly | That's very interesting -- I looked up the iterative Vincenty equations on Wikipedia and they are fairly complex, and are still just an approximation. To test my very simple algorithm, I calculated the result of starting at (0, 0) and moving northeast for 10000 km. coordinates listed as latitude, longitude: 5000 points: 63.6396103067921 83.17349983439119: reference 1000 points: error = 1.4 meters 200 points: error = 37 meters 10 points: error = 14.7 km The error is inversely proportional to the square of the number of points. So it comes down to more iterations vs complexity. | |
Feb 1, 2021 at 18:45 | comment | added | Vince | Actually geodesic functions capture the whole distance (short of antipodal distance, of course) quite easily. Iterative application of the Vincenty equations is part of every library that implements the Direct/Forward solution. | |
Feb 1, 2021 at 18:35 | history | edited | Daniel Connelly | CC BY-SA 4.0 |
I realized my initial response for an iterative solution to each segment was too complicated, since the change in latitude is independent of coordinates for a given heading and distance. It's only change in longitude which changes.
|
Feb 1, 2021 at 18:27 | review | Late answers | |||
Feb 1, 2021 at 19:57 | |||||
Feb 1, 2021 at 18:17 | review | First posts | |||
Feb 1, 2021 at 18:34 | |||||
Feb 1, 2021 at 18:11 | history | answered | Daniel Connelly | CC BY-SA 4.0 |