mathematics//numerical methods//numerical integration//symplectic integrator

A symplectic integrator is a method of numerical integration for mechanical systems without friction that preserves the geometric structure of their motion, so that the simulated energy oscillates slightly around its true value instead of drifting away over time; it is what physics engines, molecular dynamics, orbit propagation and long simulations of oscillating structures use when a run must last millions of steps. The everyday picture is a simulated pendulum: integrated with explicit Euler it swings higher and higher, with a symplectic method it keeps swinging at the same height for as long as the computer runs.


A symplectic integrator is a method of numerical integration for mechanical systems without friction that preserves the geometric structure of their motion, so that the simulated energy oscillates slightly around its true value instead of drifting away over time; it is what physics engines, molecular dynamics, orbit propagation and long simulations of oscillating structures use when a run must last millions of steps. The everyday picture is a simulated pendulum: integrated with explicit Euler it swings higher and higher, with a symplectic method it keeps swinging at the same height for as long as the computer runs.

The structure in question belongs to systems written in positions and momenta (Hamiltonian systems), which conserve energy and also conserve area in the plane of position and momentum: a patch of initial conditions moves and deforms without growing or shrinking. A method that respects that area cannot spiral outward or inward, so it cannot pump energy in or bleed it out step after step. The simplest one costs nothing extra over the Euler method: update the velocity with the current force, then the position with the new velocity (semi-implicit or symplectic Euler). The workhorse is velocity Verlet (leapfrog), second order, one force evaluation per step:

vk+12=vk+Δt2a(xk),xk+1=xk+Δt vk+12,vk+1=vk+12+Δt2a(xk+1).v_{k+\frac12}=v_k+\tfrac{\Delta t}{2}a(x_k),\qquad x_{k+1}=x_k+\Delta t\,v_{k+\frac12},\qquad v_{k+1}=v_{k+\frac12}+\tfrac{\Delta t}{2}a(x_{k+1}).vk+21​​=vk​+2Δt​a(xk​),xk+1​=xk​+Δtvk+21​​,vk+1​=vk+21​​+2Δt​a(xk+1​).

a(x)a(x)a(x) is the acceleration the forces give at position xxx; the velocity is advanced in two half steps around the position update, which makes the scheme symmetric in time.

Bounded error beats small error over long runs.

A fourth-order Runge-Kutta method is far more accurate per step, yet its tiny energy error accumulates in one direction, so after enough orbits the simulated satellite has drifted to another altitude; leapfrog's energy error is larger per step and stays bounded forever. For a minute of simulated flight RK4 wins; for a week of orbit or a molecular simulation, the symplectic method does.

Its guarantee covers conservative dynamics. Add friction, drag, a controller or a battery and the system is no longer Hamiltonian; the method stays cheap and well behaved, but its special property no longer applies, and accuracy and numerical stability decide as for any method.

It needs a fixed step. Changing the step size from one iteration to the next breaks the structure and lets energy drift return, so adaptive step solvers are not symplectic, one more reason game engines and real-time simulators run on a fixed tick.

It keeps the qualitative behaviour where it matters for testing controllers: a lightly damped mode that the integrator itself damps or excites hides or invents an oscillation, and an oscillator simulated with the wrong method can make a marginal controller look stable.