In thermodynamics, the thermodynamic free energy is one of the state functions of a thermodynamic system. The change in the free energy is the maximum amount of work that the system can perform in a process at constant temperature, and its sign indicates whether the process is thermodynamically favorable or forbidden. Since free energy usually contains potential energy, it is not absolute but depends on the choice of a zero point. Therefore, only relative free energy values, or changes in free energy, are physically meaningful.

The free energy is the portion of any first-law energy that is available to perform thermodynamic work at constant temperature, i.e., work mediated by thermal energy. Free energy is subject to irreversible loss in the course of such work.Stoner, Clinton D. (2000). Inquiries into the Nature of Free Energy and Entropy in Respect to Biochemical Thermodynamics. Entropy Vol. 2. Since first-law energy is always conserved, it is evident that free energy is an expendable, second-law kind of energy. Several free energy functions may be formulated based on system criteria. Free energy functions are Legendre transforms of the internal energy.

The Gibbs free energy is given by , where is the enthalpy, is the absolute temperature, and is the entropy. , where is the internal energy, is the pressure, and is the volume. is the most useful for processes involving a system at constant pressure and temperature , because, in addition to subsuming any entropy change due merely to heat, a change in also excludes the work needed to "make space for additional molecules" produced by various processes. Gibbs free energy change therefore equals work not associated with system expansion or compression, at constant temperature and pressure, hence its utility to solution-phase chemists, including biochemists.

In contrast, the Helmholtz free energy is defined as . Its change is equal to the amount of reversible work done on, or obtainable from, a system at constant . Thus its appellation "work content", and the designation (). Since it makes no reference to any quantities involved in work (such as and ), the Helmholtz function is completely general: its decrease is the maximum amount of work which can be done by a system at constant temperature, and it can increase at most by the amount of work done on a system isothermally. The Helmholtz free energy has a special theoretical importance since it is proportional to the logarithm of the partition function for the canonical ensemble in statistical mechanics. (Hence its utility to physicists; and to gas-phase chemists and engineers, who do not want to ignore work.)

Historically, the term 'free energy' has been used for either quantity. In physics, free energy most often refers to the Helmholtz free energy, denoted by (or ), while in chemistry, free energy most often refers to the Gibbs free energy. The values of the two free energies are usually quite similar and the intended free energy function is often implicit in manuscripts and presentations.

Meaning of "free" The basic definition of "energy" is a measure of a body's (in thermodynamics, the system's) ability to cause change. For example, when a person pushes a heavy box a few metres forward, that person exerts mechanical energy, also known as work, on the box over a distance of a few meters forward. The mathematical definition of this form of energy is the product of the force exerted on the object and the distance by which the box moved (). Because the person changed the stationary position of the box, that person exerted energy on that box. The work exerted can also be called "useful energy", because energy was converted from one form into the intended purpose, i.e. mechanical use. For the case of the person pushing the box, the energy in the form of internal (or potential) energy obtained through metabolism was converted into work to push the box. This energy conversion, however, was not straightforward: while some internal energy went into pushing the box, some was diverted away (lost) in the form of heat (the person transfers thermal energy to the surrounding).

For a reversible process, heat is the product of the absolute temperature and the change in entropy of a body (entropy is a measure of disorder in a system). The difference between the change in internal energy, which is , and the energy lost in the form of heat is what is called the "useful energy" of the body, or the work of the body performed on an object. In thermodynamics, this is what is known as "free energy". In other words, free energy is a measure of work (useful energy) a system can perform at constant temperature.

Mathematically, free energy is expressed as

This expression has commonly been interpreted to mean that work is extracted from the internal energy while represents energy not available to perform work. However, this is incorrect. For instance, in an isothermal expansion of an ideal gas, the internal energy change is and the expansion work is derived exclusively from the term supposedly not available to perform work. But it is noteworthy that the derivative form of the free energy: (for Helmholtz free energy) does indeed indicate that a spontaneous change in a non-reactive system's free energy (NOT the internal energy) comprises the available energy to do work (compression in this case) and the unavailable energy . Similar expression can be written for the Gibbs free energy change.

In the 18th and 19th centuries, the theory of heat, i.e., that heat is a form of energy having relation to vibratory motion, was beginning to supplant both the caloric theory, i.e., that heat is a fluid, and the four element theory, in which heat was the lightest of the four elements. In a similar manner, during these years, heat was beginning to be distinguished into different classification categories, such as "free heat", "combined heat", "radiant heat", specific heat, heat capacity, "absolute heat", "latent caloric", "free" or "perceptible" caloric (calorique sensible), among others.

