Following the procedure described in the gas in a box article, we can apply the Thomas–Fermi approximation, which assumes that the average energy is large compared to the energy difference between levels so that the above sum may be replaced by an integral. This replacement gives the macroscopic grand potential function Ω Ω m , which is close to Ω Ω :