Lesson 22

Ising Model

INTRODUCTION
The Ising model is a very simple system that exhibits many of the characteristics of physical systems of large numbers of particles. In this lesson we will use the Ising model to investigate a phase transition between randomly ordered domains and uniformly aligned domains, prepresenting the transition into ferromagnetism..

You are undoubtably aware of the magnetization properties of iron, but you may not have experienced the phase transition that occurs at 1000 K. Above this temperature, iron is no longer ferromagnetic. Instead, the individual domains of aligned atoms within the iron become randomly oriented. The Ising model was first used in the 1920s to study this phase transition in ferromagnetism.

The Ising model consists of a lattice of spins, which, in our application can either be up or down.

Imagine each of these spins was a tiny bar magnet, and all the magnets were aligned. If you tried to flip one of the magnets, you would have to do work on the system because you are fighting against the magnetic field of the neighboring magnets; the magnets prefer to be aligned. We can model this effect by assuming that individual spins interact with their nearest neighbors, resulting in an interaction energy than depends on the relative alignment of the spins. If the individual spins can take on values of +1 or -1 (corresponding to up or down), we can write the total energy of the system as

$E = -J \sum s_i s_j$

where the summation is over all (4 for a 2D lattice) the pairs of nearest neighbors in the system. The parameter J is known as the exchange energy, and if this constant is positive, the spins prefer to be aligned. If you try to flip one spin in the system, you can use this equation to calculate the change in the energy of the entire system due to that spin flip. For instance, consider a random box in our lattice of spins, along with its four nearest neighbors:

Flipping the spin in this box would change the total energy of the whole system through the contribution of the interaction energy with its four nearest nieghbors. Before flipping, this contribution is

$E_{before} = -J \cdot (+1) \cdot ( -1 -1 -1 +1) = +2J$

corresponding to 3 neighbors aligned with the spin in cell (i,j) (hence lower - negative - energy) and one spin aligned in the opposite direction (a high potential energy). After flipping, the contribution to the total energy of this cell would be

$E_{after} = -J \cdot (-1) \cdot ( -1 -1 -1 +1) = -2J$

The change in the total energy of the system after flipping this one cell would be

$E_{flip} = E_{after} - E_{before} = -4J$

So, if J is positive, this would decrease the energy of the system and hence it would be an energetically favorable change.

If this was all that was involved - driving the system to the lowest energy state - the end result would simply be all the cells aligned with each other. If Eflip > 0 the process would require an input of energy into the system; this is where the concept of energy comes in. The basic idea is that the thermal energy of the system provides the means for flipping spins when Eflip > 0. If the temperature is high (kT is high relative to Eflip), it will be easy to make energetically unfavorable flips because there is plenty of thermal energy available. Conversely, if the temperature is low, spins are not likely to flip when Eflip > 0.

To implement this concept of thermal spin flips, we need to know the probability that a given (unfavorable) spin flip will occur as a function of temperature. We begin with the fundamental result of statistical mechanics that for a system in equilibrium with a heat bath at temperature T, the probability of finding the system in any particular state m of energy Em is proportional to the Boltzmann factor

$P_m \propto e^{-E_m/kT}$

Skipping Einstein's elegant arguement of detailed balance...

The probability of a system transitioning from a lower energy state (2) to a higher energy state (1) is given by

$P \propto e^{-(E_1-E_2)/kT}$

The algorithm for our Ising model should look something like this:

  • Declare and initialize a 2D array of integers spin = ones((nmax,nmax))
  • Flip lots (thousands) of spins
    • Choose a random cell, e.g., (i,j) to decide to flip
    • Calculate Eflip based on 4 neighbors
    • If Eflip < 0 then flip the spin
    • If Eflip > 0 then
      • Calculate the probability of flipping
      • If random() < Probability then flip the spin
    • Track the bulk magnetization as a function of time (# of flips)

This problem is made more challenging from a programming perspective by the finite boundaries of our 2D lattice. Because the cells on a boundary have fewer neighbors, the statistic governing their behavior may be different from the cells in the bulk interior. One can avoid this limitation by imposing periodic boundaries on all side. For example, a cell on the left hand side of the lattice would have a left-hand neighbor that corresponds to the right-most cell on the lattice.

One bulk property we can use to track the state of the system is the total magnetization

$M = \sum s(i,j)$

If we pick a high temperature (greater than unity in our normalized units), the spins are flipping more or less randomly everywhere since energetically unfavorable spins are easily driven by the high temperature. The result is a random bulk magnetization as shown below.

Assignment: Create an Ising model on a 2D lattice of 10 by 10 cells. Generate a plot of magnetization versus time for three different values of the temperature: Cold, where the spins are highly aligned; Hot, where the magnetization bounces around zero; Warm, where the magnetization jumps between states of positive and negative constants.