Transformations of Random Variables
Mapping Random Variables Without Losing Probability
For a transformation Y = g(X), first identify the support of X and map it through g. The range of Y is not always obtained by applying a formula mechanically to endpoints; non-monotone functions can fold different values of X onto the same value of Y.
For a discrete variable, list every input value that maps to a proposed output and add their probabilities. For example, a squaring transformation can map two opposite signed inputs to one nonnegative output. Forgetting one preimage loses probability and makes the new mass function fail its total-probability check.
For a continuous monotone transformation, the cumulative method is often safest: write FY(y) = P(g(X) ≤ y) and translate the inequality using the original support. A density approach includes the magnitude of the inverse derivative and a transformed support.
For a CDF, check that it is zero below the support and one above it. For a density, check that it is zero outside the transformed support and integrates to one over that support.
X is uniform on (0, 1), and Y = √X. For 0 < y < 1, what is F_Y(y)?
X is uniform on (1, 3), so f_X(x) = 1/2 there. Let Y = 1/X. Which density is correct for Y?