\documentstyle[12pt]{article}
\oddsidemargin 0.25in
\topmargin -0.5in
\textheight 8.5in
\textwidth 6.25in
\newcommand{\doublespace}{
   \renewcommand{\baselinestretch}{1.5}
   \large\normalsize}
\newcommand{\singlespace}{
   \renewcommand{\baselinestretch}{1.0}
   \large\normalsize}
\newcommand{\be}{\begin{equation}}
\newcommand{\ee}{\end{equation}}
\input epsf

\begin{document}
\setcounter{page}{1}
\thispagestyle{empty}

\centerline{\bf LECTURE 4} 

\centerline{Reversible and Irreversible Processes}

Consider an isolated system in equilibrium (i.e., all microstates are
equally probable), with some number of microstates $\Omega_i$ that are
accessible to the system. Suppose some {\it internal} constraint
is removed but the total energy and particle number remain constant.
Now the system can be in any of the $\Omega_i$ microstates {\it plus}
whatever new microstates become available when the constraint is removed.
The total number of accessible microstates after the constraint is removed
is $\Omega_f$.

Note that the system is {\it not} in equilibrium {\it immediately}
after removing the constraint. Only a fraction of the states
$\Omega_i/\Omega_f$ are occupied. By the H theorem, the system now
evolves in time (approaches equilibrium) in such a manner as to
make more equal the probability of the system being found in any of the
$\Omega_f$ microstates. (If some constraint on an isolated system
is removed, the parameters readjust in such a way that 
$\Omega(y_1,...,y_n)\rightarrow$ maximum.)

Note also that if $\Omega_f>\Omega_i$, then after final equilibrium
is achieved, simply restoring the initial constraint may not restore the
system to its initial condition. In such a case we talk about an 
irreversible process.

As an example, consider a box divided into two parts by a partition.

\begin{center}
\leavevmode
\epsfxsize=3.0 true in
\epsfbox{ONboxes.eps}
       \end{center}

Removing the partition increases the number of microstates accessible
to the system as the volume accessible to each molecule increases. After
the new equilibrium is reached, simply restoring the partition will
not return the system to its original condition.

To summarize, if some constraint (or constraints) is removed in an
isolated system in equilibrium, then the number of microstates accessible
to the system can either remain constant or increase, i.e., 
$\Omega_f\geq \Omega_i$. If $\Omega_f=\Omega_i$, then the process
is reversible. If $\Omega_f>\Omega_i$, the process is irreversible.

\centerline{Dependence of Density of States on External Parameters}
We have already shown that the equilibrium condition for two thermally
interacting systems is that the $\beta$ parameters of both systems be equal.
We now want to determine the equilibrium conditions for two systems that 
interact thermally and mechanically. We will need, and therefore must
derive, the relationship
\be
\frac{\partial\ln\Omega}{\partial x_{\alpha}}=\beta\overline{X}_{\alpha}
\ee
where $x_{\alpha}$ is an external parameter and the generalized force is
\be
\overline{X}_{\alpha}=-\overline{\frac{\partial E}{\partial x_{\alpha}}}=
-\frac{\partial \overline{E}}{\partial x_{\alpha}}
\ee
In other words, we want to know how the number of states $\Omega$ changes
when work is done on the system, i.e., when the external parameters
are changed. When the external parameters are changed, the energy levels
shift. For example, consider standing waves or resonant modes in
a cavity. If we change the size of the cavity, the wavelength of the
standing waves changes, and the associated energy levels change.
(Quantum mechanically, the frequency and energy go as $1/\lambda$
where $\lambda$ is the wavelength.) This is why a piccolo has a higher
pitch than a flute or a tuba.

Consider $\Omega$ as a function of $E$ and $x$. (Let's drop the
subscript $\alpha$ for a moment and concentrate on one external
parameter.) Then how does
$\Omega$ depend on $x$? When $x$ is changed by an amount $dx$, the energy 
$E_{r}(x)$ of each microstate is changed by an amount 
$(\partial E_r/\partial x)dx$. Let $\Omega_{Y}(E,x)$ be the number
of states which have an energy between $E$ and $E+\delta E$ when the external
parameter is $x$ and which are such that 
the derivative $\partial E_r/\partial x$ is between $Y$ and $Y+\delta Y$. 
The total number of states is
\be
\Omega(E,x)=\sum_{Y}\Omega_{Y}(E,x)
\ee

