Mean Field Theory#

  • Mean Field Approximation replaces fluctuating terms with their averages. For a function dependent on multiple variables, the approximation removes all correlations between variables:

\[\big\langle f(x_1, x_2, x_3, \ldots) \big\rangle = f(\langle x_1\rangle, \langle x_2\rangle, \langle x_3\rangle, \ldots)\]
  • Mean field approximation is widely used in electronic-structure theory (Hartree-Fock), theory of liquids (Van der Waals) and condensed matter physics.

Application of MFA to the Ising Model

  • In the Ising model, this approximation allows us to decouple spins, simplifying the system to a single parameter: the average magnetization per spin, \(m\).

\[\langle s_i s_j \rangle \approx \langle s_i \rangle \langle s_j \rangle = m^2\]
\[\langle H \rangle \approx -J\sum_{ij\in neighb} \langle s_{i} \rangle \langle s_{j} \rangle - h \langle s_{i} \rangle =-\frac{1}{2}Jq m^2 -hm \]
  • The 1/2 avoids double counting, and (\(q\)) denotes the number of nearest neighbors, 4 for a 2D lattice and 6 for a 3D lattice.

Free energy of mean field ising models#

Defining macrostate M

  • Consider \(N\) spin-lattice macrostates with magnetization value \(M\) resulting from a net number of spins pointing up (down).

\[N = N_{+} +N_{-}\]
\[M = N_{+} -N_{-}\]
  • Dividing by N we can express probabilities of spin up and down \(N_{\pm}/N\) in terms of magnetization per spin \(m=M/N\) $\(p_{\pm} = \frac{1\pm m}{2}\)$

Entropy, Energy, and Free energy

  • Entropy is the familiar \(S = -\sum_i p_i\log p_i\) expression where \(p_i\) is spin up and down probabilities.

\[S(m) -N k_B \Bigg[\Big(\frac{1+m}{2}\Big) log\Big(\frac{1+m}{2}\Big) + \Big(\frac{1-m}{2}\Big) \Big(\frac{1-m}{2}\Big) \Bigg] \]
  • Energy for total spin magnetization \(M\) is the N times the average energy of each spin in the mean-field approximation

\[ E(m) = -N \Big[\frac{Jq}{2} m^2 -hm \Big]\]
  • Free energy

\[F(m) = E(m) - TS(m)\]
  • Dimensionless free energy per particle

\[f = \frac{F}{Nk_B T} = - \Bigg[\frac{Jq }{2k_B T} m^2 - \frac{h}{k_B T} m \Bigg] + \Bigg[\Big(\frac{1+m}{2}\Big) log\Big(\frac{1+m}{2}\Big) + \Big(\frac{1-m}{2}\Big) \Big(\frac{1-m}{2}\Big) \Bigg]\]

Finding critical point \(Tc\)

\[\frac{\partial f^2}{\partial m^2} = 1-\frac{Jq}{k_BT} = 0 \]
\[T_c = \frac{Jq}{k_B}\]

Magnetization as a function of temperature

The equilibrium value of magnetization is found by minimizing free energy. By taking the first derivative of free energy, we end up with an equation that can only be solved in a self-consistent manner by starting with a guess and iterating until both sides of the equation are equal.

\[-\Big(\frac{Jq }{k_B T}\Big)m - \frac{h}{k_B T}+tanh^{-1}(m) = 0\]
  • For \(h=0\) we have the following simple equation to be solved in self consistent manner:

\[-\Big(\frac{T_c}{T}\Big)m = tanh^{-1}(m)\]
  • For small values of \(m\), we can make an approximation by taylor expanding \(tanh^{-1}(x) = x+1/3x^3\)

\[ -\frac{T_c}{T}m - \frac{h}{k_B T} + (m+1/3m^3)=0\]
  • For \(h = 0\) case the solution is either trivial \(m=0\) or we get:

\[m = \pm \sqrt{\frac{3(T_c-T)}{T_c}}\]

Investigating various limits#

The \(h=0\) MFA case

The equation can be solved in a self-consistent manner or graphically by finding intersection between:

  • \(m =tanh(x)\)

  • \(x = \frac{Jqm}{k_BT}\)

When the slope is equal to one it provides a dividing line between two behaviours.

\[k_B T_c =qJ\]
\[m = tanh \Big(\frac{Tc}{T} m \Big)\]

MFA shows phase transitio for 1D Ising model at finite \(T=T_c\)!

import ipywidgets as widgets
from ipywidgets import interactive, interact
import matplotlib.pyplot as plt
import numpy as np
# Constants
J = 1  # Interaction strength
k = 1  # Boltzmann constant (set to 1 for simplicity)

def entropy(m):
    # Handle log of zero by adding a small number to the argument
    small_number = 1e-10
    return -(1+m)/2 * np.log((1+m)/2 + small_number) - (1-m)/2 * np.log((1-m)/2 + small_number)

def free_energy(m, T):
    # Calculate the free energy for given m and T
    return -0.5 * J * m**2 - T * entropy(m)

def plot_free_energy(T):
    # Magnetization range
    m_values = np.linspace(-1, 1, 100)
    F_values = [free_energy(m, T) for m in m_values]
    
    # Plotting
    plt.figure(figsize=(8, 5))
    plt.plot(m_values, F_values, label=f'T = {T}')
    plt.xlabel('Magnetization (m)')
    plt.ylabel('Free Energy per Spin (F)')
    plt.title('Mean-field Free Energy vs. Magnetization')
    plt.legend()
    plt.grid(True)
    plt.show()

interactive(plot_free_energy, T=(0.1, 2, 0.1 ))
def mfa_ising_Tc(T=1, Tc=1):

    x  = np.linspace(-3,3,1000)
    
    f = lambda x: (T/Tc)*x
    m = lambda x: np.tanh(x)
    
    plt.plot(x,m(x), lw=3, alpha=0.9, color='green')
    
    plt.plot(x,f(x),'--',color='black')
    idx = np.argwhere(np.diff(np.sign(m(x) - f(x))))
    plt.plot(x[idx], f(x)[idx], 'ro')
    
    plt.legend(['m=tanh(x)', 'x'])
    
    plt.ylim(-2,2)
    plt.grid('True')
    plt.xlabel('m',fontsize=16)
    plt.ylabel(r'$tanh (\frac{Tc}{T} m )$')
    plt.show()
interact(mfa_ising_Tc, T=(0.1,5)) 
<function __main__.mfa_ising_Tc(T=1, Tc=1)>
def mfa_ising_h_vs_m(T=1):

    Tc = 1
    x  = np.linspace(-1,1,200)
    
    h = T*(np.arctanh(x) - (Tc/T)*x)
    
    plt.plot(x, h, lw=3, alpha=0.9, color='green')

    plt.plot(x, np.zeros_like(x), lw=1, color='black')
    plt.plot(np.zeros_like(x), x, lw=1, color='black')
     
    plt.grid(True)

    plt.ylabel('m',fontsize=16)
    plt.xlabel('h',fontsize=16)
    plt.ylim([-1,1])
    plt.xlim([-1,1])
    plt.show()
interactive(mfa_ising_h_vs_m, T=(0.1,5)) 
import plotly.graph_objects as go
import numpy as np
from scipy.optimize import fsolve
from scipy.optimize import root_scalar  # Importing root_scalar

def compute_xcross(T, h_over_T):
    
    def f(M):
        Tc = 1.0  # Normalized temperature
        h = h_over_T * T  # Compute actual h from h/T and T
        return M - np.tanh((M + h) / (T / Tc))
    
    # Using symmetric interval for root finding to allow negative solutions
    interval = [-2.0, 2.0]

    # Check if a root is likely within the given range
    if f(interval[0]) * f(interval[1]) > 0:
        return 0.0  # If no root likely, return 0
    
    # Find the root using bisection method within the specified range
    result = root_scalar(f, bracket=interval, method='bisect')
    
    return result.root 

# Define ranges for h/T  and T/Tc (from 0.2 to 1.5)
h_over_T_values = np.linspace(-0.2, 0.2, 101)
T_over_Tc_values = np.linspace(0.1, 1.6, 101)

# Create a meshgrid for T/Tc and h/T
H_over_T, T_over_Tc = np.meshgrid(h_over_T_values, T_over_Tc_values)

# Initialize an array for magnetizations
Magnetizations = np.zeros_like(H_over_T)

# Compute M for each (h/T, T/Tc) pair in the meshgrid
for i, T in enumerate(T_over_Tc_values):
    for j, h in enumerate(h_over_T_values):
        
        Magnetizations[i, j] = compute_xcross(T, h)


# Create a 3D surface plot using Plotly
fig = go.Figure(data=[go.Surface(z=Magnetizations, x=H_over_T, y=T_over_Tc, 
                                 colorscale='RdBu', 
                                 contours={
                                     #'z': {'show': True, 'start': -1.0, 'end': 1.0, 'size': 0.1, 'color':'orange'},
                                     'x': {'show': True, 'start': -1, 'end': 1, 'size': 0.05, 'color':'black'},
                                     'y': {'show': True, 'start': 0.5, 'end': 1.5, 'size': 0.1, 'color':'black'}
                                 })])

