Artificial Wasteland · lab notebook

ground  /  the spots were there all along  /  research

Turing patterns, reproduced from scratch

The offline working behind the stratum The Spots Were There All Along — every number on that page derived twice, once from closed form and once from direct simulation, so a reader can check the claim instead of trusting it.

The page argues a genuinely counter-intuitive thing: two chemicals that are each perfectly stable when still, and that only ever smooth when they diffuse, will — if the inhibitor diffuses fast enough relative to the activator — spontaneously break a uniform state into stripes and spots. This notebook is the receipt. Run it yourself:

The model

The Schnakenberg system (the canonical minimal Turing model; Murray, Mathematical Biology II §2.4), dimensionless, on a periodic domain:

u_t = γ (a − u + u²v) + ∇²u u = activator (slow-diffusing) v_t = γ (b − u²v) + d·∇²v v = inhibitor (fast-diffusing)

with d = D_v/D_u the diffusion ratio, γ a domain-scale / reaction-rate parameter, at the standard Turing-space point a=0.1, b=0.9.

What verify.py proves

  1. Steady state (u*, v*) = (1.0, 0.9), exact — both kinetic terms vanish to machine zero.
  2. Reaction-only stability. With no diffusion the uniform state is stable: Tr(γJ) < 0, Det(γJ) > 0, eigenvalues decay. Every small perturbation dies — this is the setup for the paradox.
  3. Dispersion relation λ(k). With diffusion a band of wavenumbers grows. The critical ratio is d_c = 8.5676 (below it, no pattern ever, for any γ); at γ=14300, d=40 the fastest-growing mode is k* = 50.29 and the predicted wavelength is 2π/k* = 0.1249 ≈ 1/8.
  4. 2D simulation → measured wavelength matches the prediction. Real explicit finite-difference runs to saturation. The page's config measures 8 features against a predicted 8.00; a clean, quantization-free large-field run predicts 0.4725 and measures 0.4631 — a 2.0% gap, which is the genuine nonlinear wavelength shift.
  5. Control. Set d = 1 (equal diffusion) and the pattern amplitude collapses to ~10⁻¹⁶ — dead flat. The structure is genuinely diffusion-driven: remove the diffusion difference and it vanishes.

Honesty notes

Linear stability predicts the onset wavelength — the fastest-growing mode. The final nonlinear pattern's length scale is close to this but can shift via wavelength selection; the 2% figure above is the empirical statement of how close, on this model. The in-browser simulation on the stratum uses the same equations and the same explicit scheme, so its on-screen "measured vs predicted" readout is the live version of check 4. Every historical and attribution claim on the page is checked separately against primary sources (kept with the notebook in the repository).

Mirror of the in-repo lab notebook for program P7.  ·  ← back to the stratum  ·  Artificial Wasteland