Consider a particular energy $E$. When the external parameter is changed, some
states which originally had an energy less than $E$ will acquire an
energy greater than $E$ and vice--versa. Those states
for which $\partial E_r/\partial x$ has the particular value
$Y$ change their energy by $Ydx$. Hence all those states located within an
energy $Ydx$ below $E$ will change their energy from a value smaller than 
$E$ to one greater than $E$. 

\begin{center}
\leavevmode
\epsfxsize=3.0 true in
\epsfbox{energyrange.eps}
       \end{center}

The number $\sigma_{Y}(E)$ of such states is
thus given by the number per unit energy multiplied by the energy range 
$Ydx$, i.e., by
\be
\sigma_{Y}(E)=\frac{\Omega_Y(E,x)}{\delta E}Y\;dx
\ee
Different states have their energy changed by different amounts $Ydx$.
Hence the total number of states $\sigma(E)$ whose energy is changed
from a value less than to a value greater than $E$ is given by summing
over all possible values of $Y$:
\be
\sigma(E)=\sum_{Y}\sigma_{Y}(E)=\sum_{Y}\frac{\Omega_Y(E,x)}{\delta E}Y\;dx
=\frac{\Omega(E,x)}{\delta E}\overline{Y}\;dx
\label{eq:sigma}
\ee
where the mean value of $Y$ is
\be
\overline{Y}=\frac{1}{\Omega(E,x)}\sum_{Y}\Omega_Y(E,x)Y
\ee
Note that
\be
\overline{Y}=\overline{\frac{\partial E_r}{\partial x}}=-\overline{X}
\ee
where $X$ is the generalized force conjugate to the external parameter $x$.

Let us now consider the total number of states $\Omega(E,x)$ between
$E$ and $E+\delta E$. When the parameter $x$ changes from $x$ to $x+dx$,
the number of states changes by $[\partial\Omega(E,x)/\partial x]dx$
which must be due to [the number of states which enter this range from below
by having their energy changed from a value less than $E$ to one greater
than $E$] minus [the number of states that leave through the top by having 
their energy changed from a value less than $E+\delta E$ to one greater
than $E+\delta E$]: 
\begin{center}
\leavevmode
\epsfxsize=3.0 true in
\epsfbox{moveout.eps}
       \end{center}

\be
\frac{\partial \Omega(E,x)}{\partial x}\;dx=\sigma(E)-\sigma(E+\delta E)
=-\frac{\partial \sigma}{\partial E}\delta E
\ee
Using (\ref{eq:sigma}), this becomes
\be
\frac{\partial \Omega}{\partial x}=-\frac{\partial}{\partial E}
(\Omega\overline{Y})
\ee
or
\be
\frac{\partial \Omega}{\partial x}=-\frac{\partial\Omega}{\partial E}
\overline{Y}-\Omega\frac{\partial\overline{Y}}{\partial E}
\ee
Dividing both sides by $\Omega$, we have
\be
\frac{\partial\ln \Omega}{\partial x}=-\frac{\partial\ln \Omega}{\partial E}
\overline{Y}-\frac{\partial\overline{Y}}{\partial E}
\ee
The second term on the right is negligible since $\ln \Omega\sim f$ where
the number of degrees of freedom $f$ is on the order of $10^{23}$.
So we can write
\be
\frac{\partial\ln\Omega}{\partial x}=-\frac{\partial\ln\Omega}{\partial E}
\overline{Y}=\beta\overline{X}
\label{eq:doswork}
\ee
since $\beta=\partial\ln\Omega/\partial E$. If we have several external
parameters, we can easily generalize this to the desired relation:
\be
\frac{\partial\ln\Omega}{\partial x_{\alpha}}=\beta\overline{X}_{\alpha}
\ee
From (\ref{eq:doswork}) and the definition of the entropy $S=k_B\ln \Omega$,
we can write
\be
\frac{\partial S}{\partial x_{\alpha}}=\frac{\overline{X}_{\alpha}}{T}
\ee

