# Chemistry and Phases

...in which we relentlessly max out the Gibbs-Duhem equation.

$$S\, dT-V\, dP+\sum_{j=1}^m n_j\, d\mu_j=0.$$

## Phase equilibrium

Imagine two (sub)systems--one of ice $A$ and one of water $B$ enclosed in an adiabatic, fixed size container. Particles and heat can move back and forth between the two phases, subject to these constraints: $$n_A+n_B = n = {\rm constant}\ \Rightarrow dn_A = -dn_B$$ $$V_A+V_B = V= {\rm constant}$$ $$U_A+U_B = U= {\rm constant}$$

At equilibrium, $S=S_A+S_B$ should be a maximum, therefore: $$dS = dS_A+dS_B=0.$$

We'll make the entropy a bit easier to deal with by assuming the more boring picture below, where all of the ice is together, and all of the water is together, and particles and heat move back and forth freely across the moveable phase boundary.

For you to answer, and then compare with someone else...

1.) Why, in a sentence or two, is the total internal energy constant?

2.) Solve this equation below for $dS$, $$dU = T\,dS-P\,dV+\mu\,dn.$$

3.) Use the result above to write out the equilibrium condition $dS=(dS_A+dS_B)=0$ in terms of quantities for each sub-system.

4.) Now, using differential relationships that are consequences of the constraints $n_A+n_B=$constant, $V_A+V_B=$constant, and $U_A+U_B=$constant etc, re-write the equilibrium condition into this form... (that is, get rid of the differentials with $B$ subscripts...) $$$\ \$dU_A+$\ \$dV_A+$\ \$dn_A = 0.$$

The expression above works out to $$$\frac{1}{T_A}-\frac{1}{T_B}$dU_A+$\frac{P_A}{T_A}-\frac{P_B}{T_B}$dV_A+$\frac{\mu_A}{T_A}-\frac{\mu_B}{T_B}$dn_A = 0.$$

5.) Can you show these three consequences?

$T_A = T_B\$ (thermal equilibrium)

$P_A=P_B\$ (mechanical equilibrium)

$\mu_A=\mu_B$ (diffusive equilibrium)

• This last condition, that the chemical potentials are equal at equilibrium, is worth remembering!
• Isn't $\mu$ a constant for a certain substance?
• NO: You may be thinking of $\Delta G_f^o$. But recall that in general $\mu=\mu(T,P)$

## The Gibbs phase rule

For a closed system with one component (e.g. an ideal gas of a pure substance), which has reached equilibrium, specifying 2 thermodynamic parameters are enough to uniquely specify the state.

The equilibrium state.

For an open single-component system, two parameters are no longer enough to completely specify the state of the system.

If we write $$dG = -S\,dT+V\,dP+\mu\,dn$$ There are three differentials that can vary independently, so we'd need to specify 3 quantities, $T$, $P$, and $n$ for example, to uniquely specify the state.

### Multiple components

Now, consider that we have a closed system, at constant temperature and constant pressure: $$[dG]_{T,P} = \sum_{j=1}^m \mu_j dn_j.$$

Let's say that the system consists of...

• $k$ different components: e.g. CO${}_2$, H${}_2$O, and O${}_2$, numbered as $i=1..k$, with $k=3$.
• $\pi$ different phases for each component: e.g. solid, gas, and liquid, numbered as $\gamma=1..\pi$, with $\pi=3$.

There are $m=k\pi$ different kinds of things in the system. To uniquely specify the state, we'd need the standard 2 thermodynamic parameters plus perhaps $k\pi$ *more* numbers, which could be the the number of moles in each phase and each component: $$2+\pi k.$$

But it turns out the number of quantities needed to uniquely specify the state is not quite so high:

### Phase constraints and degrees of freedom

In order to group the $n_j$ by component and phase, write: $n_i^{\gamma}$ = the number of moles in component $i$, and in phase $\gamma$, where $\gamma$ is not an exponent, but just a superscript.

