beginnercore concept~15 min

Trilateration

How distances alone reveal a position

Why it matters

Every satellite positioning solution begins as a trilateration problem: the receiver knows where the satellites are and how far away each one is, and must find the single point consistent with all of those distances.

Where are you?

Imagine a friend tells you just one thing: you are exactly 500 km from Nairobi. Where are you?

You cannot say. You could be anywhere on a huge circle drawn around the city. One distance, by itself, never pins down a location — and yet distance is essentially all a satellite receiver ever measures. So how does your phone turn a handful of distances into a single dot on a map?

The idea, before any mathematics

Add a second fact: you are also 400 km from Kampala. Now the possibilities collapse dramatically. There are only two places on Earth that are simultaneously 500 km from Nairobi and 400 km from Kampala — the two points where the circles cross.

Add a third distance and, in all but special cases, only one point survives. That is the whole idea of trilateration: each distance is a constraint, and enough constraints intersect at exactly one place.

Notice what we did not use: any angle, any bearing, any sense of direction. Only distances. That distinction is the single most common point of confusion, so it is worth saying plainly: trilateration uses distances; triangulation uses angles.

Seeing it

Picture each known point as the center of a circle whose radius is your measured distance from it. One circle is a world of possibilities. Two circles narrow it to two points. Three circles meet at one.

Try it yourself

Below is a live plane. Three blue stations sit at known locations, and the green receiver is the true position we are trying to recover. Each station draws a circle whose radius is its measured distance to the receiver. The orange cross is the position computed purely from those distances.

Drag anything. With no measurement noise, all three circles pass through one point and the computed position lands exactly on the truth. Then drag the noise slider up: the circles stop agreeing, no single point satisfies them all, and the solver has to settle for the best compromise — reported as a residual.

306090306090metersABC
True position
(55.0, 58.0) m
Estimated position
(55.0, 58.0) m
Position error
0.00 m
RMS residual
0.00 m
Solver status
converged
Iterations
5

Drag the green receiver and the blue stations. With zero noise the estimate (orange) sits exactly on the truth. Add noise and watch the circles stop agreeing — the estimate becomes the best compromise.

Play until two things feel obvious: first, that three constraints are what fix the point; second, that error does not just move the answer — it blurs it into a region of uncertainty.

Now the mathematics

Everything you just saw has a compact description. Let the unknown position be p=(x,y)\mathbf{p} = (x, y) and let station ii sit at si=(xi,yi)\mathbf{s}_i = (x_i, y_i). The distance from the position to station ii is:

psi=(xxi)2+(yyi)2\lVert \mathbf{p} - \mathbf{s}_i \rVert = \sqrt{(x - x_i)^2 + (y - y_i)^2}

Each measurement says this distance should equal the measured range rir_i. With perfect measurements we simply solve those equations. With imperfect measurements there is no exact solution, so we instead choose the p\mathbf{p} that makes the disagreement as small as possible — the one that minimizes the sum of squared residuals:

minp  i(psiri)2\min_{\mathbf{p}} \; \sum_i \left( \lVert \mathbf{p} - \mathbf{s}_i \rVert - r_i \right)^2

That is ordinary least squares. Because the distance equation is non-linear, we solve it by starting from a guess and refining it (a Gauss–Newton iteration), which is exactly what the interactive above does on every drag.

How this appears in engineering

In a real GNSS receiver, the "stations" are satellites whose positions are computed from broadcast orbit data, and the "distances" are pseudoranges — range estimates derived from signal travel time. They are called pseudoranges because the receiver's clock error adds an unknown common offset to every measurement, which is why real positioning solves for a fourth unknown (the clock) and therefore needs a fourth satellite. Trilateration is the geometric skeleton; the pseudorange concept adds the flesh.

Check your understanding

  • Why is one range measurement never enough to fix a position?
  • In the interactive, why does adding noise increase the RMS residual even though the true position never moved?
  • If three stations are arranged in a straight line, why does the solution become unreliable? (Try it: drag the stations collinear and watch the solver status.)

Where to go next

Trilateration answers how distances become a position. The natural next question is where the distances come from — which leads to pseudorange — and how the geometry of the satellites affects accuracy — which leads to dilution of precision.

Common misconceptions

  • Trilateration is the same as triangulation. It is not: trilateration uses measured distances, while triangulation uses measured angles.
  • Two distances are enough in 2D. Two circles usually leave two candidate points; a third distance is needed to resolve the ambiguity.

Key takeaways

  • Distances from known points constrain position geometrically.
  • In 2D, three circles generally intersect at one point; in 3D, three spheres leave a two-point ambiguity that a fourth measurement (or physical reasoning) resolves.
  • When distances carry error, the circles no longer meet at a single point, and the solution becomes a least-squares compromise with a measurable residual.

Continue exploring