Science and Technology, March 2023

How GPS Actually Knows Where You Are

A receiver never measures its distance to a satellite. It measures time, and multiplies. Everything else follows from that, including the requirement for a fourth satellite, the reason a cold start takes a minute, and the reason a positioning receiver is also one of the cheapest sources of precise time available.

A timing problem, not a distance problem

Each satellite carries atomic frequency standards and broadcasts the current time together with the parameters describing its own orbit. A receiver notes when the message arrived, subtracts the time it says it was sent, and multiplies by the speed of light to get a range.

The arithmetic is unforgiving. Light covers about thirty centimetres in a nanosecond, so a timing error of one microsecond is three hundred metres. Positioning to a few metres requires arrival time resolved to a few tens of nanoseconds, against a transmitter twenty thousand kilometres away moving at close to four kilometres per second. The entire design is organised around that requirement.

The fourth satellite

Three ranges from three known points are geometrically sufficient to fix a position in three dimensions. The system requires four, and the reason is the receiver's own clock.

Satellite clocks are atomic and actively steered from the ground. The receiver's clock is a cheap quartz crystal, wrong by microseconds at best, which is hundreds of kilometres of apparent range error. Crucially that error is not random across the measurements. Every range taken at the same instant carries the identical offset, because they share one bad clock.

So the receiver refuses to treat its clock as known and solves for four unknowns instead of three: the three coordinates and the clock bias. Four satellites give four equations, and the solution that makes all four ranges consistent also reveals exactly how wrong the receiver was. It then corrects itself.

Every receiver is also a clock

That side effect matters more than the position. A receiver holding a fix knows the time to within tens of nanoseconds, accuracy that would otherwise require an atomic standard. Disciplined oscillators built on this provide timing for mobile base stations, broadcast, power grid monitoring, and data centres, which is why the constellation is a single point of failure for infrastructure that has nothing to do with navigation.

Finding a signal below the noise

The civilian signal is transmitted at 1575.42 MHz, and by the time it reaches the ground it is weaker than the thermal noise inside the receiver. It cannot be found by looking for it, because there is nothing there to see.

It is recovered by correlation. Each satellite modulates its carrier with a distinct pseudorandom sequence of 1023 chips clocked at 1.023 million chips per second, repeating every millisecond, and the sequences are chosen so each correlates strongly against itself and weakly against every other. That is what allows the whole constellation to share one frequency.

The receiver generates the same sequence locally and slides it against the incoming signal until the correlation rises out of the noise. Spreading fifty bits per second across 1.023 million chips per second yields roughly forty three decibels of processing gain, and that gain is precisely what lifts the signal from below the noise floor into something measurable.

Acquisition searches two dimensions

Acquisition is therefore a search in two dimensions at once, over code phase and over frequency, because satellite motion shifts the carrier by kilohertz of Doppler and the receiver's own oscillator error adds more.

Why a cold start is slow

The navigation message runs at fifty bits per second. Each satellite sends its precise orbital parameters in frames repeating every thirty seconds, along with a coarse almanac for the constellation that takes twelve and a half minutes to receive in full. A receiver with no stored data must acquire a satellite, wait for its parameters, and repeat until it holds four.

The delay is bounded by the data rate, not by processing, which is why a faster processor does not help and why delivering those parameters over a network reduces a fix from a minute to a few seconds.

What limits the accuracy

Deliberate degradation was once the largest error of all. The civilian signal was intentionally dithered until the policy was ended in the year 2000, which improved civilian accuracy by roughly an order of magnitude overnight without any change to receivers.

Relativity is not optional

Two effects act on the satellite clocks in opposite directions. General relativity predicts that a clock in weaker gravity runs faster, and the satellites gain roughly forty five microseconds a day. Special relativity predicts that a moving clock runs slower, and their orbital speed costs them roughly seven.

The net is a gain of about thirty eight microseconds a day, which uncorrected accumulates into a ranging error growing by roughly ten kilometres daily and would render the system useless within hours. The correction is applied before launch by offsetting the onboard oscillator slightly low, so that once in orbit it appears correct from the ground, with the residual variation from orbital eccentricity corrected in the receiver.

Centimetres

Everything above measures the code, and code resolution limits accuracy to metres. The carrier underneath has a wavelength of about nineteen centimetres and can be tracked to a fraction of a cycle, which would give millimetre resolution if the receiver knew how many whole cycles lie between it and the satellite.

It does not, and resolving that unknown integer, using multiple satellites and frequencies alongside corrections from a nearby reference station, is what delivers centimetre accuracy from the same constellation that gives a phone several metres.

Note: the constellation is more accurately described as a timing service than a navigation service. Position is what falls out when four clocks are compared against one.