Thermodynamics: From Heat to Equilibrium
How constraints give thermodynamic change its direction
An ideal gas fills one half of a rigid, insulated vessel. The other half is empty. Open the valve between them and the gas spreads through both halves. Once equilibrium returns, the thermometer reads as before. The energy balance would also permit the gas to gather again on its original side. What makes the expansion spontaneous?
1. What the Laws Say About Change
A thermometer and a piston
A thermometer works because thermal equilibrium is transitive. If two bodies are each in thermal equilibrium with the same thermometer at the same reading, they are in thermal equilibrium with one another. That is the content of the zeroth law. Two states can share a temperature and have different pressures and volumes. For a fixed amount of ideal gas, specifying and also fixes through , where is the amount in moles and is the molar gas constant.
For a closed system at rest, take heat entering the system and work done on it as positive. The first law reads
Heating a gas and stirring it with a paddle can produce the same increase in internal energy. The change in depends on the endpoints. The shares supplied as heat and work depend on the process. For a reversible piston displacement, , so an expanding gas gives up energy as work. In the insulated vessel, expansion into the vacuum involves zero heat and zero work. Thus . The endpoint temperatures are equal because an ideal gas's internal energy depends only on at fixed .
An insulated cylinder with a movable piston makes a revealing variation. If the gas expands reversibly, the piston receives work and the gas cools. Take the constant-volume heat capacity of the ideal gas to be independent of temperature. The balance is then
Integrating gives . Both expansions are adiabatic. The piston changes the energy balance by giving the gas a way to do work.
What a reversible cycle gives us
Carnot used two reversible isotherms joined by two reversible adiabats. The adiabats change the temperature without exchanging heat. Along the isotherms the engine absorbs from a hot reservoir at and rejects a magnitude to a cold one at . The working substance comes back to its starting state. Its net work output is .
Suppose a second engine were more efficient. Run the reversible engine backward, scaled to remove from the cold reservoir exactly the heat the second engine puts there. The pair would then deliver net work while drawing net heat from just the hot reservoir. The second law rules out that cycle. On the absolute temperature scale the reversible heat ratio is , giving the Carnot bound
The reversible cycle balances heat weighted by reciprocal temperature. For a cycle exchanging signed heats with reservoirs at , the Clausius inequality gives , with equality for a reversible cycle. Take one reversible path from to and retrace a second path in reverse. The weighted heat around the loop vanishes, so either path gives the same entropy difference.
This lets us return to the valve. We can compare its endpoints along a reversible isotherm at their common temperature. On that path , so
For two equal chambers the entropy gain is . All of it is produced within the vessel during the actual expansion. More generally, appending a reversible return to an adiabatic process gives for that process by the Clausius inequality. Stable equilibrium of an isolated system maximizes entropy among the states its constraints allow. Opening the valve enlarges that set while keeping the total energy and the volume of the vessel fixed.
Recreating the initial state by reversible isothermal compression would send of entropy into a bath. Once a bath is involved, its entropy belongs in the calculation too.
2. What We Can Learn About a Single Phase
Including the surroundings
Consider a sample in contact with a heat bath at and subject to a constant external pressure . Apply the entropy principle to the sample and its surroundings together. If the sample is closed and does only pressure–volume work, the heat it absorbs between equilibrium states at that pressure is . The term accounts for work against the surroundings. It is why heat supplied at constant pressure measures a change in enthalpy, .
The bath changes its entropy by . For endpoints at the bath temperature,
The quantity in parentheses is the Gibbs free energy . At fixed and , stable equilibrium minimizes over the allowed states because the combined entropy is maximized. For a change that raises enthalpy, the bath loses entropy . The change is favored if the sample gains more entropy than this. In a rigid vessel the volume work vanishes, giving the Helmholtz free energy and its minimum at fixed and .
The potentials also tell us how to describe equilibrium states. At fixed amount of substance the reversible heat and work expressions give . Taking the differentials of the three potentials gives
These Legendre transforms change the independent variables. The pressure that appears as a derivative of can be used as a coordinate of . The temperature controlled by a bath is already a coordinate of and .
What a pressure measurement can reveal
Within a smooth single phase, the mixed derivatives of commute. Since its temperature derivative is and its volume derivative is , we have
Measuring how pressure changes with temperature at fixed volume tells us how entropy responds to an isothermal change in volume. Put the Maxwell relation back into the differential of and it also gives
For , the right-hand side vanishes. The equation of state itself explains why the internal energy in the valve experiment was independent of volume. An interaction can change that conclusion. For a van der Waals gas, the term in the pressure gives , where and are molar internal energy and volume. At the same temperature, separating the attracting molecules raises the energy.
The same identity has a consequence for light in a large cavity. Equilibrium radiation has no conserved photon number, so the volume derivative is taken at fixed . If is the energy density, then and the pressure of isotropic radiation is . Substitution gives
The pressure of light fixes the fourth power in the Stefan–Boltzmann law. The spectrum and the proportionality constant require further physical input.
A different way to drop the pressure
Let gas flow steadily through an insulated porous plug. With zero shaft work and negligible changes in kinetic and gravitational potential energy, the molar enthalpy is the same upstream and downstream. The flow work that pushes gas into and out of the plug is included in . From and the Maxwell relation , the pressure derivative of at fixed temperature is . In a throttle, the temperature must change enough to keep constant. The Joule–Thomson coefficient gives the required rate.
where is the molar heat capacity. A pressure drop cools a gas when this coefficient is positive. For an ideal gas and the numerator vanishes. The isolated vessel held fixed, while steady flow through the plug holds fixed. For a real gas those balances can give different temperature changes.
3. How Two Phases Share a Substance
The slopes at a melting point
Consider ice in contact with liquid water at a common and . The total amount of water stays fixed, while each phase can gain or lose molecules. The Gibbs free energy of a phase now has a term in its differential. For a pure phase, is proportional to its amount, so the chemical potential is the molar Gibbs free energy . Transferring moles from solid to liquid changes the total Gibbs free energy by
If the liquid has lower , melting lowers . Coexistence requires . The two phases can agree in value and have different slopes. From the differential of , each pure phase satisfies
with molar entropy and molar volume . Warming favors the liquid because its higher entropy makes fall faster. Near the normal melting point, pressure also favors the liquid because it occupies less volume per mole than ice. To keep the two phases in balance as pressure rises, the temperature has to fall.
Along the melting curve the two chemical potentials remain equal. Equating their differentials gives the Clapeyron equation
where is the molar latent heat of melting. The entropy difference appears in two experiments. It is the heat absorbed per mole divided by the melting temperature, and it sets the slope of the phase boundary together with the volume difference.
Where coexistence ends
The same equality of chemical potentials selects the liquid–vapor pressure. In the loop of a subcritical van der Waals isotherm, two candidate molar volumes, and , share a pressure. In between lies a segment with , which is mechanically unstable. To find coexistence we must compare the free energies at the two candidate volumes.
At fixed , the molar Helmholtz free energy satisfies . Since , equal chemical potentials at the saturation pressure require
This is Maxwell's equal-area construction. The positive and negative areas cancel precisely when the two candidate states have equal Gibbs free energy per mole. At the critical point the two volumes merge and the latent heat of vaporization vanishes. A path around that point connects liquid and gas continuously, while crossing the coexistence curve below it produces a discontinuous change.
4. Equilibrium When Composition Can Change
Counting what can vary
In a mixture, adding one species changes by its partial molar Gibbs free energy. Each species has a chemical potential
At common temperature and pressure, a component that can pass between phases has equal chemical potential in those phases at equilibrium. This gives a way to count the freedom left in a phase diagram. For components in phases of a nonreacting system, each phase has independent composition variables. Include one shared and one shared , then impose equalities of chemical potential. The Gibbs phase rule follows.
For a pure substance, one phase occupies a region of the – plane, two phases coexist on a curve, and three fix both and at a triple point. The count concerns intensive variables. Along a two-phase line, the amounts in the two phases can still change.
The direction of a reaction
A reaction makes a different change available. The amounts of the elements stay fixed, while the species amounts change together according to stoichiometry. For a reaction extent , write , with negative for reactants and positive for products. The slope of along this allowed direction is
A negative slope favors the forward reaction. At an interior equilibrium the sum vanishes. In an ideal gas mixture, each differs from its standard value by , where is the partial pressure and the standard pressure. Inserting these terms gives the equilibrium constant
where . The pressure ratios keep the logarithms and the equilibrium constant dimensionless. For a given initial mixture at fixed and , the partial pressures depend on the reaction extent. The condition on their product determines the equilibrium extent.
Start at equilibrium and compress the mixture isothermally. At the old composition, increasing the total pressure scales all the partial pressures by the same factor. If the forward reaction produces fewer moles of gas, the product of pressure ratios falls below . The Gibbs slope becomes negative, favoring the forward reaction.
Where the entropy scale begins
Predicting an equilibrium constant from thermal measurements requires the entropy term in . The third law supplies the reference. For a pure, perfect crystal with a unique ground state, the entropy tends to zero as tends to zero. At fixed pressure and composition, heating through a single equilibrium phase gives
where is the heat capacity of the sample and the integration starts from its zero-entropy crystal. If the path crosses a first-order transition, integrate in each phase and add the entropy jump at the transition temperature. For melting, this is the very entropy difference that set the slope of the ice–water boundary. A melting curve and a calorimeter give two routes to the same quantity.
The expanding gas offers a microscopic version of that connection. At fixed energy, doubling the volume multiplies the available positional phase-space volume by for classical ideal-gas particles. Its logarithm, multiplied by Boltzmann's constant, is . The reversible calculation and the microscopic count agree on what changed when the valve opened.
Further Reading
- D. V. Schroeder, An Introduction to Thermal Physics, especially the chapters on engines and free energy. Oxford University Press.
- H. B. Callen, Thermodynamics and an Introduction to Thermostatistics, 2nd ed. Wiley.
- D. Tong, Lectures on Statistical Physics, §§4–5 on classical thermodynamics and phase transitions. Lecture notes.