Verlet Physics


Real time physics simulation is hard to get right. Numerical simulation, equations of motion, collision detection, and constraint solving are all very complex interrelated topics. Getting simulations to work takes a lot of effort.

Verlet integration, or related methods like position based dynamics, are nice ideas because they simplify the work involved with physics simulation considerably. They introduce their own limitations and their own way of thinking, but generally for physical systems involving "spheres" (really point masses because they have no rotational inertia), constraints, and static geometry, they're very stable and very fast. Collision detection and resolution is easy when everything is a sphere or signed distance field, and constraint resolution is intuitive since it involves moving things into legal positions using projection rather than solving for forces.

Below is a little interactive toy I made using verlet integration. I like to apply verlet integration a lot in games because the implementation is so simple and the code runs really fast. You can make 1D, 2D, and 3D systems (N dimensional works too but good luck visualizing it) with essentially the same techniques, and get nice physically based systems. The simulations are stable and adding constraints on the movement is easy. You can make "hacky" physics that runs really fast, looks just as good as real rigid body physics in most cases. This is really nice for secondary motion, since you can have real physics moving objects around reactively without needing to have the overhead of a fully featured physics engine.


figure 1 : verlet physics softbody using shape matching


Site Navigation

Homepage