Statistical mechanics · Part 25 of 30
Microstates, multiplicity and Boltzmann entropy
Expert 19 min
Counting microstates with coins and Einstein solids, S = k·ln W, why entropy increases, temperature as ∂S/∂U, and information entropy.
What you will learn
- You can count microstates for simple systems with binomial coefficients.
- You can explain why macrostates with the most microstates dominate for large N.
- You can derive temperature from entropy (1/T = ∂S/∂U) and relate Boltzmann and Shannon entropy.
Before this: Entropy and the second law
From many particles to simple laws
A litre of air contains about 2.5 × 10²² molecules. Nobody can follow them individually — and nobody needs to. Statistical mechanics derives thermodynamics (temperature, pressure, entropy) from the statistics of huge numbers of particles. Its central idea is simple counting.
Key points
- A microstate specifies every particle; a macrostate only what you measure (energy, volume, N).
- Multiplicity W = number of microstates of a macrostate; for N coins with n heads W = N! / (n!·(N − n)!).
- Boltzmann entropy: S = k·ln W.
- For large N the most probable macrostate is overwhelmingly likely: the second law is statistics.
- Temperature from counting: 1/T = ∂S/∂U; Shannon entropy H = −Σ p·log₂ p measures information.

Coins as a toy model
Flip 4 coins. There are 2⁴ = 16 equally likely microstates (HHHH, HHHT, …). The macrostate "2 heads" has W = 4!/(2!·2!) = 6 microstates, "4 heads" only 1. So "2 heads" is six times more likely than "all heads".
With 100 coins, W(50 heads) ≈ 1.0 × 10²⁹ while W(100 heads) = 1. With 10²³ coins the distribution becomes an unimaginably sharp spike: the relative width of the peak shrinks as 1/√N, about 3 × 10⁻¹² for N = 10²³. You will practically never observe anything but the most probable macrostate.
Entropy is a logarithm of a count
Boltzmann defined
S = k · ln W, k = 1.380 649 × 10⁻²³ J/K
The logarithm makes entropy additive: for two independent systems the multiplicities multiply (W = W₁·W₂) and the entropies add. The second law now has a clear meaning — an isolated system wanders among its microstates and ends up, with overwhelming probability, in the macrostate with the largest W, i.e. maximum entropy.
Free expansion. A gas of N molecules doubles its volume. Each molecule now has twice as many positions available, so W grows by 2ᴺ and ΔS = k·ln 2ᴺ = N·k·ln 2. For one mole that is R·ln 2 = 5.76 J/K — exactly what classical thermodynamics gives for an isothermal doubling.
The Einstein solid and temperature
Model a solid as N oscillators sharing q energy quanta. The number of ways is W = (q + N − 1)! / (q!·(N − 1)!). Put two such solids in contact and let them exchange quanta: energy flows until the total multiplicity is maximal. At that point both solids have the same value of ∂S/∂U. This is how statistical mechanics defines temperature:
1/T = ∂S / ∂U
Energy flows from the system whose entropy gains less per unit energy (high T) to the one that gains more (low T) — the Clausius statement, derived from counting. Negative absolute temperatures even exist in special systems with an upper energy limit (nuclear spins, some cold-atom lattices since 2013); they are "hotter than infinite temperature" in the sense that energy flows from them to any positive-temperature system.
Entropy and information
In 1948 Claude Shannon defined the information content of a message source as
H = −Σ pᵢ · log₂ pᵢ bits
A fair coin carries 1 bit per toss; a biased coin (90:10) only 0.47 bits. Shannon's formula has the same form as the Gibbs entropy S = −k·Σ pᵢ·ln pᵢ, which reduces to Boltzmann's S = k·ln W when all W microstates are equally likely. The link is physical: Landauer's principle says erasing one bit costs at least k·T·ln 2 of heat, and "Maxwell's demon" fails because its memory must eventually be erased. Compression programs like ZIP, and the entropy coding in JPEG and MP3, are applied Shannon entropy.
Flashcards
- Question: Number of microstates of 6 coins with exactly 3 heads?
- Answer: 6!/(3!·3!) = 20.
- Question: Boltzmann's entropy formula?
- Answer: S = k·ln W.
- Question: Entropy change when one mole of ideal gas doubles its volume isothermally?
- Answer: R·ln 2 ≈ 5.76 J/K.
- Question: How does statistical mechanics define temperature?
- Answer: 1/T = ∂S/∂U, the entropy gained per unit of added energy.
Check yourself
Think about your answer, then open it. In the app the quiz is interactive, earns points and brings back what you missed.
How many microstates have exactly 2 heads among 5 coins?
Show the answer
10
5!/(2!·3!) = 10.
Source: Schroeder, An Introduction to Thermal Physics, 2.1
Shannon entropy of a fair six-sided die roll, in bits (two decimals)?
Show the answer
2.58 bits (± 0.01 bits)
H = log₂ 6 ≈ 2.585 bits.
Source: MIT OCW 8.333
Why do we never see all air molecules gather in one half of a room?
- A force pushes them apart
- That macrostate has an astronomically smaller number of microstates
- It violates energy conservation
- Molecules repel each other strongly
Show the answer
That macrostate has an astronomically smaller number of microstates
Its probability is about 2^(−N) with N ≈ 10²⁷ — effectively zero.
Source: OpenStax University Physics Vol. 2, 4.7
Which statements are correct?
- Entropy is additive because ln(W₁·W₂) = ln W₁ + ln W₂
- 1/T = ∂S/∂U
- A fair coin toss carries 2 bits
- Erasing one bit costs at least k·T·ln 2 of heat
Show the answer
Entropy is additive because ln(W₁·W₂) = ln W₁ + ln W₂; 1/T = ∂S/∂U; Erasing one bit costs at least k·T·ln 2 of heat
A fair coin carries exactly 1 bit.
Source: Schroeder, An Introduction to Thermal Physics
Sources
- Schroeder, An Introduction to Thermal Physics, Oxford University Press, 2021 (reissue)
- MIT OpenCourseWare 8.333 Statistical Mechanics I, MIT, 2013
- OpenStax University Physics Volume 2, 4.7 Entropy on a Microscopic Scale, Rice University, 2016
Facts checked on 2026-11-30. Skillgrove lessons are free learning material — no certificate and no accreditation.