A planet doesn't own all the space around it — the Sun's gravity always competes for the same territory. The Hill sphere is the region where the planet's own gravity dominates over the Sun's tidal pull, so a moon can stay bound to it:
r_H = a · (m / 3M)^(1/3)
a = planet's orbital distance from the Sun
m = planet mass, M = Sun's mass
This simulator does not just draw a circle and check a formula — it numerically integrates the real restricted three-body problem with a 4th-order Runge-Kutta method, in the planet's own orbital plane: the moon feels genuine Newtonian gravity from both the Sun and the planet every step, while the planet follows its own unperturbed Keplerian orbit. Position and velocity are advanced with:
a_moon = -GM_sun · r/|r|³ − GM_planet · (r−R_planet)/|r−R_planet|³
The main view is planet-centered, scaled in units of the Hill radius, with a dashed circle marking r_H and an arrow showing the instantaneous direction to the Sun. The small inset in the corner is a fixed top-down view of the whole system, showing where the planet currently sits on its own orbit. Push the speed slider well above 1.0× and the moon can be flung past the Hill boundary, where the Sun's tidal stretching wins and it drifts away for good. One extra real effect worth trying: flip between prograde and retrograde. Numerical studies (Hamilton & Burns, 1992) show retrograde moons stay bound out to roughly twice the distance of prograde ones, because a retrograde orbit fights the Sun's tidal torque instead of resonating with it.
- Planet — sets the mass ratio m/M that drives r_H.
- Distance from Sun — r_H grows linearly with a, so the same planet has a bigger gravitational reach farther out.
- Start distance / Orbital speed — the moon's initial condition, in Hill-radius units and multiples of the local circular velocity.
- Prograde / Retrograde — direction of the moon's orbit around the planet relative to the planet's own orbit around the Sun.