"rows": [ {
"elements": [ {
"status": "OK",
"duration": {
"value": 1624,
"text": "27 mins"
},
"distance": {
"value": 24345,
"text": "15.1 mi"
}
}, ....
When I divide 24345 feet by 5280 I obtain 4.6 miles. When I convert 24345 meters to miles, I obtain 15.1 miles. This is not what the documentation regarding units=imperial states. I would have expected that the "value" would have been 79872.
Any thoughts?
> Note: this unit system setting only affects the "text" displayed within "distance" fields. The "distance" fields also contain "values" which are always expressed in meters.
> --
> You received this message because you are subscribed to the Google Groups
> "Google Maps API Web Services" group.
> To post to this group, send email to
> google-maps-ap...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-maps-api-web-...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-maps-api-web-services?hl=en.
>
feet = meters * 0.3048;
feet = meters / 0.3048;
Do you really need that accuracy? that sort of accuracy is sub-atomic!
Just use 1609.344
> 1 meter = 0.000621371192 miles
>
> So 24345 meters times 0.000621371192 miles/meter equals 15.12728166924
> miles. Now precision begins to play a part. But all you need to do is to
> truncate the resulting miles at some desired decimal place (this step is
> also required in the divide by 5280 method).
>
> But don't you think that dividing feet by 5280 is simpler?
Frankly no.
But if you want feet its still trivial to get it.
I'm now having a problem with your response. Since Google did exempt distance from the rule, that will suffice. Let me know when you've programmed scientific applications. Then let me know your take on the error function.
--
You received this message because you are subscribed to the Google Groups "Google Maps API Web Services" group.
To post to this group, send email to google-maps-ap...@googlegroups.com.
To unsubscribe from this group, send email to google-maps-api-web-...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-maps-api-web-services?hl=en.
No offense Gus but
I think the question has been answered at this point and yes it is extremely annoying to have to manage units just for US consumers or simply put... the US.