Skip to content

The Grand Canonical Ensemble

In many physical situations, a system exchanges both energy and particles with a reservoir. The grand canonical ensemble describes such open systems. The macroscopic variables are the chemical potential μ\muThe volume VVAnd the temperature TT.

Definition. The grand partition function is

Ξ=N=0ieβ(Ei(N)μN)\Xi = \sum_{N=0}^{\infty} \sum_{i} e^{-\beta(E_{i}^{(N)} - \mu N)}

Where the outer sum is over all possible particle numbers NN and the inner sum is over all states with NN particles.

The probability that the system is in state ii with NN particles is

Pi,N=eβ(Ei(N)μN)ΞP_{i,N} = \frac{e^{-\beta(E_{i}^{(N)} - \mu N)}}{\Xi}

Theorem 3.1. The grand potential ΦG=kBTlnΞ\Phi_G = -k_BT \ln \Xi satisfies

ΦG=FμN=PV\Phi_G = F - \mu N = -PV

Proof. For a classical ideal gas, Ξ=N=0eβμNZN\Xi = \sum_{N=0}^{\infty} e^{\beta \mu N} Z_N where ZN=zN/N!Z_N = z^N/N! is the canonical partition function. Therefore:

Ξ=N=0(zeβμ)NN!=exp(zeβμ)\Xi = \sum_{N=0}^{\infty} \frac{(z e^{\beta \mu})^N}{N!} = \exp(z e^{\beta \mu})

ΦG=kBTlnΞ=kBTzeβμ=PV\Phi_G = -k_BT \ln \Xi = -k_BT \cdot z e^{\beta \mu} = -PV

The last equality follows from the ideal gas law PV=NkBTPV = Nk_BT with N=zeβμN = z e^{\beta \mu}. More generally, ΦG=PV\Phi_G = -PV holds for all systems. \blacksquare

Key relations from lnΞ\ln \Xi:

N=1βlnΞμT,V,E=lnΞβμ,V+μβlnΞμT,V\langle N \rangle = \frac{1}{\beta}\frac{\partial \ln \Xi}{\partial \mu}\bigg|_{T,V}, \quad \langle E \rangle = -\frac{\partial \ln \Xi}{\partial \beta}\bigg|_{\mu,V} + \frac{\mu}{\beta}\frac{\partial \ln \Xi}{\partial \mu}\bigg|_{T,V}

S=kB(lnΞ+βEβμN)S = k_B\left(\ln \Xi + \beta \langle E \rangle - \beta \mu \langle N \rangle\right)

Theorem 3.2. The particle number fluctuations in the grand canonical ensemble satisfy

N2N2=kBT(Nμ)T,V\langle N^2 \rangle - \langle N \rangle^2 = k_BT \left(\frac{\partial \langle N \rangle}{\partial \mu}\right)_{T,V}

Proof. N2N2=1β22lnΞμ2=1βμ(1βlnΞμ)=1βNμ\langle N^2 \rangle - \langle N \rangle^2 = \frac{1}{\beta^2}\frac{\partial^2 \ln \Xi}{\partial \mu^2} = \frac{1}{\beta}\frac{\partial}{\partial \mu}\left(\frac{1}{\beta}\frac{\partial \ln \Xi}{\partial \mu}\right) = \frac{1}{\beta}\frac{\partial \langle N \rangle}{\partial \mu}. \blacksquare

For an ideal gas, N=zeβμ\langle N \rangle = z e^{\beta \mu}So N/μ=βN\partial \langle N \rangle / \partial \mu = \beta \langle N \rangleGiving relative fluctuations:

N2N2N2=1N\frac{\langle N^2 \rangle - \langle N \rangle^2}{\langle N \rangle^2} = \frac{1}{\langle N \rangle}

This is Poisson …/4-statistics-and-probability/2_statistics: fluctuations scale as 1/N1/\sqrt{N}Negligible for macroscopic systems.

3.4 Worked Example: Ideal Gas in the Grand Canonical Ensemble

