# What's the formula

## Recommended Posts

for converting distance to lat/long amounts? I used to have a link to a post that told me that but I just can't find it anymore. I know that the proportion for latitude will always be the same everywhere on the earth but that distance/longitude value will be larger at the equator. I've decided to write a quick and dirty app that will allow designers to apply an offset to all taxiway signs at once and I need to know if someone wants the signs to move say 3 meters to the east and 5 meters to the north, just how much to add or subtract from the lat/long values before rewriting the file. The app is basically done except for this formula. I could go out and find the darn circumference of the Earth and figure this out but I'm just too darned tired.Art

##### Share on other sites
 Help AVSIM continue to serve you!Please donate today!

>for converting distance to lat/long amounts? I used to have>a link to a post that told me that but I just can't find it>anymore. I know that the proportion for latitude will always>be the same everywhere on the earth but that>distance/longitude value will be larger at the equator. I've>decided to write a quick and dirty app that will allow>designers to apply an offset to all taxiway signs at once and>I need to know if someone wants the signs to move say 3 meters>to the east and 5 meters to the north, just how much to add or>subtract from the lat/long values before rewriting the file. >The app is basically done except for this formula. I could go>out and find the darn circumference of the Earth and figure>this out but I'm just too darned tired.>>ArtArt: It involves a little spherical geometry...but basically the circumference of the earth at a given latitude is proportional to the cosine of the angle of latitude. i.e., at the equator the earth has a mean radius of 3963 st. miles,therefore a circumference of approx 24,900 miles. The cosine of 10* is 0.9848, therefore at 10* north the circumference would be 24,900 x 0.9848. Divided by 360, that would be 68.117 miles per degree longitude, or 99.9 feet per second of longitude. At 80* north it is down to about 17.6 feet per second of longitude. As you say, N-S is pretty much a constant of 101.28 feet per sec of latitude. Hope that helps.Metric: Circumference of earth at equator=40,075.16 km. More than you want to know...circumference at poles about 67 km less than at equator.(0.17% difference)

##### Share on other sites

Hi Art,That all depends on the earth model that you are using of course :). And on the projections used, etc.If you assume the earth is a perfect sphere then for the y direction (north) it would mean that 2*pi*Rearth/360 is the amount of meters covered by one degree. I don't know the radius of the earth by heart (something like 6735 km or so, you would have to check that).For the x direction (east) you would have to multiply with the cosine of the latitude. But as you are also moving in that direction this will give a small error of course. So you might want to take the average of the two latitudes or so.If you take a more complex earth mou can not calculate it that easily. At work I use the Proj4 library to do transformations between different coordinate systems. You might want to take a look at that as well.

##### Share on other sites

Hi Art,I use a Constant and a Function (in Visual Basic):Public Const MeterPerDegLat As Double = 111330# Public Function MeterPerDegLon(ByVal lat As Double) As DoubleMeterPerDegLon = Cos(lat * PI / 180#) * 111330#End FunctionLuis

##### Share on other sites

Hi Art,I use a Constant and a Function (in Visual Basic):Public Const MeterPerDegLat As Double = 111330# Public Function MeterPerDegLon(ByVal lat As Double) As DoubleMeterPerDegLon = Cos(lat * PI / 180#) * 111330#End FunctionLuis

##### Share on other sites

Here's a good online calculator, which might give what you want:http://www.wherearewe.co.nz/geodetics.htmlscott s..

##### Share on other sites

Howdy,and don't forget that there may be a difference between the real world and what the FS designers used as an earth model. For example, here's what the Creating Terrain.doc from the Terrain SDK says (p.18):In Flight Simulator, the earth is defined as an

##### Share on other sites

Thanks all. For my purposes ballpark was all I needed since the amounts I'm trying to offset things are a judgment call anyway. I actually came up with the answer on my own after a little research and a brushup on my trig.Art

##### Share on other sites

I think SceneGenX build 42 already provides what you need?http://forums.avsim.net/user_files/129210.jpgscott s..

##### Share on other sites

ah wonderful. That's one product I haven't played with yet.Art

## Create an account

Register a new account

• 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!