Open Systems#

Fig. 21 Open systems are characterized by variable number of particles and energy#
Grand Canonical Ensemble#
Consider small system
in thermal and particle exchange with a large reservoir .The total system
is isolated: total energy , total particle number .Total volume is constant, and the reservoir is much larger:
, .

Microstate Probability#
The probability that the system has energy
and particle number is proportional to the number of microstates of the reservoir with , :
Define entropy of the reservoir
. Then:
Expand to first order:
Use thermodynamic definitions:
Grand Canonical Distribution and Partition Function#
Define the grand canonical partition function:
where:
is called the fugacity. is the canonical partition function at fixedThe microstate probability in grand canonical ensemble is:
The macrostate probability over different energy values in grand canonical ensemble is:
Grand-Canonical distribution
Connections with and #
Statistical Dominance of Average Energy and Particle Number#
Recall that the canonical ensemble emerges by weighting microcanonical contributions at different energies with an exponential factor
.Similarly, the grand canonical ensemble arises by further summing over all particle numbers
, each weighted by the fugacity factor . This yields the grand canonical partition function:In the thermodynamic limit, the sum is dominated by the most probable energy and particle number, giving:
We identify a new thermodynamic potential for the grand canonical ensemble that plays same role as free energy in canonical ensemble:
Grand potential
Thermodynamics and Legendre transform#
In thermodynamics grand potential
is derived from the internal energy via a Legendre transform that replaces the natural variables and :
Grand Potential and Pressure#
Using Euler’s relation for extensive thermodynamic variables:
Substituting into the definition of
, we find:Hence, the grand potential is directly related to the pressure and volume:
Fluctuations in particle numbers#
We once again find that in case of fluctuating quantities (energy in NVT) the relative fluctuation scales as
a hallmark of Central Limit Theorem!
Using thermodynamics we could also link number fluctuations with isothermal compressibility
The relationship is analogus to what we had established in
between energy flcutuations and heat capcity.
It takes a bit more work manipulating variables to get there in this case. See belwo for derivation:
Ideal Gas in the Grand Canonical Ensemble#
We begin by considering an ideal gas of indistinguishable, non-interacting particles in a volume
, in thermal and chemical equilibrium with a reservoir at temperature and chemical potential .The canonical partition function for
particles is:
Where the thermal de Broglie wavelength is:
Grand Canonical Partition Function#
To account for fluctuations in particle number, we compute the grand canonical partition function:
Fugacity:
, a dimensionless measure of how favorable it is to add a particle to the system.The average particle number is then obtained by taking first derivative withr espect to N
Chemical Potential in Terms of Pressure and Density#
We can invert the relation for
to express the chemical potential:
Noting that for an ideal gas
, this becomes:
Chemical Potential of Ideal Gas
is the reference chemical potential at unit pressure.
Number Fluctuations#
In the grand canonical ensemble, number fluctuations are given by:
So the standard deviation
, and relative fluctuations vanish as in the thermodynamic limit.
Isothermal Compressibility#
We relate number fluctuations to the isothermal compressibility
:
This is the well-known result for the ideal gas compressibility:
, a positive quantity ensuring mechanical stability.
Molecular Adsorption of Ideal Gas on Surfaces#
One Site–One Molecule Model#
We consider a simple model where each adsorption site can hold at most one molecule. The surface is in thermal and chemical equilibrium with a gas reservoir at temperature
Each site has two possible states:
Empty: energy
Occupied: energy
Then the grand partition function for a single site is:
Independent Sites#
If there are
independent and identical adsorption sites, then the total grand partition function is:
Since the sites do not interact, their contributions multiply.
Average Number of Adsorbed Molecules#
The average occupation number per site is:
The total number of adsorbed molecules is:
Average Energy#
The average energy per site is:
The total energy of the system is:
Connecting to Pressure#
For an ideal gas in the reservoir, the chemical potential is related to pressure via:
Substituting this into the expression for
:
and thus the total number of adsorbed molecules becomes:
This is the Langmuir adsorption isotherm, describing how the fraction of occupied adsorption sites depends on gas pressure. It captures saturation behavior as
, where .
Show code cell source
import matplotlib.pyplot as plt
import numpy as np
# Parameters
T = 298 # Temperature in K
epsilon = 10 * 1.38e-23 # Adsorption energy in J (10 k_B T)
k_B = 1.38e-23 # Boltzmann constant
beta = 1 / (k_B * T)
p0 = 1 # Reference pressure (arbitrary units)
# Pressure range
p = np.linspace(0, 5, 500)
# Langmuir isotherm
n_avg = p / (p0 * np.exp(beta * epsilon) + p)
# Plotting
plt.figure(figsize=(8, 5))
plt.plot(p, n_avg, lw=2)
plt.xlabel('Pressure (p / p₀)', fontsize=12)
plt.ylabel('Average Occupancy ⟨n⟩', fontsize=12)
plt.title('Langmuir Adsorption Isotherm', fontsize=14, weight='bold')
plt.grid(True)
plt.ylim(0, 1.05)
plt.xlim(0, 5)
plt.tight_layout()
plt.show()

Exercise: Multi-stide binding of molecular gas with internal states
Write down partition function for these scenarious
Molecule A binds to one site and adopts 2 conformations.
Two molecules of B can bind one site. When one molecle is bound it has one conformation and when two bound there are 5 conformations.
Chemical Equilibrium in gas mixtures#
For each species
where:
is the thermal wavelength, is the internal partition function (rotations, vibrations, etc.), is the number of molecules of species .For conenvience lets use the Helmholtz free energy (same result with Gibbs Free energy):
Using Stirling’s approximation
:
Equilibrium via minimization of free energy#
Now, we consider a chemical reaction:
We introduce an extent of reaction
which measures how far reaction has progressed from reactants to products:
We minimize
at constant by setting:
Computing the derivative:
with
the stoichiometric coefficient ( for reactants, for products). Or we can write it in terms of positive stochimoetric coefficients:
Chemical potential and Chemical equilibrium
So the equilibrium condition is:
Exponentiating both sides we relate ration of equilibrium numbers or concentrations to partition functions
Equilibrium Constant from Partition Functions
Problems#
#
Consider a three level single particle system with five microstates with energies 0, ε, ε, ε, and 2ε. What is
n=0,1,2 for this system? What is the mean energy of the system if is in equilibrium with a heat bath at temperature T ?Derive an expression for the chemical potential of an ideal gas using clssical mechanics model for energy
in the ensemble evaluate the fluctuations in particle number.Consider a system in equilibrium with a heat bath at temperature
and a particle reservoir at chemical potential . The system can have a minimum of one and a maximum of four distinguishable particles. The particles in the system do not interact and can be in one of two states with energies zero or . Determine the (grand) partition function of the system.Combine the Gibbs formula of Entropy
with the Grand canonical prbability distribution to show thatDerive partition function for a pressure ensemble
and show its connection with microcanonical ensembleAt a given temperature T a surface with
adsorption centers has on average number of adsorbed molecules. Suppose hat there are no interactions between molecules.Show that the chemical potential of adsorbed gas is given by:
What is the meaning of