A Simple Machine, Impossible to Predict
The double pendulum — two rigid rods connected end-to-end, swinging under gravity — is one of the simplest mechanical systems that exhibits chaos. Unlike a single pendulum, which swings back and forth in a perfectly predictable way, the double pendulum's motion becomes wildly unpredictable when released from large angles. Two pendulums started with nearly identical conditions will quickly diverge into completely different trajectories.
Lagrangian Mechanics
The equations of motion are derived using Lagrangian mechanics — a powerful framework from classical physics. The Lagrangian L = T − V (kinetic minus potential energy) is written in terms of the two angles θ₁ and θ₂. Applying the Euler-Lagrange equations yields two coupled, nonlinear second-order differential equations. These equations have no closed-form solution — they must be solved numerically.
Reading the Simulation
The white circle is the first bob, the red circle is the second. The cyan trail shows the path traced by the second bob's tip. Watch how the trail fills a complex region of space without ever repeating exactly. The pivot point is fixed at the top center. Try changing the initial angles by just one degree and compare the resulting motion — this sensitivity is the signature of chaos.
Energy Conservation
Despite the chaotic motion, one quantity is perfectly conserved: total mechanical energy. The simulation uses a fourth-order Runge-Kutta (RK4) integrator with a small time step to maintain this conservation. The total energy readout at the bottom should remain nearly constant throughout the simulation — any drift indicates numerical error rather than physical dissipation.