2,500 double pendulums
Chaos vs order
Identical physics, different starting angles: the lower arm's across the grid (−π to π), the upper arm's down it (π to −π); 0 hangs straight down, ±π points straight up. Watch predictability dissolve at the edges while islands of order hold.
About the physics
Each cell is a frictionless double pendulum: two point masses on light, rigid arms under Earth gravity, integrated with fourth-order Runge–Kutta at 240 steps per simulated second. By default the masses are equal and both arms are 1 m long, so the clock reads real seconds. Lower mass and Lower arm set the lower bob's mass and arm length relative to the upper ones (currently equal masses and equal arm lengths); changing either restarts the run. The classic flip-time images use two solid rods, count a flip of either arm and put the upper angle across, so at the default settings their central island looks much like this one, slightly reshaped and with the axes swapped. The physics is point-symmetric, so only half the grid is integrated: each pendulum in the other half is the exact mirror image of its partner across the center, with angles and speeds negated. Nothing is prerecorded — every pendulum is computed live.
Hue colors each pendulum by the current angle of its lower arm, so coherent regions flow together. Chaos runs an invisible twin of every pendulum, offset by one hundred-millionth of a radian, and colors by how far the pair has drifted apart — the signature of sensitive dependence on initial conditions. Lyapunov colors by how fast that gap grows: every quarter second the gap is measured, its growth is added up, and the twin is pulled back to 10⁻⁸ so it never saturates; the average growth rate per second converges to the pendulum's largest Lyapunov exponent. The twins run only in a run that started in Chaos or Lyapunov, so choosing one of them restarts the run if its twins are not already running. Flips records when each lower arm first swings over the top. Inside the outlined region, energy conservation forbids a flip; outside it, the flip times form an intricate fractal pattern.
The pendulums inside that outlined region (at the default settings a lens across the middle) have too little energy ever to swing the lower arm over the top. Most of them swing regularly, but some, mostly near its rim, wander chaotically without ever flipping. The corners start nearly inverted, with the most energy: they tumble at once and are the first to diverge from their twins (amber in Chaos colors after about 15 seconds).
Tap or click a cell, or focus the grid and use the arrow keys, to follow it in the Inspector: its pendulum drawn large with the path of the lower tip, its energy (the drift is the integrator's tiny error), and its own twin, drawn faintly, with their separation since t = 0 on a log scale, where a straight rising line means exponential divergence. The status line (it starts with t =) gives the simulated time and the share of lower arms that have flipped so far, with the share that has the energy to flip at all in brackets. Auto-restart after starts the run afresh every 30, 60 or 120 simulated seconds (a setting the run has already passed takes effect from the next cycle), and the Flips colors then stretch over that time. Further reading: Jeremy S. Heyl, The Double Pendulum Fractal (2008).