every particle turns to the average heading of whoever is within one radius of it, then steps forward at fixed speed. The only other ingredient is noise: each turn is spoiled by a random angle of width η. Below a critical η the whole flock spontaneously picks one direction out of nowhere — and the corner panel plots the flock's own order parameter against η while it happens.
try this first just watch. The field arrives as grey static: thousands of particles, no agreed direction, colour drained because nothing agrees with its neighbours. η is falling on its own — and somewhere around 2.9 the grey breaks and the screen floods with one colour, because colour is heading here. Nothing chose which colour. Every dot in the corner is a real measurement the run made on its way past; the cloud scatters hardest exactly where the transition is. Then drag η yourself, or click the plot to jump straight to a value and hold there.
r plus a uniform
random angle in [−η/2, +η/2], then advance every particle by
v · the panel plots φ = |Σvi|/Nv, one dot per 12
steps, measured only ·
← more sketchesPhilosophy — the direction nobody picked. There is nothing in this rule that prefers north. Rotate the entire model and it is the same model; the equations do not know left from right. And yet, with the noise turned low enough, four thousand particles end up going one way, and you can point at the screen and name the direction. That is spontaneous symmetry breaking: the law keeps a symmetry that its outcome does not. The direction is not caused by anything you could have found by inspecting the rule, or any particle, or the initial conditions in any usable way — it is a fluctuation that happened to win, amplified by a system that rewards agreement. Run it again and you get another direction, chosen just as thoroughly and for just as little reason. What makes the 1995 result its own paper rather than a footnote to magnetism is where it happens: the Mermin–Wagner theorem says a two-dimensional system with a continuous symmetry and short-range interactions cannot order at any finite temperature, and a flock is exactly that — two dimensions, a continuous choice of heading, only local coupling. The loophole is that the particles move. Motion carries alignment across the box faster than diffusion could, and the system orders where an equilibrium magnet is forbidden to. This is a genuinely non-equilibrium ordering: it needs the driving to exist. Whether the transition is continuous or abrupt turned out to be a fifteen-year argument — the original paper read it as continuous, Grégoire and Chaté (2004) argued that at large enough systems it is discontinuous with the sharpness only appearing at sizes far past anything on this canvas. This piece does not settle that, and does not pretend to. It plots what it measured.
Technique — the instrument, and why it slows down. Two disciplines matter.
First, the neighbourhood: the rule is a range query over every particle every step, which is
quadratic if you do it naively. The particles are counting-sorted into a uniform grid of cells exactly
r across, with positions copied into cell order so the inner loop walks memory
forwards, and each pair is tested once and credited to both ends — "j is within r of i"
and "i is within r of j" are the same fact, so the half-stencil (self cell, plus four of the eight
neighbours) does all the work at half the distance checks. Second, the measurement. The panel is a
scatter plot and nothing else. There is no fitted curve, no spline through the dots, no smoothing that
would turn scatter into a line, and no marked ηc: every dot is the mean of φ over 12
consecutive steps of the run you are watching, dropped at the mean η of those same steps, and left
there. What the plot then shows for free is the thing a fitted curve would have destroyed — the
dots are tight at both ends and sprayed through the middle, because near a critical
point the fluctuations are the physics, not the error bars. The sweep is deliberately slowest there:
the rate is scaled by how close φ currently is to the middle of its range, so the run spends its
time where the measurement is changing. Two honest caveats live in that design. The dots are coloured
by sweep direction, cyan going down and amber coming back up, so any gap between the branches is
visible — but a sweep at finite rate always lags, so a gap here is an upper bound on
hysteresis and not evidence of it. And this box holds a few thousand particles, which is small; the
literature's sharpest claims are about systems orders of magnitude larger, so no exponent is printed
and none is implied.
Aesthetics — colour is heading, chroma is agreement. The obvious way to draw a flock is arrows, and arrows are unreadable at four thousand. So each particle is a short stroke along its own heading, and its hue is that heading, mapped around a full cycle — heading is an angle, so the colour map has to close, or the piece would invent a seam where the physics has none. The map is built in OKLCh at fixed lightness with the chroma gamut-clipped per hue, so no direction is louder than any other; a rainbow is exactly wrong here, because a rainbow makes yellow shout and blue mumble and you would read that as structure. The second channel is the one that does the real work: a particle's chroma and brightness are set by local alignment, the same quantity the rule already computed to steer it. But local alignment is never zero — a dozen random headings still add up to something — so each particle is scored against the chance level for its own neighbour count, and against the best a patch in perfect consensus could still measure at the current noise. A particle that has not beaten coincidence is drawn grey. Past η ≈ 4 the second number falls below the first and the field goes uniformly grey, because at that noise no neighbourhood can prove anything. So the disordered phase is genuinely colourless — not stylised as colourless, measured as colourless — and the transition is the screen gaining colour. Strokes are drawn additively over a short trail, which costs nothing and buys the model's other famous feature for free: the giant density fluctuations pile light on light, so the travelling high-density bands show up as bright filaments running across the ordered phase, which is what people came to look at.
Honest weaknesses. Every dot is measured during a moving sweep, not from a run equilibrated at that η, so the cloud lags: the descending branch keeps order slightly past where it belongs and the ascending branch is slow to find it. That is why the two colours are separated at all, and why the gap is an upper bound on hysteresis rather than a measurement of it. The sweep deliberately crawls where φ is mid-range, which means the dot density along the axis is a statement about the sweep controller and not about the physics — do not read a dense band as a long-lived state. Four thousand particles in an 800×600 box is a small system; ηc here sits somewhere near 2.9 but drifts with density, speed and radius, and none of the sharpness arguments in the literature apply at this size, so no exponent is printed. The colour is gated by how much room the current noise leaves between coincidence and consensus, and past η ≈ 4 that room closes and the field goes flat grey — correct, but it means the high-η end tells you less than the low-η end. Raising particles to 7000 roughly doubles the per-tick cost and a slow machine will start shedding ticks, which quietly slows the sweep rather than dropping frames. Moving the particle slider up seeds the new ones at random into a field that has already agreed, so φ dips for a second afterwards; that dip is the slider, not the model.