For example, lets say I have two parallel roads with starting point and ending point 1 mile apart.

The left hand road is as flat and straight as an arrow.

The right hand road is also straight....but has a series of sine-wave shaped hills and valleys.

Obviously, if I measure using a Surveyor's wheel, the second path will be longer, even though both roads are starting and ending a mile apart.

My question: which measurement does google maps use? Does it account for difference in elevation adding to the travel distance?


3 Answers 3


I doubt it. Since the length of a sloped road would be sqrt(1+x^2)-times the length of the flat one (where x is the slope). For low values of x, this is roughly 1+1/2*x^2, which is rather low, eg. for a 10 % slope, you get an error of 0.5 %. Not considering the actual lane you drive probably has a similar error.

  • also in extreme cases a hilly road is likely to have speed restriction on it which routing algorithms can use to make a choice
    – jk.
    Oct 12, 2011 at 13:54
  • 2
    Don't know why this was closed as off topic. I was planning on implementing a similar system for calculating travel distance in a game, and wanted to know how the big boys do it. Thanks for providing an example in the slope equation though. :). Oct 12, 2011 at 15:01

Even a very steep 10% grade is only 1/2% longer than a flat road covering the same horizontal distance.


It does in cycling mode. Not because of the difference in the distance, but trying to minimise the total climb

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.