Skip to content
Mental Models

Entropy & the Second Law

Counting the Ways: Microstates & Macrostates

The statistical heart of entropy — the difference between a macrostate (what you see) and the astronomical number of microstates (arrangements) inside it, Boltzmann's S = k ln W, and why entropy is really a count of "how many ways there are to be this way."

16 min Updated Jul 11, 2026

The last lesson gave you the slogan: disorder isn’t a force, it’s a count. This lesson cashes it out. We’re going to make “count” completely literal — small enough to tally on a napkin — and then watch that same tally, scaled up, explain why coffee never un-mixes and why heat always flows the wrong way to help you. By the end, the word entropy will stop being a vibe about messiness and become exactly one thing: a count of how many microscopic arrangements produce the situation you see. Boltzmann carved the equation on his tombstone. We’ll earn it by counting coins.

Before you read — take a guess

Before we start — take a guess. You flip four fair coins. Which single outcome is MOST likely to happen?

Macrostate vs microstate — the whole distinction

Everything in this lesson rests on telling two words apart, so let’s nail them down before we count anything.

A microstate is a complete, exact description of a system, right down to the finest detail the system has — every particle’s position and speed, every coin’s individual face, every card’s identity and slot. It is the full, God’s-eye specification, leaving nothing unsaid. A macrostate is the coarse description — the handful of bulk features you can actually observe or care about from the outside: the total number of heads, the temperature and pressure of a gas, “the milk is mixed.” A macrostate is a bucket that gathers up all the microstates that look the same at that coarse level.

The analogy that makes it click is a hand of cards — or simpler, a rolled pair of dice. When you roll two dice, the microstate is the exact pair of faces: “the red die shows 3, the white die shows 4.” The macrostate is usually all you announce at the table: “the total is 7.” One macrostate, “total 7,” contains six different microstates (1-6, 2-5, 3-4, 4-3, 5-2, 6-1). The macrostate “total 2” contains just one (1-1). This is why 7 comes up six times as often as snake-eyes even though every individual face-pair is equally likely: 7 is a bigger bucket.

Info:

The one distinction to carry everywhere

Microstate = the exact, complete arrangement (which die shows what). Macrostate = the summary you observe (the total). Many microstates map to one macrostate. Entropy measures how many microstates are in the bucket — how many distinct ways the system can secretly be arranged while still looking the way it looks.

Count it by hand: four coins

Dice are good, but coins are cleaner because every coin has just two faces, so we can list everything. Flip four fair coins in a row. A microstate is the exact sequence of heads (H) and tails (T) — like HTHT. Because each of the 4 coins is independently H or T, there are 24=162^4 = 16 microstates in total, and — this is the load-bearing assumption of all of statistical mechanics — every microstate is equally likely, each exactly 1 in 16.

The macrostate is the thing you’d actually report: how many heads came up, ignoring the order. There are only five possible macrostates: 0, 1, 2, 3, or 4 heads. Now let’s count how many microstates land in each bucket — this count is what physicists call WW (from the German Wahrscheinlichkeit, “probability”), the multiplicity or number of microstates:

