Finding the CDF of a transformation of a random variable without first finding its PDF

213 Views Asked by At

This is in the context of random variables and their transformations.

Given a random variable $X$, its probability density function (PDF) $f_{X}$, and another random variable $Y$, which is a a function of $X$, how do I calculate the cumulative density function (CDF) of $Y$ (without first finding the PDF of $Y$)?

Below is a question and my solution:

$\\$

Question:

The PDF of a random variable $X$ is $f_{X}(x) =\begin{cases}\dfrac{1}{3}&,& -2 < x < 1\\ 0&,&\text{ elsewhere }\end{cases}$.

Find the CDF of $Y$ where $Y=X^{4}$.

$\\$

My solution:

From the PDF of $X$, we get the CDF of $X$ by using $F_X(x)=\int_{-\infty}^{x} f_X(t)\space dt$.

This comes out to be: $F_{X}(x)=\begin{cases}0&,& x <-2\\ \dfrac{x+2}{3}&,& -2\leq x <1\\ 1&,& x\geq 1\end{cases}$.

$\\$

Since $X\in (-2, 1)$ here, and $Y=X^{4}$, hence $Y\in [0, 16)$.

$\\$

Finding the CDF of $Y=X^{4}$, that is, $F_{Y}(y)$:

$\begin{align}F_{Y}(y) &= P(Y \leq y) \\ &= P(X^{4} \leq y) \end{align}$

$\\$

Firstly, for$\space $ $-2 < x < 0 \space$ ($\equiv \space 0 < y < 16$), we have $X=-Y^{1/4}$ (since $X$ is negative for these values of $Y$).

So,

$\begin{align} F_{Y}(y) &= P(-y^{1/4}\leq X <0) \\ &=\int ^{0}_{-y^{1/4}}f_{x}(x)\space dx \\ &= \dfrac{x}{3}\Bigg|_{x\space =\space -y^{1/4}}^{x\space =\space 0} \\ &= \dfrac{1}{3}y^{1/4}\end{align}$

$\\$

Now, for $\space $ $0 \le x < 1 \space$ ($\equiv \space 0 \le y < 1$), we have $X=Y^{1/4}$ (since $X$ is non-negative for these values of $Y$).

So,

$\begin{align}F_{Y}(y) &= P(0 \leq X <y^{1/4}) \\ &=\int ^{y^{1/4}}_{0}f_{x}(x)\space dx \\ &= \dfrac{x}{3}\Bigg|_{x\space =\space 0}^{x\space =\space y^{1/4}} \\ &= \dfrac{1}{3}y^{1/4}\end{align}$

$\\$

Combining the above two results, I am getting:

(1). For $0 \le y < 1$: $\space F_{Y}(y) = \dfrac{2}{3}y^{1/4}$, and,

(2). For $1 \le y < 16$: $\space F_{Y}(y) = \dfrac{1}{3}y^{1/4}$.

The second one above is clearly wrong since it is $\textbf{not}$ giving $\space F_{Y}(16^-) = 1$, while the first one is correct (as confirmed by the answer that I have).

What have I missed here while finding the CDF of $Y$?

I know we can first find the PDF of $Y=X^{4}$ using a transformation formula and then find its CDF from its PDF, but I do not want to solve this using that formula.

2

There are 2 best solutions below

0
On

For $0 \le y \le 1$ you have that $x$ spans $-y^{1/4} \le x \le y^{1/4}$
instead for $ 1 < y \le 16$ $x$ spans $ -y^{1/4} \le x < -1$

1
On

Your problem is with the supposed equivalences $$ -2<x<0\ \equiv\ 0<y<16\\ $$ and $$ 0\le x<1\ \equiv\ 0\le y<1 $$ neither of which is a true equivalence, since $\ 0<y<16\Leftrightarrow$$\,\{-2<x<0\}\color{red}{\vee\{0<x<2\}}\ $ and $\ 0\le y<1\Leftrightarrow$$\,\color{red}{-1<}x<1\ $.

For any $\ y\ge0 $ you have \begin{align} F_Y(y)&=P(Y\le y)\\ &=P\left(-y^{-\frac{1}{4}}\le X\le y^\frac{1}{4}\right)\\ &=P\left(\max\left(-2,-y^{-\frac{1}{4}}\right)\le X\le \min\left(1,y^\frac{1}{4}\right)\right)\\ &=\cases{P\left(-y^{-\frac{1}{4}}\le X\le y^\frac{1}{4}\right)&if $\ 0\le y\le1$\\ P\left(-y^{-\frac{1}{4}}\le X\le1\right)&if $\ 1< y\le1$6\\ 1&if $\ 16<y$}\\ &=\cases{\frac{2y^\frac{1}{4}}{3}&if $\ 0\le y\le1$\\ \frac{y^\frac{1}{4}}{3}+\frac{1}{3}&if $\ 1< y\le16$\\ 1&if $\ 16<y$}\ . \end{align} While you did end up with the correct result for $\ 0\le y\le1 $, your derivation of it was not fully coherent.