\centerline{Equilibrium Conditions}
Consider now two systems A and A$^{\prime}$ in contact
which can exchange heat and do work on each other.
A is described by the macroscopic parameters $E$ and $x$, while A$^{\prime}$ is
described by $E^{\prime}$ and $x^{\prime}$ where $E^o=E+E^{\prime}$
and $x^o=x+x^{\prime}$. Then
\be
\Omega^o(E,x)=\Omega(E,x)\Omega^{\prime}(E^{\prime},x^{\prime})
\ee
\be
\ln \Omega^o(E,x)=\ln\Omega(E,x)+\ln\Omega^{\prime}(E^{\prime},x^{\prime})
\ee
At equilibrium
\be
d\ln\Omega^o=d(\ln\Omega+\ln\Omega^{\prime})=0
\ee
But
\begin{eqnarray}
d\ln\Omega &=&\frac{\partial \ln\Omega}{\partial E}\;dE
+\frac{\partial\ln\Omega}{\partial x}\;dx
\nonumber\\
&=&\beta dE+\beta\overline{X}\;dx
\end{eqnarray}
and
\begin{eqnarray}
d\ln\Omega^{\prime} &=&\frac{\partial \ln\Omega^{\prime}}
{\partial E^{\prime}}\;dE^{\prime}
+\frac{\partial\ln\Omega^{\prime}}
{\partial x^{\prime}}\;dx^{\prime}
\nonumber\\
&=&-\beta^{\prime} dE-\beta^{\prime}\overline{X}^{\prime}\;dx
\end{eqnarray}
since $dE^{\prime}=-dE$ and $dx^{\prime}=-dx$. The equilibrium condition
$d\ln\Omega^o =0$ implies
\be
(\beta-\beta^{\prime})dE+
(\beta\overline{X}-\beta^{\prime}\overline{X}^{\prime})dx=0
\ee
Both coefficients must vanish since $E$ and $x$ are independent variables.
Hence the equilibrium conditions are
\be
\beta=\beta^{\prime}
\ee
and
\be
\overline{X}=\overline{X}^{\prime}
\ee
where $\overline{X}$ is any generalized force. So if $\overline{X}$ is the
pressure $p$, then the pressures and temperatures are equal in 
equilibrium.  

\centerline{Quasi--Static Processes}
Almost by definition, when a system undergoes a process and changes,
it cannot be exactly described by equilibrium statistical mechanics
or thermodynamics. However we can talk about a quasi--static process
in which the system progresses slowly enough to be arbitrarily close
to equilibrium throughout the process. We can think of the system
progressing through a series of equilibrium states infinitesimally
separated from each other. 

Consider first an infinitesimal quasi--static process in which a system
A is brought from an equilibrium state described by mean energy $E$ and
external parameter $x_{\alpha}$ to an infinitesimally different equilibrium
state described by $E+dE$ and $x_{\alpha}+dx_{\alpha}$ due to an interaction
with system A$^{\prime}$. Since $\Omega=\Omega(E,x_1,x_2,...,x_n)$, we can write
\begin{eqnarray}
d\ln\Omega &=&\frac{\partial \ln\Omega}{\partial E}\;dE
+\sum_{\alpha=1}^{n}\frac{\partial\ln\Omega}{\partial x_{\alpha}}\;dx_{\alpha}
\nonumber\\
&=&\beta\left(dE+\sum_{\alpha=1}^{n}\overline{X}_{\alpha}dx_{\alpha}\right)
\end{eqnarray}
Let the {\it total} mechanical work done by the system be
\be
dW=\sum_{\alpha=1}^{n}\overline{X}_{\alpha}dx_{\alpha}
\ee
Hence
\be
d\ln\Omega=\beta(dE+dW)=\beta dQ
\ee
since
\be
dQ=dE+dW
\ee
This statement is valid for any quasistatic process, even if work of any form 
is done by the system. But
\be
TdS=\frac{1}{\beta}d\ln\Omega=dE+dW=dQ
\ee
or
\be
dS=\frac{dQ}{T}
\ee
This statement is true for any infinitesimal quasi--static processes, even 
if work is done. 

