The Swendsen - Wang algorithm is the first non-local or cluster algorithm for Monte Carlo simulation for large systems near criticality. It has been introduced by Robert Swendsen and Jian-Sheng Wang in 1987 at Carnegie Mellon.
The original algorithm was designed for the Ising and Potts models, and it was later generalized to other systems as well, such as the XY model by Wolff algorithm and particles of fluids. The key ingredient was the random cluster model, a representation of the Ising or Potts model through percolation models of connecting bonds, due to Fortuin and Kasteleyn. It has been generalized by Barbu and Zhu[1] to arbitrary sampling probabilities by viewing it as a Metropolis–Hastings algorithm and computing the acceptance probability of the proposed Monte Carlo move.
The problem of the critical slowing-down affecting local processes is of fundamental importance in the study of second-order phase transitions (like ferromagnetic transition in the Ising model), as increasing the size of the system in order to reduce finite-size effects has the disadvantage of requiring a far larger number of moves to reach thermal equilibrium. Indeed the correlation time
\tau
Lz
z\simeq2
t\gg\tau
z=0.35
z=2.125
z=0.75
z=2.0
See main article: Random cluster model. The algorithm is non-local in the sense that a single sweep updates a collection of spin variables based on the Fortuin–Kasteleyn representation. The update is done on a "cluster" of spin variables connected by open bond variables that are generated through a percolation process, based on the interaction states of the spins.
Consider a typical ferromagnetic Ising model with only nearest-neighbor interaction.
n,m
bn,m\in\lbrace0,1\rbrace
bn,m=0
n
m
bn,m=1
\sigmanand\sigmam
P\left[bn,m=0|\sigman ≠ \sigmam\right]=1
P\left[bn,m=1|\sigman ≠ \sigmam\right]=0
P\left[bn,m=0|\sigman=\sigma
-2\betaJnm | |
m\right]=e |
P\left[bn,m=1|\sigman=\sigma
-2\betaJnm | |
m\right]=1-e |
Jnm>0
This probability distribution has been derived in the following way: the Hamiltonian of the Ising model is
H[\sigma]=\sum\limits<i,j>-Ji,j\sigmai\sigmaj
and the partition function is
Z=\sum\limits\lbrace\sigma\rbracee-\beta
Consider the interaction between a pair of selected sites
n
m
Hnm[\sigma]=\sum\limits<i,j> ≠ <n,m>-Ji,j\sigmai\sigmaj.
Define also the restricted sums:
same | |
Z | |
n,m |
=\sum\limits\lbrace\sigma\rbrace
-\betaHnm[\sigma] | |
e |
\delta | |
\sigman,\sigmam |
diff | |
Z | |
n,m |
=\sum\limits\lbrace\sigma\rbrace
-\betaHnm[\sigma] | |
e |
\left(1-\delta | |
\sigman,\sigmam |
\right).
\betaJnm | |
Z=e |
same | |
Z | |
n,m |
-\betaJnm | |
+e |
diff | |
Z | |
n,m |
.
Introduce the quantity
ind | |
Z | |
nm |
same | |
=Z | |
n,m |
diff | |
+Z | |
n,m |
the partition function can be rewritten as
\betaJnm | |
Z=\left(e |
-\betaJnm | |
-e |
same | |
\right)Z | |
n,m |
-\betaJnm | |
+e |
ind | |
Z | |
n,m |
.
Since the first term contains a restriction on the spin values whereas there is no restriction in the second term, the weighting factors (properly normalized) can be interpreted as probabilities of forming/not forming a link between the sites:
P<n,m> link
-2\betaJnm | |
=1-e |
.
same | |
Z | |
n,m |
diff | |
Z | |
n,m |
It can be shown that this algorithm leads to equilibrium configurations. To show this, we interpret the algorithm as a Markov chain, and show that the chain is both ergodic (when used together with other algorithms) and satisfies detailed balance, such that the equilibrium Boltzmann distribution is equal to the stationary distribution of the chain.
Ergodicity means that it is possible to transit from any initial state to any final state with a finite number of updates. It has been shown that the SW algorithm is not ergodic in general (in the thermodynamic limit).[2] Thus in practice, the SW algorithm is usually used in conjunction with single spin-flip algorithms such as the Metropolis–Hastings algorithm to achieve ergodicity.
The SW algorithm does however satisfy detailed-balance. To show this, we note that every transition between two Ising spin states must pass through some bond configuration in the percolation representation. Let's fix a particular bond configuration: what matters in comparing the probabilities related to it is the number of factors
q=e-2\beta
p
P\lbrace\sigma\rbrace → \lbrace\sigma'\rbrace | = | |
P\lbrace\sigma'\rbrace → \lbrace\sigma\rbrace |
Pr\left(\lbrace\sigma'\rbrace|B.C.\right)Pr\left(B.C.|\lbrace\sigma\rbrace\right) | = | |
Pr\left(\lbrace\sigma\rbrace|B.C.\right)Pr\left(B.C.|\lbrace\sigma'\rbrace\right) |
| |||||||
|
=e-\beta\Delta
since
\DeltaE=-\sum\limits<l,m>Jlm\left(\sigma'l\sigma'm-\sigmal\sigmam\right)=-\sum\limits<l,m>Jlm
\left[\delta | |
\sigma'l,\sigma'm |
-\left(1-\delta | |
\sigma'l,\sigma'm |
\right)-\delta | |
\sigmal,\sigmam |
+\left(1-\delta | |
\sigmal,\sigmam |
\right)\right]=-2\sum\limits<l,m>Jlm
\left(\delta | |
\sigma'l,\sigma'm |
-\delta | |
\sigmal,\sigmam |
\right)
This is valid for every bond configuration the system can pass through during its evolution, so detailed balance is satisfied for the total transition probability. This proves that the algorithm is correct.
Although not analytically clear from the original paper, the reason why all the values of z obtained with the SW algorithm are much lower than the exact lower bound for single-spin-flip algorithms (
z\geq\gamma/\nu
The algorithm is not efficient in simulating frustrated systems, because the correlation length of the clusters is larger than the correlation length of the spin model in the presence of frustrated interactions.[4] Currently, there are two main approaches to addressing this problem, such that the efficiency of cluster algorithms is extended to frustrated systems.
The first approach is to extend the bond-formation rules to more non-local cells, and the second approach is to generate clusters based on more relevant order parameters. In the first case, we have the KBD algorithm for the fully-frustrated Ising model, where the decision of opening bonds are made on each plaquette, arranged in a checkerboard pattern on the square lattice.[5] In the second case, we have replica cluster move for low-dimensional spin glasses, where the clusters are generated based on spin overlaps, which is believed to be the relevant order parameter.