One bob is a clock. Two is weather. Three is a signature.
Grab any bob and drag it to set the starting angles. Release and watch. A single pendulum keeps the same time forever; a double one forgets where it came from after a few swings; a triple one writes a different sentence every time you ask. Same equations, same code path — only the number of links changes.
What you are looking at
§ 08 · Reading2π√(L/g) — independent of mass, independent of amplitude. Pull it out wider and the period grows, slowly. This is the small-angle approximation showing where it breaks.How the simulation behaves
§ 08 · Method
One code path handles all three modes. The state is the vector of angles
θ = (θ₁, …, θ_n) and their rates θ̇. From the
planar Lagrangian for point bobs on massless rigid rods, the equations of
motion take the matrix form M(θ)·θ̈ = −C(θ,θ̇) − G(θ) − b·θ̇
with the symmetric inertia matrix
M_jk = A_jk · L_j L_k · cos(θ_j − θ_k), the Coriolis vector
C_l = Σ A_lj · L_l L_j · sin(θ_l − θ_j) · θ̇_j², the gravity
vector G_l = B_l · g L_l · sin(θ_l), and the suffixed mass
sums A_jk = B_max(j,k) = Σ_{i≥max(j,k)} m_i.
Each frame steps the state with classical fourth-order Runge–Kutta at a
fixed substep of 1/240 s. RK4 is not symplectic, so energy
will drift on very long runs at very large amplitudes — turn damping to
zero and leave the triple pendulum overnight if you want to see the drift
become visible. For minutes of play it is invisible.
Dragging a bob rewrites θ_i from the cursor; downstream bobs
ride along on the rigid chain. On release, all velocities are zeroed —
the system starts from rest at whatever pose you set. The phase-space
inset plots (θ_n, θ̇_n) for the tip bob: a clean loop for the
single pendulum, a tangle for the double, a thicket for the triple.