Section titled “3.4 Worked Example: Ideal Gas in the Grand Canonical Ensemble”

Problem. Compute Ξ\Xi, N\langle N \rangleAnd E\langle E \rangle for a classical ideal gas in the grand canonical ensemble.

Solution

The single-particle partition function is z=V/λth3z = V/\lambda_{\mathrm{th}^3} where λth=h/2πmkBT\lambda_{\mathrm{th} = h/\sqrt{2\pi m k_BT}}. The canonical partition function for NN indistinguishable particles is ZN=zN/N!Z_N = z^N/N!. The grand partition function:

Ξ=N=0zNN!eβμN=N=0(zeβμ)NN!=ezeβμ\Xi = \sum_{N=0}^{\infty} \frac{z^N}{N!} e^{\beta \mu N} = \sum_{N=0}^{\infty} \frac{(ze^{\beta \mu})^N}{N!} = e^{ze^{\beta \mu}}

lnΞ=zeβμ=Vλth3eβμ\ln \Xi = ze^{\beta \mu} = \frac{V}{\lambda_{\mathrm{th}^3} e^{\beta \mu}}

Average particle number:

N=1βlnΞμ=Vλth3eβμ\langle N \rangle = \frac{1}{\beta}\frac{\partial \ln \Xi}{\partial \mu} = \frac{V}{\lambda_{\mathrm{th}^3} e^{\beta \mu}}

Solving for the chemical potential: μ=kBTln(Nλth3/V)\mu = k_BT \ln(\langle N \rangle \lambda_{\mathrm{th}^3 / V)}.

Average energy (using E=lnΞ/β+μN/(kBT)\langle E \rangle = -\partial \ln \Xi / \partial \beta + \mu \langle N \rangle / (k_BT)):

E=32NkBT\langle E \rangle = \frac{3}{2}\langle N \rangle k_BT

This recovers the equipartition result. \blacksquare

  • Confusing the grand canonical ensemble with the canonical ensemble: In the canonical ensemble, NN is fixed and TT is specified. In the grand canonical ensemble, μ\mu is specified and NN fluctuates. Using the wrong ensemble for a problem (e.g., fixing NN when the system exchanges particles with a reservoir) leads to incorrect results.
  • Forgetting that Ξ\Xi is a sum over both NN and states: The grand partition function sums over all particle numbers and all microstates for each NN. It is not simply a product of single-particle partition functions unless particles are non-interacting.
  • Assuming fluctuations are always negligible: While relative fluctuations scale as 1/N1/\sqrt{N}, in small systems (nanoparticles, quantum dots, biological macromolecules) NN can be small enough that fluctuations become significant and the canonical and grand canonical ensembles give different predictions.
  • Misapplying ΦG=PV\Phi_G = -PV: This relation holds for homogeneous systems in thermodynamic equilibrium. For non-equilibrium or inhomogeneous systems (e.g., systems with interfaces or external fields), the grand potential includes additional terms.

Worked Example: Grand Canonical Treatment of Adsorption

Section titled “Worked Example: Grand Canonical Treatment of Adsorption”

Problem. A surface has MM independent adsorption sites, each of which can be either empty or occupied by at most one gas molecule with energy ε-\varepsilon. Derive the average coverage θ=N/M\theta = \langle N \rangle / M in equilibrium with a gas reservoir at chemical potential μ\mu.

Solution. Each site is a two-level system: empty with energy 0, occupied with energy ε-\varepsilon. The single-site grand partition function is:

ξ=1+eβ(μ+ε)\xi = 1 + e^{\beta(\mu + \varepsilon)}

Since sites are independent, Ξ=ξM=(1+eβ(μ+ε))M\Xi = \xi^M = (1 + e^{\beta(\mu + \varepsilon)})^M.

N=1βlnΞμ=Meβ(μ+ε)1+eβ(μ+ε)\langle N \rangle = \frac{1}{\beta}\frac{\partial \ln \Xi}{\partial \mu} = M \frac{e^{\beta(\mu + \varepsilon)}}{1 + e^{\beta(\mu + \varepsilon)}}

