A very standard question in introductory statistical mechanics courses is:
The solution can be obtained almost mindlessly, by using the appropriate formulas. It goes something like this: the system’s Hamiltonian is
\[H(\boldsymbol x, \boldsymbol p)=\frac{\boldsymbol p^2}{2m} + \frac{k \boldsymbol x^2}{2}.\]The partition function