Can a dirac delta and integral be exchanged on level sets?

44 Views Asked by At

Let $Y\subseteq \mathbb{R}$, $g:\mathbb{R}\rightarrow\mathbb{R}$ and $f:\mathbb{R}\rightarrow\mathbb{R}$. It is true that:

$$\int_{y\in Y}\int_{x \in g^{-1}(k)}f(g(x))\,\mathrm dx \,\mathrm dy=\int_{y\in Y}f(y)\int_{x \in g^{-1}(k)}1\,\mathrm dx\,\mathrm dy$$

My question is this: does the same manipulation work if $f$ is the dirac delta function? I.e. does this hold:

$$\int_{y\in Y}\int_{x \in g^{-1}(k)}\delta(g(x))\,\mathrm dx\,\mathrm dy=\int_{y\in Y}\delta(y)\int_{x \in g^{-1}(k)}1\,\mathrm dx\,\mathrm dy$$