My question in a nutshell is: Is there a correlation between the number of decimals used in GPS co-ordinates and the accuracy of the location?
Right now I happen to be working with the Android SDK but I'm sure this question can apply to many other geolocation SDKs. Basically, Android returns GPS coordinates with up to 14 digits. That seems like overkill in most situations. Lets say I needed accuracy down to about an area of 10 feet by 10 feet. How many decimals do I really need to worry about? The use-case that I'开发者_如何学运维m looking for is I want to know if a person is north or south of a particular latitude - how many digits would I need to store in the database and how many digits would I need to compare?
In New York City - which is a pretty representative latitude where people live - crossing a wide two lane street will take you about 25 meters and you'll traverse about 0.1 seconds of longitude.
If you are representing locations as 40°42'42.96"N 73°59'23.33"W, then 0.1 seconds means the difference between one side of the street or the other. Depending on how you count your "decimals" then ddd:mm:ss.ssss
should be accurate enough for human purposes. If you are looking at decimal degrees then ±ddd.fff'fff'fff
for each of latitude and longitude would be enough and leave you some slop for rounding error.
Do look at the linked page though, as geocoding has a lot of error built in as a result of how good multiple "fixes" are, and keeping track of extra digits can be helpful in pinning a location.
Latitude & longitude define a single point, not an area. Accuracy is a separate measurement, and for consumer GPS devices is at least several meters.
With regard to the number of digits needed to specify feet: It depends on where you are. A degree of longitude at the equator is about 110 km, but a degree of longitude here in Portland (45°N) is about 78 km1. So (at 45 N) every 4⁄100000° is about 10 feet when walking east or west.
1 (cos (45°) × earth's radius × 2π) / 360 ≈ 78 km
精彩评论