For one particular phase, the mole fraction (percentage) of each component in that phase can be written as... $$x_i^{\gamma}=\frac{n_i^{\gamma}}{\sum_i n_i^{\gamma}}.$$

Such that $$\sum_{i=1}^{k} x_i^{\gamma} = 1.$$

For example, we could freely choose that 30% of the gas phase is CO${}_2$, and 50% of the gas phase is H${}_2$O. But now we have enough information to know that the O${}_2$ mole fraction must be 20%.

There is one of these phase constraint equations for each phase--$\pi$ of them in all. So, the total number of numbers we need to completely specify the state of our multi-component system is not $2+\pi k$, but rather just: $$2+\pi k -\pi = 2+\pi(k-1).$$

Diffusive equilibrium: For the different phases of one component $i$ to all be in equilibrium with each other, the criteria is that the chemical potentials must all be equal: $$\mu_i^{\alpha} = \mu_i^{\beta}=..=\mu_i^{\pi}.$$

This is a total of $\pi-1$ separate equations for each of the $k$ phases. There are a total of $$k(\pi-1)$$ constraint equations related to the condition for diffusive equilibrium.

So, the total number of degrees of freedom $f$, (also called the "variance") is:

$$f=2+\pi(k-1) -k(\pi-1) =2 + k -\pi,$$

where $k$ is the number of components, and $\pi$ is the number of phases. This is the Gibbs phase rule.

#### For example:

An ideal gas of a single type of molecule?
$k=$___?, $\pi=$___?, $\Rightarrow f=$___? What *are* those two free parameters you can specify?

$k=1$; $\pi=1$ $\Rightarrow f=2$.
A single component with a single phase has 2 degrees of freedom. $n$ is a constant for a closed system. So, we could arbitrarily pick $P$ and $T$.

Three phases of water (liquid, gas, vapor) all present in equilibrium with each other.
$k=$___?, $\pi=$___?, $\Rightarrow f=$___? What does that mean?

$k=1$; $\pi=3$ $\Rightarrow f=0$.
This is the case for the triple point of water. If three phases are to coexist, this must happen at fixed $P$ and $T$.

Liquid water and water vapor co-exist in equilibrium.
$k=$___?, $\pi=$___?, $\Rightarrow f=$___? What does that mean?

$k=1$; $\pi=2$ $\Rightarrow f=1$.
This is the case for liquid-vapor coexistence. We can chose $P$, but then $T$ is determined (or vice versa).

A mixture of three chemically distinct substances, carbon-dioxide, oxygen, and nitrogen, but all in the same (gas) phase.
$k=$___?, $\pi=$___?, $\Rightarrow f=$___? What could those parameters be?

$k=3$; $\pi=1$\Rightarrow f=4$. The 4 quantitities we specify could be$P$,$T$, and the partial pressures (concentrations) of two of the gases. ### Chemical reactions Consider $$2{\rm H}_2+{\rm O}_2 \rightarrow 2{\rm H}_2{\rm O}.$$ The stoichiometric coefficients for such a reaction are integers which represent the molecular ratios, with the convention that they are negative for initial reactants, and positive for products. E.g. $$\nu_{{\rm H}_2}=-2 ; \nu_{{\rm O}_2}=-1 ; \nu_{{\rm H}_2{\rm O}}=+2.$$ The ratios of the changes in the number of kilomoles of each species is, neatly: $$dn_{{\rm H}_2}:dn_{{\rm O}_2}:dn_{{\rm H}_2{\rm O}} = -2:-1:+2 = \nu_{{\rm H}_2}:\nu_{{\rm O}_2}:\nu_{{\rm H}_2{\rm O}}.$$ At equilibrium,$dG=0$. In particular, for constant$T$, and$P$, we have $$[dG]_{T,P} =0= \sum_{j=1}^m\mu_j\, dn_j.$$ Since the$dn_j$are proportional to the$\nu_j\$, we have... $$\sum_{j=1}^m\mu_j\, \nu_j = 0.$$

Work out what relationship this implies for the chemical potentials of the three species discussed above.

This is a useful internal consistency check for chemical potentials.