# Thermodynamics

- Page ID
- 5214

In the canonical ensemble, the Helmholtz free energy \(A (N, V, T)\) is a natural function of \(N , V \) and \(T\). As usual, we perform a Legendre transformation to eliminate \(N\) in favor of \( \mu = \frac {\partial A}{\partial N} \):

\( \tilde{A}(\mu,V,T)\) | \( A(N(\mu),V,T) - N\left(\frac {\partial A}{\partial N}\right)_{V,T}\) | ||

\( A(N(\mu),V,T) - \mu N \) |

It turns out that the free energy \( \tilde{A}(\mu,V,T)\) is the quantity \(- PV \). We shall derive this result below in the context of the partition function. Thus,

\[-PV = A(N(\mu),V,T) - \mu N\]

To motivate the fact that \(PV\) is the proper free energy of the grand canonical ensemble from thermodynamic considerations, we need to introduce a mathematical theorem, known as Euler's theorem:

**Euler's Theorem**: Let \( f(x_1,...,x_N) \) be a function such that

\[ f(\lambda x_1,...,\lambda x_N) = \lambda^n f(x_1,...,x_N)\]

Then \(f\) is said to be a

*homogeneous function of degree \(n\)*. For example, the function \( f(x) = 3x^2 \) is a homogeneous function of degree 2, \( f(x,y,z) = xy^2 + z^3 \) is a homogeneous function of degree 3, however, \( f(x,y) = e^{xy}-xy \) is not a homogeneous function.

*Euler's Theorem*states that, for a homogeneous function \(f\),

\[nf(x_1,...,x_N) = \sum_{i=1}^N x_i \frac {\partial f}{\partial x_i}\]

**Proof**: To prove Euler's theorem, simply differentiate the the homogeneity condition with respect to lambda:

\( \frac {d}{d\lambda} f(\lambda x_1,...,\lambda x_N) \) | \( \frac {d}{d\lambda} \lambda^nf(x_1,...,x_N)\) | ||

\( \sum_{i=1}^N x_i \frac {\partial f}{\partial (\lambda x_i)}\) | \( n\lambda^{n-1}f(x_1,...,x_N)\) |

Then, setting \(\lambda = 1 \), we have

\[\sum_{i=1}^N x_i \frac {\partial f}{\partial x_i} = nf(x_1,...,x_N)\]

Now, in thermodynamics, extensive thermodynamic functions are homogeneous functions of degree 1. Thus, to see how Euler's theorem applies in thermodynamics, consider the familiar example of the Gibbs free energy:

\[ G = G (N, P, T ) \]

\[ G (\lambda N, P, T) = \lambda G (N, P, T ) \]

\[ G(N,P,T) = N \frac {\partial G}{\partial N} = \mu N\]

or, for a multicomponent system,

\[ G = \sum_{j} \mu_j N_j\]

\[ G = E - TS + PV \]

Now, for the Legendre transformed free energy in the grand canonical ensemble, the thermodynamics are

\[ d\tilde{A} = dA - \mu dN - Nd\mu = -PdV - SdT - Nd\mu\]

But, since

\(\tilde{A}\) | \(\tilde{A}(\mu,V,T)\) | ||

\(d \tilde{A}\) | \( \left(\frac {\partial \tilde{A}}{\partial \mu}\right)_{V,T}d\mu+\left(\frac {\partial \tilde{A}}{\partial V}\right)_{\mu,T}dV+ \left(\frac {\partial \tilde{A}}{\partial T}\right)_{\mu,V}dT\) |

the thermodynamics will be given by

\(N\) | \( -\left(\frac {\partial \tilde{A}}{\partial \mu}\right)_{V,T}\) | ||

\(P\) | \( -\left(\frac {\partial \tilde{A}}{\partial V}\right)_{\mu,T}\) | ||

\(S\) | \( -\left(\frac {\partial \tilde{A}}{\partial T}\right)_{V, \mu}\) |

Since, \(\tilde{A}\) is a homogeneous function of degree 1, and its extensive argument is \(V\), it should satisfy

\[ \tilde{A}(\mu,\lambda V,T) = \lambda \tilde{A}(\mu,V,T)\]

\[ \tilde{A}(\mu,V,T) = V \frac {\partial \tilde{A}}{\partial V} = -PV\]

and since

\[\tilde{A} = A-\mu N = E - TS - \mu N\]