# Introduction to Mathematical Physics/Statistical physics/Entropy maximalization

In general, a system is described by two types of variables. External variables $y^{i}$ whose values are fixed at $y_{j}$ by the exterior and internal variables $X^{i}$ that are free to fluctuate, only their mean being fixed to ${\bar {X^{i}}}$ . Problem to solve is thus the following:

Problem:

Find distribution probability $P_{l}$ over the states $(l)$ of the considered system that maximizes the entropy

$S=-k_{B}\sum P_{l}\ln(P_{l})$ and that verifies following constraints:

${\begin{matrix}\sum X_{l}^{i}P_{l}&=&{\bar {X^{i}}}\\\sum P_{l}&=&1\end{matrix}}$ Entropy functional maximization is done using Lagrange multipliers technique. Result is:

$P_{l}={\frac {1}{Z}}e^{-\lambda _{1}X_{l}^{1}-\lambda _{2}X_{l}^{2}-...}$ where function $Z$ , called partition function, \index{partition function} is defined by:

$Z=\sum _{(l)}e^{-\lambda _{1}X_{l}^{1}-\lambda _{2}X_{l}^{2}-...}$ Numbers $\lambda _{i}$ are the Lagrange multipliers of the maximization problem considered.

Example:

In the case where energy is free to fluctuate around a fixed average, Lagrange multiplier is:

$\beta ={\frac {1}{k_{B}T}}$ where $T$ is temperature.\index{temperature} We thus have a mathematical definition of temperature.

Example:

In the case where the number of particles is free to fluctuate around a fixed average, associated Lagrange multiplier is noted $\beta \mu$ where $\mu$ is called the chemical potential.

Relations on means that:

$S/k=\sum \lambda _{i}{\bar {X^{i}}}+\ln(Z)$ This relation that binds $L$ to $S$ is called a {\bf Legendre transform}.\index{Legendre transformation} $L$ is function of the $y^{i}$ 's and $\lambda _{j}$ 's, $S$ is a function of the $y^{i}$ 's and ${\bar {X^{j}}}$ 's.

1. They are used to determine Lagrange multipliers $\lambda _{i}$ from associated means ${\bar {X_{i}}}$ } can be written as:
$-{\frac {\partial }{\partial \lambda _{i}}}\ln Z(y,\lambda _{1},\lambda _{2},...)={\bar {X_{i}}}$ It is useful to define a function $L$ by:

$L=\ln Z(y,\lambda _{1},\lambda _{2},...)$ It can be shown\footnote{ By definition

$S=-k_{B}\sum P_{l}\ln(P_{l})$ thus

$S/k=-\sum P_{l}\ln({\frac {1}{Z}}e^{-\lambda _{1}X_{l}^{1}-\lambda _{2}X_{l}^{2}-...})$ $S/k=1\ln Z+\lambda _{1}{\bar {X_{l}^{1}}}+\lambda _{2}{\bar {X_{l}^{2}}}+...$ 