This project simulates the interactions between celestial bodies using Newton's Law of Universal Gravitation. It employs the SDL3 library for rendering graphics.
The Three Body Simulation aims to visualize the gravitational effects between three celestial bodies. It provides insights into complex orbital mechanics and the chaotic nature of three-body systems.
- Simulates gravitational interactions between three bodies.
- Uses SDL3 for graphical rendering.
- Simple to build and run.
To build the project, ensure that the dependencies for SDL3 are satisfied. You can follow these steps:
git clone https://github.com/Aurelien-vr/ThreeBodySimulation/
cd ThreeBodySimulation
make
./tbsOnce built, run the simulation with ./tbs. You will see a graphical representation of the three bodies interacting through gravity. You can adjust the initial parameters in the code to explore different scenarios.
-
Collision Handling: Currently, the simulation stops when bodies collide. Future work will include handling collisions more realistically.
-
Optimization: Performance enhancements may be necessary as the simulation scales to include more celestial bodies.
There is a memory leak that I haven't been able to identify.
This project is licensed under the MIT License. See the LICENSE file for more details.