Find the forces on the object. Find the new momentum (based on the force and the small time interval) Find the new position (based on the velocity and time interval). Simple. And it even works most of ...
The complex-step method is a clever way of obtaining a numerical approximation to the first derivative of a function, avoiding the round-off error that plagues ...