Contents · Physics Engines
Part 0 · Orientation
Part 1 · Mathematical Foundations
Part 2 · Equations of Motion
- The Manipulator Equation
- Featherstone: ABA, CRBA, and RNEA
Part 3 · Time Integration
Part 4 · Collision Detection
Part 5 · Contact & Constraints
Part 6 · Constraint Solvers
Part 7 · Position-Based Dynamics
Part 8 · GPU & Parallelism
Part 9 · Differentiable Simulation
Part 2 · Equations of Motion
The Manipulator Equation
Part 1 ended with the equation of motion. Here is where it comes from, what each term does, and the two directions you can run it.
One equation, two derivations
The Lagrangian route starts from energy. With (kinetic minus potential), the Euler-Lagrange equations grind out, after substituting , exactly
The Newton-Euler route writes and for every body and projects onto the joint axes. It produces the same equation, and done recursively over the tree it is the RNEA algorithm of the next chapter. Both give the standard manipulator form, with symmetric positive definite, the Coriolis and centripetal terms, and gravity.1
Reading the three terms
- : inertia felt at the joints. Configuration dependent, as the mass matrix demo showed.
- : Coriolis and centrifugal forces. Quadratic in velocity, the bookkeeping cost of describing motion in a rotating, moving frame.
- : gravity.
Run the arm along a prescribed motion and watch inverse dynamics split the required torque into those three parts:
Two directions
- Forward dynamics. Given torques, find the acceleration, . This is what a simulator does every step.
- Inverse dynamics. Given a desired acceleration, find the torque that produces it. This is what a controller does, and what the demo computes.
Both look like they need , an operation if you form and factorize . You do not have to. Featherstone's articulated-body algorithm computes forward dynamics in , and its inverse-dynamics sibling RNEA is also . That is the next chapter. It is also worth knowing that the derivatives of this equation, and , have closed-form algorithms too,2 which is what makes minimal-coordinate engines like Drake differentiable and usable inside trajectory optimization.
Footnotes
-
Lynch & Park, Modern Robotics (2017): "M(θ) is the symmetric positive-definite mass matrix, c(θ, θ̇) is the vector containing the Coriolis and centripetal torques, and g(θ) is the vector containing the gravitational torques." ↩
-
Carpentier & Mansard, Analytical Derivatives of Rigid Body Dynamics Algorithms (RSS 2018). ↩