Some couplings in a spin glass conflict, so no arrangement of spins satisfies them all. The energy landscape fills with disordered valleys, and cooling freezes the system into one.
At a dinner party with friend pairs (same side) and rival pairs (opposite sides), any loop of people containing an odd number of rival pairs leaves at least one pair unhappy no matter how you seat them. This is called frustration, and it is the central idea behind spin glasses.
A spin glass is a material with random magnetic couplings. Some bonds want neighbors aligned and some want them opposite, and on certain triangles no assignment satisfies every bond. The system has many nearly equivalent configurations separated by energy barriers, and cooling it freezes in disorder. Below, exact enumeration counts what frustration costs and how many valleys a small patch has, annealing measures how often cooling reaches the bottom, a large lattice shows the slow relaxation called aging, and the mean-field model Parisi solved shows the many states directly.
The majority rule of the previous essay is this model at zero temperature with every coupling ferromagnetic. There every bond could be satisfied at once, and only geometry blocked consensus. Here the couplings have mixed signs, and some cannot be satisfied together. (The ferromagnet at finite temperature, with its phase transition, lives in the Ising essay of the lattice simulation series.)
Each circle is a spin (red up, blue down). Solid bonds are ferromagnetic and want matching spins; dashed bonds are antiferromagnetic and want opposite spins. Frustration depends only on the bonds, so flipping spins never changes which triangles are orange.
Click a spin to flip it.
Figure 1. A triangular spin glass lattice. Green bonds are satisfied by the current spins and red bonds are not. Orange triangles are frustrated: no configuration satisfies all three of their bonds.
A triangle is frustrated exactly when it has an odd number of antiferromagnetic bonds. To see what frustration costs, take a 20-spin patch of the same lattice: its $2^{20}$, about a million, configurations are few enough to check every one. Figure 2 sets every possible number of the patch's 43 bonds antiferromagnetic, draws 24 arrangements of each, and finds each draw's lowest energy, its ground state, exactly.
--
Figure 2. Each dot is one draw of bonds on the 20-spin patch; lines are column means (medians in the bottom panel). Top: share of the 24 triangles that are frustrated, against the exact expectation (dashed). Middle: bonds the exact ground state leaves broken, against the floor of one broken bond per two frustrated triangles (dashed). Bottom: how many configurations share the ground state, a configuration and its global flip counted once. Click, tap or use the arrow keys to pick a column; the lattice shows one of its draws in its ground state, frustrated triangles shaded, broken bonds heavy red.
The frustrated share reaches one half by 40% antiferromagnetic and keeps climbing, to every triangle when every bond is antiferromagnetic, because a triangle is an odd loop. Each frustrated triangle needs at least one broken bond, and a broken bond serves at most the two triangles beside it, so half the frustrated count is a floor on the cost. At 40% the ground state breaks 8.0 bonds on average against a floor of 6.0: frustrated triangles sit apart, and strings of broken bonds have to join them in pairs. With every bond antiferromagnetic the frustrated triangles tile the patch and 12 broken bonds pair them exactly. On this patch that ground state is unique, though on a large triangular lattice the number of ground states grows exponentially with size (Wannier, 1950). In between, ground states multiply: a median of 6 at 40%, 17 just short of all antiferromagnetic, and more than a hundred in 8 of the 1,056 draws.
The Metropolis algorithm picks a spin, computes the energy change $\Delta E$ of flipping it, and accepts the flip if it goes downhill, or with probability $e^{-\Delta E / T}$ if it goes uphill. At $T = 5$ about four proposed flips in five are accepted, uphill or not; near $T = 0$ only downhill and level moves are accepted.
The schedule cools geometrically from $T = 5$ to $T = 0.05$; the slider sets how many sweeps it takes. Breaking one more bond costs 2, so final energies come in steps of 2. Offline, for 120 draws of bonds on this 30-spin lattice, we found each true ground state by trying all $2^{29}$ configurations and ran 400 anneals per setting. A 10-sweep cooling leaves about three runs in four one to four bonds above the ground state. A 1000-sweep cooling brings about four runs in five down to it on a typical draw, but anywhere from under half to all of them depending on the bonds. Click the run chips after a few slow runs: runs that tie at the lowest energy usually sit in different configurations, because a typical draw has about nine ground states.
While paused, click a spin to flip it by hand.
Figure 3. Each colored line is one cooling run; the dashed grey curve is the temperature schedule \( T(t) \) on its own axis. Pause to inspect the configuration or flip spins by hand to probe the local barrier. Click a run chip to recall that run's final state.
Back on the 20-spin patch, call a configuration stuck if no single flip lowers its energy, and group stuck configurations joined by flips costing nothing into one valley. A zero-temperature quench (the majority rule again, except that a flip that changes nothing is never taken) always ends in some valley. Figure 4 lists every valley and measures how often 2000 quenches from random starts end there.
With all bonds ferromagnetic there are 37 valleys. The lowest, all spins aligned, catches a little under half of the quenches; the other 36 are open-boundary cousins of the previous essay's frozen stripes, one or two walls running edge to edge. With 40% antiferromagnetic bonds the count usually rises: over 200 draws the median was 75 valleys, and nine draws in ten gave between 37 and 134. In about half the draws two or more valleys share the lowest energy, and the share of quenches that reach it falls to about one in seven (between 4% and 29% in nine draws of ten).
Figure 4. Every valley of a 4×5 triangular patch with open edges, found by exhaustive enumeration. Horizontal position is energy above the lowest valley (valleys at the same energy are spread slightly apart); vertical position is the share of 2000 random-start quenches that end in that valley, on a log scale. Orange marks the lowest valleys. A configuration and its global spin flip are counted once. Hover or tap a dot to see one configuration from that valley, with unsatisfied bonds drawn heavy red.
Frustration makes even this small landscape harder to search: there are more valleys for a greedy descent to stop in, and the lowest ones are no longer related by a simple symmetry, so finding one says little about where the others are. On a planar lattice with no external field the ground state can still be found in polynomial time, by pairing the frustrated triangles of Figure 2 with the shortest strings of broken bonds, a matching problem. Barahona showed in 1982 that adding a field or going to three dimensions makes it NP-hard.
Nothing can be enumerated on 4,096 spins (a 64 by 64 lattice wrapped into a torus, 40% of bonds antiferromagnetic), but we can watch it. Figure 5 starts one random configuration at four fixed temperatures and runs the Metropolis rule. The zero-temperature quench is stuck within seven sweeps at −0.426 per bond, no lower than the lattice sits at $T = 2$. At $T = 1$ the energy nearly stops after a few hundred sweeps (−0.544 at 300, −0.549 at 10,000). At $T = 0.6$ it goes lower and is still falling at the last sweep, from −0.560 at 3,000 sweeps to −0.562 at 10,000.
--
Figure 5. Left: energy per bond against sweeps since the quench, log axis, one line per temperature, same bonds and same random start. Right: for the chosen temperature, the overlap $C = \frac{1}{N}\sum_i s_i(t_w)\,s_i(t_w + t)$ between the configuration at age $t_w$ and the one $t$ sweeps later, for three ages. Pick a temperature with the buttons or by clicking its line.
The right panel asks how much of the configuration at age $t_w$ survives $t$ sweeps later. At $T = 2$ the three ages give the same curve: the lattice forgets in a few dozen sweeps, however old it is. At $T = 0.6$ they separate. After 1,000 further sweeps a lattice quenched 10 sweeps earlier keeps an overlap of 0.42, one quenched 1,000 sweeps earlier keeps 0.73. The older system changes more slowly, so its behaviour depends on its age as well as its temperature. This is aging, which Lundgren, Svedlindh, Nordblad and Beckman measured in a copper-manganese spin glass in 1983. At $T = 1$ the energy has nearly stopped falling, yet the ages still separate: 0.18 against 0.41 after 1,000 sweeps.
Sherrington and Kirkpatrick (1975) proposed a spin glass that can be solved: every spin coupled to every other, each coupling a Gaussian random number of variance $1/N$. It freezes below $T = 1$. Giorgio Parisi's solution of this model gives its ground-state energy in the limit of many spins, −0.7633 per spin. Figure 6 measures how close three searches come.
--
Figure 6. Energy per spin of the Sherrington-Kirkpatrick model against the number of spins (log axis). Dots are single samples of the couplings, lines are means. Steepest descent always makes the flip that lowers the energy most; the quench flips in random order; the anneal cools from $T = 3$ to $0.05$ over 1,000 sweeps. Up to 20 spins every configuration is checked for the exact ground state. Dashed: Parisi's value for infinitely many spins. Click, tap or arrow to read a column.
Small systems sit well above Parisi's value even at their exact ground state, −0.654 per spin on average at 20 spins; Palassini (2003) found the gap shrinks roughly as $N^{-2/3}$. The anneal finds the exact ground state in 59 of 72 small samples and reaches −0.749 at 1,024 spins. Both single-flip descents stop near −0.68 there, about 0.07 per spin higher, and it makes little difference whether they flip steepest first or in random order: both stop in the first valley they reach.
Parisi's solution says more than the energy. Below $T = 1$ the glass has many equilibrium states that no symmetry relates, so two copies of the same sample, equilibrated independently, can sit in different ones. Their overlap $q = \frac{1}{N}\sum_i s^a_i s^b_i$ measures how alike they are, and its distribution $P(q)$ is the order parameter Parisi proposed in 1983. Figure 7 runs two copies of 64-spin systems by parallel tempering and records $q$ every sweep.
Figure 7. Distribution of the overlap $q$ between two independently equilibrated copies of the same 64-spin system, collected over 16,000 sweeps after 4,000 of burn-in, on a fixed square-root vertical scale. The ferromagnet couples every pair equally (strength $1/N$, so it also orders below $T = 1$); the three glasses are Sherrington-Kirkpatrick samples. Each copy is a ladder of 12 temperatures that swap configurations, which lets it cross barriers at the lowest one.
The ferromagnet gives two sharp peaks at $q = \pm 0.94$: both copies are magnetized, either the same way or opposite. Each glass sample spreads its weight across the whole range, and each in its own way: $|q| < 0.25$ holds 26% of the first sample's weight, 6% of the second's and 40% of the third's. A broad $P(q)$ that differs between samples is what many states look like in this measurement. Switch to $T = 1.5$ and all four collapse to one bump around zero.
Parisi received half of the 2021 Nobel Prize in Physics "for the discovery of the interplay of disorder and fluctuations in physical systems from atomic to planetary scales." In his solution the glass's states are organized as a hierarchy, like the leaves of a family tree (Mézard and colleagues, 1984). The same ideas have since been applied to neural network memory (Amit, Gutfreund and Sompolinsky, 1985), error-correcting codes (Sourlas, 1989), and random optimization problems such as the traveling salesman problem (Mézard and Parisi, 1986).
The next essay removes the couplings altogether and asks only whether neighboring sites connect, which already gives a sharp threshold.