Sand Pendulum Patterns
A pendulum dripping sand traces Lissajous-like patterns as it swings and decays. Adjust the initial conditions to create spirographs written by gravity and friction. Click and drag on the canvas to set the initial velocity vector, or use the sliders to dial in precise frequency ratios.
x(t) = A·sin(ωₓt)·e−γt · y(t) = A·sin(ωᵧt + φ)·e−γt
About this experiment
The sand pendulum is a physical device in which a funnel filled with fine sand hangs from a long cord or pair of cords, free to swing in two perpendicular directions simultaneously. As the pendulum swings, sand trickles from a small hole in the funnel onto a flat surface below, tracing a record of the pendulum’s two-dimensional trajectory. The resulting patterns are closely related to Lissajous figures — the family of curves produced when two perpendicular sinusoidal oscillations are combined. Jules Antoine Lissajous described these figures mathematically in 1857, though Nathaniel Bowditch had investigated the same curves as early as 1815, which is why they are sometimes called Bowditch curves.
The crucial ingredient that makes sand pendulum patterns more visually rich than idealized Lissajous figures is damping. A real pendulum loses energy to air resistance and friction at the pivot, so its amplitude decays exponentially over time. This means the pattern does not simply retrace itself; instead, it spirals inward, filling in the interior of the figure with ever-tighter loops. The ratio of the pendulum’s natural frequencies in the x and y directions determines the topology of the pattern: a 1:1 ratio produces a decaying ellipse, 1:2 gives a figure-eight, 2:3 traces a trefoil, and so on. When the ratio is irrational, the curve never closes and eventually fills a region of the plane — a property related to the concept of ergodicity in dynamical systems.
Sand pendulums became a popular fixture in science museums during the 19th century, alongside the harmonograph — a related device that uses pendulums to move a pen across paper. Both instruments made abstract mathematics tangible: visitors could watch the emergence of complex geometry from simple physical laws. The patterns also connect to modern physics through the study of coupled oscillators and normal modes, concepts that underpin everything from molecular vibrations to the resonant frequencies of bridges and buildings. In this simulation, each sand grain is placed with a small random displacement to mimic the natural scatter of falling sand, giving the traces their characteristic soft, granular texture.
Lissajous figures and frequency ratios
A Lissajous figure is the path traced by a point whose x and y coordinates are each driven by a sinusoidal oscillation: x(t) = A sin(ωₓt + φ) and y(t) = B sin(ωᵧt). When the frequency ratio ωₓ/ωᵧ is a rational number p/q, the curve closes after traversing q lobes in the x-direction and p in the y-direction. The phase offset φ controls the “openness” of the figure: at φ = 0, a 1:1 ratio traces a diagonal line; at φ = π/2, it traces a circle.
The visual beauty of these curves lies in their sensitivity to small parameter changes. Adjusting the frequency ratio by even a fraction causes the pattern to precess — slowly rotating and filling in regions that a perfectly rational ratio would leave empty. This is the same phenomenon that makes the sand pendulum patterns so rich: in practice, the two frequencies are never in a perfectly rational relationship, and the irrational component creates quasi-periodic orbits of infinite visual complexity.
The harmonograph and Victorian science
The harmonograph was a Victorian-era parlor entertainment that combined science and art. Hugh Blackburn, a professor of mathematics at the University of Glasgow, popularized the device in the 1840s. The simplest harmonographs used two pendulums: one moving the pen horizontally, the other moving it vertically. More elaborate designs added a third pendulum to rotate the drawing platform, producing curves of extraordinary intricacy.
The drawings produced by harmonographs were collected, framed, and exchanged much like photographs. The connection between the visual patterns and musical intervals was well understood: frequency ratios corresponding to consonant intervals (octave, fifth, fourth) produced the simplest, most symmetrical figures. This made the harmonograph a powerful tool for demonstrating the Pythagorean idea that mathematical harmony underlies both music and visual beauty.
Today, sand pendulums serve a similar educational role in science museums worldwide. The Exploratorium in San Francisco, the Deutsches Museum in Munich, and hundreds of other institutions maintain large sand pendulums that visitors can set into motion. The patterns they produce are ephemeral — each one is brushed away before the next visitor takes a turn — which gives them a meditative, mandala-like quality that static harmonograph drawings lack.