Note that if $dQ=0$, then $dS=0$. Thus entropy does not 
change in an infinitesimal, adiabatic process. An adiabatic process is one in 
which there is no heat transfer.
We can extend this discussion to a finite process which proceeds 
quasi--statically through
a series of equilibrium states, and obtain the result that if the external 
parameters of a {\it thermally isolated} system are changed 
{\it quasi--statically} by a finite amount, then
\be
\Delta S=\int dS=0
\ee
In other words, the entropy is unchanged. 
Since $\Delta S=0$, the number of accessible states is unchanged. This
means that the process is reversible.
However, it is worth emphasizing that even if a system is thermally 
isolated so that it absorbs no heat, its entropy will {\it increase}
if processes take place which are {\it not} quasi--static.

Note that while $dQ$ is an inexact differential, $dQ/T$ is an exact
differential, i.e.,
\be
S({\rm final})-S({\rm initial})=\int_{i}^{f}\frac{dQ}{T}
\ee
provided the path of integration is a series of equilibrium states. Only
for equilibrium states is the entropy a defined concept. Entropy 
($S=k_B\ln\Omega$) just depends on the equilibrium state of the system and not
on how it got there.  So the entropy difference is path independent.
The inverse
temperature ($1/T$) is thus an integrating factor for $dQ$. This, in fact,
is another way mathematically to define the concept of temperature. The
reciprocal temperature can be defined as the integrating factor of $dQ$.

\centerline{Limiting Behavior of Entropy}
In quantum mechanics,
as the energy of a system decreases, it goes towards its ground state.
The lowest possible energy state of a system is called its ground state.
Let's call the ground state energy $E_o$. Corresponding to this energy
there is usually only one possible microstate of the system. Or there
may be a relatively small number of such states, all with the same energy
$E_o$; in this case the ground state is then said to be
``degenerate.'' If there is just one state with energy $E_o$, the
ground state is nondegenerate. Then 
\be
S(E_o)=k_B\ln\Omega(E_o)=k_B\ln 1=0
\ee
Even if the ground state is degenerate, $S\sim k_B\ln f$ which is
negligibly small compared to the entropy at large energy. Since
$\Omega(E)\sim E^f$ at large energies, $S=k_B\ln\Omega(E)\sim k_B f\ln E
\sim k_B f$ which is much larger than $S$ at low energies.
In general at low energies $S$ is vanishingly small and we can write
\be
{\rm as}\;\;E\rightarrow E_o,\;\;\;\; S\rightarrow 0
\ee
We can state this in terms of the temperature. Recall that we can
think of the temperature roughly as the energy per degree of freedom.
As the temperature drops, the energy of the system drops. If we plot
the $\ln\Omega$ versus $E$, it looks something like:
\begin{center}
\leavevmode
\epsfxsize=3.0 true in
\epsfbox{lnOmega.eps}
       \end{center}
The slope gives the inverse temperature $\beta=1/k_BT$:
\be
\beta=\frac{\partial\ln\Omega}{\partial E}
\ee
Notice that the slope gets steeper as $E\rightarrow E_o$. So
\be
\frac{\partial\beta}{\partial E}< 0
\ee
or
\be
\frac{\partial T}{\partial E}> 0
\ee
At $E_o$ the slope is vertical, $\beta=\infty$, and $T=0$.
So as the temperature approaches zero, the system approaches its
ground state, the energy approaches $E_o$ and the entropy approaches
zero.
\be
{\rm as}\;\; T\rightarrow 0,\;\;\;\; S\rightarrow 0
\label{eq:3rdlaw}
\ee
In applying this, one must be sure that equilibrium arguments apply
to the system in question. Equation (\ref{eq:3rdlaw}) is the third 
law of thermodynamics.

\centerline{Ideal Gas}
It is about time we applied a few of these ideas to a simple system. Perhaps
the simplest nontrivial example of a large collection of particles is
the ideal gas. We will come back to this example several times because
of its simplicity. An ideal gas consists of a collection of noninteracting
particles treated as mass points. The only energy available is the kinetic
energy of the particles; no internal excitations, no internal vibrations, no
rotation and no interactions. 
We will first treat the ideal gas as a simple classical system.

