# Partition function

The **partition function** of a system is given by

where *H* is the Hamiltonian. The symbol *Z* is from the German *Zustandssumme* meaning "sum over states". The canonical ensemble partition function of a system in contact with a thermal bath
at temperature is the normalization constant of the Boltzmann distribution
function, and therefore its expression is given by

- ,

where is the density of states with energy and the Boltzmann constant.

In classical statistical mechanics, there is a close connection between the partition function and the configuration integral, which has played an important role in many applications (e.g., drug design).

## Helmholtz energy function[edit]

The partition function of a system is related to the Helmholtz energy function through the formula

This connection can be derived from the fact that is the entropy of a system with total energy . This is an extensive magnitude in the sense that, for large systems (i.e. in the thermodynamic limit, when the number of particles or the volume ), it is proportional to or . In other words, if we assume large, then

where is the entropy per particle in the thermodynamic limit, which is a function of the energy per particle . We can therefore write

Since is large, this integral can be performed through steepest descent, and we obtain

- ,

where is the value that maximizes the argument in the exponential; in other words, the solution to

This is the thermodynamic formula for the inverse temperature provided is the mean energy per particle of the system. On the other hand, the argument in the exponential is

the thermodynamic definition of the Helmholtz energy function. Thus, when is large,

## Connection with thermodynamics[edit]

We have the aforementioned Helmholtz energy function,

we also have the internal energy, which is given by

and the pressure, which is given by

- .

These equations provide a link between classical thermodynamics and statistical mechanics