Dynamics
SuperDex Physics advances mechanical systems by stable implicit time integration of their equations of motion. This page introduces the continuous system dynamics, describes SuperDex Physics' unified implicit time integration, and discusses how problem structure can often be exploited to formulate the implicit equations as an optimization problem within each step.
System Dynamics
Much of the dynamics simulated by SuperDex Physics can be expressed in the framework of classical Lagrangian mechanics, although it needs to be augmented with additional non-conservative forces to include dissipative mechanisms.
Let be the generalized configuration and its generalized velocity. When is a vector space, tangent-space increments can be added directly. Rotations, articulated poses, and rod frames instead lie on nonlinear configuration manifolds, so SuperDex Physics applies increments in a tangent space and maps them back to with type-specific updates.
Define the Lagrangian
where is kinetic energy and is the total conservative potential. The Euler–Lagrange equations are
where contains nonconservative generalized forces. When dissipative forces derive from a dissipation potential ,
and the equations can be written as
Here, collects forces not represented by or . Depending on the system, the total conservative potential can include elastic, gravitational, contact, constraint, and applied-load terms. The actor pages define the forms of , , and used by each model.
Time Integration
SuperDex Physics advances differential variables governed by
with a unified family of implicit multistep and Runge–Kutta methods. Each method first combines completed-step states, then solves one or more implicit stages. Backward Euler is the default. Kennedy and Carpenter (2016) provide a detailed review of diagonally implicit Runge–Kutta methods, which the reader may find helpful for additional background information.
Unified Formulation
A multistep method uses states from multiple completed time steps, whereas a multistage method evaluates one or more intermediate stage states within the current time step. The formulation below combines both structures: the coefficients and define the -step structure, while the coefficients defining the -stage structure are canonically expressed as a so-called Butcher tableau , to facilitate the algebraic definitions below. Readers interested in a high-level conceptual overview of implicit integration may consider substituting and into these formulas to recover the simplest case of backward Euler. The full list of supported methods is given in the Available Methods section below.
Define the multistep base state
where the first coefficient multiplies the most recent completed state . Let denote the full time-step size. Stage is
and the completed step is
Lowercase denotes the ODE state at a completed time step, whereas uppercase and denote the stage-start and stage-end states within the current step. SuperDex Physics reconstructs from completed-step history, solves the stage states sequentially, and combines them to produce . Although these states may coincide for particular methods, they have distinct roles in the general formulation.
For a mechanical system, the first-order ODE state is , where is generalized configuration and is generalized velocity. Correspondingly, and contain the stage-start and stage-end mechanical states. Thus, SuperDex Physics solves stage as a backward-Euler-like problem over the stage duration .
Stages are solved sequentially. Accordingly, SuperDex Physics supports lower-triangular with positive diagonal entries. Explicit stages and fully coupled implicit Runge–Kutta methods are not supported.
Stage-State Reconstruction
SuperDex Physics stores stage-end states rather than the slopes . Define
The states needed by later stages and by the completed step can then be reconstructed as
Here, is entry of row . For variables in vector spaces, these are ordinary weighted differences. For rotations and other manifold-valued configurations, SuperDex Physics applies the analogous type-specific difference and update operations.
Mechanical Variables
Although the general stage state contains both configuration and velocity, SuperDex Physics can use alone as the nonlinear unknown. Given the stage-start state , it reconstructs the stage-end velocity and acceleration as
These are stage-local differences: the reference is the reconstructed stage-start state, not necessarily the state at the beginning of the full time step. For manifold-valued configurations, SuperDex Physics replaces the subtractions above with the analogous type-specific difference and tangent-space operations. Other rates used in dissipative terms (e.g., strain-rates for viscoelasticity, rates of constraint residuals for constraint damping, etc.) are also formulated as stage-local differences, to facilitate the use of optimization techniques to solve the implicit stage problem, as discussed further in the section on Incremental Potential Form below.
Implicit Stage Problem
At each implicit stage , SuperDex Physics treats the stage-start state as fixed and solves for the configuration component of the stage-end state . The velocity and acceleration components are reconstructed from using the stage-local relations above. Substituting these relations into the discretized equations of motion produces the nonlinear stage residual
The arguments after the semicolon are fixed data for the stage. SuperDex Physics solves this equation with a Newton-like method, using the residual derivative
This residual equation is the general form of the abstract implicit stage solve represented earlier by together with .
Incremental Potential Form
The implicit stage problem to solve at each step is a system of nonlinear algebraic equations. The solution of arbitrary nonlinear systems is challenging, and typically relies on iterative algorithms like Newton's method, which are not guaranteed to converge unless specific conditions are met. However, additional techniques are available for solving optimization problems, where the residual is the gradient of some scalar potential. This is not guaranteed to be the case for arbitrary choices of configuration-dependent or , but it does hold for many nontrivial systems. When the stage residual is the gradient of a potential, that potential is referred to as the "incremental potential", to distinguish it clearly from the physical potential energy of the continuous problem. Gast et al. (2015) provide background on the general concept of incremental potential integration, using backward Euler as a representative implicit integrator. We now provide a brief introduction in the notation of the current page.
Consider a mechanical system whose configuration space is a vector space and for which . Suppose its kinetic energy and dissipation potential have the forms
Here, the symmetric positive-definite, constant matrix maps generalized velocity to generalized momentum and is called the mass matrix; the velocity-only dependence of will ensure that its discrete contribution has the intended gradient. Using for the stage-end configuration unknown, define
The incremental potential is
where . Its gradient is
The implicit stage equation is therefore the stationarity condition for . The factor multiplying is essential: the chain rule converts its configuration gradient into without an extra time-step factor. In this exact case,
The assumptions above can be relaxed only when the resulting discrete terms remain integrable. A configuration-dependent kinetic energy, such as , produces additional inertial terms through the full Euler–Lagrange operator and does not reduce to the quadratic inertial term shown above.
Similarly, a continuous dissipation potential can depend on configuration as well as velocity, , with dissipative force at fixed and . Directly inserting such an into the discrete objective generally gives
The additional configuration derivative is not part of the original dissipative force. An equivalent incremental potential therefore exists only if this extra term vanishes, belongs to the intended discrete model, or is avoided by explicitly evaluating the configuration-dependent coefficients and holding them fixed during the stage. Any force in must likewise derive from a potential that can be absorbed into ; otherwise it precludes an exact incremental-potential form.
When these conditions do not hold, the residual remains the authoritative discrete equation. SuperDex Physics may still assemble a scalar merit for line search, or use a symmetric, fitted, or positive-semidefinite approximation to the exact residual derivative. Important departures from this simple vector-space setting include:
- State-dependent dissipation can be potential-derived when its coefficients are fixed during the stage. Contact friction, for example, can evaluate selected normals or normal-force magnitudes explicitly to recover an integrable stage model.
- Some formulations, such as Newton–Euler rigid inertia, provide a residual without an exact incremental potential of this form.
Actor pages specialize this structure by defining their kinetic, conservative, and dissipative terms and documenting any problem-specific explicit evaluations or approximations.
Available Methods
The Coefficients column lists and the Butcher tableau .
| Method | Steps | Stages | Order | Stability or structure | Coefficients |
|---|---|---|---|---|---|
BackwardEuler (BDF1, DIRK11) | 1 | 1 | 1 | L-stable | ; ; |
BDF2 | 2 | 1 | 2 | A-stable | ; ; |
BDF3 | 3 | 1 | 3 | Not A-stable | ; ; |
DIRK22 | 1 | 2 | 2 | L-stable | ; ; |
DIRK23 | 1 | 2 | 3 | A-stable, not L-stable | ; ; |
DIRK33 | 1 | 3 | 3 | L-stable | ; ; |
SymplecticDIRK12 (implicit midpoint) | 1 | 1 | 2 | A-stable, symplectic | ; ; |
SymplecticDIRK22 | 1 | 2 | 2 | A-stable, symplectic | ; |