TITLE: Derivation of multivariate transformation of random variables
QUESTION [6 upvotes]: I encounter the formula for transformation of random variables and I would like to try to derive it:
Given random variables $X_1$ and $X_2$, we have $Y_1 = u(X_1, X_2)$ and $Y_2 = v(X_1, X_2)$, then the pdf wrt Ys is:
$f_{Y_1,Y_2}(y_1, y_2) = \frac{1}{{|J(x_1,x_2})|}f_{X_1,X_2}(x_1, x_2)$
I know that $\iint{f(x_1,x_2)dx_1dx_2} = \iint{f(u^{-1}(y_1),v^{-1}(y_2))J(y_1,y_2)dy_1dy_2}$, but I can't seem to proceed from there. Probability textbooks tell me to refer to a text on calculus for the formula, but I can't find any text that proves this probabilistic modification of the formula.
Please shed some light.

REPLY [6 votes]: Let $A \subseteq \mathbf R^2$ be a Borel set. To shorten notation, we will write $X = (X_1, X_2)$, $Y = (Y_1, Y_2)$ and $g = (u,v) \colon \mathbf R^2\to \mathbf R^2$. Hence $Y = g(X)$. We have
\begin{align*}
   \def\P{\mathbf P}\P[Y \in A] &= \P[g(X) \in A]\\
        &= \P[X \in g^{-1}(A)]\\
        &= \int_{g^{-1}(A)} f_X(x)\, dx
\end{align*}
by the definition of $Y$ and $f_X$ respectively. Now comes the "transformation of variables formula" from calculus you cite. It holds that 
$$ \int_{g^{-1}(A)} f_X(x_1, x_2) \, d(x_1,x_2) 
   = \int_A (f_X \circ g^{-1})(y_1, y_2)\cdot |J_{g^{-1}}(y_1,y_2)| \, d(y_1,y_2) $$
Here $J_{g^{-1}}(y) = \det Dg^{-1}(y)$ is the Jacobian of $g^{-1}$. Now we have 
$$ Dg^{-1}(y) = \Bigl(Dg\bigl(g^{-1}(y)\bigr)\Bigr)^{-1} $$
and hence can continue above 
\begin{align*}
  \P[Y \in A] &= \int_{g^{-1}(A)} f_X(x)\, dx\\
    &= \int_A (f_X \circ g^{-1})(y) \cdot \left|J_{g}\bigl(g^{-1}(y)\bigr)\right|^{-1}\, dy\\
    &= \int_A \frac{f_X\bigl(g^{-1}(y)\bigr)}{\left|J_{g}\bigl(g^{-1}(y)\bigr)\right|}\, dy
\end{align*}
So $Y$ has a density with respect to Lesbesgue measure, namely 
$$ f_Y(y) :=  \frac{f_X\bigl(g^{-1}(y)\bigr)}{\left|J_{g}\bigl(g^{-1}(y)\bigr)\right|} $$