In 1780, for example, Laplace and Lavoisier stated: "In general, one can change the first hypothesis into the second by changing the words ‘free heat, combined heat, and heat released’ into ‘vis viva, loss of vis viva, and increase of vis viva.’" In this manner, the total mass of caloric in a body, called absolute heat, was regarded as a mixture of two components; the free or perceptible caloric could affect a thermometer, whereas the other component, the latent caloric, could not. The use of the words "latent heat" implied a similarity to latent heat in the more usual sense; it was regarded as chemically bound to the molecules of the body. In the adiabatic compression of a gas, the absolute heat remained constant but the observed rise in temperature implied that some latent caloric had become "free" or perceptible.

During the early 19th century, the concept of perceptible or free caloric began to be referred to as "free heat" or "heat set free". In 1824, for example, the French physicist Sadi Carnot, in his famous "Reflections on the Motive Power of Fire", speaks of quantities of heat ‘absorbed or set free’ in different transformations. In 1882, the German physicist and physiologist Hermann von Helmholtz coined the phrase ‘free energy’ for the expression , in which the change in A (or G) determines the amount of energy ‘free’ for work under the given conditions, specifically constant temperature.

Thus, in traditional use, the term "free" was attached to Gibbs free energy for systems at constant pressure and temperature, or to Helmholtz free energy for systems at constant temperature, to mean ‘available in the form of useful work.’ With reference to the Gibbs free energy, we need to add the qualification that it is the energy free for non-volume work and compositional changes.

An increasing number of books and journal articles do not include the attachment "free", referring to G as simply Gibbs energy (and likewise for the Helmholtz energy). This is the result of a 1988 IUPAC meeting to set unified terminologies for the international scientific community, in which the adjective ‘free’ was supposedly banished. This standard, however, has not yet been universally adopted, and many published articles and books still include the descriptive ‘free’.

Application Just like the general concept of energy, free energy has a few definitions suitable for different conditions. In physics, chemistry, and biology, these conditions are thermodynamic parameters (temperature , volume , pressure , etc.). Scientists have come up with several ways to define free energy. The mathematical expression of Helmholtz free energy is:

This definition of free energy is useful for gas-phase reactions or in physics when modeling the behavior of isolated systems kept at a constant volume. For example, if a researcher wanted to perform a combustion reaction in a bomb calorimeter, the volume is kept constant throughout the course of a reaction. Therefore, the heat of the reaction is a direct measure of the free energy change, . In solution chemistry, on the other hand, most chemical reactions are kept at constant pressure. Under this condition, the heat of the reaction is equal to the enthalpy change of the system. Under constant pressure and temperature, the free energy in a reaction is known as Gibbs free energy .

These functions have a minimum in chemical equilibrium, as long as certain variables (, and or ) are held constant. In addition, they also have theoretical importance in deriving Maxwell relations. Work other than may be added, e.g., for electrochemical cells, or work in elastic materials and in muscle contraction. Other forms of work which must sometimes be considered are stress-strain, magnetic, as in adiabatic demagnetization used in the approach to absolute zero, and work due to electric polarization. These are described by tensors.

In most cases of interest there are internal degrees of freedom and processes, such as chemical reactions and phase transitions, which create entropy. Even for homogeneous "bulk" materials, the free energy functions depend on the (often suppressed) composition, as do all proper thermodynamic potentials (extensive functions), including the internal energy.

is the number of molecules (alternatively, moles) of type in the system. If these quantities do not appear, it is impossible to describe compositional changes. The differentials for processes at uniform pressure and temperature are (assuming only work):

where μi is the chemical potential for the ith component in the system. The second relation is especially useful at constant and , conditions which are easy to achieve experimentally, and which approximately characterize living creatures. Under these conditions, it simplifies to

Any decrease in the Gibbs function of a system is the upper limit for any isothermal, isobaric work that can be captured in the surroundings, or it may simply be dissipated, appearing as times a corresponding increase in the entropy of the system and/or its surrounding.

An example is surface free energy, the amount of increase of free energy when the area of surface increases by every unit area.

The path integral Monte Carlo method is a numerical approach for determining the values of free energies, based on quantum dynamical principles.

Work and free energy change For a reversible isothermal process, ΔS = qrev/T and therefore the definition of A results in

(at constant temperature)