See also: Course-wide Conventions & Notation
Run the code: Notebook for Section 7.2, in which you can change and rerun the Python cells of this section in your browser.
Overview and Learning Objectives¶
Section 7.1 derived the equilibrium constant from macroscopic thermochemistry: given and (e.g., from the NIST-JANAF Thermochemical Tables or the Active Thermochemical Tables), one computes and then .
In this section we derive the same from microscopic information — molecular masses, rotational and vibrational constants, electronic degeneracies, and bond dissociation energies. This completes the statistical-mechanical bridge built in Modules 2, 4, and 5: Module 4 connected the canonical partition function to the Helmholtz free energy, ; Module 5 showed that is the master potential at constant , generating , , , and — as we now develop — the chemical potentials . Once we have in terms of the single-molecule partition functions , the equilibrium condition gives directly in terms of molecular properties.
The payoff: for any gas-phase reaction, we can predict from spectroscopic data alone, and we can see which molecular features (masses, moments of inertia, bond strengths) drive the equilibrium.
Learning objectives:
Write the equilibrium condition at fixed as from minimizing the Helmholtz free energy.
Use for an ideal-gas mixture to derive from .
Express equilibrium constants in terms of single-molecule partition functions, and relate and through .
Identify how translational, rotational, vibrational, and electronic factors contribute to for a specific reaction, and compute numerically from molecular constants.
Core Ideas and Derivations¶
The Right Potential for Equilibrium at Constant ¶
Consider a general gas-phase reaction
under the ideal-gas assumption used throughout this module, with the signed stoichiometric coefficients of Section 7.1.
Section 5.1 established that at constant and , the relevant thermodynamic potential is the Helmholtz free energy . When the amounts of the species can change, its differential acquires a term for each species, as the differential of does in Section 6.1:
At constant and ,
where the second equality uses from Section 7.1 (under Extent of Reaction ). Equilibrium at fixed occurs at a minimum of , so
This is the chemical equilibrium condition written in terms of chemical potentials. It has the same form as the condition of Section 7.1. What differs is the potential that is stationary: at fixed , and at fixed . The chemical potential can be taken from either potential (the second expression follows from ):
Concept Check 1 asks why the two conditions agree, and Concept Check 1 of Section 7.1 asks what changes when the volume is held fixed instead of the pressure.
Partition Function of an Ideal-Gas Mixture¶
From Section 2.4 (factorization over independent subsystems, and the factor for indistinguishable particles), the canonical partition function of a mixture of ideal gases factorizes:
where is the single-molecule partition function for species . Each species is treated independently because ideal-gas molecules don’t interact.
Chemical Potentials from the Partition Function¶
Section 4.3 established
and Section 5.1 developed as the “master potential” at fixed , with , , all following from its derivatives. The chemical potential is the natural extension of that derivative machinery to composition:
Using Eq. (7.2.6),
and applying Stirling’s approximation in the thermodynamic limit (, as introduced in Section 2.5),
So the per-molecule chemical potential is
Multiplying by Avogadro’s number to express on a per-mole basis (as used throughout Section 7.1),
where . Equation (7.2.12) is the microscopic counterpart of the thermodynamic expression from Section 7.1: both express the chemical potential of a gas-phase species, one in terms of partial pressure and a reference , the other in terms of microscopic counting through .
Equilibrium Constants from Partition Functions¶
Inserting Eq. (7.2.12) into the equilibrium condition :
Equivalently,
Relating to and ¶
Define a number concentration . Dividing Eq. (7.2.14) by (with ) gives
For an ideal gas, , so the pressure-based equilibrium constant is
The prefactor converts between “molecules per unit volume” and “pressure ratios relative to .” When , this prefactor is unity and is dimensionless directly.
So, once you can compute the single-molecule partition functions , you can compute (and then ).
The Simplest Case: ¶
For an isomerization, , Eq. (7.2.14) reads
Both partition functions are sums over the levels of one molecule, and both measure the energy from the same zero. A molecule that can convert between the two forms therefore has a single set of levels, of which some belong to A and the others to B. At equilibrium every level is populated according to one Boltzmann distribution, and is the total population of the levels of B divided by the total population of the levels of A.
Figure 7.2.1 shows a model in which the lowest level of B lies above the lowest level of A, while the levels of B lie closer together. At the lower temperature almost all molecules occupy the lowest levels, which belong to A, and . At the higher temperature the many levels of B together hold more molecules than the few levels of A, and . The energy of the lowest level favors A, and the number of accessible levels favors B.
Source
import sys
import numpy as np
import matplotlib.pyplot as plt
sys.path.append("..") # the book folder, which holds figstyle
import figstyle as fs
# Model: energies in units of epsilon, temperatures as t = k_B T / epsilon
spacing_A, spacing_B, offset_B = 2.0, 0.5, 3.0
E_top = 12.0
levels_A = np.arange(0.0, E_top + 1e-9, spacing_A)
levels_B = np.arange(offset_B, E_top + 1e-9, spacing_B)
def K_model(t):
# q_B / q_A with the sums over all levels (geometric series)
q_A = 1 / (1 - np.exp(-spacing_A / t))
q_B = np.exp(-offset_B / t) / (1 - np.exp(-spacing_B / t))
return q_B / q_A
def draw_populations(c):
fig, axes = plt.subplots(1, 2, figsize=(fs.WIDTH, 3.9), sharey=True, constrained_layout=True)
columns = (("A", 0.2, levels_A, c.blue), ("B", 1.95, levels_B, c.vermilion))
for ax, letter, t, title in zip(axes, "ab", (1.0, 4.0),
("$k_{\\mathrm{B}}T = \\varepsilon$", "$k_{\\mathrm{B}}T = 4\\varepsilon$")):
for name, x0, levels, color in columns:
ax.hlines(levels, x0, x0 + 0.22, color=c.muted, lw=1.0)
ax.barh(levels, np.exp(-levels / t), left=x0 + 0.30, height=0.3, color=color, lw=0)
E = np.linspace(levels[0], E_top + 0.3, 200)
ax.plot(x0 + 0.30 + np.exp(-E / t), E, color=c.gray, lw=1.2, ls=(0, (4, 3)))
ax.text(x0 + 0.11, -0.75, name, color=color, ha="center", va="top", fontweight="bold")
ax.text(1.85, 13.2, f"$K = N_{{\\mathrm{{B}}}}/N_{{\\mathrm{{A}}}} = {K_model(t):.2f}$", ha="center")
ax.set(xlim=(0, 3.4), ylim=(-0.6, 13.9), xticks=[])
ax.spines["bottom"].set_visible(False)
fs.panel(ax, letter, title)
axes[0].set_ylabel("Energy, $E/\\varepsilon$")
return fig
fs.show(draw_populations, alt="Two panels, each with two ladders of energy levels on one energy axis. The levels of "
"form A start at zero and are 2 units apart. The levels of form B start at 3 units "
"and are half a unit apart. A bar on each level shows its population, which falls "
"with energy along the same exponential curve for both forms. In panel a, at the "
"lower temperature, nearly all the population is on the lowest level of A, and K is "
f"{K_model(1.0):.2f}. In panel b, at four times that temperature, many levels of B "
f"are populated, and K is {K_model(4.0):.2f}.")Figure 7.2.1:Populations of the levels of a model molecule with two forms, A and B, at (a) and (b) . The levels of A lie at and those of B at . The length of each bar is the population of its level relative to the lowest level, and the dashed curve is the Boltzmann factor , which is the same for both forms. is the total population of the levels of B divided by that of the levels of A, Eq. (7.2.17). The sums include the levels above , which are not drawn.
In Figure 7.2.2, you can change the temperature and the energy of the lowest level of B in the same model, and follow , , and .
Figure 7.2.2:Populations of the levels of a molecule with two forms, A and B, and the equilibrium constant . Panel (a) shows the levels of both forms on one energy scale, with a bar for the population of each level. Panel (b) shows against temperature for the chosen energy of the lowest level of B, on a logarithmic scale, with the present temperature marked. The dashed line marks .
Two things to try:
Start from the levels of Figure 7.2.1, and raise the temperature until . Compare the two partition functions at this temperature, and find the levels that hold most of the molecules of each form.
Set the lowest level of B to the same energy as the lowest level of A, and raise the temperature from its lowest to its highest value. Neither form is now lower in energy. Follow how changes, and relate the change to the number of levels of each form that lie within of the lowest level.
Example: Formation¶
Consider
Here,
so and the equilibrium constant is
The choice is pedagogically convenient: it makes volume factors cancel exactly (see the Worked Example below), so depends only on intrinsic molecular properties (masses, rotational and vibrational constants, bond strengths). With reactions, one would need the factor from Eq. (7.2.16) to convert between and .
Single-Molecule Partition Function for a Diatomic Ideal Gas¶
Within the rigid-rotor/harmonic-oscillator approximations developed in Module 2 (see Section 2.8 for the summary table), the single-molecule partition function for a diatomic gas factors as
Putting the four factors together (cf. Section 2.8):
where the thermal de Broglie wavelength is
Notes on Parameters¶
: molecular mass.
: rotational symmetry number — for homonuclear diatomics (H, I), for heteronuclear (HI). See Section 2.7.
: characteristic rotational temperature (from Section 2.7).
: characteristic vibrational temperature (from Section 2.6).
: ground-state electronic degeneracy. For the species in the HI reaction, all three ground states are nondegenerate singlets ( for and , for HI), so for each.
: bond dissociation energy referenced from the level (per-mole units when combined with , per-molecule when combined with ).
for in Terms of Molecular Parameters¶
Substituting Eq. (7.2.23) into , and using the fact that volume cancels when (see the Worked Example), yields
With and , the symmetry-number prefactor is . With the energy zero at the separated atoms, the zero-point energies are contained in the values, and the vibrational block holds only the “hot-mode” factors.
Equation (7.2.25) makes the microscopic physics very explicit:
Translation contributes the mass dependence.
Rotation contributes the symmetry-number and factors.
Vibration contributes the factors that encode how many vibrational quanta are thermally accessible.
Bond strengths enter through the dissociation energies in the exponential; the numerator is essentially the negative of the reaction internal energy at 0 K.
Numerical Evaluation: from Spectroscopic Data¶
To see the microscopic-to-macroscopic bridge at work, we evaluate Eq. (7.2.25) at using spectroscopic constants. The rotational and vibrational temperatures of and are those of the tables in Section 2.6 and Section 2.7. The values for HI are computed in the same way, from and (NIST Chemistry WebBook).
| Species | () | (K) | (K) | () | ||
|---|---|---|---|---|---|---|
| 2.016 | 87.55 | 6332 | 432.07 | 2 | 1 | |
| 253.808 | 0.05377 | 309 | 148.81 | 2 | 1 | |
| 127.912 | 9.25 | 3322 | 294.67 | 1 | 1 |
import numpy as np
R = 8.314462618 # J mol^-1 K^-1
# Spectroscopic / thermochemical constants
mol = {
"H2": dict(M=2.016e-3, Theta_rot=87.55, Theta_vib=6332.0, D0=432.07e3, sigma=2),
"I2": dict(M=253.808e-3, Theta_rot=0.05377, Theta_vib=309.0, D0=148.81e3, sigma=2),
"HI": dict(M=127.912e-3, Theta_rot=9.25, Theta_vib=3322.0, D0=294.67e3, sigma=1),
}
T = 700.0 # K
# Mass factor (translational)
mass_factor = (mol["HI"]["M"]**2 / (mol["H2"]["M"] * mol["I2"]["M"]))**1.5
# Rotational factor
rot_factor = (mol["H2"]["sigma"] * mol["I2"]["sigma"] / mol["HI"]["sigma"]**2) \
* (mol["H2"]["Theta_rot"] * mol["I2"]["Theta_rot"]
/ mol["HI"]["Theta_rot"]**2)
# Vibrational factor: "hot-mode" (1 - exp(-Th_vib/T)) factors
def vfac(Tvib): return 1 - np.exp(-Tvib/T)
vib_factor = (vfac(mol["H2"]["Theta_vib"]) * vfac(mol["I2"]["Theta_vib"])
/ vfac(mol["HI"]["Theta_vib"])**2)
# Bond-energy factor: exp((2 D0_HI - D0_H2 - D0_I2)/RT)
dD0 = 2*mol["HI"]["D0"] - mol["H2"]["D0"] - mol["I2"]["D0"] # J/mol
bond_factor = np.exp(dD0 / (R*T))
K = mass_factor * rot_factor * vib_factor * bond_factor
print(f"T = {T:.0f} K")
print(f" Mass (translational) factor: {mass_factor:10.3f}")
print(f" Rotational factor: {rot_factor:10.4f}")
print(f" Vibrational factor: {vib_factor:10.4f}")
print(f" Bond-energy factor exp(dD0/RT): {bond_factor:10.4f}")
print(f" 2 D0(HI) - D0(H2) - D0(I2): {dD0/1e3:+.2f} kJ/mol")
print()
print(f" K(700 K) from molecular constants: {K:.1f}")
print(f" K(700 K) from the NIST-JANAF tables: 56.8")
print(f" Measured K (Bodenstein, ~700 K): ~54")T = 700 K
Mass (translational) factor: 180.817
Rotational factor: 0.2201
Vibrational factor: 0.3631
Bond-energy factor exp(dD0/RT): 4.2784
2 D0(HI) - D0(H2) - D0(I2): +8.46 kJ/mol
K(700 K) from molecular constants: 61.8
K(700 K) from the NIST-JANAF tables: 56.8
Measured K (Bodenstein, ~700 K): ~54
Discussion. The predicted compares with from the NIST-JANAF tables at 700 K and with a measured value near 54. Agreement at the 10 to 15 % level is about what one should expect from the rigid-rotor/harmonic-oscillator approximation. The largest single correction comes from the rotation of . With , the high-temperature form of Section 2.7 lies about 4 % below the sum over the rotational levels, and correcting it lowers by the same 4 %. Corrections for anharmonicity, vibration–rotation coupling, and centrifugal distortion (none of which are in our model) each shift by a few percent or less.
More importantly, the decomposition makes the physics transparent:
The translational mass factor () is the largest single contribution. The ratio is driven far from unity when the two atomic masses differ by a lot — for H and I, , so . If instead the atoms had similar masses (e.g., with ), this factor would be close to 1.
The rotational factor () is well below unity because I is unusually heavy and has an extraordinarily small K; the corresponding is very large, which favors keeping mass in I rather than redistributing it into HI. The factor-of-4 symmetry-number prefactor (from ) nudges equilibrium toward products but doesn’t overcome this.
The vibrational factor () is also below unity, and it comes almost entirely from I. The stiff stretches of H and HI are still nearly frozen out at 700 K, so their factors are 0.9999 and 0.991. The low-frequency mode of I is partially excited, and its factor, which stands in the numerator, is 0.357.
The bond-energy factor () contains the “chemistry”: says the two HI bonds together are slightly stronger than one H–H plus one I–I bond, a modest exothermicity that at 700 K gives just over a factor of 4 in .
The calculation can be repeated at other temperatures. Figure 7.2.3 compares Eq. (7.2.25) with the NIST-JANAF tables between 300 and 1500 K and shows how each of the four factors changes with temperature.
Source
import sys
import matplotlib.pyplot as plt
sys.path.append("..") # the book folder, which holds figstyle
import figstyle as fs
def hot(Theta_vib, T):
return 1 - np.exp(-Theta_vib / T)
def factors(T):
# The four factors of the molecular formula for K at temperature T (K)
vib = (hot(mol["H2"]["Theta_vib"], T) * hot(mol["I2"]["Theta_vib"], T)
/ hot(mol["HI"]["Theta_vib"], T)**2)
bond = np.exp(dD0 / (R * T))
return mass_factor * np.ones_like(T), rot_factor * np.ones_like(T), vib, bond
# K from the NIST-JANAF tables: exp(-[2 dfG(HI) - dfG(I2, g)] / RT)
T_ref = np.array([300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200, 1300, 1400, 1500])
K_ref = np.array([673.9, 245.9, 128.2, 80.57, 56.81, 43.25, 34.74, 29.05, 25.04, 22.09,
19.86, 18.11, 16.71])
T_plot = np.linspace(300, 1500, 300)
f_mass, f_rot, f_vib, f_bond = factors(T_plot)
def draw_constant(c):
fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(fs.WIDTH, 3.4), constrained_layout=True)
# (a) The molecular formula against the tables
ax1.semilogy(T_plot, f_mass * f_rot * f_vib * f_bond, color=c.blue, lw=fs.LINE)
ax1.semilogy(T_ref, K_ref, "o", color=c.gray, ms=5.5)
ax1.text(520, 230, "molecular formula", color=c.blue)
ax1.text(330, 30, "NIST-JANAF", color=c.muted)
ax1.set(xlabel="Temperature (K)", ylabel="$K$")
ax1.set_yticks([20, 50, 100, 200, 500], ["20", "50", "100", "200", "500"])
ax1.minorticks_off()
fs.panel(ax1, "a", "Equilibrium constant")
# (b) The four factors of the formula
ax2.axhline(1, color=c.gray, lw=1.2, ls=(0, (4, 3)))
for factor, label, color, y in ((f_mass, "mass", c.blue, 220), (f_bond, "bond energy", c.purple, 5.2),
(f_vib, "vibrational", c.vermilion, 0.47), (f_rot, "rotational", c.green, 0.135)):
ax2.semilogy(T_plot, factor, color=color, lw=fs.LINE)
ax2.text(900, y, label, color=color)
ax2.set(ylim=(0.1, 400), xlabel="Temperature (K)", ylabel="Factor")
fs.panel(ax2, "b", "The four factors")
return fig
fs.show(draw_constant, alt="Two panels for the equilibrium of hydrogen, iodine, and hydrogen iodide between 300 and "
"1500 K. Panel a plots the equilibrium constant on a logarithmic axis. It falls from about "
"700 at 300 K to about 18 at 1500 K, and the curve from the molecular formula lies slightly "
"above the points from the NIST-JANAF tables. Panel b plots the four factors of the "
"formula. The mass factor, near 180, and the rotational factor, near 0.14, do not change "
"with temperature. The bond-energy factor falls from about 30 toward 2, and the "
"vibrational factor falls from near 1 to about 0.3.")Figure 7.2.3:(a) Equilibrium constant of from Eq. (7.2.25) (line) and from the NIST-JANAF tables (points). The formula lies 8 to 13 % above the tabulated values over the whole range. (b) The four factors of Eq. (7.2.25). In this model the mass and rotational factors do not depend on temperature. The bond-energy factor falls from 30 at 300 K to 2.0 at 1500 K, and the vibrational factor from 0.64 to 0.23.
The lesson: every digit of can be traced back to a specific molecular property, and the relative sizes of the four factors tell us which part of molecular structure matters most for this particular equilibrium. A student who computed from thermochemical tables (Computing from Tabulated Thermochemistry in Section 7.1) and a student who computed from spectroscopic constants (this subsection) would arrive at nearly the same number by very different routes — and each route teaches something different about why the equilibrium sits where it does.
Worked Example¶
Why Volume Cancels When : ¶
Writing each single-molecule partition function as with (and collecting the rotational, vibrational, and electronic factors, all of which are -independent):
Because , the volume factors cancel:
leaving
Since , the translational contribution collapses to the mass factor seen in Eq. (7.2.25).
Result. For reactions with , is independent of volume (and pressure) in the ideal-gas model; microscopic physics enters through masses and internal partition functions only. For reactions with , the uncancelled factors of reappear as the conversion in Eq. (7.2.16).
Concept Checks¶
Why is the Helmholtz free energy the relevant potential for equilibrium at constant , and why does the resulting condition match the condition derived in Section 7.1 at constant ?
Where does Stirling’s approximation enter the derivation of , and what physical limit makes it reasonable?
In Eq. (7.2.23), how would the vibrational factor change if we chose the energy zero at the bottom of the potential well rather than at ? Show that is unchanged by this rechoice (as it must be).
Vibrational contributions to often matter most at high temperatures. Why? Reason from the temperature dependence of .
Suppose all three species in a reaction had identical masses, moments of inertia, vibrational frequencies, and values, but different values. What would reduce to, and what does this limit teach you about when “bond counting” arguments are quantitatively trustworthy?
Key Takeaways¶
Microscopic partition functions provide a route to equilibrium constants by linking (Section 4.3) to chemical potentials via .
For ideal-gas mixtures, (per-mole), and the equilibrium condition delivers as a ratio of single-molecule partition functions.
Translational, rotational, vibrational, and electronic factors contribute in separable ways under the common rigid-rotor/harmonic-oscillator approximations of Module 2.
For gas reactions, volume (and hence pressure) dependence cancels in the ideal-gas equilibrium constant; for , the factor converts between and .
For the benchmark, the four factors in Eq. (7.2.25) predict , within 10 to 15 % of the tabulated value (56.8) and of the measured value (about 54) — a concrete illustration of how molecular structure alone determines the position of equilibrium.