θ=NM=eβ(μ+ε)1+eβ(μ+ε)=11+eβ(μ+ε)\theta = \frac{\langle N \rangle}{M} = \frac{e^{\beta(\mu + \varepsilon)}}{1 + e^{\beta(\mu + \varepsilon)}} = \frac{1}{1 + e^{-\beta(\mu + \varepsilon)}}

This is the Langmuir adsorption isotherm. Since the gas reservoir is ideal, μ=kBTln(P/P0)\mu = k_BT \ln(P/P_0), giving θ=KP/(1+KP)\theta = KP/(1 + KP) where K=eβε/P0K = e^{\beta\varepsilon}/P_0, recovering the standard Langmuir form.

Worked Example: Fermi-Dirac and Bose-Einstein Statistics

Section titled “Worked Example: Fermi-Dirac and Bose-Einstein Statistics”

For non-interacting quantum gases, the grand partition function factorises over single-particle states:

Ξ=iΞi,Ξi={1+eβ(εiμ)(fermions)11eβ(εiμ)(bosons)\Xi = \prod_i \Xi_i, \quad \Xi_i = \begin{cases} 1 + e^{-\beta(\varepsilon_i - \mu)} & \text{(fermions)} \\ \frac{1}{1 - e^{-\beta(\varepsilon_i - \mu)}} & \text{(bosons)} \end{cases}

The average occupation number follows directly:

ni=1βlnΞiεi=1eβ(εiμ)±1\langle n_i \rangle = -\frac{1}{\beta}\frac{\partial \ln \Xi_i}{\partial \varepsilon_i} = \frac{1}{e^{\beta(\varepsilon_i - \mu)} \pm 1}

where ++ is for fermions (Fermi-Dirac) and - is for bosons (Bose-Einstein). This unified derivation from the grand canonical ensemble illustrates its power: both quantum statistics emerge naturally from the same formalism, with the only difference being whether each single-particle state can be occupied at most once (fermions) or any number of times (bosons).

  • The grand canonical ensemble extends the canonical ensemble by allowing particle number fluctuations, making it suitable for open systems in contact with both a heat reservoir and a particle reservoir.
  • ΦG=PV\Phi_G = -PV connects microscopic statistics to macroscopic thermodynamics: The grand potential directly gives the equation of state, linking the partition function to pressure and volume.
  • Fluctuations scale as 1/N1/\sqrt{N}: For macroscopic systems (N1023N \sim 10^{23}), relative particle number fluctuations are negligible (1012\sim 10^{-12}), justifying the use of the canonical ensemble for most practical purposes.
  • The fugacity z=eβμz = e^{\beta\mu} parameterises particle number: The grand partition function is a power series in zz, where each coefficient encodes the thermodynamics of the NN-particle sector.
  • Ideal gas statistics emerge naturally: The grand canonical treatment of the ideal gas reproduces the canonical results (E=32NkBT\langle E \rangle = \frac{3}{2}Nk_BT, PV=NkBTPV = Nk_BT) without the need to compute NN-particle partition functions.
  • Adsorption and surface science: The grand canonical ensemble describes gas molecules adsorbing on a surface, where the number of adsorbed particles fluctuates as the system exchanges molecules with the gas phase.
  • Semiconductor physics: Carrier concentrations in semiconductors are calculated using grand canonical methods, where electrons and holes are exchanged with reservoirs at fixed chemical potential.
  • Nuclear physics: The statistical model of nuclear reactions uses the grand canonical ensemble to describe particle production in high-energy collisions, where the number of produced pions, kaons, etc. fluctuates.
  • Chemical equilibrium: Reactions in solution are naturally described in the grand canonical ensemble, where the chemical potentials of reactants and products are fixed by the reservoir.
  • Monte Carlo simulations: Grand canonical Monte Carlo (GCMC) simulations insert and delete particles to sample the grand canonical distribution, used extensively in studies of porous materials and fluid adsorption.