Thermodynamic potential or fundamental function is a quantity used to represent the state of a system.
We have four fundamental functions: internal energy U, enthalpy H, Helmholtz free energy F, and Gibbs free energy G.
They are “potential energy” defined as capacity to do work.
These four potentials provide a comprehensive framework for understanding and analyzing the behavior of thermodynamic systems.
Actually there are not just 4 , there are as many thermodynamic potentials as you want.
The first thermodynamic potential is internal energy and it comes from the first law of thermodynamics.
E=E(S,V);H=H(S,P);F=F(T,V).
In this list of pairs of four arguments, only one pair is missing: {T,P}.
The thermodynamic function of this pair, which gives the two remaining variables (S and V) by simple differentiation, is called the Gibbs energy (or sometimes the “Gibbs free energy”): G=G(T,P).