An interactive, browser-based simulation of the three-body problem with realistic astrophysical units and dynamic visualisation. WORKS BEST ON PC OR LANDSCAPE MODE ON PHONE
Live demo: https://adilneaz.github.io/3-Body-simulator-/
See the full Development Log for a detailed timeline of how this project was built.
- Real physics using astronomical units (AU), solar masses (M☉), and km/s.
- Interactive controls: set initial positions, velocities, and masses for each body.
- Time control: adjustable simulation speed with pause/start buttons.
- Smooth zoom and pan: mouse-wheel zoom (centred on cursor), right-click drag to pan.
- Velocity-based trails: dynamic colour gradient (blue → red) based on each body's speed.
- Dynamic speed legend: log-scaled, draggable, with real-time min/max speed in m/s.
- Info panel: explains all units and controls; pauses simulation when open.
- Presets: Sun–Earth–Jupiter, binary + probe, and a figure-8 approximation.
This simulator visualises chaos in orbital mechanics — small changes in initial conditions can lead to vastly different outcomes, a hallmark of chaotic systems in astrophysics.
Use it to explore:
- Orbital stability and resonance
- Gravitational scattering and capture/ejection
- Sensitivity to initial conditions
- Open the Live demo link above.
- Click in the canvas to place/select a body; drag to set its initial velocity vector.
- Adjust mass (M☉), position (AU), and velocity (km/s) from the control panel.
- Scroll to zoom, right-click and drag to pan.
- Open the Help tab for unit explanations and controls.
MIT License © 2025 Adil Neaz
You are free to use, modify, and distribute this project, provided credit is given.
Created by Adil Neaz — open to collaborations and academic discussion. Email: AdilF0rmalAcc0unt@gmail.com