How does Dodelson calculate the number density of a particle species? In chapter three of Modern Cosmology, Dodelson models the evolution of a particle plasma as the universe expands.  On page 61, the author gives the formula for the species-dependent equilibrium density as:$$n_i=g_i\space e^{\mu_i/T}\int\frac{d^3p}{(2\pi)^3}e^{-E_1/T}\tag1$$For equilibrium (when a species is created as often as it's annihilated), we have:$$n_i^{(0)}=g_i\space\int\frac{d^3p}{(2\pi)^3}e^{-E_1/T}\tag2$$Now this is the part I don't follow.  How does Dodelson go from Eq. (2) to this:$$n_i^{(0)}=g_i\left(\frac{m_iT}{2\pi}\right)^{3/2} e^{-m_1/T}\tag3$$I get that $\int d^3 p=\frac{p^3}{({2\pi})^3\space6}$, and I get that $E_1=m_1$, and I get that $p=\sqrt{E^2-m^2}$, but I can't put them together.  How do we go from Eq. (2) to Eq. (3)?
 A: I'm afraid your primary error is one of elementary calculus.  $\int d^3p$ is not equal to $\frac{p^3}{(2\pi)^3 6}$.  Secondly, $E\neq m$ (how could it, since as you correctly say in your next words, $p=\sqrt{E^2-m^2}$??).
To evaluate this integral we go to spherical coordinates, in which $\int d^3 p = \int_0^\infty p^2 dp \int_{0}^{\pi} sin(\theta)\space d\theta \int _0^{2\pi} d\phi = 4\pi \int_0^\infty p^2 dp$, where we've used the spherical symmetry of the problem to evaluate the angular integrals.  From there, we have
$$n_i^{(0)} = g_i \frac{4\pi}{(2\pi)^3} \int_0^\infty p^2 e^{-\sqrt{p^2+m_i^2}/T} dp$$
This integral doesn't have a nice form.  However, if we assume that $m_i \gg p$, we can approximate $\sqrt{p^2+m_i^2} \approx m_i + \frac{p^2}{2m_i}$ (a non-relativistic approximation), which allows us to simplify to
$$n_i^{(0)} \approx g_i \frac{4\pi}{(2\pi)^3}e^{-m_i/T} \int_0^\infty p^2 e^{-p^2/2m_iT} dp$$
$$ = g_i\frac{4\pi}{(2\pi)^3} e^{-m_i/T} \frac{\sqrt{\pi}}{4}(2m_iT)^{3/2}$$
which simplifies after a bit of algebra to
$$n_i^{(0)} \approx g_i e^{-m_i/T} \left(\frac{m_iT}{2\pi}\right)^{3/2}$$
The non-relativistic approximation is valid as long as $m\gg T$ or, in SI units, $m\gg \frac{k_B T}{c^2}$.
