# Deriving the partition function for a harmonic oscillator

This question is in reference to an answer I posted here yesterday.

In it I derived the partition function for a harmonic oscillator as follows

$$q = \sum_{j}e^{-\frac{\epsilon_j}{kT}}$$

For the harmonic, oscillator $\epsilon_j = (\frac{1}{2}+j)\hbar \omega$ for $j \in \{ 0,1,2.. \}$

Note that $\epsilon_0 \neq 0$ there exists a zero point energy.

Let's write out a few terms $$q = e^{-\frac{\hbar \omega/2}{kT}} + e^{-\frac{\hbar \omega3/2}{kT}} + e^{-\frac{\hbar \omega5/2}{kT}} +.....$$

factoring out $e^{-\frac{\hbar \omega/2}{kT}}$

$$q = e^{-\frac{\hbar \omega/2}{kT}} \left( 1+ e^{-\frac{\hbar \omega}{kT}} + e^{-\frac{2\hbar \omega}{kT}} +.....\right)$$

The sum in the bracket takes the form of a geometric series whose sum converges as shown below $$1+x+x^2+... = \frac{1}{(1-x)}$$ herein, $x \equiv e^{-\frac{\hbar\omega}{kT}}$

Putting all of this together

$$q = \frac{e^{-\frac{\hbar \omega/2}{kT}}}{(1-e^{-\frac{\hbar\omega}{kT}})}$$

I happened to check Atkins Physical chemistry (10th edition) for the same derivation earlier today.

On page 620, the vibrational partition function using the harmonic oscillator approximation is given as $$q = \frac{1}{1-e^{-\beta h c \nu'}}$$, $\beta$ is $\frac{1}{kT}$ and $\nu'$ is wave number

This result was derived in brief illustration 15B.1 on page 613 using a uniform ladder. However, in that illustration the uniform ladder starts at 0, but the harmonic oscillator has a zero point energy (which I accounted for in my derivation).

I discussed this with my instructor and he pointed out that as $T \rightarrow 0$ $q \rightarrow 1$ (since only one state is thermally accessible.

The result derived in Atkins' does that indeed, but mine goes $q \rightarrow 0$.

Now, in the formalism developed in Atkins the do set the ground state energies to zero (on page 605), and basically add non-zero ground state energies to a calculated $\langle \epsilon \rangle$, which is fine.

Anyway, I would love it if someone could weigh in on this and help me resolve this conceptual mess in my head.

• By relative ratios, do you mean the relative populations of the excited states? Actually, it shouldn't really be difficult for you to figure it out. The maths works out because the population ratio only depends on the difference in energy: $n_i/n_j \propto \exp[-\beta(\epsilon_i - \epsilon_j)]$ and this is independent of whether the zero point energy is set to 0 or not. Sorry if you are asking about something else. :D Also, if I am not wrong, the interpretation of $q$ as the number of thermally accessible states only makes sense if you set the ZPEs to zero. – orthocresol Oct 18 '16 at 10:50
• Oh that's true. Silly me, the problem with the limits still remains. What you say about the interpretation does make sense. If someone could confirm, then it would be great. – getafix Oct 18 '16 at 10:58
• Absolute values of $q$ and energy are not important at all. It is the derived quantities that matter, and they don't depend on your zero energy. – Ivan Neretin Oct 18 '16 at 11:16
• You are correct in your first calculation to obtain $\exp(-h\nu/(2kT))/(1-\exp(-h\nu/(kT))$ because you here choose the zero to be at the bottom of the potential well, if you choose the $j=0$ level to be zero then you obtain $1/(1-\exp(-h\nu/(kT))$ which is what Atkins assumes. – porphyrin Oct 19 '16 at 7:38

I'm confused why you're interpreting the partition function as a count of states. It can't be a count; it's continuous.

The zero point energy doesn't actually matter because you can just shift the energy scale so that it starts at zero. The main point of zero point energy is that the ground state of the harmonic oscillator is such that there is energy, and the system is not stationary. I'm going to use it below anyway because you are.

You can get the answer you want, but you'll want to look at the probability $P_i$ of being in state $i$, where the partition function is used to normalize:

$$P_{i} = \frac{\epsilon_{i}}{q} = \frac{\mathrm{e}^{-\beta\hbar\omega (i + 1)/2}}{\sum_{i}\mathrm{e}^{-\beta\hbar\omega (i+1)/2}}$$

$$P_{i} = \mathrm{e}^{-\beta\hbar\omega (i+1)/2} \frac{1 - \mathrm{e}^{-\beta\hbar\omega}}{\mathrm{e}^{-\beta\hbar\omega/2}} = \mathrm{e}^{-\beta\hbar\omega i}(1- e^{-\beta\hbar\omega})$$
For $T\rightarrow 0$, $P_{i} = \delta_{i0}$, which is exactly what you are looking for.
• Partition functions are defined as sum over states . If the gap between energy levels is small wrt kT then the sum can be replaced by an integral. This is ok for translational motion and although used for rotational motions in textbooks gives rise to a significant systematic error. The partition number tell us how, in the equilibrium distribution, the systems are partitioned or divided up among the different energy levels. There are $n_1$ systems with energy $\epsilon _1$, $n_2$ with $\epsilon _2$ etc. – porphyrin Oct 19 '16 at 8:00