Functions of a Random Variable
What
We define a new random variable \(Y = g(X)\), where \(X\) is a known random variable and \(g\) is a deterministic function. This allows us to study the distribution of transformed quantities, like kinetic energy from velocity, Celsius from Fahrenheit, or squared values from a normal distribution.
Why
- Many real-world quantities are functions of more basic random variables.
- Enables modeling derived or transformed metrics, like energy, signal power, or log-returns.
- Critical in probability and statistics for creating new distributions (e.g., chi-square from normal).
How
To find the distribution of \(Y = g(X)\):
- Do not directly plug \(g(X)\) into the PDF of \(X\) → this is incorrect.
- Instead, follow this valid procedure:
Why you cannot directly plug \(g(X)\) into the PDF\(f_X(x)\):
- The PDF \(f_X(x)\) gives the probability density at a particular Celsius temperature \(x\).
- \(g(X)\) gives the Fahrenheit temperature corresponding to Celsius temperature \(X\).
- To find the PDF of \(Y\), you cannot just substitute \(g(x)\) inside \(f_X\) like \(f_X(g(x))\). That won't give you a proper PDF of \(Y\).
1. Use the CDF:
Transform this into an expression involving \(X\) and use \(F_X\) (the known CDF of \(X\)).
2. Differentiate the CDF to get the PDF:
You cannot go PDF → PDF directly. You must pass through the CDF.
This gives a well-defined PDF for \(Y\), which reflects the correct transformation.
Example 1: Linear Transformation
Let \(X \sim \mathcal{N}(\mu, \sigma^2)\) and define \(Y = aX + b\) Then to get the CDF:
Differentiating CDF to get the PDF:
Result: \(Y \sim \mathcal{N}(a\mu + b, a^2\sigma^2)\)