Consider $N$ particles with mass $m$ and momentum $\vec{p}_i$. The
particles are identical. The total energy is
\be
E=\frac{1}{2m}\sum_{i=1}^{N}\vec{p}_i\cdot\vec{p}_i
\ee
In classical statistical mechanics, the total number of microstates is the
total volume of the accessible phase space divided by the volume of a unit
cell of phase space. $N$ particles require $3N$ spatial coordinates and
$3N$ components of momenta to specify a point in the $6N$ dimensional
phase space. The number of microstates is
\be
\Omega(E)=\frac{1}{h_o^{3N}}
\int_0^V\int_E^{E+dE}(d^3\vec{r}_1...d^3\vec{r}_N d^3\vec{p}_1 ...d^3\vec{p}_N)
\ee
Now the coordinates and momenta are independent. Also each integration over
$d^3\vec{r}_i$ yields a factor of $V$, the volume of the container in which
the gas is contained. We obtain
\be
\Omega(E)=V^{N}\chi(E)
\ee
where
\be
\chi(E)=\frac{1}{h_o^{3N}} \int_E^{E+dE}(d^3\vec{p}_1... d^3\vec{p}_N)
\ee
Thus
\be
\ln \Omega(E)=N\ln V+\ln \chi(E)
\ee
The generalized force corresponding to the external parameter $V$ is the
pressure $p$. Thus
\be
\overline{p}=\frac{1}{\beta}\frac{\partial\ln\Omega}{\partial V}
=\frac{N}{\beta}\frac{\partial\ln V}{\partial V}=
\frac{N}{\beta V}=\frac{Nk_BT}{V}
\ee
or
\be
p=nk_BT
\label{eq:pVnkT}
\ee
where $n=N/V$ is the number of molecules per unit volume. Alternatively
one can write $N=\nu N_a$ where $\nu$ is the number of moles of gas present
and $N_a$ is Avogadro's number. Then (\ref{eq:pVnkT}) becomes
\be
pV=\nu RT
\ee
where $R=N_ak_B$ is called the ``gas constant.''
This equation is known as an equation of state. It relates the macroscopic
parameters pressure, volume, and temperature. We will talk more about
equations of state in our discussion of thermodynamics. In general
equations of state relate $p$, $V$, and $T$. $pV=\nu RT$ is the equation
of state for an ideal gas and it is the most famous one. 

The parameter $\beta$ is given by
\be
\beta=\frac{\partial \ln\Omega}{\partial E}=\frac{\partial\ln\chi(E)}
{\partial E}=\beta(E)
\ee
The temperature of an ideal gas is a function only of the total energy
and does not depend on $V$. We can invert this to say that the mean energy is
solely a function of the temperature
\be
\overline{E}=\overline{E}(T)
\ee
For an ideal gas the mean energy $\overline{E}$ does not depend on the volume.
Changing the volume of the container changes the mean distance between
the particles and affects the strength of their mutual interaction. But in
the case of an ideal gas, there are no interactions. Since the kinetic
energies do not depend on the distances between particles, the mean energy
is unaffected by the change in volume.
Later we will find the complete relation between
$\beta$ and $E$, and find that 
\be
E=\frac{3}{2}Nk_BT
\ee

\centerline{The van der Waals gas}
Just to show you that there is more than one equation of state, I would
like to mention the van der Waals gas. The molecules in
real gases interact with one another and one approximation to a real gas
is known as a van der Waals gas. The equation of state for a van der Waals
gas is
\be
\left(p+\frac{a}{v^2}\right)(v-b)=RT
\label{eq:vanderWaals}
\ee
where $v=V/\nu$ is the molar volume. $a$ and $b$ are constants. This is
an empirical equation known as the van der Waals equation. van der Waals
interactions refer to spontaneous electronic charge fluctuations on a molecule
which produces a short lived dipole moment. These fluctuations induce
complementary fluctuations on neighboring molecules and the molecules attract
one another. So the molecules are a little closer together than
noninteracting molecules, i.e., the gas is compressed a little bit; the
term $a/v^2$ represents this additional positive pressure. On the other hand
there are also short--range repulsive forces between the molecules which
keep them apart sufficiently to prevent them from occupying the same place
at the same time. The term $b$ represents the volume occupied by the
molecules themselves and which must thus be subtracted from the volume
available to any one molecule in the container. Notice that for 
$a=b=0$ or in the limit of a very dilute gas ($v\rightarrow \infty$), 
(\ref{eq:vanderWaals}) reduces to the equation of state for an ideal gas.

\end{document}
