Skip to content

Orbits and Gravitational simulations using OpenGL and C++

License

Notifications You must be signed in to change notification settings

TheMisterOdd/Gravity

Repository files navigation

Gravity

Orbits and Gravitational simulations using OpenGL and C.

The Algorithm

Firstly, the program calculates the gravitational force between all the celestial bodies by using this formula:

by using this other formula, the force formula:

the program can get the acceleration of a body:

now, apply this acceleration to this movement equation:

Example:

window output

About

Orbits and Gravitational simulations using OpenGL and C++

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages