# Excess chemical potential

The excess chemical potential is defined as the difference between the chemical potential of a given species and that of an ideal gas under the same conditions (in particular, at the same pressure, temperature, and composition).[1]

Chemical potential of a pure fluid can be estimated by the Widom insertion method.

For a system of diameter $L$ and volume $V$, at constant temperature :$T$, the classical partition function $Q(N,V,T)=\frac{V^{N}}{\Lambda^{dN}N!}\int_{0}^{1}\ldots\int_{0}^{1}ds^{N}\exp[-\beta U(s^{N};L)]$ s is a scaled coordinate.

$F(N,V,T)= -k_{B}T\ln Q=-k_{B}T\ln\left(\frac{V^{N}}{\Lambda^{dN}N!}\right)-k_{B}T \ln{\int ds^{N}\exp[-\beta U(s^{N};L)]}=$
$\;=F_{id}(N,V,T)+F_{ex}(N,V,T)$

combining the above equation with the definition of chemical potential, $\mu_{a}= \left(\frac{\partial G}{\partial N_{a}}\right)_{PTN}$,

we get the chemical potential of a sufficiently large system from

$\mu= -k_{B}T\ln(Q_{N+1}/Q_{N})=-k_{B}T\ln\left(\frac{V/\Lambda^{d}}{N+1}\right) - k_{B}T \ln{\frac{\int ds^{N+1}\exp[-\beta U(s^{N+1})]}{\int ds^{N}\exp[-\beta U(s^{N})]}}=\mu_{id}(\rho) + \mu_{ex}$

wherein the chemical potential of an ideal gas can be evaluated analytically. Now let's focus on $\mu_{ex}$, since the potential energy of an N+1 particle system can be separated into the potential energy of an N particle system and the potential of the excess particle interacting with the N particle system, that is,

$\Delta U\equiv U(s^{N+1}) - U(s^{N})$

and

$\mu_{ex}= -k_{B}T \ln \int ds_{N+1} \langle \exp(-\beta\Delta U)\rangle_{N}$.

Thus far we converted the excess chemical potential into an ensemble average, and the integral in the above equation can be sampled by the brute force Monte Carlo method.

The calculating of excess chemical potential is not limited to homogeneous systems, but has also been extended to inhomogeneous systems by the Widom insertion method, or other ensembles such as NPT and NVE.