Thread
#thermofact
The Logic of Thermodynamics

1/ All applications of thermodynamics run on a basic algorithm.

This thread traces the derivation of the Basic Algorithm of Thermodynamics (BAT) from a few facts of nature.
2/ The logic requires several ideas: isolated system, quantum state, probability, equilibrium, internal variable, state of constrained equilibrium, and process.

To master thermodynamics, you do not need courses on quantum mechanics and probability. A few basic concepts will do.
3/ An isolated system is a part of the world that does not interact with the rest of the world.

An isolated system has a set of quantum states. Denote the number of quantum states by Ω.

An isolated system flips among its quantum states, rapidly and ceaselessly.
4/ In the language of probability, an isolated system is an experiment.

Each quantum state of the isolated system is an outcome of the experiment, called a sample point.

All the quantum states of the isolated system constitute a set, called the sample space.
5/ A system isolated for a long time flips to every one of its quantum states with equal probability, and is said to have reached equilibrium. This fact is called the fundamental postulate.
6/ A map from the sample space to another set is called a random variable in probability, and an internal variable in thermodynamics.
7/ For example, a half bottle of water can be an isolated system. In the bottle, some H2O molecules form water, and other H2O molecules form steam.

The number of H2O molecules in the steam is an internal variable.
8/ When a constraint internal to an isolated system fixes an internal variable at a value x, the isolated system flips among the quantum states in a subset of the sample space.

The number of quantum states in the subset is a function of the internal variable, Ω(x).
9/ Now lift the constraint and let the internal variable x vary. The probability for the internal variable to take value x is Ω(x)/Ω. The isolated system flips to a subset more likely if the subset has more quantum states.
10/ In thermodynamics, an internal variable x is chosen such that the function Ω(x) has a sharp peak.

Thus, the peak locates the mean of x. The fluctuation in x is small compared to the mean, and is negligible.
11/ When x varies, the isolated system equilibrates when x maximizes Ω(x).
12/ A process of an isolated system begins at a state of constrained equilibrium at x = a, and ends at another state of constrained equilibrium at x = b.
13/ A process from a to b is irreversible if Ω(a) < Ω(b). All processes from a to b have the same degree of irreversibility, Ω(b)/Ω(a).

A process from a to b is impossible if Ω(a) > Ω(b).

A process from a to b is reversible if Ω(a) = Ω(b).
14/ For an isolated system with an internal variable x, define the subset entropy by

S(x) = log Ω(x)

The logarithm is an increasing function. When Ω increases, so does S.

Paraphrase the Basic Algorithm of Thermodynamics using the subset entropy, S(x).

15/ It seems unfair for entropy to steal the show by hiding the number of quantum states behind a log.

Logarithm adds no physical content, but adds algebraic convenience. Entropy is an extensive property, but the number of quantum states is not.
16/ Isolating a system for a long time is like rolling a fair die many times. Nature acts like a maniac gambler, ceaselessly and rapidly rolling numerous fair dies, each die having numerous faces.

A random variable in probability is called an internal variable in thermodynamics.
17/ This thread is adapted from my course notes, which divides thermodynamics into two parts.

One part turns the fundamental postulate of statistics into the basic algorithm of thermodynamics, and the other applies the algorithm to various situations.
docs.google.com/document/d/12j5d-QBfZGoF-31RLIpK0gY6HAcvMe-yc4FnkRh06kg/edit
Mentions
See All