I see that (F*dT) / M = dV but how do I get this to apply to two colliding bodies?
Also was my method of calculating the acceleration due to the gravitational pull of the other bodies and summing it correct?
thank you for your reply, I did make this modified version. I decided starting with a simpler program will be best.
This is more like a black hole that sucks everything in.
So chiro, basically I want two bodies that collide to stick together (mass adds together) and travel at the new...
Hi everyone, I am new here, nice to meet you.
For fun I am trying to make a gravity simulator in c++ and using SDL.
I believe there is a problem in my merge function when I calculate the new velocity and trajectory of two colliding bodies.
Also, does my main code look accurate. The part...