Lecture 13

Change of Variables


Grace Tompkins

Last modified — 13 Nov 2026

Learning Outcomes

By the end of this lecture, students are anticipated to be able to:

  • Use the Distribution method to transform discrete or continuous CDFs

  • Use the Jacobian method to transform continuous PDFs

1 Transformations of CDFs

One-Dimensional Change of Variables

Sometimes we want to perform transformations on a random variable. This is when we can turn to change of variables.

  • Let \(X\) be a random variable with some distribution
  • Let \(Y = g(X)\) for some function \(g : {\mathbb{R}}\to {\mathbb{R}}\).
  • We want to find the distribution of \(Y\).


There are two ways to do this: the distribution method and the Jacobian method. We will present both.

One-Dimensional Change of Variables: Distribution Method

The distribution method just uses the definition:

\[\mathbb{P}(Y \in A) = \mathbb{P}(g(X) \in A) = \mathbb{P}(\{x : g(x) \in A\}).\]

If we can characterize these sets, we can find the distribution of \(Y\). This method always works, and is easy for discrete random variables.

Let \(X\) be a discrete random variable with PMF \(p_X(x)\). Let \(Y = g(X)\) for some function \(g : {\mathbb{R}}\to {\mathbb{R}}\). Then the PMF of \(Y\) is given by \[p_Y(y) = \sum_{x : g(x) = y} p_X(x) = \sum_{x \in g^{-1}(y)} p_X(x).\]

One-Dimensional Change of Variables: Distribution Method

Let’s make this method a little more algorithmic.

If you want to find the distribution of \(Y = g(X)\), then you can do the following: \[\mathbb{P}(Y \in A) = \mathbb{P}(g(X) \in A) = \mathbb{P}(\{x : g(x) \in A\}) = \cdots\]

  1. Start with the definition of the distribution of \(Y\).
  2. Use the definition of \(Y\) in terms of \(X\) to rewrite the probability in terms of \(X\).
  3. Use the distribution of \(X\) to compute the probability that \(g(X) \in A\).
  4. Then play algebra games to get it into a nice form; possibly “match” a known PDF or CDF.

One-Dimensional Change of Variables: Distribution Method (Discrete)

Let’s start with a straightforward example:

  • Let \(X \sim {\mathrm{Binom}}(n, \theta)\), for some \(\theta \in (0,1)\).
  • Let \(Y = n - X\).

Find the PMF of \(Y\).

One-Dimensional Change of Variables: Distribution Method (Discrete)

One-Dimensional Change of Variables: Distribution Method (Continuous)

Let \(X \sim {\mathrm{Exp}}(\lambda)\), find the distribution of \(Y = 3X\).

One-Dimensional Change of Variables: Distribution Method (Continuous)

If \(X \sim {\mathrm{Exp}}(\lambda)\), what is the CDF of \(Y = X + 5\)?

One-Dimensional Change of Variables: Distribution Method (Continuous)

If \(X \sim {\mathrm{Unif}}(0,1)\), what is the CDF of \(Y = X + 3\)?

One-Dimensional Change of Variables: Useful Results

The following useful results follow from the previous examples

If \(X\) be a random variables with CDFs \(F_{X}\) Then the the following hold:

  1. The RV \(Y = X + c\) has CDF \(F_{X}(x - c)\);
  2. The RV \(Y = kX\) has CDF \(F_{X}(x/k)\) for any \(k > 0\);

One-Dimensional Change of Variables: Jacobian Method

For continuous random variables, we can often use the Jacobian method in addition to the distribution method.

Let \(X\) be an (absolutely) continuous random variable, with density function \(f_X\). Let \(Y = h(X)\), where \(h : {\mathbb{R}}\to {\mathbb{R}}\) is a function that is differentiable and monotonic.

Then \(Y\) is also absolutely continuous, and its density function \(f_Y\) is given by \[f_Y(y) = f_X(h^{-1}(y)) \left| \frac{\mathsf{d}}{\mathsf{d}y} (h^{-1}(y)) \right|,\] where \(h^{-1}(y)\) is the unique number \(x\) such that \(h(x) = y\).

One-Dimensional Change of Variables: Jacobian Method

  • Let \(X \sim {\mathrm{Unif}}(0,1)\).
  • Let \(Y = -\log(X)\).

Find the PDF of \(Y\).

One-Dimensional Change of Variables: Jacobian Method

  1. Let \(X \sim {\mathrm{Unif}}\left( -1,1\right)\). Use the distribution method to find the PDF of \(Z = X^2\).

  2. Let \(X \sim {\mathrm{Gam}}(\alpha, \lambda)\). Use the Jacobian method to find the PDF of \(Y = 1/X\).

Recall the Gamma PDF: \[f_X(x) = \frac{\lambda^\alpha}{\Gamma(\alpha)} x^{\alpha - 1} e^{-\lambda x} I_{(0, \infty)}(x).\]

One-Dimensional Change of Variables: Jacobian Method

One-Dimensional Change of Variables: Jacobian Method

Upcoming Assessments:

  • Checkpoint 4 (Sections 2.4.1 - 2.5: Continuous Families and CDFs) is on Friday Nov 6th
  • Checkpoint 5 (Sections 2.6 - 2.7: Change of Variables, Joint and Marginal Distributions) is on Friday Nov 6th