Closed Gabrieldowen closed 8 months ago
Great job figuring out the haversine algorithm for computing distance between points on a sphere. The math looks right for that, but honestly it's hard to sight read all the sines/cosines/tangents and confirm it's all in the right order and everything :)
I'd love to see some unit tests for this code. At the very least, let's vet that if we call getPath with two points "very close" to one another that we get back a two-element list and match the origin and destination with no points in between vs. calling getPath with two "further away from one another" points that require some intermediate steps.
to run uncomment the test at the very bottom of the file
getPath inputs: startLat = start airport latitude, startLong = start airport longitude, destLat = destination airport latitude, destLong = destination airport longitude, radius = radius of each API call, pathWidth = the width of the flight path that you want NOTAMs from
How it works: