Measurements

After the system reaches equilibrium, we can measure physical quantities, such as, energy, magnetization, and various susceptibilities. However, measuring physical quantities accurately requires careful consideration of autocorrelation and the generation of independent samples. Autocorrelation refers to the correlation between measurements taken at different Monte Carlo steps, which can lead to biased estimates and underestimated errors. Generating independent samples ensures that the measurements are statistically meaningful.

Autocorrelation of Physical Quantities

1. Autocorrelation Function

The autocorrelation function CA(t)C_A(t) measures the correlation between measurements of a quantity AA separated by a time interval tt (in Monte Carlo steps): CA(t)=⟨AkAk+tβŸ©βˆ’βŸ¨Ak⟩2⟨Ak2βŸ©βˆ’βŸ¨Ak⟩2, C_A(t) = \frac{\langle A_k A_{k+t} \rangle - \langle A_k \rangle^2}{\langle A_k^2 \rangle - \langle A_k \rangle^2}, where ⟨AkAk+t⟩\langle A_k A_{k+t} \rangle is the average of the product of measurements separated by tt steps.

2. Autocorrelation Time

The autocorrelation time Ο„A\tau_A characterizes how quickly the autocorrelation function decays. It is defined as: Ο„A=βˆ‘t=1∞CA(t). \tau_A = \sum_{t=1}^{\infty} C_A(t). In practice, Ο„A\tau_A is estimated by fitting CA(t)C_A(t) to an exponential decay: CA(t)∼eβˆ’t/Ο„A. C_A(t) \sim e^{-t / \tau_A}.

3. Effect of Autocorrelation

Autocorrelation reduces the effective number of independent samples, leading to underestimated statistical errors. To account for this, the error in the measured quantity AA is corrected by: ΟƒA=Var(A)Neff, \sigma_A = \sqrt{\frac{\text{Var}(A)}{N_{\text{eff}}}}, where Var(A)\text{Var}(A) is the variance of AA, and NeffN_{\text{eff}} is the effective number of independent samples:

  • Var(A)\text{Var}(A) is the variance of AA, defined as: Var(A)=⟨A2βŸ©βˆ’βŸ¨A⟩2, \text{Var}(A) = \langle A^2 \rangle - \langle A \rangle^2, where ⟨A2⟩\langle A^2 \rangle is the average of the squared measurements, and ⟨A⟩\langle A \rangle is the average of the measurements.
  • NeffN_{\text{eff}} is the effective number of independent samples: Neff=Nmeas1+2Ο„A. N_{\text{eff}} = \frac{N_{\text{meas}}}{1 + 2 \tau_A}.

Generating Independent Samples

1. Spacing Measurements

To reduce autocorrelation, measurements should be spaced by at least the autocorrelation time Ο„A\tau_A. This ensures that consecutive measurements are approximately independent. For example, if Ο„A=10\tau_A = 10, measurements should be taken every 10 Monte Carlo steps.

2. Blocking Method

The blocking method is a technique to generate independent samples by grouping measurements into blocks. Each block should be larger than the autocorrelation time. The average of each block is treated as an independent sample, and the variance of these block averages is used to estimate the error.

3. Parallel Tempering

For systems with slow dynamics, parallel tempering can be used to generate independent samples. This involves running multiple simulations at different temperatures and periodically swapping configurations between them. The swaps help the system explore configuration space more efficiently.

Physical Quantities

Some example physical quantities are shown below for Ising model. For different models, different quantities would need to be considered.

Magnetization:

M=1Nβˆ‘isiz, M = \frac{1}{N} \sum_i s_i^z, where NN is the total number of spins.

Energy:

E=βˆ’Jβˆ‘βŸ¨i,j⟩sizsjzβˆ’hβˆ‘isiz. E = -J \sum_{\langle i,j \rangle} s_i^z s_j^z - h \sum_i s_i^z.

Magnetic susceptibility:

The magnetic susceptibility Ο‡\chi measures the response of the system’s magnetization to an external magnetic field. It is defined as: Ο‡=βˆ‚βŸ¨MβŸ©βˆ‚h, \chi = \frac{\partial \langle M \rangle}{\partial h}, where ⟨M⟩\langle M \rangle is the average magnetization, and hh is the external magnetic field. In Monte Carlo simulations, Ο‡\chi is computed from the fluctuations in the magnetization MM using the formula: Ο‡=Ξ²N(⟨M2βŸ©βˆ’βŸ¨M⟩2), \chi = \frac{\beta}{N} \left( \langle M^2 \rangle - \langle M \rangle^2 \right), where:

  • Ξ²=1/(kBT)\beta = 1/(k_B T) is the inverse temperature,
  • NN is the total number of spins,
  • ⟨M⟩\langle M \rangle is the average magnetization,
  • ⟨M2⟩\langle M^2 \rangle is the average of the squared magnetization.

Specific Heat:

The specific heat CC measures the system’s heat capacity, or how much energy is required to change its temperature. It is defined as: C=βˆ‚βŸ¨EβŸ©βˆ‚T, C = \frac{\partial \langle E \rangle}{\partial T}, where ⟨E⟩\langle E \rangle is the average energy of the system.

In Monte Carlo simulations, CC is computed from the fluctuations in the energy EE using the formula: C=Ξ²2N(⟨E2βŸ©βˆ’βŸ¨E⟩2), C = \frac{\beta^2}{N} \left( \langle E^2 \rangle - \langle E \rangle^2 \right), where:

  • Ξ²=1/(kBT)\beta = 1/(k_B T) is the inverse temperature,
  • NN is the total number of spins,
  • ⟨E⟩\langle E \rangle is the average energy,
  • ⟨E2⟩\langle E^2 \rangle is the average of the squared energy.