On the Harmonic Oscillator Regularization of Partition Functions
  A convenient way to calculate $N$-particle quantum partition functions is by confining the particles in a weak harmonic potential instead of using a finite box or periodic boundary conditions. There is, however, a slightly different connection between partition functions and thermodynamic quantities with such volume regularization. This is made explicit, and its origin explained to be due to the system having a space-varying density in an external potential. Beyond perturbation theory there is a potential pitfall with the method, which is pointed out. 
K{\aa}re Olaussen