Cymatics
Scatter sand on a thin metal plate, bow its edge, and the sand runs off the parts that move and gathers on the lines that don't. Ernst Chladni drew these figures in 1787; they are the nodal lines of the plate's vibration, made visible. Cymatics is a sketchbook for the algorithms behind them: a driven plate, the sand that settles on it, and the standing waves on a shaken layer of fluid.
Pick a square plate or a disc, with a free or fixed edge, and drag the frequency. Drag on the plate to move the driver; click the spectrum to tune to one of its peaks, or press Resonance to snap to the nearest one. Sweep glides upward through the whole range. Pure modes sets the driver aside and lets you add two modes by hand, which is how Chladni's ± figures are made. Tone plays the drive frequency, and Listen lets a whistle or a voice drive the plate.
Modes
A plate has a family of shapes in which it is happy to vibrate, its modes, each with its own frequency. Because a plate resists bending, frequency rises with the square of the wavenumber. The square uses separable cosines (free edge) or sines (fixed edge); the disc uses Bessel functions, with the wavenumbers taken from the roots of J_m or of its derivative.
square φ = cos(nπu) · cos(mπv) f ∝ √(Dx/Dy) · n² + m² / √(Dx/Dy)
disc φ = J_m(λ r) · cos(mθ) f ∝ λ²
These are the idealised, separable modes — the true free-plate modes are not separable — but they carry the same nodal families. Stiffness Dx/Dy imitates a grained plate, like the spruce top of a violin, and splits the pairs of modes that a perfectly square plate shares.
The driven response
A point driver excites every mode at once. The steady-state shape is a damped sum over all of them, the plate's Green's function:
w(x) = Σ φ_k(x) φ_k(x₀) / (f_k² − f² + iγ f f_k)
Near a resonance one term dominates; between resonances its neighbours mix, which is why the figures morph rather than switch. Move the driver onto a node of a mode and that mode drops out of the sum. A grain of sand only leaves the plate where the plate's acceleration beats gravity; there it hops, in proportion to the excess, and drifts down the amplitude gradient. Where the plate is too quiet to throw it, it stays put. So the antinodes empty, and every grain that lands in the quiet band around a nodal line stays there, which is what draws the line. Agitation is the drive level: more of it narrows the band. When two nearly degenerate modes ring out of phase, |w| vanishes only at points, and the sand gathers in islands instead of lines.
Faraday waves
Shake a shallow dish of liquid up and down and, past a threshold, its surface breaks into a standing pattern that oscillates at half the drive frequency. The wavelength comes from the dispersion relation for capillary-gravity waves, solved here by bisection:
(2π · f/2)² = (g k + σ k³ / ρ) · tanh(k h)
The surface is drawn as a sum of standing plane waves at evenly spaced angles: two give squares, three give hexagons, and four to six give the quasicrystalline patterns that appear under two-frequency forcing.
Plain HTML5 canvas and vanilla JavaScript, built as a handful of web components (<cymatics-plate>, <cymatics-spectrum>, <text-switch>, <theme-switch>), with no libraries. It follows the site's light and dark themes, or the system setting.
References
- Chladni, E. F. F. (1787). Entdeckungen über die Theorie des Klanges. Leipzig.
- Faraday, M. (1831). On a peculiar class of acoustical figures. Philosophical Transactions of the Royal Society 121, 299–340.
- Tuan, P. H., et al. (2015). Exploring the resonant vibration of thin plates: Reconstruction of Chladni patterns and determination of resonant wave numbers. J. Acoust. Soc. Am. 137, 2113.
- Edwards, W. S., & Fauve, S. (1994). Patterns and quasi-patterns in the Faraday experiment. J. Fluid Mech. 278, 123–148.
- Leissa, A. W. (1969). Vibration of Plates. NASA SP-160.