Two spacecraft-relative angles fully constrain a 3D position: the camera photographs reference bodies A, B, C against the star background and measures the angular separation between each pair. Each measured angle traces out a surface of points that would see that same separation; three known bodies give three such surfaces, and their intersection — solved iteratively — pins down the probe.
residual = θ_measured − θ_model(P̂)
P̂ ← P̂ + (JᵀJ + λI)⁻¹ Jᵀ·residual (Gauss–Newton, seeded from the prior estimate)
- Free explore — drag the sliders to move the probe's true position; the triangulation re-solves every frame purely from the noisy angle measurements plus the bodies' known ephemerides, never by reading the true coordinates directly.
- Mission cruise — dead reckoning just propagates the planned trajectory and never learns about unmodeled drift (solar pressure, thruster bias), so its error grows without bound. Celestial fix re-triangulates every few days and snaps the estimate back near the truth, keeping the error tightly bounded over the whole cruise.
- Sensor noise — a real star tracker's angle-measurement precision; higher noise widens the bounded error band and adds jitter to the free-explore fix.
This is exactly how deep-space probes navigate beyond Earth orbit, where GPS doesn't exist and round-trip radio ranging can take hours: optical angles to known bodies, triangulated on board, with no external signal required.