# Update plot layout
fig.update_layout(
    title='3D Plot of Magnetization M vs normalized temperature and field; T/Tc and h/T',
    scene=dict(
        xaxis_title='h/T',
        yaxis_title='T/Tc',
        zaxis_title='M',
        aspectmode='manual',
        yaxis_autorange='reversed',  # Reverse the Y-axis
        aspectratio=dict(x=2, y=2, z=0.75),  # Adjust these values as needed
        camera=dict(
            eye=dict(x=-4, y=-2, z=2),  # Adjust camera "eye" position for better view
            up=dict(x=0, y=0, z=1)  # Ensures Z is up
        )
    ),
    autosize=False,
    width=900,
    height=900
)

# Display the figure with configuration options
fig.show()
len(h_over_T_values)//2+1
51
plt.plot(Magnetizations[:, len(h_over_T_values)//2-1], color='blue')
plt.plot(Magnetizations[:, len(h_over_T_values)//2+1], color='blue')
[<matplotlib.lines.Line2D at 0x180bcedf0>]
../_images/202c7065a295cd5d5d980202ab5843170bd24239df1d833f36bd16afa20d8650.png

Critical exponents#

A signature of phase transitions of second kind or critical phenomena is the universal power law behaviour near critical point

\[m \sim |T-T_c |^{\beta}\]
\[c \sim |T-T_c|^{-\alpha}\]
\[\chi =\frac{\partial m}{\partial B} \sim |T-T_c|^{-\gamma}\]

Correlation lengths \(\xi\) diverge at critical points

\[f(r=|j-k|) = \langle s_j s_k \rangle \sim r^{-d+2+\eta}e^{-r/\xi}\]
\[\xi \sim |T-T_c|^{-\nu}\]

Mean field exponents#

We can derive the value of critical exponent \(\beta\) within mean field approximation by Taylor expanding the hyperbolic tangent

\[tanh(x) \approx x-\frac{1}{3}x^3+...\]
\[m = tanh(\beta J q m) \approx \beta J q m - \frac{1}{3} (\beta Jqm)^3\]
  • One solution is obviously m = 0 which is the only solution above \(T_c\)

  • Below \(T_c\) the non-zero solution is found \(m=\sqrt{3}\frac{T}{T_c} \Big(1-\frac{T}{T_c} \Big)^{1/2}+...\)

  • \(\beta_{MFA}=1/2\)

Landau theory#

# Calculate the free energy for different temperatures
T = 5
a, b = -1, 3

phi = np.linspace(-1, 1, 100)
F   = a * phi**2 / 2 + b * phi**4 / 4

# Plot the free energy as a function of the order parameter for different temperatures
plt.figure(figsize=(10, 6))
plt.plot(phi, F )
plt.xlabel('Order parameter')
plt.ylabel('Free energy')
plt.show()
../_images/aa4cdbebd9221735ea978d657c99786549dcd3583bf285b408baa695d3c65354.png

Problems#

  1. Use Transfer matrix method to solve general 1D Ising model with \(h = 0\) (Do not simply copy the solution by setting h=0 but repeat the derivation :)

  2. Plot temperature dependence of heat capacity and free energy as a function for \((h=\neq, J\neq 0)\) \((h=0, J\neq 0)\) and \((h=\neq, J\neq \neq)\) cases of 1D Ising model. Coment on the observed behaviours.

  3. Explain in 1-2 sentences:

    • why heat capacity and magnetic susceptibility diverge at critical temperatures.

    • why correlation functions diverge at a critical temperature

    • why are there universal critical exponents.

    • why the dimensionality and range of intereactions matters for existance and nature of phase transitions.

    • why MFT predictions fail for low dimensionsal systems but consistently get better with higher dimensions?

  4. Using mean field approximation show that near critical temperature magnetization per spin goes as \(m\sim (T_c-T)^{\beta}\) (critical exponent not to nbe confused with inverse \(k_B T\)) and find the value of \beta. Do the same for magnetic susceptibility \(\chi \sim (T-T_c)^{-\gamma}\) and find the value of \(\gamma\)

  5. Consider a 1D model given by the Hamiltonian:

\[H = -J\sum^{N}_{i=1} s_i s_{i+1} + D\sum^{N}_{i=1} s^2_i \]

where \(J>1\), \(D>1\) and \(s_i =-1,0,+1\)

  • Assuming periodic boundary codnitions calcualte eigenvalues of the transfer matrix

  • Obtain expresions for internal energy, entropy and free energy

  • What is the ground state of this model (T=0) as a function of \(d=D/J\) Obtain asymptotic form of the eigenvalues of the transfer matrix in the limit \(T\rightarrow 0\) in the characteristic regimes of d (e.g consider differnet extereme cases)