Site Guide

Find your way around the Engineering Club.

Know what you need? Search for a component, concept or project.

Around the site

Start

Labs

TestingExperimental

Build

Club

LearnExperimental

Go a little deeper

Entry points to larger collections. Use Search for individual records.

Learning paths & reference

Inside PiCrawlerExperimental

Inside Inventory

Experimental / Statistical mechanics

Potts Model

Lower the temperature below the critical temperature and watch matching regions grow. Raise it above that point to see thermal fluctuations disrupt that order.

Loading simulation…

What this shows

Each square is a site that holds one of qq states, drawn as qq colors. Neighboring sites lower their energy by matching, while temperature changes them at random. The temperature is shown as a multiple of the critical temperature TcT_c, so the phase transition is always at 1:

  • Below TcT_c, matching wins. Regions of one color grow, and given enough time one color covers most of the grid.
  • Above TcT_c, the random changes win, and every color covers about 1/q1/q of the grid.
  • At TcT_c, what happens depends on qq. Up to 4 states the transition is continuous: regions of every size appear at once, as in the Ising model. With 5 or more it is discontinuous: ordered and disordered regions can sit side by side, and the order disappears abruptly.

The corner shows the temperature, qq and the share of sites in the most common state.

Things to try: at the default 3 states, drag the temperature from 1.2 down to 0.8 and back. Then set 10 states and do the same, and compare how sharply the order appears and disappears.

How the visualization works

  • Sites are updated with the Metropolis algorithm. Each attempt picks a site at random and proposes one of the other q−1q - 1 states. If the energy would not go up, the change is made. Otherwise it is made with probability e−ΔE/Te^{-\Delta E/T}.
  • One sweep is as many attempts as there are sites.
  • The grid wraps around at the edges, so no site sits on a boundary.
  • All randomness comes from a seeded pseudo-random generator, and the acceptance probabilities use only addition, subtraction, multiplication and division, so a shared link reproduces the same sequence of configurations at the same sweep count.
  • The simulation runs in a Web Worker so the page stays responsive.

Parameters

  • Grid size: sites along each side. Restarts the run.
  • States: qq, from 2 to 10. Restarts the run.
  • Temperature: as a multiple of TcT_c. Applies from the next sweep.
  • Starting state: random (as if infinitely hot) or all the same (as if at absolute zero). Restarts the run.
  • Speed: sweeps per second. Never changes the results.

Mathematical background

A configuration assigns a state σi∈{1,…,q}\sigma_i \in \{1, \dots, q\} to every site ii. Its energy is

H=−∑⟨i,j⟩δ(σi,σj),H = -\sum_{\langle i, j \rangle} \delta(\sigma_i, \sigma_j),

summed over neighboring pairs, where δ(a,b)\delta(a, b) is 1 when a=ba = b and 0 otherwise. At temperature TT a configuration occurs with probability proportional to e−H/Te^{-H/T}. With q=2q = 2 this is the Ising model with every temperature halved: TcT_c is about 1.135 here and 2.269 there.

Renfrey Potts introduced the model in 1952 and located its critical point on the square lattice by a duality argument. Beffara and Duminil-Copin proved in 2012 that the transition is at

Tc=1ln⁡(1+q),T_c = \frac{1}{\ln\bigl(1 + \sqrt{q}\bigr)},

about 0.995 for q=3q = 3. Whether the transition is continuous was settled by Duminil-Copin, Sidoravicius and Tassion for q≤4q \le 4 and by Duminil-Copin, Gagnebin, Harel, Manolescu and Tassion for q>4q > 4.

The critical temperature describes the infinite square lattice. This finite simulation shows fluctuations and finite-size effects, rather than a sharp thermodynamic singularity.

Sources

Attribution

Simulation and explanation adapted from Stephen McArdle’s Math Visualizer.