← Tutorials

Tutorial Series · Part 2 of 27

Coordinates and Frames: Describing a Place Precisely

Explain latitude, longitude, height, ECEF and local navigation frames.

Series Context

Navigation from First Principles

This article is part of an ordered course. Use the previous and next links to stay in sequence.

A navigation computer needs a precise way to say where something is. “Liverpool” is useful to a human, but it is not enough for a filter, a map renderer or a GNSS receiver. Modern navigation commonly uses latitude, longitude and height tied to a geodetic reference frame such as WGS 84. NGA describes WGS 84 as a 3D coordinate reference frame for latitude, longitude and heights used in navigation, positioning and targeting.1

This post introduces three linked ideas:

  1. Earth is not a perfect sphere.
  2. Coordinates only mean something relative to a reference frame.
  3. A navigation algorithm often converts between global and local frames.

NOAA’s National Geodetic Survey defines geodesy as the science of accurately measuring Earth’s geometric shape, gravity field and orientation in space.2

The problem

A web map often displays latitude and longitude. An inertial navigation algorithm may prefer a local North-East-Down frame. A satellite-positioning equation may use Earth-Centred, Earth-Fixed coordinates. These are not competing truths; they are different coordinate descriptions of the same physical point.

The model

Use geodetic coordinates:

(ϕ,λ,h)(\phi, \lambda, h)

where ϕ\phi is latitude, λ\lambda is longitude and hh is ellipsoidal height.

A common conversion from geodetic WGS 84-style coordinates to ECEF is:

N(ϕ)=a1e2sin2ϕN(\phi)=\frac{a}{\sqrt{1-e^2\sin^2\phi}} x=(N+h)cosϕcosλx=(N+h)\cos\phi\cos\lambda y=(N+h)cosϕsinλy=(N+h)\cos\phi\sin\lambda z=(N(1e2)+h)sinϕz=(N(1-e^2)+h)\sin\phi

where aa is the semi-major axis and ee is ellipsoid eccentricity.

For a local navigation frame, define a tangent frame at a chosen origin. A small local displacement can be written:

Δrned=[ΔnΔeΔd]\Delta \mathbf{r}_{ned} = \begin{bmatrix} \Delta n \\ \Delta e \\ \Delta d \end{bmatrix}

where north and east are horizontal components and down is positive toward Earth.

Interactive demo: coordinate frame explorer

The demo below shows the same point in geodetic, ECEF and local coordinates at the same time. It uses a Liverpool-centred local map patch and live WGS 84 conversions to make the relationships visible.

Interactive Demo

Coordinate Frame Explorer

Origin Set

Drag the point across a small map patch, set a local origin, and compare the same location in latitude/longitude, ECEF, and local NED coordinates.

Red marks the chosen origin. Blue marks the current point. Use the toggles to compare the global and local frames.

Coordinate Readout

Lat, Lon -
Height -
ECEF x -
ECEF y -
ECEF z -
Local N, E, D -
Flat-Earth Distance Error -
Frame View -

Controls

What to watch

  • Dragging the point updates latitude, longitude, ECEF, and local NED together.
  • Setting a local origin makes the selected point read near [0, 0, 0] in the local frame.
  • Small east-west moves produce intuitive metre-scale changes in the local east component.
  • The flat-Earth approximation stays close nearby, but the readout makes it clear that it is still only an approximation.

Try this

Set the origin at Liverpool and drag the point a short distance east. Longitude changes, but the local-frame display keeps the motion readable as a simple metre-scale displacement.

Where this breaks

This post does not cover vertical datums, geoids, plate motion, epoch, map projections or survey-grade transformations. For beginner navigation, the key is to stop thinking of latitude and longitude as “just numbers” and start thinking in terms of coordinate frames.

Footnotes

  1. National Geospatial-Intelligence Agency, “World Geodetic System 1984 (WGS 84)”. https://earth-info.nga.mil/GandG/wgs84/ - Official reference for WGS 84 as a 3D coordinate reference frame for latitude, longitude and height in navigation, positioning and targeting. Accessed 2026-06-11.

  2. NOAA National Geodetic Survey, “Geodesy”. https://www.ngs.noaa.gov/INFO/geodesy.shtml - Defines geodesy as measurement and understanding of Earth shape, gravity field and orientation in space. Accessed 2026-06-11.