Skip to main content

Extra Practice: Class 2

Probability II

These extra practice problems for Class 2 come from exams and review exercises that I wrote for Econ 103, from the probability collections that I set for my Oxford students in previous years, and from past Oxford demonstration lectures. Econ 103 is the introductory statistics course that I taught at the University of Pennsylvania. They are grouped by topic. Within each topic they run from warm-up questions, through standard and harder problems, to challenge problems that go beyond what the lecture videos cover. Try each problem before clicking to reveal its solution.

Discrete random variables and pmfs

Problem 1 Warm-up

Write out the support set, pmf, and CDF of a Bernoulli\((p)\) RV.

The support set is \(\{0, 1\}\). The pmf is \[f(x) = \left\{ \begin{array}{ll} 1 - p & x = 0\\ p & x = 1 \\ 0 & \text{otherwise} \end{array}\right.\] which can also be written as \(f(x) = p^x (1-p)^{1-x}\) for \(x \in \{0,1\}\), zero otherwise. The CDF is \[F(x) = \left\{ \begin{array}{ll} 0 & x < 0\\ 1 - p & 0 \leq x < 1 \\ 1 & x \geq 1 \end{array}\right.\]

Problem 2 Warm-up

Define the Binomial\((n,p)\) RV in terms of independent Bernoulli trials, and write down its support set and probability mass function.

A Binomial\((n,p)\) RV \(X\) counts the number of successes in \(n\) independent Bernoulli trials, each with probability of success \(p\): if \(X_1, \dots, X_n\) are independent Bernoulli\((p)\) RVs, then \(X = X_1 + X_2 + \dots + X_n\). Its support set is \(\{0, 1, 2, \dots, n\}\) and its pmf is \[f(x) = {n \choose x} p^x (1-p)^{n-x}, \quad x \in \{0, 1, \dots, n\}\] and zero otherwise.

Problem 3 Warm-up

Substitute \(n=1\) into the pmf of a Binomial\((n,p)\) RV and show that you obtain the pmf of a Bernoulli\((p)\) RV.

The pmf for a Binomial\((n,p)\) RV is \[f(x) = {n \choose x} p^x (1-p)^{n-x}\] with support \(\{0, 1, 2, \dots, n\}\). Setting \(n=1\) gives, \[f(x) = {1 \choose x} p^x (1-p)^{1-x}\] with support \(\{0,1\}\). Plugging in each realization in the support, and recalling that \(0! = 1\), we have \[f(0) = \frac{1!}{0!(1-0)!} p^0 (1-p)^{1-0} = 1 - p\] and \[f(1) = \frac{1!}{1!(1-1)!} p^1 (1-p)^0 = p\] which is exactly how we defined the Bernoulli Random Variable.

Problem 4 Standard

A multiple choice quiz has 12 questions, each of which has 5 choices. To pass you need to get at least 8 of them correct. Nina forgot to study, so she simply guesses at random.

  1. Let the random variable \(X\) denote the number of questions that Nina gets correct on the quiz. What kind of random variable is \(X\)? Specify all parameter values.

    Each question is an independent Bernoulli trial with probability of success \(1/5\), so \(X \sim \text{Binomial}(n = 12, p = 1/5)\).

  2. Calculate the probability that Nina passes the quiz.

    Nina passes if \(X \geq 8\). The events \(X = 8, \dots, X = 12\) are mutually exclusive, so \[P(X \geq 8) = \sum_{x = 8}^{12} {12 \choose x} \left(\frac{1}{5}\right)^x \left(\frac{4}{5}\right)^{12 - x} \approx 0.000519 + 0.000058 + 0.000004 + 0.0000002 + 0.000000004 \approx 0.00058.\] Guessing at random, Nina has well under a one in a thousand chance of passing.

Problem 5 Standard

Suppose that \(X_1 \sim \text{Bernoulli}(p_1)\), \(X_2 \sim \text{Bernoulli}(p_2)\) and \(X_3 \sim \text{Bernoulli}(p_3)\) where \(X_1, X_2\) and \(X_3\) are mutually independent. Let \(Y\) be a random variable that takes on the value one if and only if a majority of the random variables \(X_1, X_2, X_3\) take on the value one. In any other situation \(Y\) takes on the value zero.

  1. What kind of random variable is \(Y\)? You don’t need to give the values of any associated parameters: just name the random variable and explain briefly.

    Since it can only take on only the values zero and one, \(Y\) is a Bernoulli RV.

  2. Suppose that \(p_1 = p_2 = p_3 =p\). In this case what kind of random variable is \(X_1 + X_2 + X_3\)?

    In this case \(X_1, X_2, X_3\) are independent Bernoulli\((p)\) random variables, so their sum is, by definition, a Binomial\((3,p)\) random variable.

  3. Using your answer to the preceding part, calculate \(P(Y=1)\) for the case in which \(p_1 = p_2=p_3 =p\).

    From the preceding part, \(X_1 + X_2 + X_3\) is a Binomial\((3,p)\) random variable. Hence its pmf is \[f(x)={3 \choose x} p^x (1-p)^{3-x}\] By definition, \(Y=1\) when a majority of \(X_1, X_2, X_3\) equal one. Thus we need to calculate the probability that the sum \(X_1+X_2+X_3\) equals either two or three. Since these are mutually exclusive outcomes, we calculate \[\begin{aligned} P(Y=1) &= P(X_1 + X_2 + X_3 \geq 2) = f(2) + f(3)\\ &={3 \choose 2} p^2 (1-p) + {3\choose 3} p^3\\ &= 3p^2 (1-p) + p^3\\ &= 3p^2 - 3p^3 + p^3\\ &=3p^2 - 2p^3 \end{aligned}\]

CDFs and quantiles

Problem 6 Warm-up

Mark each statement as True or False. If you mark a statement as False, provide a brief explanation. If you mark a statement as True, no explanation is needed.

  1. If \(X\) is a random variable, the CDF \(F(x_0)\) of \(X\) gives the probability that \(X\) exceeds a specified threshold \(x_0\).

    FALSE: it gives the probability that \(X\) does not exceed \(x_0\), namely \(P(X \leq x_0)\).

  2. The support set of the Bernoulli random variable is \(\{0,1\}\).

    TRUE

Problem 7 Warm-up

Let \(X\) be a RV with support set \([-2,2]\) and the following CDF: \[F(x_0) = \left\{ \begin{array}{rr} 0, & x_0 < -2\\ (x_0 + 2)/4, & -2 \leq x_0 \leq 2\\ 1, & x_0 > 2 \end{array} \right.\]

  1. Calculate the PDF of \(X\).

    \(f(x) = F'(x) = 1/4\) for \(x \in [-2, 2]\), zero otherwise

  2. Is \(X\) an example of one of the “named” RVs from the lecture slides? If so, which one? Be sure to specify the values of any and all parameters of the distribution.

    \(X \sim \text{Uniform}(-2, 2)\)

Problem 8 Standard

Let \(X_1, \dots, X_5\) be independent random variables, each with pdf \(f(x) = (x+1)/2\) and support set \(x \in [-1,1]\).

  1. Calculate the CDF \(F(x_0)\) of \(X_1\).

    For \(x_0 \in (-1,1)\) we have \[F(x_0) = \int_{-\infty}^{x_0} f(x)\; dx = \frac{1}{2}\int_{-1}^{x_0} (x+1)\; dx = \frac{1}{2}\left.\left( \frac{x^2}{2} + x \right)\right|_{-1}^{x_0} = \frac{1}{4}\left( x_0^2 + 2x_0 + 1 \right)\] For \(x_0 < -1\), on the other hand, \(F(x_0) = 0\) and for \(x_0 > 1\) it equals 1.

  2. Calculate \(P(X_1 > 0)\).

    \(P(X_1 > 0) = 1 - F(0) = 1 - \frac{1}{4}\left(0^2 + 2\times 0 + 1 \right) = 3/4\)

  3. What is the probability that exactly four of \(X_1, \dots, X_5\) are greater than zero?

    Let \(Z\) denote the number of RVs among \(X_1, X_2, X_3, X_4, X_5\) that take on a positive value. E.g. if all of them are positive then \(Z\) is 5 and if none are positive then \(Z\) is zero. Since \(X_1, X_2, X_3, X_4, X_5\) are independent and each has \(P(X_i >0) = 3/4\), it follows that \(Z \sim \text{ Binomial}(5,3/4)\) and we need to calculate \(f_Z(4)\) where \(f_Z(z) = {5\choose z} (3/4)^z(1/4)^{5-z}\). We have: \[f_Z(4)= {5 \choose 4} (3/4)^4 (1/4)^1 = \frac{5!}{4!1!}(3/4)^4 1/4 = 5/4 \times 81/256 \approx 0.40\]

Problem 9 Harder

Let \(X_1\) and \(X_2\) be independent random variables, each with cumulative distribution function \(F\), and define \(X^* = \max\{X_1, X_2\}\). Let \(c\) be a constant.

  1. In terms of \(F\), what is \(P(X_1 \leq c)\)? What is \(P(X_2 \leq c)\)?

    By the definition of a CDF and the fact that \(X_1\) and \(X_2\) both have CDF \(F\), \(F(c) = P(X_1 \leq c) = P(X_2 \leq c)\).

  2. In terms of \(F\) what is \(P(X_1\leq c \cap X_2 \leq c)\)?

    By independence, \[P(X_1\leq c\cap X_2 \leq c) = P(X_1 \leq c)P(X_2\leq c) =F(c)F(c) = F^2(c)\]

  3. Explain why \(P(X^*\leq c) = P(X_1\leq c \cap X_2\leq c)\).

    Since \(X^*\) is the maximum of \(X_1\) and \(X_2\), the events \(X^* \leq c\) and \((X_1 \leq c) \cap (X_2 \leq c)\) are logically equivalent. If both \(X_1\) and \(X_2\) are no greater than \(c\) then their maximum is no greater than \(c\). Further, if the maximum of \(X_1\) and \(X_2\) is no greater \(c\) then it must be the case that both \(X_1\) and \(X_2\) are no greater than \(c\). Since the events are equivalent, their probabilities must be equal.

  4. Using your answer to (c), what is the CDF of \(X^*\)?

    \(F^*(x) = F^2(x)\)

  5. Now suppose that \(X_1\) and \(X_2\) are independent Uniform\((0,1)\) random variables. Using your answer to part (d), calculate the probability density function of \(X^*\).

    For a Uniform(0,1) random variable \(F(x) = x\) for \(x\in[0,1]\) while \(F(x) = 1\) for \(x>1\) and \(F(x) = 0\) for \(x<0\). Hence, \[\begin{aligned} F^*(x) = F^2(x) = \left\{ \begin{array}{cr} 0 & x < 0 \\ x^2 & 0\leq x \leq 1 \\ 1 & x>1\end{array} \right. \end{aligned}\] Differentiating, \(f^*(x) = 2x\) for \(x\in [0,1]\), zero otherwise.

Continuous random variables and pdfs

Problem 10 Warm-up

From a past Oxford demonstration lecture.

Consider a random variable \(X\) which is uniformly distributed \(U(0, 1)\).

  1. Draw the probability density function (pdf), \(f(x)\). What is the formula for the pdf?

    \[f(x) = \left\{ \begin{array}{ll} 1 & 0 \leq x \leq 1\\ 0 & \text{otherwise} \end{array}\right.\] The graph is zero to the left of \(0\), a horizontal line at height one between \(0\) and \(1\), and zero to the right of \(1\). The area under it is a unit square, so the pdf integrates to one.

  2. Draw the cumulative distribution function (cdf), \(F(x)\). What is the formula for the cdf?

    For \(0 \leq x \leq 1\), \(F(x) = \int_0^x 1 \, dt = x\), so \[F(x) = \left\{ \begin{array}{ll} 0 & x < 0\\ x & 0 \leq x \leq 1 \\ 1 & x > 1 \end{array}\right.\] The graph is flat at zero to the left of \(0\), rises along a straight line from \((0,0)\) to \((1,1)\), and is flat at one to the right of \(1\).

Problem 11 Warm-up

From a past Oxford demonstration lecture.

For a random variable \(X \sim U (2, 12)\) (read the \(\sim\) as “that is distributed”)

  1. What is \(P(3 \leq X \leq 8)\)?

    The pdf of \(X\) is \(f(x) = 1/(12 - 2) = 1/10\) for \(2 \leq x \leq 12\) and zero otherwise. Hence \[P(3 \leq X \leq 8) = \int_3^8 \frac{1}{10}\, dx = \frac{8 - 3}{10} = 0.5.\] Equivalently, this is the area of a rectangle with width \(5\) and height \(1/10\).

  2. What is \(P(X = 9)\)?

    \(P(X = 9) = 0\), since \(X\) is a continuous random variable and the probability that a continuous random variable takes on any particular value is zero.

Problem 12 Warm-up

Let \(X\) be a continuous RV with support \([0,1]\) and \(f(x) = C x^2(1 - x)\). Find \(C\).

\(12\)

Problem 13 Warm-up

Let \(X\) be a continuous RV with support \([0,1]\) and \(f(x) = 3x^2\). Calculate the probability that \(X\) takes a value in the interval \([0.2, 0.8]\).

For \(x_0 \in [0,1]\) the CDF of \(X\) is \(F(x_0) = \int_0^{x_0} 3x^2 \, dx = x_0^3\). Hence \[P(0.2 \leq X \leq 0.8) = F(0.8) - F(0.2) = 0.8^3 - 0.2^3 = 0.512 - 0.008 = 0.504.\]

Problem 14 Warm-up

For each of the following parts, simply write down the answer: no explanation is needed.

  1. What is the median of a normal RV with mean -4 and variance 36?

    By symmetry: -4

  2. Write down the pmf of a Binomial\((10,1/3)\) RV.

    \(p(x) = {10 \choose x} (1/3)^x (2/3)^{10 - x}\)

  3. Suppose that \(X\) is a continuous RV that is equally likely to take on any value in \([-2,2]\) but never takes on a value outside this range. Write down its pdf.

    \(f(x)=1/4\) on \([-2,2]\), zero otherwise.

  4. What is the support set of a Binomial\((5,1/2)\) RV?

    \(\left\{ 0, 1, 2, 3, 4, 5 \right\}\)

  5. Calculate the approximate value of \(P\left( Z > 3 \right)\) if \(Z \sim N(\mu = 1, \sigma^2 = 4)\).

    \(P(Z>3) = P\left( \left[ Z-1 \right]/2 > 1 \right)\approx 0.16\)

Problem 15 Warm-up

In each of the following parts \(X\) denotes a continuous RV.

  1. Let \(X\) have support set \([0, +\infty)\) and CDF \(F(x) = 1 - e^{-x}\). Find the pdf of \(X\).

    \[f(x) = F'(x) = e^{-x}\]

  2. Let \(X\) have support set \([0, c]\) and pdf \(f(x) = \sqrt{x}\). Find \(c\).

    \[1 = \int_{-\infty}^{\infty} f(x)\, dx = \int_{0}^{c} x^{1/2} \, dx = \frac{c^{3/2}}{3/2}\] Hence \(3/2 = c^{3/2}\). Squaring both sides, \(9/4 = c^3\) so \(c = \sqrt[3]{9/4} \approx 1.31\).

Problem 16 Standard

From a past Oxford demonstration lecture.

Consider a random variable \(X\) which is uniformly distributed \(U(0, 1)\).

  1. What is the distribution of \(Z = 2 + X\)?

  2. What is the distribution of \(Z = 3X\)?

  3. What is the distribution of \(Z = 2 + 3X\)?

If \(X \sim U(a, b)\) and \(c > 0\) and \(d\) are constants, then \(Z = d + cX \sim U(d + ca, d + cb)\): adding \(d\) shifts both endpoints by \(d\), and multiplying by \(c\) stretches the interval by a factor of \(c\), while the pdf stays flat. To check this, note that \(Z\) takes values in \([d + ca, d + cb]\), and for \(z\) in this interval \[P(Z \leq z) = P\left(X \leq \frac{z - d}{c}\right) = \frac{(z - d)/c - a}{b - a} = \frac{z - (d + ca)}{(d + cb) - (d + ca)},\] which is the CDF of a \(U(d + ca, d + cb)\) random variable. Here \(a = 0\) and \(b = 1\), so

  1. \(Z = 2 + X \sim U(2, 3)\)

  2. \(Z = 3X \sim U(0, 3)\)

  3. \(Z = 2 + 3X \sim U(2, 5)\)

Problem 17 Standard

From a past Oxford demonstration lecture.

Consider a random variable \(X\) which is uniformly distributed \(U(-2, 3)\).

  1. What is the distribution of \(Z = 2 + X\)?

  2. What is the distribution of \(Z = 3X\)?

  3. What is the distribution of \(Z = 2 + 3X\)?

If \(X \sim U(a, b)\) and \(c > 0\) and \(d\) are constants, then \(Z = d + cX \sim U(d + ca, d + cb)\): adding a constant shifts both endpoints of the interval, multiplying by a positive constant multiplies both endpoints, and in each case the pdf stays flat on the new interval. Here \(a = -2\) and \(b = 3\), so

  1. \(Z = 2 + X \sim U(0, 5)\)

  2. \(Z = 3X \sim U(-6, 9)\)

  3. \(Z = 2 + 3X \sim U(2 - 6, 2 + 9) = U(-4, 11)\)

The Normal distribution

Problem 18 Warm-up

From a past Oxford demonstration lecture.

Consider a random variable \(X\) which is normally distributed with mean 0 and variance of 1.

  1. What is the distribution of \(Z = 5 + X\)?

  2. What is the distribution of \(Z = 2X\)?

  3. What is the distribution of \(Z = 2 + 3X\)?

If \(X \sim N(\mu, \sigma^2)\) then adding a constant shifts the location only, \(a + X \sim N(a + \mu, \sigma^2)\), while multiplying by a constant changes both the location and the spread, \(bX \sim N(b\mu, b^2\sigma^2)\). Combining the two rules, \(a + bX \sim N(a + b\mu, b^2\sigma^2)\). Here \(\mu = 0\) and \(\sigma^2 = 1\), so

  1. \(Z = 5 + X \sim N(5, 1)\)

  2. \(Z = 2X \sim N(0, 4)\)

  3. \(Z = 2 + 3X \sim N(2, 9)\)

Problem 19 Warm-up

Let \(Z \sim N(0,1)\). Without consulting a table, approximately what is \(P(Z \leq 1)\)? Hint: use symmetry and the approximate probability that a Normal random variable lies within one standard deviation of its mean.

Since \(P(-1 \leq Z \leq 1) \approx 0.68\), the two tails together have probability about \(0.32\). By symmetry each tail has probability about \(0.16\), so \(P(Z \leq 1) \approx 1 - 0.16 = 0.84\).

Problem 20 Warm-up

Let \(X \sim N(0, 9)\) and \(Y \sim N(3, 4)\). For each of the following, please give a numeric answer.

  1. What is the approximate value of \(P(-1\leq X/3 \leq 1)\)?

    This is simply the probability that a standard normal takes a value in the interval \([-1,1]\) which we know is 0.68.

  2. What value of \(k\) ensures that \(P(3-k\leq Y \leq 3 + k)\approx 0.95\)?

    Rearranging, we need to find \(k\) such that \[\begin{aligned} P(3-k \leq Y \leq 3+k) &= P(-k\leq Y-3 \leq k) \\ &=P\left(-k/2 \leq \frac{Y-3}{2}\leq k/2\right) \approx 0.95 \end{aligned}\] Since \((Y-3)/2\) is a standard normal, we need \(k/2 = 2\), hence \(k=4\).

Problem 21 Harder

Let \(X \sim N(-1,1)\) independently of \(Y \sim N(1,1)\).

  1. Approximately what is the probability that \(X\) takes on a positive value?

    \(P(X >0) = P(X + 1 > 1) \approx 0.16\), since \(X + 1 \sim N(0,1)\), by the symmetry of the normal distribution and the fact that approximately 68% of the probability density of a standard normal lies in the interval \([-1,1]\).

  2. Approximately what is the probability that \(Y\) takes on a positive value?

    \(P(Y > 0) = P(Y - 1 > -1) \approx 0.84\), since \(Y - 1 \sim N(0,1)\), by the symmetry of the normal distribution and the fact that approximately 68% of the probability density of a standard normal lies in the interval \([-1,1]\).

  3. Suppose I generate a random variable \(Z\) using the following steps. First, I make one draw each from \(X\) and \(Y\). Then I independently draw \(Q\), a Bernoulli\((1/2)\) random variable. If \(Q = 1\), then I set \(Z\) equal to the draw from \(X\). Otherwise I set \(Z\) equal to the draw from \(Y\). Thus \(Z = Q \times X + (1 - Q) \times Y\). Using your answers to parts (a) and (b) above, calculate the approximate probability that \(Z\) takes on a positive value. Prove your answer.

    By the Law of Total Probability: \[\begin{aligned} P(Z > 0) &= P(Z > 0 |Q = 1)P(Q = 1) + P(Z > 0| Q = 0)P(Q = 0)\\ &= P(Z > 0 |Q = 1)\times 1/2 + P(Z > 0| Q = 0)\times 1/2 \\ &= P(X > 0) \times 1/2 + P(Y > 0)\times 1/2\\ &\approx 1/2 \times \left[0.16 + 0.84\right] = 0.5 \end{aligned}\] In fact this answer is exact rather than approximate: by the symmetry of the normal distribution, \(P(X > 0) = P(Y \leq 0)\), so \(P(X > 0) + P(Y > 0) = 1\) exactly.

  4. Continuing from the preceding part, suppose I make a draw from \(Z\). It is a positive number. Calculate the probability that \(Q\) took on the value 1.

    By Bayes’ Rule, \[\begin{aligned} P(Q = 1|Z >0) &= P(Z>0|Q = 1)P(Q =1)/P(Z>0)\\ &= P(X >0) P(Q = 1)/P(Z>0)\\ &\approx 0.16 \times 0.5/0.5 = 0.16 \end{aligned}\]

Joint, marginal, and conditional distributions

Problem 22 Warm-up

What is the difference between a joint pmf and a marginal pmf? Can you calculate a marginal pmf from a joint? How? Can you calculate a joint pmf from a marginal pmf?

A joint pmf \(p_{XY}(x,y) = P(X = x \cap Y = y)\) gives the probability that two random variables simultaneously take on particular values, while a marginal pmf, such as \(p_X(x) = P(X = x)\), describes a single random variable on its own. We can always calculate a marginal pmf from a joint pmf by summing over all the values of the other random variable: \(p_X(x) = \sum_{\text{all } y} p_{XY}(x,y)\). We cannot in general calculate a joint pmf from the marginal pmfs, because the marginals contain no information about how the two random variables are related. The exception is when \(X\) and \(Y\) are independent, in which case \(p_{XY}(x,y) = p_X(x)p_Y(y)\).

Problem 23 Warm-up

Mark each statement as TRUE or FALSE. If FALSE provide a one sentence explanation.

  1. If \(X\) is a continuous RV with pdf \(f(x)\) then \(f(0)\) gives \(P(X=0)\).

    FALSE: if \(X\) is continuous \(P(X=x)=0\) for any \(x\).

  2. If \(X\) and \(Y\) are discrete RVs then \(p_Y(y) = \sum_{\text{all } y} p_{XY}(x,y)\).

    FALSE: the sum should be taken over all \(x\).

Problem 24 Warm-up

Suppose that \(X\) is a random variable with support \(\{1,2\}\) and \(Y\) is a random variable with support \(\{0,1\}\) where \(X\) and \(Y\) have the following joint pmf: \[\begin{aligned} p_{XY}(1,0) = 0.20, &\quad p_{XY}(1,1) = 0.30\\ p_{XY}(2,0) = 0.25, &\quad p_{XY}(2,1) = 0.25 \end{aligned}\]

  1. Express the joint pmf in a table with \(X\) in the rows.

    \(Y = 0\) \(Y = 1\)
    \(X = 1\) 0.20 0.30
    \(X = 2\) 0.25 0.25
  2. Using the table, calculate the marginal pmfs of \(X\) and \(Y\).

    \[\begin{aligned} p_X(1) &=p_{XY}(1,0) + p_{XY}(1,1)=0.20+0.30 = 0.50 \\ p_X(2) &=p_{XY}(2,0) + p_{XY}(2,1)=0.25 + 0.25 = 0.50 \\ p_Y(0) &=p_{XY}(1,0) + p_{XY}(2,0) = 0.20 + 0.25 = 0.45 \\ p_Y(1) &= p_{XY}(1,1) + p_{XY}(2,1) = 0.30 + 0.25 = 0.55 \end{aligned}\]

Problem 25 Warm-up

The question relies upon the following joint pmf:

\(X = 0\) \(X = 1\)
\(Y = 1\) 0.1 0.2
\(Y = 2\) 0.3 0.4
  1. Calculate the conditional pmf of \(Y\) given that \(X = 0\).

    First, \(p_X(0) = 0.1 + 0.3 = 0.4\). Hence \(p_{Y|X}(1|0) = 0.1/0.4 = 1/4\) and \(p_{Y|X}(2|0) = 0.3/0.4 = 3/4\).

  2. Calculate the conditional pmf of \(X\) given that \(Y = 2\).

    First, \(p_Y(2) = 0.3 + 0.4 = 0.7\). Hence \(p_{X|Y}(0|2) = 0.3/0.7 = 3/7\) and \(p_{X|Y}(1|2) = 0.4/0.7 = 4/7\).

Problem 26 Standard

From a past Oxford demonstration lecture.

Consider the following bivariate probability mass function \(f(X, Y)\)

\(X=0\) \(X=2\) \(X=3\)
\(Y=0\) 1/36 1/18 1/12
\(Y=1\) 1/9 2/9 1/3
\(Y=2\) 1/36 1/18 1/12

what is

  1. the marginal PMF of \(X\)?

    Summing each column, \(f(X = 0) = 1/36 + 4/36 + 1/36 = 1/6\), \(f(X = 2) = 2/36 + 8/36 + 2/36 = 1/3\) and \(f(X = 3) = 3/36 + 12/36 + 3/36 = 1/2\). These sum to one, as they must.

  2. the marginal CDF of \(Y\)?

    Summing each row, \(f(Y = 0) = 1/6\), \(f(Y = 1) = 2/3\) and \(f(Y = 2) = 1/6\). Hence \[F(y) = \left\{ \begin{array}{ll} 0 & y < 0\\ 1/6 & 0 \leq y < 1\\ 5/6 & 1 \leq y < 2\\ 1 & y \geq 2 \end{array}\right.\]

  3. the conditional PMF of \(Y\): \(f(Y |X = 3)\)?

    Dividing the \(X = 3\) column by \(f(X = 3) = 1/2\) gives \(f(Y = 0|X = 3) = (1/12)/(1/2) = 1/6\), \(f(Y = 1|X = 3) = (1/3)/(1/2) = 2/3\) and \(f(Y = 2|X = 3) = 1/6\).

  4. the conditional CDF of \(X\): \(F(X|Y = 2)\)?

    Dividing the \(Y = 2\) row by \(f(Y = 2) = 1/6\) gives the conditional pmf \(f(X = 0|Y = 2) = 1/6\), \(f(X = 2|Y = 2) = 1/3\) and \(f(X = 3|Y = 2) = 1/2\). Hence \[F(x|Y = 2) = \left\{ \begin{array}{ll} 0 & x < 0\\ 1/6 & 0 \leq x < 2\\ 1/2 & 2 \leq x < 3\\ 1 & x \geq 3 \end{array}\right.\]

  5. Are \(X\) and \(Y\) independent?

    Yes. Every entry of the table equals the product of the corresponding marginal probabilities: for example \(f(X = 0, Y = 0) = 1/36 = 1/6 \times 1/6\) and \(f(X = 3, Y = 1) = 1/3 = 1/2 \times 2/3\), and the same holds for the other seven cells. Consistent with this, the conditional pmfs found in parts (c) and (d) equal the corresponding marginal pmfs.