# Great Circle

## Recommended Posts

Ok... here's a challenge. *sigh*In a GPS Direct To flight plan there are only 2 waypoints. One can not simply draw a straight line from point a to point b and see the navigation track. It has to be rendered in an arc because it follows a great circle.I've yet to figure out how to accomplish this math-wise. Anyone have ideas/suggestions/info?

##### Share on other sites

hi,You can found the Great circle math-formula in the aviation Formulary V1.43:http://williams.best.vwh.net/avform.htmcheers

##### Share on other sites

It mostly depend on the projection type you choose for the display! the Reality XP Sandel use a mercator projection, and I've created a complex function to draw the curve arcs. However, in the Airbus, I use a anzimuthal projection which is less sensible to deformations (and cope well so far in drawing straight lines).Basically, I approximate the curve with a series of well chosen segment lengths. It depends on the range factor and GC dist for the segment.Hope this helps!

##### Share on other sites

>It mostly depend on the projection type you choose for the>display! the Reality XP Sandel use a mercator projection, and>I've created a complex function to draw the curve arcs.>However, in the Airbus, I use a anzimuthal projection which is>less sensible to deformations (and cope well so far in drawing>straight lines).>>Basically, I approximate the curve with a series of well>chosen segment lengths. It depends on the range factor and GC>dist for the segment.>>Hope this helps!So... how are you defining the arc radius?

##### Share on other sites

>hi,>You can found the Great circle math-formula in the aviation>Formulary V1.43:>>http://williams.best.vwh.net/avform.htm>>cheersNot what I asked, but thanks. ;)

##### Share on other sites

Well, I don't define the arc radius per-see, I travel along the GC heading for a given distance, and this gives me a lat/lon point I can draw a segment between. If choosen not too loose but not too close (to save computation/drawing time), you can approximate the arc via a series of segments quite nicely. I've tested this against the GNS 430/Sandel gauge and both were giving quite similar results, for 2 distant points when flying in the middle of the distance of the two.

##### Share on other sites

>Well, I don't define the arc radius per-see, I travel along>the GC heading for a given distance, and this gives me a>lat/lon point I can draw a segment between. If choosen not too>loose but not too close (to save computation/drawing time),>you can approximate the arc via a series of segments quite>nicely. I've tested this against the GNS 430/Sandel gauge and>both were giving quite similar results, for 2 distant points>when flying in the middle of the distance of the two.Ok... was hoping there was a simple method to do this... guess not. ;)

##### Share on other sites

>>hi,>>You can found the Great circle math-formula in the aviation>>Formulary V1.43:>>>>http://williams.best.vwh.net/avform.htm>>>>cheers>>Not what I asked, but thanks. ;)Don't be so hasty! You can use this to calculate any intermediate points along the arc based on some fraction of the total distance between the end points:------------------------------------------Intermediate points on a great circleIn previous sections we have found intermediate points on a great circle given either the crossing latitude or longitude. Here we find points (lat,lon) a given fraction of the distance (d) between them. Suppose the starting point is (lat1,lon1) and the final point (lat2,lon2) and we want the point a fraction f along the great circle route. f=0 is point 1. f=1 is point 2. The two points cannot be antipodal ( i.e. lat1+lat2=0 and abs(lon1-lon2)=pi) because then the route is undefined. The intermediate latitude and longitude is then given by: A=sin((1-f)*d)/sin(d) B=sin(f*d)/sin(d) x = A*cos(lat1)*cos(lon1) + B*cos(lat2)*cos(lon2) y = A*cos(lat1)*sin(lon1) + B*cos(lat2)*sin(lon2) z = A*sin(lat1) + B*sin(lat2) lat=atan2(z,sqrt(x^2+y^2)) lon=atan2(y,x)------------------------------------------Take the total distance between the two end points, then divide that by some arbitrary number of points you wish to calculate, then draw your segments accordingly!f=0.0-----departure apt = lat1,lon1f=0.2-----intermediate point at 2/10ths totalf=0.4f=0.6f=0.8f=1.0-----destination apt = lat2,lon2The number of "calculated intermediate points" could be based on the total distance. If < 500nm use 4 points, >500 & < 1000, use 6 points, etc.

##### Share on other sites

It will take more points than that to show the aircraft actually on the route.

##### Share on other sites

>It will take more points than that to show the aircraft>actually on the route.Granted... however if the calculation is written as a func(); you can call it as often as desired in realtime to keep track of your track... :)Let's see, "now I'm here, and there is where I'll wind up, where will I be in - say - another 10nm?"For that matter, how long would it take to calculate and populate an array of - say - 100 points? 1000 points?

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×

• Tom Allensworth,
Founder of AVSIM Online

• ### Hot Spots

• Flight Simulation's Premier Resource!

AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!