Introduction to Probability & Statistics
Assignment 4, 2025/26
Submit your answers to the four questions marked Hand-in. You should upload your solutions to the VLE as a single pdf file. Marks will be awarded for clear, logical explanations, as well as for correctness of solutions.
Solutions to questions marked have been released at the same time as this assignment, in case you want to check your answers or need a hint.
You should also look at the other questions in preparation for your Week 9 seminar.
Starters
These questions should help you to gain confidence with the basics.
S1. Let \(X\) be a random variable with \(\mathbb{E}\left[X\right]=5\). What is the expectation of \(3X+5\)? If furthermore \(\mathbb{E}\left[X^2\right]=30\), what is the variance of \(X\)?
S2. I arrive at the train station at 12.00 exactly. My train departs at a time which follows a (continuous) uniform distribution on the interval [11.55, 12.15]. What is the probability that I miss my train?
S3. Hand-in
Buses leave campus for the train station every 20 minutes, at 5, 25, and 45 minutes past the hour. If a student arrives at the bus stop at a time that follows a (continuous) uniform distribution on the interval between 09.00 and 09.35, find the probability that they wait
- less than 5 minutes for a bus;
- at least 10 minutes for a bus.
S4. Suppose that you have a lecture at 14.00, and that the time taken to travel from your room to the lecture theatre is normally distributed with mean 30 minutes and standard deviation 4 minutes. What is the latest time you should leave your room if you want to be 99% certain that you will not miss the start of the lecture? (Hint: if \(Z\sim\mbox{\textup{N}}(0,1)\) then the R function qnorm(p) returns the value \(z\in\mathbb{R}\) such that \(\mathbb{P}\left(Z\le z\right) = p\).)
S5. Give an example of a joint probability table for two discrete random variables \(X\) and \(Y\), each having only two possible values, so that \(F_{X,Y}(5,6)=0.4, F_X(5)=0.5, F_Y(6)=0.6\) and \(\mathbb{E}\left[X\right]=10, \mathbb{E}\left[Y\right]=4\).
S6. Let \(X:\Omega\to\{1,2\}\) and \(Y:\Omega\to\{0,1\}\) be two discrete random variables. The following is a partial table of their joint and their marginal mass functions:
| \(y\backslash x\) | 1 | 2 | \(p_Y(y)\) |
|---|---|---|---|
| 0 | \(1/6\) | \(1/2\) | |
| 1 | |||
| \(p_X(x)\) | \(5/12\) | \(1\) |
- Fill in the missing values.
- Determine the joint distribution function of \(X\) and \(Y\).
- Calculate \(\mathbb{E}\left[X\right]\) and \(\mathbb{E}\left[Y\right]\).
- Let \(Z = XY\). Calculate \(\mathbb{E}\left[Z\right]\).
S7. Hand-in
Let \(X:\Omega\to\{0,1\}\) and \(Y:\Omega\to\{0,1\}\) be two discrete random variables. The following is a partial table of their joint and their marginal mass functions:
| \(y\backslash x\) | 0 | 1 | \(p_Y(y)\) |
|---|---|---|---|
| 0 | \(1/8\) | \(1/4\) | |
| 1 | \(1/2\) | ||
| \(p_X(x)\) |
- Fill in the missing values.
- Calculate \(\mathbb{E}\left[XY\right]\).
Mains
These are important, and cover some of the most substantial parts of the course.
M1. A random variable \(W\) has probability density function \[ f_W(x) = \begin{cases} \frac{6}{5675}(5x^2+3x+11)& \qquad \text{for } 3\leq x\leq 8\\ 0& \qquad \text{otherwise.} \end{cases} \] Would you expect \(\mathbb{E}\left[W\right]\) to lie closer to 3 or to 8? Calculate \(\mathbb{E}\left[W\right]\) and check whether your intuition was correct.
M2. Let \(X\sim\mbox{\textup{Geom}}(p)\). Calculate \(\mathbb{E}\left[h(X)\right]\), where \(h(x) = e^{tx}\) for some \(t>0\). For what values of \(t\) is \(\mathbb{E}\left[h(X)\right]<\infty\)?
M3. Hand-in
Show that if \(Z\) is a standard normal random variable then, for \(x>0\),
- \(\mathbb{P}\left(Z>x\right)=\mathbb{P}\left(Z<-x\right)\);
- \(\mathbb{P}\left(|Z|>x\right)=2\mathbb{P}\left(Z>x\right)\);
- \(\mathbb{P}\left(|Z|<x\right)=2\mathbb{P}\left(Z<x\right)-1\).
Hint: for part (a), express the probabilities in terms of integrals over the density function \(\phi\), and use the fact that \(\phi\) is an even function (i.e. \(\phi(z) = \phi(-z)\)).
M4. Hand-in
Let \(X\sim\mbox{\textup{Exp}}(\lambda)\). Use proof by induction to show that \[
\mathbb{E}\left[X^m\right]=\frac{m!}{\lambda^m} \qquad \text{for all $m\in\mathbb{N}\cup\{0\}$.}
\]
M5. Let \(X\) and \(Y\) be random variables. Show that \(\textup{Cov}\left(X,Y\right)=\mathbb{E}\left[XY\right]-\mathbb{E}\left[X\right]\mathbb{E}\left[Y\right]\).
M6. The joint probability mass function \(p_{X,Y}(x,y)\) of two random variables \(X\) and \(Y\) is summarised by the following table, where \(\eta\) is some real number:
| \(x\backslash y\) | -1 | 0 | 1 |
|---|---|---|---|
| 4 | \(\eta-1/16\) | \(1/4-\eta\) | \(0\) |
| 5 | \(1/8\) | \(3/16\) | \(1/8\) |
| 6 | \(\eta+1/16\) | \(1/16\) | \(1/4-\eta\) |
Extend the table by including also the marginal probabilities, i.e., the values of the probability mass functions \(p_X\) and \(p_Y\).
Which are the valid choices for \(\eta\)?
Is there a value of \(\eta\) for which \(X\) and \(Y\) are independent?
M7. A married couple decide to have children until they have at least one child of each sex: let \(X\) denote the total number of children that they have. The probability of any one child being a boy is \(1/2\) (with the sex of each child being independent of all the others).
What is the mass function of \(X\)? (I.e. write down \(\mathbb{P}\left(X=n\right)\) for all \(n\in \mathbb{N}\).)
Show that \[ \mathbb{E}\left[X\right] = 3 \,. \] Hint: you may find it useful to refer to the result from lectures that if \(Y\sim\mbox{\textup{Geom}}(p)\) then \(\mathbb{E}\left[Y\right] = 1/p\).
M8. Let \(X\) be a discrete random variable. Show that for all functions \(h_{1},h_{2}:\mathbb{R}\rightarrow \mathbb{R}\), \[ \mathbb{E}\left[h_1(X) + h_2(X)\right] =\mathbb{E}\left[h_1(X)\right] + \mathbb{E}\left[h_2(X)\right]\,. \]
M9. Let \(X\) and \(Y\) be random variables and let \(r,s,t,u\in\mathbb{R}\). Show that \[ \rho(rX+s,tY+u)=\begin{cases}\rho(X,Y)&\text{ if }rt>0\\ 0&\text{ if }rt= 0\\-\rho(X,Y)&\text{ if }rt<0\\\end{cases} \] where \(\rho(X,Y)\) denotes the correlation coefficient of \(X\) and \(Y\).
Desserts
Still hungry for more? Try these if you want to push yourself further. (These are mostly harder than I’d expect you to answer in an exam, or involve non-examinable material.)
D1. Prove that binomial coefficients satisfy the identity \[n{{n-1}\choose{r-1}} = r{n\choose r}.\] Use this to find \(\mathbb{E}\left[X\right]\) and \(\textup{Var}\left(X\right)\), where \(X\sim\mbox{\textup{Bin}}(n,p)\).
D2. Let \(X\sim \mbox{\textup{Uniform}}(0,a)\) for some \(a>0\). Show that for any \(n\in\mathbb{N}\), \[ \mathbb{E}\left[X^n\right] =\frac{a^n}{n+1}. \] Use this to determine \(\rho(X,X^2)\), and show that this does not depend upon the value of \(a\).
D3. A bag contains 3 cubes, 4 pyramids and 7 spheres. An object is drawn randomly from the bag and its type is recorded. Then the object is replaced. This is repeated 20 times.
Let \(C_i\) be the indicator random variable for the event that the \(i\)-th draw gives a cube, for \(i=1,\dots,20\). Calculate \(\mathbb{E}\left[C_i\right], \mathbb{E}\left[C_i^2\right]\) and \(\mathbb{E}\left[C_iC_j\right]\) for \(i\neq j\).
Let \(C\) be the number of times a cube was drawn, Use that \(C=\sum_{i=1}^{20}C_i\) to calculate \(\mathbb{E}\left[C\right]\) and \(\textup{Var}\left(C\right)\).
Let \(S_i\) be the indicator random variable for the event that the \(i\)-th draw gives a sphere. Calculate \(\mathbb{E}\left[C_iS_i\right]\) and \(\mathbb{E}\left[C_iS_j\right]\) for \(i\neq j\).
Let \(S\) be the number of times a sphere was drawn. Use the above results to calculate \(\mathbb{E}\left[CS\right]\), \(\textup{Cov}\left(C,S\right)\), \(\rho(C,S)\).
D4. Consider a random variable \(X\sim\mbox{\textup{Uniform}}[a,b]\), where \(a\) and \(b\) are unknown. You are told that \[ \mathbb{P}\left(X<2\right) = 1/3 \quad \text{and} \quad \mathbb{P}\left(1<X\leq 3\right) = 1/2 \,. \] Given this information, find \(a\) and \(b\).
D5. Let \(X\) and \(Y\) be two independent geometrically distributed random variables with parameter \(p\), i.e., \(X\sim\mbox{\textup{Geom}}(p)\) and \(Y\sim\mbox{\textup{Geom}}(p)\). For any natural numbers \(i\) and \(n\) with \(i<n\) calculate the conditional probability \(\mathbb{P}\left(X=i\,|\,X+Y=n\right)\). Describe in words the meaning in terms of Bernoulli trials of what you just calculated.
A stick of length 1 is snapped into two at a point \(U\sim\mbox{\textup{Uniform}}(0,1)\). What is the expected length of the piece containing the point \(s\), where \(s\) is some fixed number between 0 and 1? For what values of \(s\) is this expected length maximised/minimised? How does the variance of this length depend upon \(s\)?