While implementing a physics engine or any rigid body simulation in 3D, you will probably need to model some constraints like contacts, friction or joints between the bodies. You can use a Sequential Impulse solver (as described in Erin Catto’s presentation at GDC 2009) or a PGS solver (as described in* Iterative Dynamics with Temporal Coherence* from Erin Catto) to solve the constraints. However, with both techniques, you will need to compute some quantities for each constraint like the Jacobian matrix or the bias velocity vector. Sometimes, it is difficult to find the appropriate documentation explaining how to model the constraints and how to derive those quantities. For instance, the contact and friction constraints are well explained in Erin Catto’s presentation at GDC or in *Iterative Dynamics with Temporal Coherence*. However, it is more difficult to find the derivation of some joints in 3D.

During the implementation of my physics library, I have written a document that explains how to compute those quantities for different types of constraints.

Here is the list of the constraints that are covered in the document:

– Contact and Friction

– Ball-And-Socket joint

– Slider joint (with motor and limits)

– Hinge joint (with motor and limits)

– Fixed joint

You can download the document here. I hope it will be useful.

Thank you very much, Great Article!

Amazing, great article, and Its easy to understand, thank you very much