Macrostate (# heads)The microstates in the bucketW (count)Probability
0 headsTTTT11/16 ≈ 6%
1 headHTTT, THTT, TTHT, TTTH44/16 = 25%
2 headsHHTT, HTHT, HTTH, THHT, THTH, TTHH66/16 ≈ 38%
3 headsHHHT, HHTH, HTHH, THHH44/16 = 25%
4 headsHHHH11/16 ≈ 6%
Total16100%

Those counts — 1, 4, 6, 4, 1 — are a row of Pascal’s triangle, and they add to 16, our total number of microstates. Read the table and the punchline is right there: the balanced macrostate (2 heads, half and half) has the most microstates, W=6W = 6, so it’s the most probable. The extreme, tidy macrostates (all heads or all tails) have W=1W = 1 each — a single ticket apiece. All-heads isn’t forbidden or fighting an uphill force; it’s just one arrangement out of sixteen, and random flipping lands there one time in sixteen.

Warning:

Don't confuse 'one microstate' with 'one macrostate'

The trap: “each microstate is equally likely, so all outcomes are equally likely.” True for microstates (HHHH is exactly as likely as HTHT — both 1/16). False for macrostates, because macrostates aren’t equal-sized buckets. “2 heads” outweighs “4 heads” six-to-one purely because more arrangements fall into it. Entropy lives at the macrostate level; that’s where the imbalance is.

From the four-coin table: the exact sequence HHHH and the exact sequence HTHT. Which statement is correct?

Now scale it up: 100 coins

Four coins already tilt toward balance; a hundred coins make the tilt look like a cliff. With 100 coins there are 21001.27×10302^{100} \approx 1.27 \times 10^{30} microstates — a nonillion. All-heads is still exactly one of them. The most balanced macrostate, 50 heads, has a multiplicity of (10050)1.01×1029\binom{100}{50} \approx 1.01 \times 10^{29} microstates — about a hundred billion billion billion arrangements, all looking like “roughly half heads.”

Here’s the staggering part. If you tally up every macrostate from 45 to 55 heads — a narrow band right around the middle — that band holds over 72% of all 103010^{30} microstates. Widen it to 40–60 heads and you’ve swept up more than 99.99% of them. The entire population of microstates is crammed into a thin sliver near 50/50, and the tidy extremes are a rounding error. Flip 100 coins and asking to see all heads is asking to draw the single special ticket out of 1.27×10301.27 \times 10^{30} — you would flip all day, every day, for far longer than the age of the universe and never see it.

Tip:

This is the coffee cup, in miniature

Swap “coins” for “molecules” and “number of heads” for “how mixed the milk is,” and you have the intro’s coffee cup exactly. There is essentially one way to be perfectly separated and an astronomical number of ways to be mixed, so random jostling — drawing microstates from the hat — lands in the mixed band with crushing certainty and stays there. Entropy going up is just the system sliding into the biggest bucket, because the biggest bucket is where almost all the tickets are.

Entropy = the log of the count: Boltzmann’s equation

We’ve been saying “the count of microstates, WW.” Entropy is essentially that count — but passed through a logarithm and scaled by a constant. This is the most important equation in the whole course, and it’s engraved on Ludwig Boltzmann’s gravestone in Vienna:

S=kBlnWS = k_B \ln W

Let’s define every symbol, because each one carries weight:

  • SS is the entropy of a macrostate — the quantity the second law says only ever increases.
  • WW is the multiplicity: the number of microstates in that macrostate’s bucket — the thing we counted by hand above (1, 4, 6, 4, 1 for the coins).
  • ln\ln is the natural logarithm (log to base e2.718e \approx 2.718). Its job is explained below — it’s not a cosmetic choice.
  • kBk_B is the Boltzmann constant, a tiny fixed conversion factor, kB1.38×1023k_B \approx 1.38 \times 10^{-23} joules per kelvin (J/K). It exists only to convert a pure count into the physical units — energy per degree of temperature — that thermodynamics was already using before anyone knew about atoms. If you’re a physicist it makes the statistical SS line up with the older, measured SS. If you’re here for the intuition, you can mentally set kB=1k_B = 1 and read entropy as simply “the log of the number of ways.”

Why the logarithm? Because counts multiply but entropy should add

The logarithm isn’t decoration — it’s doing essential structural work, and understanding why is what separates knowing the formula from understanding it.

Consider two independent systems side by side — say a box of gas on the left and an unrelated box on the right. If the left box has WAW_A microstates and the right has WBW_B, how many microstates does the combined system have? For every way to arrange the left box, the right box can be in any of its ways, so the arrangements multiply: Wtotal=WA×WBW_{\text{total}} = W_A \times W_B. Counts of independent things multiply — this is the same counting rule you already know from compounding, where independent possibilities pile up by multiplication and the totals explode.

But we want entropy to be an additive, “extensive” quantity — put two identical boxes together and you’d like double the entropy, the way two identical boxes hold double the mass or double the energy. A quantity that multiplies when you combine systems is awkward; a quantity that adds is natural. The logarithm is precisely the mathematical machine that turns multiplication into addition:

ln(WA×WB)=lnWA+lnWB\ln(W_A \times W_B) = \ln W_A + \ln W_B

so

Stotal=kBln(WAWB)=kBlnWA+kBlnWB=SA+SB.S_{\text{total}} = k_B \ln(W_A W_B) = k_B \ln W_A + k_B \ln W_B = S_A + S_B.

The multiplicities multiply; take the log, and the entropies add. That’s the whole reason the ln\ln is there. As a bonus, it tames the numbers: a gas has WW on the order of 10(1023)10^{(10^{23})} — a number with more digits than there are atoms in your body — and lnW\ln W shrinks that monstrosity down to something a lab instrument can read off a dial.

A tiny worked example

Numbers make it concrete. Suppose system A has WA=4W_A = 4 microstates and system B has WB=8W_B = 8. Combine them and the total multiplicity is W=4×8=32W = 4 \times 8 = 32 — every one of A’s 4 ways pairs with every one of B’s 8 ways. Now check that the entropies add. Using S=kBlnWS = k_B \ln W and setting kB=1k_B = 1 for clarity:

SystemW (multiplicity)S = ln W
A alone4ln 4 ≈ 1.386
B alone8ln 8 ≈ 2.079
A and B combined32ln 32 ≈ 3.466

And indeed ln4+ln8=1.386+2.079=3.466=ln32\ln 4 + \ln 8 = 1.386 + 2.079 = 3.466 = \ln 32. The counts multiplied (4×8=324 \times 8 = 32); the entropies added (1.386+2.079=3.4661.386 + 2.079 = 3.466). That is the logarithm earning its place, on numbers small enough to check on a calculator.

System A has 5 microstates; system B has 6. You place them side by side as one combined system. What are the combined multiplicity W and the combined entropy S (taking k_B = 1)?

Why “the balanced state” wins — watch it happen

Put the two halves together — counting and the logarithm — and the second law stops being mysterious. The highest-entropy macrostate is simply the one with the most microstates (the biggest WW, hence the biggest lnW\ln W). Random microscopic motion is, in effect, drawing a fresh microstate out of the hat every instant, with every microstate equally likely. So the system spends essentially all its time in whichever macrostate owns essentially all the tickets — the balanced, spread-out one. It doesn’t seek that state; it’s just overwhelmingly outvoted into it.

The two-gas box from the intro is this exact argument rendered as a movie. “Red on the left, blue on the right” is the all-heads corner of the coin table: one tiny bucket, WW near 1. “Evenly mixed” is the 50/50 band: virtually every microstate lives there. Press Play and the box wanders, microstate by microstate, out of the tiny ordered bucket and into the giant mixed one — and the entropy meter climbing is literally lnW\ln W growing as the system reaches the macrostate with the most ways to be.

Entropy lab

Watch the climb toward the biggest bucket

Every particle starts crammed into the left half, then just drifts. Watch it fill the whole box — not because anything pushes it, but because "spread out" is overwhelmingly the most likely arrangement. Push the particle count up to see how much harder it becomes to ever run backwards.

Entropy S = ln W

0%

Split
120 left · 0 right
Odds of returning to the start (all on the left)
1 in 10^36

120 on the left, 0 on the right. Entropy is 0% of its maximum. Chance of spontaneously re-bunching on the left: 1 in 10^36.

Same box, new lens. Read the starting state as the all-heads corner of the coin table — one lonely microstate, tiny W. Press Play and watch the system random-walk into the macrostate with overwhelmingly the most microstates, the mixed 50/50 band, exactly the way 100 coins pile up near 50 heads. The entropy meter climbing IS ln W growing. Push the particle slider up and the mixed band swallows an even larger share of all arrangements, so the climb becomes even more certain and the odds of ever un-mixing collapse further. Nothing pushes the particles; they are simply outvoted, arrangement by arrangement, into the biggest bucket.

Energy, not just tidiness — the part everyone gets wrong

Here’s where the “messy room” picture, useful as a first hook, starts to mislead — and where the rigorous meaning matters. Entropy is not a measure of visual untidiness. It’s the count of accessible microstates, and the microstates that matter most in real physics aren’t about where particles sit but about how a fixed amount of energy is spread across them. Entropy is really about the dispersal of energy over all the ways the system can hold it.

The cleanest example is the intro’s cooling cup — heat flowing from hot to cold, which the second law insists on and the reverse never happens. Why? A hot object is one where a lot of energy is concentrated in a few particles; a cold object has little. Ask: across all the ways to distribute a fixed total energy among all the particles, how many microstates correspond to “energy piled up in the hot object” versus “energy shared out more evenly between hot and cold”? Spreading the same energy over more particles opens up vastly more ways to arrange it — the multiplicity WW of the shared-out configuration dwarfs that of the concentrated one, often by factors with astronomical exponents. So energy flows hot-to-cold for the identical reason coins drift to 50/50 and milk mixes: the spread-out arrangement is a hugely bigger bucket of microstates. Temperature equalizing is entropy climbing into that bucket. No messiness required — a perfectly clean, uniform lukewarm cup is the high-entropy state.

Warning:

Misconception: 'entropy = a messy room'

“Entropy is disorder, like a messy bedroom” is a loose metaphor, handy for a first pass and wrong the moment you lean on it. Messiness is about the look of particle positions; entropy is the count of accessible microstates and how energy disperses across them. The gaps this metaphor opens: a uniformly warm room (dull, “tidy”-looking) is higher entropy than a cold room with one hot radiator; two mixed gases look no messier than two separated ones yet have far higher entropy; and “order” that costs no energy to maintain (like a crystal at absolute zero) can be the lowest-entropy state of all. When the metaphor and the count disagree, trust the count.

Sort each statement by whether it describes entropy correctly (as a count of microstates / energy spread) or falls for the 'entropy is literal mess' trap.

Place each item in the right group.

  • Any arrangement that looks visually scrambled must have more entropy than any arrangement that looks orderly
  • A uniformly warm, featureless room can have higher entropy than a tidy-looking cold room with one hot spot
  • A room is high-entropy whenever clothes are strewn on the floor, regardless of energy
  • A macrostate has higher entropy when more distinct microscopic arrangements produce it
  • Cleaning your desk measurably lowers the universe total entropy because the desk looks neater
  • Heat flows hot-to-cold because spreading energy over more particles vastly multiplies the number of microstates

Match each term to its precise meaning.

Pick a term, then click its definition.

Success:

The sentence to keep

Entropy is not a substance, a force, or a mood. It is a count of possibilities — specifically, S=kBlnWS = k_B \ln W, where WW is how many microscopic arrangements produce the macrostate you’re looking at. “Entropy increases” means only this: the system drifts into the macrostate that can be realized in the most ways, because that’s where almost all the equally likely microstates live. Everything else in this course — the arrow of time, wasted heat, the cost of order — is a consequence of that one count.

When to use it

Reach for this model the instant you catch yourself thinking a system is “seeking” disorder, “wants” to decay, or is being “pulled” toward chaos — the language of purpose and force. Every time, translate it into the language of counting:

  • Replace “seeks disorder” with “drifts toward the macrostate with the most microstates.” There’s no seeking; there’s a landslide of probability. The mixed state isn’t a goal, it’s just where nearly all the tickets are.
  • When something spreads out — heat, ink, a smell, a crowd — ask “what’s the bigger bucket?” The spread-out configuration is almost always realizable in vastly more ways than the concentrated one, so random motion finds it and stays.
  • Distrust “it got messy” as an explanation; count instead. If tidiness and entropy seem to point different ways (a bland warm room, two invisibly mixed gases), trust the microstate count over the eye test.
  • Remember the scaling. Whatever the tilt looks like for a handful of coins, real systems have 102310^{23} of them, which turns a mild statistical preference into an iron, exceptionless law. “Overwhelmingly probable” and “certain” are the same sentence at that scale.

Recap

A microstate is the exact, complete arrangement of a system; a macrostate is the coarse summary you actually observe, and it acts as a bucket gathering all the microstates that look the same. Every microstate is equally likely — HHHH ties HTHT at 1 in 16 — but macrostates are unequal-sized buckets, so the balanced macrostate (2 heads, W=6W = 6) beats the tidy extreme (4 heads, W=1W = 1) six-to-one, and at 100 coins the balanced band hoards over 99.99% of all arrangements. Entropy is essentially the log of that bucket’s size, S=kBlnWS = k_B \ln W: WW is the multiplicity, kBk_B a tiny units-fixing constant, and the logarithm is there so that the counts of independent systems (which multiply) turn into entropies (which add). And it’s about energy dispersal, not tidiness — heat flows hot-to-cold because spreading energy over more particles multiplies the microstates, not because anything looks messy. Disorder wins because disorder is the biggest bucket. Full stop.

Next we turn that count into a direction. If entropy almost always climbs, then the film of the universe looks obviously wrong run backward — and that one-way-ness is the only thing in all of physics that tells the past from the future. Lesson 02: the arrow of time.

Mark lesson as complete