geoprimsField-grade geospatial math

Route legs, courses, and totals

Each leg's distance, true and magnetic course, and cumulative distance for a route of waypoints, with leg times and arrival times from a groundspeed and departure time.

Planning and education aid. Not for primary navigation. Full disclaimer

370.8NM

The route is 370.8 NM in 3 legs.

Legs
FromToDistanceTrue courseFinal true courseDeclinationMagnetic courseCumulative distanceLeg timeArrival time
KDENKASE108.9 NM250 deg249 deg7.3 deg243 deg108.9 NM54 min09:54
KASEKGJT77.6 NM266 deg265 deg8.4 deg258 deg186.5 NM39 min10:33
KGJTKDEN184.4 NM75 deg77 deg9.1 deg66 deg370.8 NM1 h 32 min12:05
Route
LatitudeLongitudeName
39.8617000 deg-104.6731000 degKDEN
39.2232000 deg-106.8688000 degKASE
39.1224000 deg-108.5267000 degKGJT
39.8617000 deg-104.6731000 degKDEN
Total time
Arrival time
Arrival time (UTC)
Legs
Provenance
Computed by
navigation.route.legs 1.0.0, core 0.1.0
Model
Geodesic (Karney 2013) legs on WGS 84; magnetic declination from WMM2025 at each leg's start
Accuracy
Distances and courses to nanometers; declination per WMM2025 (about ±0.5° typical)
Reference data
version WMM2025 (2024-11-13) of a reference dataset
Notes
None
Cites
Karney, C. F. F., Journal of Geodesy, Algorithms for geodesics; NOAA National Centers for Environmental Information and British Geological Survey, The US/UK World Magnetic Model for 2025-2030: Technical Report

Something look off?

Your values

Showing an example. Change anything.
KML, KMZ, GPX, GeoJSON, CSV, WKT, or WKB — or drop it on the box. Read on this device.
More options 4
Run many at once from a CSV

Loading…

How we got thisFormula, worked example, sources, and proof

Model: Geodesic legs (Karney 2013) on WGS 84; magnetic declination from WMM2025

Accuracy: Distances and courses to nanometers; declination per WMM2025 (about ±0.5° typical)

When to use this: Use this to turn a list of waypoints into a flight or voyage plan: the distance and true course of every leg, the running total, and, with a groundspeed and a departure time, how long each leg takes and when you arrive. It is the table a navigation log is filled in from.

Limitations: The legs are geodesics, the shortest way between each pair, so the course changes continuously along one and the figure given is the course leaving the waypoint; a rhumb line holds one heading instead and is the other tool. The time assumes the groundspeed given holds for the whole route, which is a planning figure and not a forecast: wind, climb, and descent are not in it. Courses are true, not magnetic, so a compass needs the variation applied.

Worked example: Denver to Aspen to Grand Junction to Denver at 120 kt. Source: navigation route-geometry scenario: a 4-waypoint route shows true and magnetic courses per leg, with the declination and model.

You enter

Date for magnetic courses
2026-09-18
Departure time
09:00
Groundspeed
120 kt
UTC offset
-06:00
Waypoints
KDEN, 39.8617, -104.6731 KASE, 39.2232, -106.8688 KGJT, 39.1224, -108.5267 KDEN, 39.8617, -104.6731

You get

Total distance
370.8 NM
Total time
3 h 05 min
Arrival time
12:05
Arrival time (UTC)
18:05Z
Legs
3

Review: Not yet independently reviewed by a geodesist.

Last verified: 2026-09-18, when a maintainer last confirmed this tool's sources at the issuer. See the sources ledger.

Status: version 1.0.0, core 0.1.0. See this tool in the verification report.

Changes

Checked against: 22 golden test vectors (download the test vectors, each with its source and tolerance). See how results are checked and every source.

Sources

Terms

UTC: Coordinated Universal Time
The world's civil time standard, kept within 0.9 s of Earth's rotation by leap seconds. Aviation calls it Zulu time, written with a Z. Source: IERS Bulletin C (leap seconds)