4

All GPS devices tell me how much positioning error there is in the fix (e.g. 12 meters). Then why does it not tell me anything before it has a very accurate fix?

When a device is looking for its location, I can see that it receives certain satellites, so it surely knows which side of the world I'm on. I'm assuming that at some point it will know which part of the country I'm in, even if it doesn't have it down to street level.

Is there something in the physics that prevent this, is it a hardware/firmware thing that I cannot fix even if I could rewrite the software part, or is it just the software giving up when it has too much error?

3

To answer your question strictly as asked, this behavior is due to the fact that most consumer GPS receivers and the NMEA protocol evolved from navigation applications.

In navigation hardware there is almost always an accuracy threshold that must be satisfied before a position is reported. This is to prevent users of the position, both human and computer, from acting on inaccurate data with possibly disastrous result.

Some GPS receivers allow you to set the accuracy criteria, others let you "see" inaccurate positions with the accuracy reported at the same moment. But in general there will be a pre-established threshold beyond which they will not report a fix.

There is nothing in the physics or mathematics to prevent reporting such positions as long as there are 4 satellites in the fix. It's purely user interface policy that prevents it.

|improve this answer|||||
  • Thank you for actually answering my question! This helps :) – Luc Apr 5 '16 at 5:23
3

From a cold start to obtain a lock to satellites, GPS needs to download coarse orbit information about all satellites (almanac).

At the rate GPS navigational signal is transmitted, it will take 12.5 minutes to download the entire almanac.

There are some improvements that can reduce this time, e.g. based on location obtained through cell phones, among other things. But before obtaining the lock, the GPS itself cannot tell. You may of course use other means to figure out coarse location information, such as which side of the earth you are on.

|improve this answer|||||
  • Thanks for your response, but it doesn't really answer my question. My phone downloads aGPS so the almanac is there (I assume, correct me if I'm wrong), it seems to be only about finding the correct time. Time to fix is about 130-200 seconds with moderately good signal. The thing is, very early on in the process it shows me 4+ satellites and where they are relative from me, but it does not give applications a clue whether I'm in Germany or on Hawaii. Is it deliberate in the hardware/software, or is it actually still impossible to tell at that point? – Luc Jan 27 '16 at 20:18
  • @Luc Depending on the GPS device you use, I guess the 4+ stars you saw might be from guesswork based on your location obtained, e.g. from other sources like your network, not the satellites. So if you are in Hawaii, it can guess your location based on your wifi location etc and predict which satellites you will see. So I think it may be possible to use that info. But GPS itself still needs to finish locking to do the real positioning. Again, the ways of improvement on the cold-start vary. – tinlyx Jan 27 '16 at 21:27
  • It's not that, though. Even in airplane mode (cell&WiFi off) it shows sats' location when it has enough signal (usually 4 is enough). My phone is assisted by all sorts of sensors (accelerometer, gyro, compass, barometer) but that doesn't explain why it can show me one thing (my location relative to 4+ sats) and not the other (my rough coordinates). Screenshot of such a situation: snag.gy/M3L4Q.jpg Before this screenshot, it did not show the position of sats when it saw only 3 or less, so it's not guessing at / deriving my position another way. – Luc Jan 28 '16 at 8:44
  • @Luc, why do you assume that your cell phone will show all the information it has? The rough coordinates from assisted means or dead-reckoning could be miles off and not pleasant to show and still good enough to figure out the visible satellites. Or the software engineer may have just neglected this use case. I am not asserting that this is the case. It's just that your logic is a bit problematic to me. – tinlyx Feb 2 '16 at 10:58
3

I would say it's more of a math thing. GPS uses trilateration to calculate location.

You need four satellites to get a proper position and my guess is that GPS units don't show anything until the minimum requirements have been met.

So, that's an all or none affair, rather than piecemeal like you are suggesting. I think that's especially true since one of the big components of calculating position is time.

Something along the lines of "you need all the variables in the formula in order to spit out the result."

You may be able to find the actual formulas and math on gps.gov as well.

I know that smartphones can speed up position locking by using tower locations, but I don't know how that works with GPS in terms of hardware or software. It sounds like tinlyx may have a better grasp of that than I do.

Other links that may be useful:

WhyDoesGPSRequire4Satellites

DiffBetweenTriangulationAndTrilateration

Addition: I found some more info that may be useful, although I'm not certain it fully answers your comment.

The following is an excerpt from this article:

When you measure the distance to four located satellites, you can draw four spheres that all intersect at one point. Three spheres will intersect even if your numbers are way off, but four spheres will not intersect at one point if you've measured incorrectly. Since the receiver makes all its distance measurements using its own built-in clock, the distances will all be proportionally incorrect.

The receiver can easily calculate the necessary adjustment that will cause the four spheres to intersect at one point. Based on this, it resets its clock to be in sync with the satellite's atomic clock. The receiver does this constantly whenever it's on, which means it is nearly as accurate as the expensive atomic clocks in the satellites.

In order for the distance information to be of any use, the receiver also has to know where the satellites actually are. This isn't particularly difficult because the satellites travel in very high and predictable orbits. The GPS receiver simply stores an almanac that tells it where every satellite should be at any given time. Things like the pull of the moon and the sun do change the satellites' orbits very slightly, but the Department of Defense constantly monitors their exact positions and transmits any adjustments to all GPS receivers as part of the satellites' signals.

This description suggests to me that GPS receivers receive an initial almanac showing satellite locations, but then go through an additional series of checks to ensure their locations are correct, so that any time and distance calculations are accurate. This would explain why you can see satellite positions, but not your location yet. The receiver has to wait until its internal clock matches the satellites before any calculations are made.

I also know that initial satellite almanacs can have some satellites in the wrong location, and only after receiving info from each satellite does the receiver know to update their positions before calculating distances and time. The next page of the article talks more about how receivers handle errors in location and time.

|improve this answer|||||
  • Thanks for your answer. I knew this already, I've searched pretty far and wide but I am not good enough with signals and math to understand it enough that I could build a receiver myself. In all research the one thing I haven't been able to find is why it can know which satellites are visible and where they are relative from me (GPS info apps show this in a radar-like view) and yet not even provide the slightest clue whether I'm in Afghanistan or Antarctica :/ – Luc Jan 27 '16 at 20:13
  • 1
    I think this is the answer you're looking for. It is a math thing. With 1 or 2 satellites, you could be at an infinite number of locations. At 3, you could be around 2 locations. At 4, your position is narrowed to within an error ellipse around a single location. 5+ satellites reduce the size of that error ellipse, thus giving you more accurate location information. It's not that the receiver just doesn't show you until the 4 sat minimum has be met. It's that it can't even solve the equation until the minimum has been met. – Wes Jan 28 '16 at 14:52

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.