1.1 Cumulative distribution technique
Theorem 1.1.1. Let \(X\) be a continuous random variable with pdf \(f_X(x)\), and let \(g\) be a differentiable function that is strictly increasing or strictly decreasing. Then the random variable \(Y = g(X)\) has pdf \[ f_Y(y) = f_X\bigl (g^{-1}(y)\bigr )\,\left |\frac {d}{dy}g^{-1}(y)\right | . \]
Proof. Suppose first that \(g\) is increasing. Then \(g(X) \le y\) exactly when \(X \le g^{-1}(y)\), so \begin {align*} F_Y(y) = P(Y \le y) &= P\bigl (g(X) \le y\bigr ) \\ &= P\bigl (X \le g^{-1}(y)\bigr ) = F_X\bigl (g^{-1}(y)\bigr ) , \end {align*}
and differentiating by the chain rule, \[ f_Y(y) = \frac {d}{dy}F_X\bigl (g^{-1}(y)\bigr ) = f_X\bigl (g^{-1}(y)\bigr )\frac {d}{dy}g^{-1}(y) , \] where \(\frac {d}{dy}g^{-1}(y) > 0\). If \(g\) is decreasing, then \(g(X) \le y\) exactly when \(X \ge g^{-1}(y)\), so \(F_Y(y) = 1 - F_X\bigl (g^{-1}(y)\bigr )\) and \(f_Y(y) = -f_X\bigl (g^{-1}(y)\bigr )\frac {d}{dy}g^{-1}(y)\), where now \(\frac {d}{dy}g^{-1}(y) < 0\). In both cases \[ f_Y(y) = f_X\bigl (g^{-1}(y)\bigr )\,\left |\frac {d}{dy}g^{-1}(y)\right | . \] □
Example 1.1.2. Let \(X\) be a continuous non-negative random variable with pdf \(f_X(x)\), and let \(Y = X^k\) with \(k > 0\). Find the pdf of \(Y\).
Solution. Here \(g(x) = x^k\) is increasing for \(x \ge 0\), with \(g^{-1}(y) = y^{1/k}\). By Theorem 1.1.1, \begin {align*} f_Y(y) &= f_X\bigl (g^{-1}(y)\bigr )\,\left |\frac {d}{dy}g^{-1}(y)\right | \\ &= f_X\bigl (y^{1/k}\bigr )\cdot \frac 1k\,y^{\frac 1k - 1} \\ &= \frac 1k\,y^{\frac 1k - 1}f_X\bigl (y^{1/k}\bigr ) . \end {align*}
For example, if \(k = 2\), \[ f_Y(y) = \frac 12y^{-1/2}f_X\bigl (y^{1/2}\bigr ) = \frac {1}{2\sqrt y}f_X\bigl (\sqrt y\bigr ) , \qquad y \in g(I) , \] where \(I\) is the set on which \(f_X\) is positive. The cdf technique was used to prove Theorem 1.1.1, but it can also be used directly to find the density of \(Y = g(X)\), as the next example shows.
Example 1.1.3. Let \(X\) be a continuous random variable with pdf \(f_X(x)\). Find the pdf of \(Y = |X|\), and evaluate it when \(X \sim N(\mu , \sigma ^2)\).
Solution. For \(y > 0\), \begin {align*} F_Y(y) &= P(Y \le y) = P(|X| \le y) \\ &= P(-y \le X \le y) \\ &= F_X(y) - F_X(-y) , \end {align*}
so, differentiating, \[ f_Y(y) = f_X(y) + f_X(-y) , \qquad y > 0 . \] If \(X \sim N(\mu , \sigma ^2)\), then \[ f_X(x) = \frac {1}{\sqrt {2\pi \sigma ^2}}\,e^{-\frac 12\left (\frac {x-\mu }{\sigma }\right )^2} , \] and \begin {align*} f_Y(y) &= \frac {1}{\sqrt {2\pi \sigma ^2}}\,e^{-\frac 12\left (\frac {y-\mu }{\sigma }\right )^2} + \frac {1}{\sqrt {2\pi \sigma ^2}}\,e^{-\frac 12\left (\frac {-y-\mu }{\sigma }\right )^2} \\ &= \frac {1}{\sqrt {2\pi \sigma ^2}}\Bigl \{e^{-\frac {1}{2\sigma ^2}(y^2 - 2\mu y + \mu ^2)} + e^{-\frac {1}{2\sigma ^2}(y^2 + 2\mu y + \mu ^2)}\Bigr \} \\ &= \frac {1}{\sqrt {2\pi \sigma ^2}}\,e^{-\frac {1}{2\sigma ^2}(y^2 + \mu ^2)}\Bigl \{e^{\mu y/\sigma ^2} + e^{-\mu y/\sigma ^2}\Bigr \} , \qquad y > 0 . \end {align*}
Questions on this section
Stuck on something here? Ask below and it stays attached to this topic.