Visualizations
479 / 500

479 · Physics

Wind Harp

An Aeolian harp on a misty hill: vortex shedding picks the harmonic each string sings.

Wind across a thin string sheds a von Karman street at the Strouhal frequency, f = St U / D, with St taken from Roshko's fits to the Reynolds number (below Re of about 47 nothing sheds). As in the traditional instrument, all seven strings are tuned to the same C and differ only in thickness, so one breeze puts each string's shedding near a different multiple of that C. Each string is a set of 24 mode amplitudes that grow when the shedding falls within about ten percent of them, saturate, and compete, so one harmonic captures the wake (lock-in), holds it with hysteresis as gusts drift, and lets go when the wind moves on; the harp sounds chords from the harmonic series. The wake is drawn in 24 slices per string, each with its own shedding phase: while locked the slices are pulled into step, flipping by half a cycle across each node of the mode, so the shed vortices line up into tubes along the string, and at the near end each street is drawn as a smoke line rolling up around its alternating vortices. The glowing beads mark the antinodes of the harmonic each string is singing, and after a click the mode amplitudes are synthesized as sines with a breath of wind noise through a generated hillside reverb.

Try it. Drag anywhere to set the wind: sideways sets its speed and direction across the strings, while dragging up or down adds a component along the strings, which the shedding ignores (the independence principle). Click a string, or press 1 to 7, to pluck it and hear its whole harmonic series. Left and right change the wind, up and down change how gusty it is, Space sends a gust, M mutes.

  • Vortex shedding
  • Strouhal number
  • Lock-in with hysteresis
  • Mode competition
  • Additive synthesis
  • Axonometric projection

View the source · one module, plus a small shared runtime for sizing, the animation loop and input

Build your own

Paste this into Claude Code, Codex or any coding agent to get a simple version running, then take it wherever you like.

Build an Aeolian harp, a set of strings that sing in the wind, with JavaScript, the HTML canvas element and the Web Audio API. Put everything in a single index.html file with no libraries or build step, so I can open it directly in a browser.

Start simple:
- Make a full-window, high-DPI canvas with a misty hillside of layered ridges.
- Draw seven horizontal strings across a wooden frame. Tune them all to the same note (130.8 Hz) but give them different diameters, from 0.6 to 1.6 mm.
- Let dragging left and right set a wind speed U in m/s.
- For each string compute the vortex shedding frequency f = 0.2 U / D (the Strouhal law). Each string has modes at n times its fundamental, n = 1 to 16. Give each mode an amplitude that grows when f is within about 10 percent of it, decays otherwise, and saturates, and let the strongest mode suppress the others so one harmonic wins.
- Draw each string vibrating in its winning mode shape, sin(n pi x / L), slowed down and exaggerated, with glowing beads at the antinodes.

Then make it sing:
- On the first click, start an AudioContext (show a "Click for sound" hint until then) and run one sine oscillator per string and mode, setting each gain from its mode amplitude every frame.
- Add a convolution reverb made from a few seconds of decaying noise.

Once that works, make it beautiful:
- Draw a von Karman vortex street behind each string: alternating curls shed from the top and bottom at the shedding rate, drifting downwind and fading.
- Add slow gusts so the strings hop between harmonics, and drifting mist that moves with the wind.

Explain the key ideas in short code comments. When you're done, tell me how to open it and suggest three directions I could take it next, such as hysteresis in the lock-in, plucking strings with the mouse, or showing the wake in 3D slices along each string.
PreviousImpossible ArchitectureWalkers climb Penrose stairs forever on a pastel tower whose paths only meet on screen. NextCuckoo Hash HotelThree pastel hotels, three hash tables: linear probing, Robin Hood and cuckoo.

Related visualizations

  • Plucked StringsSound Seven finite-difference strings to pluck, with live harmonics and slow-motion kinks.
  • Bowed StringPhysics Helmholtz motion on a bowed violin string, with a Schelleng diagram measured live.
  • Glass HarpSound Ray-traced wine glasses, tuned with water and sung by stick-slip friction on the rim.
  • Missing FundamentalIllusions Peel a note's harmonics away, fundamental first, and the heard pitch refuses to move.
  • Music BoxSound A pinned brass drum plucks cantilever tines from a punched strip you can edit.
  • HurricaneSimulation A satellite loop of a hurricane, driven by a vortex you can steer over a warm ocean.
  • Wind TunnelFluids A lattice Boltzmann wind tunnel: draw any shape and watch it shed vortices.
  • Xenakis GlissandiGenerative art Metastaseis-style string glissandi as ruled surfaces on graph paper, and a gas of notes.
  • Dissonance CurveSound Plomp-Levelt roughness summed over every partial pair: where consonance comes from.

Use ← and → to move between demos. While the canvas has focus, keys go to the demo instead.

← More from Emergent Mind Labs