# Problem with indistinguishability in partition function

Consider an ideal gas of classical particles of mass $m$ in uniform potential $\xi$ in 3d. The gas $N$ molecules, volume $V$ and is at temperature $T$. I believe that the Hamiltonian of this system is $H=\sum_{i=1}^N \frac{p_i^2}{2m}+\xi$.

The partition function is \begin{align} Z &= \sum_{\Gamma}e^{-\beta \left(\sum_{k=1}^N \frac{p_k^2}{2m}+ \xi\right )} \\ &\rightarrow \frac{1}{N!}\int \prod_{i=1}^N \frac{d^3p_i d^3q_i}{h_0^3} e^{-\beta \left(\sum_{k=1}^N \frac{p_k^2}{2m}+ \xi\right )} \\ &=\frac{1}{N!}\int \prod_{i=1}^N \frac{d^3p_i d^3q_i}{h_0^3} e^{-\beta \left(\sum_{k=1}^N \frac{p_k^2}{2m}\right)}e^{-\beta N \xi} \\ &=\frac{V^N e^{-\beta N \xi}}{N!h_0^{3N}} \prod_{i=1}^N \int d^3p_i e^{-\beta \left(\frac{p_i^2}{2m}\right)} \\ &=\frac{V^N e^{-\beta N \xi}}{N!h_0^{3N}} \left(\sqrt{\frac{\pi}{\frac{\beta}{2m}}}\right)^{3/2} \\ &=\frac{V^N e^{-\beta N \xi}}{N!h_0^{3N}} \left( \frac{2m\pi}{\beta}\right)^{3/2} \\ \end{align}

So the Helmholtz free energy is \begin{align} F=-k_BT \ln \left[ \frac{V^N e^{-\beta N \xi}}{N!h_0^{3N}} \left( \frac{2m\pi}{\beta}\right)^{3/2} \right] \end{align}

But apparently $\mu=\xi+k_BT\ln \left[\frac{N\lambda^3}{V}\right]$

So I take \begin{align}\mu &= \left(\frac{\partial F}{\partial N}\right)_{T,V} \\ &= \frac{\partial}{\partial N}\mid_{T,V} -k_BT \ln \left[ \frac{V^N e^{-\beta N \xi}}{N!h_0^{3N}} \left( \frac{2m\pi}{\beta}\right)^{3/2} \right] \\ &= -k_BT \frac{\partial}{\partial N}\mid_{T,V} \left( \ln \left[ \left( 2m\pi k_BT\right)^{3/2} \right]+\ln \left[ V^N e^{-\beta N \xi} \right] - \ln \left[ N!h_0^{3N} \right] \right) \\ &= -k_BT \frac{\partial}{\partial N}\mid_{T,V} \left( \ln \left[ V^N e^{-\beta N \xi} \right] - \ln \left[ N!h_0^{3N} \right] \right) \\ &= -k_BT \frac{\partial}{\partial N}\mid_{T,V} \left( N\ln V +-\beta N \xi- \ln \left[ N!h_0^{3N} \right] \right) \\ &= -k_BT \left( \ln V +-\beta \xi- \frac{\partial}{\partial N}\mid_{T,V} \ln \left[ N!h_0^{3N} \right] \right) \\ \end{align}

but the $N!$ is not very tractable so I dont see how the indistinguishability can be incorporated. Or should it be there at all? If not why not?

You will probably find the Stirling approximation useful here. For your purposes it will be sufficient to use the form $\ln N! \approx N\ln N - N$, which is valid for $N\gg 1$.