What does a transformation do?
If $X$ is random and $Y=g(X)$, then the randomness is inherited through the map $g$. The main question is: how does probability mass or probability density move under the map?
$F_Y(y)=P(Y\le y)=P(g(X)\le y)$.
If $g$ is monotone, use inverse and derivative.
For vectors, use the determinant of the inverse map derivative.
This simple formula is only directly valid when $g$ is one-to-one on the relevant support.
CDF method: $Y=X^2$ when $X$ has density $f_X(x)=\frac12(1+x)$ on $(-1,1)$
This transformation is not one-to-one because both $x=\sqrt y$ and $x=-\sqrt y$ map to the same $y$. The CDF method avoids mistakes.
The shaded interval is $[-\sqrt y,\sqrt y]$ in the original $x$-space.
One-to-one transformation: $Y=aX+b$
Let $X\sim \text{Uniform}(0,1)$ and $Y=aX+b$, where $a>0$. Then $Y$ is uniform on $(b,a+b)$ with density $1/a$.
Many-to-one formula: two inverse branches
When $g$ is not one-to-one, split the support into intervals where $g$ is monotone and add all contributions.
| Branch | Inverse | Contribution |
|---|
Probability integral transform
If $X$ is continuous with CDF $F_X$, then $U=F_X(X)\sim \text{Uniform}(0,1)$.
For the density $f_X(x)=\frac{x-1}{2}$ on $1 After transformation, the histogram should become nearly flat on $(0,1)$.
Jacobian method for two variables
For a transformation $(U,V)=T(X,Y)$, use the inverse map $(X,Y)=T^{-1}(U,V)$:
Example: sum and difference
If $U=X+Y$ and $V=X-Y$, then $$x=\frac{u+v}{2},\qquad y=\frac{u-v}{2},\qquad \left|\det\frac{\partial(x,y)}{\partial(u,v)}\right|=\frac12.$$
Jacobian calculator
For linear map $u=ax+by$, $v=cx+dy$, the inverse Jacobian factor is $1/|ad-bc|$.
Transformation can create a mixed distribution
Let $T\sim \text{Exponential}(\theta=1.5)$ and define $$V=\begin{cases}5,&T<3,\\2T,&T\ge 3.\end{cases}$$ Then $V$ has a point mass at $5$ and a continuous density for $v\ge6$.
Quick practice questions
1. Why is $Y=X^2$ not one-to-one on $(-1,1)$?
Because $x$ and $-x$ produce the same value $x^2$. For example, $0.4^2=(-0.4)^2$.
2. What is the most common mistake with $Y=X^2$?
Using only one inverse branch, such as $x=\sqrt y$, and forgetting $x=-\sqrt y$.
3. What does the absolute value in the Jacobian do?
It measures local stretching or shrinking of area/volume, and it must be positive for density.
4. Why does $F_X(X)$ become uniform?
Because $P(F_X(X)\le u)=P(X\le F_X^{-1}(u))=u$ for $0