# Integration over phase space for a one-dimensional harmonic oscillator

The problem asks for a proof of the following equation, and I have no idea on how to approach this:

$$\int dx dp \delta(E-\frac{p^2}{2m}-\frac{m \omega^2 x^2}{2})f(E) = \frac{2\pi}{\omega}f(E) ,$$ for an arbitrary function $$f(E)$$, where $$x$$ and $$p$$ are the position and momentum, and $$\delta$$ is a Dirac delta function.

$\delta(f(x))=\sum_{i} \frac{1}{\mid\frac{df}{dx}(x_i)\mid} \delta(x-x_i)$
where $x_i$ is the i_th zero of f(x)