Questing · 2026-09-04 · Materials Physics · Zero Dependencies
QUENCH
Cool a binary mixture below its miscibility gap. The two components have no choice — they must unmix. What begins as invisible fluctuations becomes a labyrinth of interlocking phases that slowly, inexorably, coarsens.
Open Quench →What Is Quench?
Quench simulates spinodal decomposition — the spontaneous unmixing of a binary mixture cooled rapidly below its miscibility gap. Unlike classical nucleation (where phase separation requires a seed and an energy barrier to overcome), spinodal decomposition has no barrier: any infinitesimal fluctuation in composition grows exponentially. The system is thermodynamically unstable in every direction, so it falls apart into two coexisting phases from the first moment after the quench.
The simulation starts with a near-uniform mixture perturbed by tiny thermal noise. Within seconds of simulated time, a labyrinthine pattern of amber domains (A-rich, c ≈ +1) and teal domains (B-rich, c ≈ −1), separated by nearly-black diffuse interfaces, emerges from nothing. These domains then slowly coarsen — the average domain size grows as t1/3 — as larger regions consume smaller ones through diffusion.
The Cahn-Hilliard Equation
The model governing spinodal decomposition is the Cahn-Hilliard equation, introduced by John Cahn and John Hilliard in 1958. It describes how a conserved composition field c evolves to minimize the Ginzburg-Landau free energy functional F[c] = ∫[f(c) + (κ/2)|∇c|²] dV, where f(c) = ¼(c²−1)² is the double-well bulk free energy and κ is the gradient energy coefficient penalizing sharp interfaces.
// Free energy landscape: double-well with minima at c = ±1 f(c) = ¼(c² − 1)² → f'(c) = c³ − c // Chemical potential: bulk driving force minus interface penalty μ = f'(c) − κ∇²c = c³ − c − κ∇²c // Cahn-Hilliard PDE (conserved dynamics): ∂c/∂t = M∇²μ = M∇²(c³ − c − κ∇²c) // Discretized on 200×200 grid, periodic BC, explicit Euler: μᵢⱼ = cᵢⱼ³ − cᵢⱼ − κ·∇²c[i,j] cᵢⱼ ← cᵢⱼ + Δt · ∇²μ[i,j] // Domain size at equilibrium: ξ = √κ (interface half-width) // Characteristic spinodal wavelength: λ* = 2π√(2κ/|f''(c₀)|)
The crucial feature of the Cahn-Hilliard equation is that it is a conserved (Model B) dynamics: ∂c/∂t = ∇·J, so ∫c dV is constant throughout the evolution. The two phases separate, but the total amounts of A and B do not change — the system redistributes composition, never creates or destroys it. This is what distinguishes Cahn-Hilliard from the Allen-Cahn equation (used in Nema), which allows the order parameter magnitude to change.
Spinodal vs. Nucleation
Within the miscibility gap — the region of composition-temperature space where a homogeneous mixture is unstable — there are two regimes. The metastable region (between the binodal and the spinodal curves) requires a finite nucleus to trigger phase separation; small fluctuations are damped. The unstable spinodal region (inside the spinodal curve) has f"(c₀) < 0: the free energy curvature is negative, and every fluctuation, no matter how small, lowers the total free energy and therefore grows.
The growth rate of a Fourier mode with wavenumber q is σ(q) = q²(|f"| − κq²). The most unstable mode has q* = √(|f"|/2κ), giving a characteristic spinodal wavelength λ* = 2π/q*. At early times the simulation looks like a superposition of these preferred-wavelength waves — which is exactly what you see in the first moments after quench: a labyrinthine pattern with a well-defined length scale, not a random fractal.
Coarsening and the t⅓ Law
After the initial spinodal decomposition saturates (compositions reach ≈ ±1 in the bulk), the pattern coarsens: large domains grow at the expense of small ones via diffusion of material across the thin interfaces. This is Ostwald ripening (or coarsening). The kinetic theory of Lifshitz, Slyozov (1961) and Wagner (1961) — the LSW theory — predicts that the mean domain size L(t) grows as:
L(t) ∝ t^(1/3) (Lifshitz-Slyozov-Wagner law) // Driving force: curvature of interfaces raises chemical potential // Small domains: high curvature → high μ → molecules leave // Large domains: low curvature → low μ → molecules arrive // Net effect: small domains dissolve into large ones // Measurable in Quench: domain size readout (HUD) increases over time
The interface density (total interface length per unit area) decreases proportionally to t−1/3. The Quench HUD tracks this: the domain size readout, computed as 1/⟨|∇c|⟩, climbs slowly as the pattern coarsens from the initial spinodal scale to progressively larger domains.
Composition and Morphology
The composition slider c₀ sets the average concentration. At c₀ = 0 (symmetric quench), both phases are equally abundant — the result is a bicontinuous labyrinthine morphology: neither phase forms isolated droplets; both are percolating networks. As c₀ moves away from zero, the minority phase begins to form isolated droplets. Past the percolation threshold (|c₀| ≳ 0.4), the morphology inverts completely to discrete droplets in a continuous matrix.
The κ slider controls the gradient energy coefficient — the cost of having a sharp interface. Large κ → wide diffuse interfaces and a coarser characteristic spinodal wavelength (λ* ∝ √κ). Small κ → sharper interfaces and finer initial patterns.
Where This Physics Appears
Spinodal decomposition is ubiquitous in materials science and biology. Steel metallurgy: Fe-Cr and Fe-Ni alloys quenched into the spinodal region develop interpenetrating phases that harden the metal (spinodal hardening). The lamellar microstructures visible in electron micrographs of these alloys look exactly like Quench's early-time patterns. Polymer blends: mixtures of PMMA and SAN, or polystyrene and polyvinylmethylether, phase-separate by spinodal decomposition when quenched, producing the nano- and micro-scale morphologies that determine mechanical and optical properties of engineering plastics.
Cell membranes may be the most surprising application. The plasma membrane is a mixture of lipids with different melting temperatures — saturated (ordered) and unsaturated (disordered) lipids, plus cholesterol. Under certain conditions, these components phase-separate by Cahn-Hilliard-type dynamics into ordered lipid rafts floating in a disordered sea. These rafts concentrate signaling proteins and may be critical for immune-cell activation and membrane trafficking. The same equation that describes iron alloys governs the nanoscale structure of your cell membrane.
Glass ceramics (Pyrex, Vycor, optical glass) are manufactured by deliberately driving spinodal decomposition in silicate glasses, then etching or heat-treating the separated phases to produce controlled porosity or the glass-ceramic composite. The same labyrinthine morphology Quench generates is precisely what gives these materials their mechanical strength and thermal shock resistance.