For an ultrarelativistic particle, . Including the two spin states of an electron, counting wavevectors in a sphere gives the density of states
The grand canonical partition function of the ideal Fermi gas is therefore
Since the grand potential satisfies , integration by parts gives
Thus
This is the equation of state of an ideal ultrarelativistic gas.
For an ultrarelativistic particle, . Setting and writing the three-dimensional momentum integral radially gives
The standard Bose integrals yield
For fermions, the corresponding integrals differ by the familiar factors
Thus the number density scales as , while the energy density and pressure scale as .