Extra Practice: Class 3
Probability III
These extra practice problems for Class 3 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.
Expected value
Problem 1 Warm-up
Let \(X\) be a discrete RV and \(a, b\) be constants. Prove that \(E[a + bX] = a + bE[X]\).
Problem 2 Warm-up
Let \(X\) be a Uniform\((a,b)\) RV. Calculate \(E[X]\)
Problem 3 Warm-up
Let \(X\) be a RV with support set \(\left\{ -1,1 \right\}\) and \(p(-1) = 1/2\).
Calculate \(E[X]\).
Write out the CDF \(F(x_0)\) of \(X\).
Calculate \(E[X^2]\).
Calculate \(Var(X)\).
Calculate \(\displaystyle E\left[ \frac{X}{X^2 + 1} \right]\)
Problem 4 Warm-up
Suppose that \(X \sim \text{Binomial}(9, 1/3)\) and \(Y \sim \text{Binomial}(4, 1/2)\). Calculate \(E[(Y - X) / 2]\).
Problem 5 Standard
Suppose \(X \sim \text{Uniform}(0,1)\) and let \(A\) be the area of a circle with radius equal to \(X\). Recall that the area of a circle with radius \(r\) is \(\pi r^2\).
Calculate \(E[X]\).
Calculate \(E[A]\).
Suppose I constructed a circle with radius equal to \(E[X]\). Would its area equal \(E[A]\)? Why or why not? Explain briefly.
Calculate \(Var(A)\). You may leave your answer in terms of \(\pi\).
Problem 6 Standard
From my HT 2022 probability collection.
To answer this question you will need to refer to the following joint pmf:
| \(Y = 1\) | \(Y = 2\) | \(Y = 3\) | |
|---|---|---|---|
| \(X = 0\) | 0 | 0.2 | 0.4 |
| \(X = 1\) | 0.1 | 0.3 | 0 |
Are \(X\) and \(Y\) independent? Briefly explain why or why not.
Write out the marginal pmf of \(Y\) and use it to calculate \(E[Y^3]\).
Write out the marginal CDF of \(Y\).
Derive the conditional pmf of \(X\) given \(Y=2\).
Calculate the expected value of the ratio of \(X\) and \(Y\), namely \(E\left[\displaystyle\frac{X}{Y}\right]\).
Problem 7 Standard
Let \(X\) be a continuous RV with support set \([0, 1]\) and pdf \(f(x) = a + b x^2\) where \(a,b>0\).
Calculate the CDF of \(X\), \(F(x_0)\), in terms of \(a\) and \(b\).
Calculate \(E[X]\) in terms of \(a\) and \(b\).
Since \(a\) and \(b\) are positive, \(f(x)\geq 0\). This is one of the two conditions required to ensure that \(f(x)\) is a valid pdf. What is the other condition? What restriction must we place on \(a\) and \(b\) to ensure that the condition is satisfied?
Suppose \(E[X] = 3/5\). Solve for \(a\) and \(b\).
Problem 8 Standard
This question concerns a game played by rolling a fair, six-sided die with sides numbered 1–6. To play the game you roll the die once. Let \(x\) denote the number on the side that shows face-up. If \(x\) is even you win \(x\) dollars but if \(x\) is odd you win \(2x\) dollars.
Suppose you were to play this game an extremely large number of times. On average, how much would you win per play?
Your winnings in one play of this game can be viewed as the realization of a discrete random variable \(Z\). Calculate \(Var(Z)\).
For the rest of this question we change the rules of the game as follows: after rolling the die and observing \(x\) you are given the option to roll a second time. If you choose not to roll a second time, your winnings are calculated as before: \(x\) dollars if \(x\) is even and \(2x\) dollars if \(x\) is odd. If you do choose to roll again your winnings are calculated in the same way but based on whatever number comes up on your second roll. For example if your initial roll is 3 and you re-roll and get a 1 then you win 2 dollars. If you want to maximize your average winnings over a large number of plays of this modified game, then you should choose to roll a second time if and only if your first roll is a 1, 2, or 4. Briefly explain why.
Problem 9 Harder
The “Moment Generating Function” of a random variable \(X\) is defined as \(M_X(t) = E[e^{tX}]\) where \(t\) is a constant. Don’t let the constant \(t\) confuse you: this is simply the expected value of a function \(g\) of \(X\), namely \(g(x) = e^{tx}\).
Suppose that \(X\) is a discrete RV. Use the general formula for \(E[g(X)]\) to express \(M_X(t)\) as a sum involving the pmf \(p(x)\) of \(X\).
Suppose that \(X\) is a continuous RV. Use the general formula for \(E[g(X)]\) to express \(M_X(t)\) as an integral involving the pdf \(f(x)\) of \(X\).
Use your answer to part (a) to calculate the moment generating function of the Bernoulli\((p)\) random variable.
Use your answer to part (b) to calculate the moment generating function of the Uniform\((0,1)\) random variable.
Problem 10 Harder
You are about to bid on a poster autographed by the cast of The Jersey Shore. This is a one-of-a-kind item, not available in stores. The most you would be willing to pay is $500. In an ordinary auction, you could start with a low bid, say $10, and increase it only if someone outbid you. This auction, however, is a sealed bid auction. Each participant submits a single bid in a sealed envelope, so there is no way for you to know how much anyone else has bid. The highest bidder wins the auction and pays whatever bid she placed in her envelope; the losers pay nothing. Based on research you have carried out on other auctions of Jersey Shore memorabilia, you estimate that the probability \(p\) that you will win the auction as a function of your bid \(b\) is as follows: \[p(b) = \left\{ \begin{array}{ll} b/600 & b \leq 600\\ 1 & b > 600 \end{array}\right.\]
Suppose you want to maximize your expected payoff. Losing the auction gives you a payoff of $0; winning gives you a payoff of $500 minus your bid, i.e. your consumer surplus. How much should you bid, and what is the probability that you will win the auction? Be sure to check the second order condition.
Using what you know about expected value, briefly explain why someone might rationally decide not to follow the bidding strategy you derived in part (a).
Problem 11 Harder
An ancient artifact worth $100,000 fell out of Indiana Jones’s airplane and landed in the Florida Everglades. Unless he finds it within a day, it will sink to the bottom and be lost forever. Dr. Jones can hire one or more helicopters to search the Everglades. Each helicopter charges $1,000 per day and has a probability of 0.9 of finding the artifact, independently of the others. If Dr. Jones wants to maximize his expected value, how many helicopters should he hire?
Problem 12 Challenge
I have an urn that contains two red balls and three blue balls. I offer you the chance to play the following game. You draw one ball at a time from the urn. Draws are made at random and without replacement. You win $1 for each red ball that you draw, but lose $1 for each blue ball that you draw. You are allowed to stop the game at any point. Find a strategy that ensures your expected value from playing this game is positive.
Problem 13 Challenge
From my HT 2024 probability collection.
Sam and Caroline have $100 and need to make big returns fast. Elon offers them the chance to play the following game. First Sam and Caroline must choose the fraction \(\varphi\) of the $100 that they want to bet. This can be any real number between \(0\) and \(1\) inclusive, so they can bet nothing, everything, or anything in between. Then Elon makes a random draw \(X_1\) with probability density function \(f(x) = 2x\) for \(x \in [0,1]\), zero otherwise. If \(X_1 > 1/2\), Sam and Caroline win: they keep their initial $100 and Elon gives them an additional \(\varphi \times \$100\). If \(X_1 \leq 1/2\), Sam and Caroline lose: they have to pay \(\varphi\times \$100\) to Elon. The game then proceeds to round two: Elon makes a second random draw \(X_2\) that is independent of \(X_1\) but has the same pdf. The rules in round two are the same as before, except that Sam and Caroline now bet a fraction \(\varphi\) of however much money they have after round one. Depending on whether they win or lose in the first round, this could be more or less than $100. The game ends after round two. Note that the same value of \(\varphi\) is used in each round.
Calculate \(p \equiv \mathbb{P}(X_1 > 1/2) = \mathbb{P}(X_2 > 1/2)\).
Let \(R_1\) be a random variable that takes the value \(1\) if \(X_1 >1/2\) and \(0\) otherwise. Define \(R_2\) analogously for \(X_2\). Write down the probability mass function of the random variable \(S \equiv R_1 + R_2\).
Sam wants to choose \(\varphi = 1\) and risk everything in both rounds of the game. In expectation, how much money will Sam and Caroline have at the end of the game if they follow this plan?
Caroline thinks Sam is crazy: setting \(\varphi = 1\) means there’s a good chance they’ll go bust, ending up with $0 at the end of the game. Caroline proposes setting \(\varphi = 1/2\) instead. If they follow Caroline’s strategy, how much money will they have in expectation at the end of the game? What is the chance of going bust under Caroline’s strategy?
Let \(W(\varphi)\) be the amount of money that Sam and Caroline have at the end of the game as a function of the fraction \(\varphi\) that they choose to bet. It turns out that \(W(\varphi) = \$100 \times (1 + \varphi)^S (1 - \varphi)^{2 - S}\). Briefly explain why this is so, and then use this expression to show that \(\varphi = 1/2\) maximizes \(\mathbb{E}[\log W(\varphi)]\), where \(\log\) denotes the natural logarithm. You don’t have to check the second-order condition.
Variance
Problem 14 Warm-up
Prove the shortcut formula for variance: \(Var(X) = E[X^2] - \left( E[X] \right)^2\).
Problem 15 Warm-up
Suppose that \(X\) is a continuous random variable with probability density function \[f(x) = \left\{ \begin{array}{ll} 3x^2 & \text{for } 0 \leq x \leq 1\\ 0 & \text{elsewhere} \end{array}\right.\]
What is the support of \(X\)?
Given your answer to (a), why couldn’t the pdf be \(4x^2\) in this example?
Calculate the cumulative distribution function of \(X\).
Calculate \(E[X]\).
Calculate \(E[X^2]\).
Calculate \(Var(X)\).
Problem 16 Standard
Let \(X\) be a random variable that equals the total number of heads that you get over four tosses of a fair coin and define \(Y = 10X + 25\).
Write out the support set and probability mass function of \(X\).
Write out the cumulative distribution function of \(X\).
Calculate \(E[X]\).
Calculate \(E[X^2]\).
Calculate \(Var(X)\).
Calculate \(E[Y]\).
Calculate \(Var(Y)\).
Problem 17 Standard
From my HT 2022 probability collection.
Let \(X\) be a variable with support \([-1,1]\) and PDF \(f(x) = \displaystyle\frac{3}{4}(1 - x^2)\).
Show that \(E[X] = 0\).
Calculate \(\text{Var}(X)\).
Calculate the CDF of \(X\).
Problem 18 Standard
From my HT 2023 probability collection.
Let \(Y\) be a continuous random variable with support \([0,1]\) and pdf \(f(y) = C y^{3}(1-y)\).
Calculate the value of the constant \(C\) in the pdf of \(Y\).
Calculate the CDF of \(Y\).
Calculate the expected value of \(Y\).
Calculate the variance of \(Y\).
Problem 19 Standard
Let \(X, Y, Z\) be iid discrete RVs with support set \(\left\{-1,1 \right\}\) and probability mass function \(p(-1) = 1-p\), \(p(1) = p\). Define \(S = X + Y + Z\).
Calculate \(E[X]\).
Calculate the variance of \(Z\). How does it compare to that of a Bernoulli\((p)\) RV?
Calculate \(Var(S)\).
Calculate \(P(S = 1)\).
Problem 20 Standard
This question concerns the Beta\((a,b)\) random variable, a continuous random variable that the lectures do not cover. The Beta random variable has support \([0,1]\) and is defined by two parameters \(a\) and \(b\), both of which are greater than zero. Its pdf is given by the following expression: \[f(x) = \frac{x^{a-1} (1-x)^{b-1}}{B(a,b)}\] where \(B(a,b)\) is the so-called “Beta Function” evaluated at \((a,b)\).
The Beta\((2,2)\) random variable has pdf \(f(x) = 6x(1-x)\). Calculate its variance using the shortcut rule.
In order for \(f(x)\) to be a valid pdf, what must the formula for the Beta Function, \(B(a,b)\), be? You do not need to evaluate or simplify any integrals in your answer: simply give an expression for \(B(a,b)\).
What is the pdf of the Beta\((1,1)\) random variable?
Problem 21 Harder
Let \(X\) be a continuous RV with support set \([0,1]\) and pdf \(f(x) = \alpha x^{\alpha-1}\) where \(\alpha > 0\).
Calculate the CDF of \(X\).
Calculate \(E[X]\).
Calculate \(\text{Var}(X)\). You do not have to simplify your answer.
Covariance, correlation, and independence
Problem 22 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.
If \(Cov(X,Y) = 0\) then \(E[XY] = E[X]E[Y]\)
If \(X\) and \(Y\) are uncorrelated then \(Var(X-Y) = Var(X) - Var(Y)\)
The pdf \(f(x)\) of a continuous random variable \(X\) gives \(P(X=x)\).
For any random variable \(X\) and any function \(g\), \(E[g(X)]=g\left( E[X] \right)\).
Problem 23 Warm-up
Prove that \(Cov(X, Y + Z) = Cov(X,Y) + Cov(X,Z)\) where \(X, Y,\) and \(Z\) are three RVs.
Problem 24 Standard
Let \(X\) and \(Y\) be discrete random variables. Prove that if \(X\) and \(Y\) are independent, then \(Cov(X,Y) = 0\). Hint: write out the definition of covariance for two discrete RVs in terms of a double sum, and use independence to substitute \(p_{XY}(x,y) = p_X(x)p_Y(y)\).
Problem 25 Standard
This question relies on the following joint pmf:
| \(Y = -1\) | \(Y = 0\) | \(Y = 1\) | |
|---|---|---|---|
| \(X = 0\) | 1/9 | 1/9 | 0 |
| \(X = 1\) | 2/9 | 1/9 | 1/9 |
| \(X = 2\) | 0 | 1/9 | 2/9 |
Calculate \(p_Y(0)\).
Calculate \(p_{X|Y}(2|0)\).
Calculate \(E[XY]\).
Calculate \(Cov(X,Y)\)
Are \(X\) and \(Y\) independent? Why or why not?
Problem 26 Harder
Let \(X\) and \(Y\) be two random variables with covariance \(\sigma_{XY}\) and variances \(\sigma_{X}^2\) and \(\sigma_{Y}^2\) where \(E[X]=E[Y]=0\). Define \(\beta = \sigma_{XY}/\sigma_{X}^2\) and \(Z = Y - \beta X\).
Is \(\beta\) a random variable or a constant? Explain briefly.
Is \(Z\) a random variable or a constant? Explain briefly.
Calculate \(E[Z]\).
Calculate \(Cov(X,Z)\).
Problem 27 Challenge
Let \(Y\) and \(X\) be RVs. In this problem you will find the constants \(\beta_0\) and \(\beta_1\) that solve \[\min_{\beta_0, \beta_1} E[(Y - \beta_0 - \beta_1 X)^2].\] For the purposes of this question you may assume that expectation and differentiation can be interchanged, i.e. that \(\frac{∂}{∂ \theta} E[f(Z,\theta)] = E[\frac{∂}{∂ \theta} f(Z,\theta)]\). You do not have to check the second order condition.
Show that \(\beta_0 = E[Y] - \beta_1 E[X]\).
Using the preceding part, find \(\beta_1\).
Linear combinations
Problem 28 Warm-up
Let \(X\) and \(Y\) be two RVs with \(Var(X) = \sigma_X^2\), \(Var(Y) = \sigma_Y^2\) and \(Corr(X,Y)=\rho\).
Write down an expression for \(Var(X + Y)\) in terms of \(\sigma_X, \sigma_Y\) and \(\rho\).
Write down an expression for \(Var(X - Y)\) in terms of \(\sigma_X, \sigma_Y\) and \(\rho\).
Which is larger: \(Var(X + Y)\) or \(Var(X - Y)\)? Explain briefly.
Problem 29 Standard
Suppose that \(X \sim \text{Binomial}(n,p)\).
Explain how \(X\) can be defined in terms of Bernoulli\((p)\) RVs.
Using the preceding part, derive \(E[X]\).
Using the preceding part, derive \(Var(X)\).
Problem 30 Standard
Students applying for a job at a consulting firm are required to take two tests. For a given applicant, scores on the two tests can be viewed as random variables: \(X\) and \(Y\). From information on past applicants, we know that both tests have means equal to 50, and standard deviations equal to 10. The correlation between scores on the two tests is 0.62. Let \(Z = X + Y\) denote an applicant’s combined score.
Calculate \(E[Z]\)
Calculate \(Var(Z)\).
Only students whose combined score is at least 136 are hired. If \(Z\) is normally distributed, approximately what percentage of applicants will be hired?
Continuing under the assumption that \(Z\) is normally distributed, as in the preceding part, suppose the firm wanted to hire the top 16% of applicants. Approximately what cutoff should they use for each applicant’s combined score?
Problem 31 Standard
Let \(Y_1, Y_2, Y_3 \sim \text{ iid } N(0, \sigma^2 = 36)\) and define: \(\displaystyle Z = Y_1 + \frac{Y_2}{2} + \frac{Y_3}{3}\).
Calculate \(E[Z]\)
Calculate \(\text{Var}(Z)\)
What kind of random variable is \(Z\)? Specify the values of any and all parameters.
For what value of \(c\) is \(P(Z<c)\approx 0.975\)? Your answer should specify a numeric value.
Problem 32 Standard
Let \(Y_1, \dots, Y_7 \sim \text{iid } N(\mu = -3, \sigma^2 = 9)\).
Let \(X = 1 + Y_1/3\). What kind of random variable is \(X\)? You do not need to explain your answer, but be sure to specify any and all relevant parameters.
Let \(W = (Y_2 + Y_3 + Y_4 + Y_5 + Y_6 + Y_7)/6\). What kind of random variable is \(W\)? You do not need to explain your answer, but be sure to specify any and all relevant parameters.
What kind of random variable is \(X + W\)? You do not need to explain your answer, but be sure to specify any and all relevant parameters.
Problem 33 Standard
The random variables \(X_1\) and \(X_2\) correspond to the annual returns of Stock 1 and Stock 2. Suppose that \(E[X_1]=0.1\), \(E[X_2]=0.3\), \(Var(X_1) = Var(X_2) = 1\), and \(\rho=Corr(X_1, X_2)\). A portfolio \(\Pi(\omega)\) is defined by the proportion \(\omega\) of Stock # 1 that it contains. That is, \(\Pi(\omega) = \omega X_1 + (1-\omega) X_2\) where \(0\leq \omega \leq 1\).
What value of \(\omega\) gives a portfolio with expected return \(0.15\)?
Suppose that \(\omega = 1/4\). In terms of \(\rho\), what is the portfolio variance?
Again, suppose that \(\omega = 1/4\). What are the maximum and minimum values of the portfolio variance? What are the corresponding values of \(\rho\)?
If we assume that variance is a reasonable measure of risk, what does your answer to part (c) suggest about the benefits of constructing a portfolio rather than holding only one stock? Explain briefly.
Problem 34 Harder
Let \(X\) and \(Y\) be independent, normally distributed random variables representing the returns of two stocks such that \(\mu_x = \mu_y = 1\) and \(\sigma_x^2 = \sigma_y^2 = 2\). A portfolio \(\Pi(\omega)\) is a linear combination of the form \(\omega X + (1- \omega) Y\) where \(\omega \in [0,1]\) is the fraction of your total funds that are invested in \(X\).
If you wish to construct the portfolio with the lowest possible variance, what value of \(\omega\) should you choose? Prove your answer.
Calculate the expected value and the variance of the portfolio from the preceding part.
Approximately what is the probability that the minimum variance portfolio will make a negative return?
Conditional expectation
Problem 35 Standard
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 distribution: \[\begin{aligned} p_{XY}(1,0) &= 0.30\\ p_{XY}(1,1) &=0.25\\ p_{XY}(2,0) &=0.20\\ p_{XY}(2,1) &=0.25 \end{aligned}\]
Express the joint probability mass function (pmf) in a \(2\times 2\) table.
Using the table, calculate the marginal pmfs of \(X\) and \(Y\).
Calculate the conditional pmfs of \(Y|X=1\) and \(Y|X=2\).
Calculate \(E[Y|X=1]\) and \(E[Y|X=2]\).
Calculate the covariance between \(X\) and \(Y\).