Let $(X,\mathcal{M},\mu)$ be a $\sigma$-finite measure space and $f$ a measurable real valued function on $X$. Prove that \begin{equation*} \int_X e^{f(x)}\mathrm{d}\mu(x) = \int_\mathbb{R} e^{t}\mu(E_t)\mathrm{d}t \end{equation*} where $E_t=\{x\mid f(x)>t\}$ for each $t\in\mathbb{R}$.
Can this be solved by a change of variable formula?
\begin{align*} \int_{X}e^{f(x)}d\mu(x)& = \int_{X}\int_{-\infty}^{f(x)}e^{t}dt d\mu(x)\\ & = \int_{X}\int_{\mathbb{R}}I_{\{t< f(x)\}}(t)e^{t}dtd\mu(x)\\ & = \int_{X}\int_{\mathbb{R}}I_{\{f(x)>t\}}(x)e^{t}dtd\mu(x)\\ & = \int_{\mathbb{R}}\int_{X}I_{\{f(x)>t\}}(x)d\mu(x)e^tdt\\ & = \int_{\mathbb{R}}e^t\mu\left\{ f(x)>t \right\}dt. \end{align*}