I need to calculate the expectation value for a harmonic oscillator coupled to a heat bath using the trace method. I know that the density operator looks like:
$$\rho = \frac{e^{-H / k_B T}}{\text{Tr}\left( e^{-H/ k_B T} \right) } \, .$$
I need to show the following:
$$\text{Tr} (\rho H) = \frac{1}{2 \hbar \omega} + \frac{\hbar \omega}{e^{\hbar \omega / k_B T} - 1} \, .$$
I know the energy spectrum of the harmonic oscillator, but how do I compute the expectation value if I take the exponential of the Hamiltonian? I guess one should somehow use the creation and annihilation operator.