Site Percolation (2D)
Site percolation on a square lattice colors each cell independently “open” with probability p and “closed” otherwise. Open cells that share an edge form clusters. Near the critical threshold p_c ≈ 0.592746 on the infinite square lattice, correlation lengths diverge and the spanning cluster (when it exists) is a fractal with fractal dimension D_f = 91/48 in two dimensions. This simulator draws one finite realization at your chosen p, labels connected components, highlights the largest cluster, and reports whether **any** cluster connects the left and right edges (spanning need not be the largest cluster). A crude box-counting slope on the largest cluster gives a rough D̂ when the cluster is large enough; it is noisy for small systems and should be read as illustrative.
Who it's for: Students learning phase transitions on networks, scaling, and universality in statistical physics.
Key terms
- Percolation
- Critical probability p_c
- Spanning cluster
- Fractal dimension
- Box counting
- Correlation length
How it works
Square-lattice site percolation: random occupation, cluster labeling, spanning probability near p_c, and a crude fractal dimension from box counting on the largest cluster.
Frequently asked questions
- Why does my estimated D̂ differ from 91/48?
- 91/48 describes the spanning cluster at criticality in the thermodynamic limit. A single L×L sample is finite, sub-leading corrections matter, and box counting with a handful of box sizes is statistically noisy. Expect qualitative agreement near p_c only when the largest cluster is big and you average many realizations.
- Is this bond or site percolation?
- Site percolation: vertices (cells) are occupied randomly; edges are implicit between occupied nearest neighbors. Bond percolation would randomize links instead; the critical probability is different.
- Does “spanning” require the highlighted largest cluster to cross the system?
- No. The gold frame means **some** open cluster connects the left column to the right column. The largest cluster is highlighted for visualization and for the box-counting estimate D̂, but it might sit in the interior while a thinner cluster provides connectivity.
More from Thermodynamics
Other simulators in this category — or see all 31.
Bose–Einstein vs Fermi–Dirac
Grand-canonical occupation f(E) at the same T and μ: FD, BE, and classical Maxwell–Boltzmann comparison.
Ideal Gas Simulator
Bouncing particles in a box. See PV=nRT in action.
Gas Laws Interactive
Boyle's, Charles's, Gay-Lussac's laws with interactive piston.
Heat Transfer
Conduction, convection, and radiation with temperature gradients.
Phase Diagram
Temperature-pressure diagram with phase transitions.
Carnot Engine
PV diagram animation with cycle steps and efficiency.