"Chaotic" gets thrown around loosely, so I made it a number. The LK Forge physics labs run real integrators in the browser, so I took the exact engines behind two of them — the double pendulum and the bifurcation diagram — and measured how fast order becomes unpredictability. Every number below is computed by a dependency-free script that copies the simulators' own code, so it's fully reproducible.
A thousandth of a radian, gone in seven seconds
Release two identical double pendulums from almost the same spot and watch how long they stay in step. Both start from the simulator's default (173.12° and 178.85° from hanging); one is nudged by just 0.001 radian — 0.057°, about a seventeenth of a single degree — and both are integrated forward with the same RK4 solver the live lab uses.
They stay visually locked for about 5.6 seconds, then fully decorrelate by 7.2 seconds. The largest Lyapunov exponent is ≈ 1.095 per second — a Lyapunov time of 0.91 s, meaning the gap between them multiplies by e (~2.7×) roughly every second.
Plotted on a log scale, the gap climbs an almost straight line: the error doesn't grow steadily, it grows exponentially. Make the initial nudge ten times bigger and you don't lose ten times the time — full divergence just arrives sooner (2.8 s for a 0.05 rad start vs 7.2 s for 0.001 rad). No matter how precisely you measure the start, the unknown part doubles and redoubles until it swamps everything. That's why the third swing of a double pendulum is, for all practical purposes, unpredictable.
Where chaos begins: r ≈ 3.5699
The double pendulum is chaos in continuous motion. The bifurcation diagram shows the other classic route in, from one of the simplest equations that can misbehave — the logistic map x → r·x·(1−x). Pick a growth rate r, iterate, and see what value the sequence settles onto. For low r it settles on one number. Turn r up and that value splits in two, then four, then eight — a period-doubling cascade — with the splits crowding together until, at a precise point, the sequence never repeats.
From the map's own iterations:
- period 2 at r ≈ 3.00
- period 4 at r ≈ 3.449
- period 8 at r ≈ 3.544
- period 16 at r ≈ 3.564
- chaos at r ≈ 3.5699
About 39% of the range r ∈ [3, 4] is chaotic; the rest still settles to a finite cycle. And the spacing between successive doublings shrinks by a fixed ratio — from these numbers, 4.75 then 4.65, converging on the Feigenbaum constant, 4.669. That's the strange, beautiful part: the same 4.669 governs the double pendulum too, and dripping taps, and heart-rhythm models. The route into chaos is universal — it doesn't care what the underlying equation is.
Chaos isn't randomness
Both systems here are fully deterministic — the same starting numbers produce the same trajectory every single run, which is exactly why this is reproducible from one short script. Chaos is not randomness; it's sensitive dependence on initial conditions. The rules are exact, but any uncertainty in the starting point grows exponentially, so long-term prediction becomes impossible in practice even though the system is, in principle, perfectly determined.
Reproduce it
The whole study is two tiny engines:
// Double pendulum — one RK4 step of the equations of motion (g = 9.8, DT = 1/240)
function deriv([th1, w1, th2, w2]) {
const d = th1 - th2, cd = Math.cos(d), sd = Math.sin(d)
const den = 3 - Math.cos(2*th1 - 2*th2) // equal masses & lengths
const a1 = (-g*3*Math.sin(th1) - g*Math.sin(th1 - 2*th2)
- 2*sd*(w2*w2 + w1*w1*cd)) / den
const a2 = (2*sd*(w1*w1*2 + g*2*Math.cos(th1) + w2*w2*cd)) / den
return [w1, a1, w2, a2]
}
// Logistic map — the whole of it
const next = (x, r) => r * x * (1 - x)
Run two pendulums 0.001 rad apart and time the separation → 7.2 s to full divergence. Iterate the logistic map while raising r and record where the cycle length doubles → chaos at r ≈ 3.5699.
See it move
Open the double pendulum, turn on the ghost twin, and watch the two arms trace each other before splitting for good. Then drag the growth-rate slider on the bifurcation diagram across r ≈ 3.5699 and see the single line shatter into a band. Both run entirely in your browser — nothing is uploaded.
Originally published on LK Forge.
Top comments (0)