I am programming a simple physics simulation and have been following along with some books about the subject. Everything has gone well so far, although at the moment I'm stuck on how to calculate the impulse when two rigid bodies collide. I'll explain the algorithms that I'm using below...