136 Chapter 7 Hard Constraints
5. For each collision, work out the exact time of the first collision.
6. Choose the first collision to have occurred.
7. If the first collision occurs after the end time, then we’ re done: exit the algorithm.
8. Remove the effects of the Step 2 update, and perform a new update from the
start time to the first collision time.
9. Pr ocess the collision, applying the appropriate impulses (no interpenetration
resolution is needed, because at the instant of collision the objects are only just
touching).
10. Setthestarttimetobethefirstcollisiontime,keeptheendtimeunchanged,
andreturntoStep1.
This gives an accurate result, and avoids the problems with interpenetration res-
olution. It is a commonly used algorithm in engineering ...