The minimization is with respect to the unconstrained variables. In the case of chemical reactions this is usually the number of particles or mole fractions, subject to the conservation of elements. At equilibrium, these will take on their equilibrium values, and the internal energy U 0 will be a function only of the chosen value of entropy S 0 . By the definition of the Legendre transform, the Helmholtz free energy will be: