Thermodynamics 219
for molecular dynamics calculations in these ensembles. We will show how the volume
and density distributions can be generated by treating the volume as an additional
dynamical variable with a corresponding momentum, the latter serving as a barostatic
control of the fluctuations in the internal pressure. This idea will be extended to
anisotropic volume shape-changes by treating the cell vectors asdynamical variables.
5.2 Thermodynamics of isobaric ensembles
We begin by considering the isoenthalpic-isobaric ensemble, which derives from a Leg-
endre transformation performed on the microcanonical ensemble. In the microcanon-
ical ensemble, the energyEis constant and is expressed as a function of the number
of particlesN, the volumeV, and the entropyS:E=E(N,V,S). Since we seek to
use an external applied pressureP as the control variable in place of the volumeV,
it is necessary to perform a Legendre transform ofEwith respect to the volumeV.
Denoting the new energy asE ̃, we find
E ̃(N,P,S) =E(N,V(P),S)−∂E
∂V
V(P). (5.2.1)
However, sinceP=−∂E/∂V, the new energy is justE ̃=E+PV, which we recognize
as the enthalpyH:
H(N,P,S) =E(N,V(P),S) +PV(P). (5.2.2)
The enthalpy is naturally a function ofN,P, andS. Thus, for a process in which
these variables change by small amounts, dN, dP, and dS, respectively, the change in
the enthalpy is
dH=
(
∂H
∂N
)
P,S
dN+
(
∂H
∂P
)
N,S
dP+
(
∂H
∂S
)
N,P
dS. (5.2.3)
SinceH=E+PV, it also follows that
dH= dE+PdV+VdP
=TdS−PdV+μdN+PdV+VdP
=TdS+VdP+μdN, (5.2.4)
where the second line follows from the first law of thermodynamics. Comparing eqns.
(5.2.3) and (5.2.4) leads to the thermodynamic relations
μ=
(
∂H
∂N
)
P,S
, 〈V〉=
(
∂H
∂P
)
N,S
, T=
(
∂H
∂S
)
N,P
. (5.2.5)
The notation〈V〉for the volume appearing in eqn. (5.2.5) serves to remind us that
the observable volume results from a sampling of instantaneous volume fluctuations.