Menu

Three-Body Problem

Interactive gravitational simulation of three bodies

A planet orbits two stars (P-type). The binary pair revolves around their shared center of mass while the planet circles both. Stable only beyond a critical distance.

Binary System

Presets

Playback

Display

Center On

Controls

Space Play / Pause
R Reset simulation
Drag to pan view
Scroll to zoom
Center On → follow a body

Tips

Circumbinary — planet must orbit beyond the stability limit (dashed circle)
Lagrange — switch to co-rotating frame to see tadpole / horseshoe orbits
Hierarchical — watch eccentricity chart for secular oscillations
ΔE monitors integration accuracy — keep it small
E 0.000 L 0.000 t 0.000 yr ΔE 0.000%
How to Use

Circumbinary (P-type): Two stars orbit their shared center of mass while a planet orbits both. Try Kepler-16b for a stable configuration, or "Unstable" to watch the planet get ejected. The dashed circle marks the approximate stability boundary.

Lagrange Points: Sun–Jupiter system with a massless test particle. Switch to the co-rotating frame to see kidney-shaped tadpole orbits around L4/L5, or horseshoe orbits that alternate between leading and trailing. L1 and L2 are unstable—the particle drifts away within a few orbits.

Hierarchical (S-type): A planet orbits Star A while a distant companion Star B perturbs it. Watch the eccentricity chart to see secular oscillation from the companion's gravity. The dashed ellipse shows the osculating (instantaneous) Keplerian orbit.

Figure-8: Three equal masses trace a figure-eight path—a famous exact solution discovered by Chenciner & Montgomery (2000).

Controls: Space to play/pause, R to reset, mouse wheel to zoom, drag to pan. Center on any body with the Center buttons.