Foundations, independence and counting
MATH40005 Probability and Statistics Resit Preparation
Question 1
1(a). Define a probability measure on a measurable space (Ω, F). (3 marks)
1(b). Prove that if events A and B are independent, then Ac and Bc are independent. (3 marks)
1(c). How many ordered quadruples of positive integers sum to 12? State the general formula for a sum
k of n positive integers. (4 marks)
1(d)(i). Prove algebraically that n3n−1 = Pn
k=0
n
k
2k(n − k). (4 marks)
1(d)(ii). Give a story proof of the same identity. (4 marks)
1(e). State why pairwise independence is weaker than mutual independence. (2 marks)
T otal: 20 marks
12
Worked solution and marking guidance
MATH40005 Probability and Statistics Resit Preparation
Question 1: solution and marking guide
1(a). A map P : F → [0, 1] such that P (Ω) = 1 , P (A) ≥ 0, and for pairwise disjoint Ai, P (∪iAi) =P
i P (Ai).
3 marks; A:3
1(b). Using inclusion–exclusion and independence, P (Ac ∩ Bc) = 1 − P (A) − P (B) + P (A ∩ B) =
(1 − P (A))(1 − P (B)) = P (Ac)P (Bc).
3 marks; A:3
1(c). Stars and bars gives
11
3
= 165. In general the number is
k−1
n−1
for k ≥ n, and 0 otherwise.
4 marks; A:2, C:2
1(d)(i). From 3n = (2 + 1)n, differentiate with respect to the second variable or use n
n−1
k
=
n
k
(n − k):
n3n−1 = n Pn−1
k=0
n−1
k
2k = Pn
k=0
n
k
2k(n − k).
4 marks; B:4
1(d)(ii). Count assignments to n people with one distinguished “captain” and three choices for each
non-captain. Left: choose the captain in n ways and assign one of three choices to each other person.
Right: choose k people receiving one of two ordinary choices (
n
k
2k), then choose the captain from the
remaining n − k; all remaining non-captains receive the third choice. Sum over k.
4 marks; D:4
1(e). Pairwise independence checks only every pair. Mutual independence also requires all finite inter-
sections to factorise, including the three-way intersection; pairwise conditions do not imply this.
2 marks; C:2
Question total: 20 marks
14
PGF and compound Poisson
MATH40005 Probability and Statistics Resit Preparation
Question 2
2(a). Let X be geometric on {1, 2, . . .} with success probability p. Find its probability generating
function and domain. (6 marks)
2(b). Let N ∼ Poi(λ) and Y1, Y2, . . . be i.i.d., independent of N , with mean m and variance v. For
S = PN
i=1 Yi, find E[S] and Var(S), with justification. (10 marks)
2(c). For independent X ∼ Poi(λ) and Y ∼ Poi(µ), identify the conditional law of X given X + Y = n.
(4 marks)
T otal: 20 marks
13
Worked solution and marking guidance
MATH40005 Probability and Statistics Resit Preparation
Question 2: solution and marking guide
2(a). GX (s) = P
x≥1 sx(1 − p)x−1p = ps/[1 − (1 − p)s], valid for |(1 − p)s| < 1.
6 marks; A:2, B:1, C:3
2(b). Conditioning on N , E[S|N ] = N m and Var(S|N ) = N v. Thus E[S] = E[N ]m = λm. By total
variance, Var(S) = E[N v] + Var(N m) = λv + λm2 = λE[Y 2
1 ].
10 marks; A:4, B:4, D:2
2(c). It is Bin(n, λ/(λ + µ)), obtained by dividing the product Poisson pmf by the Poisson (λ + µ) pmf
of the sum.
4 marks; A:2, D:2
Question total: 20 marks
15
Estimation and probability inequalities
MATH40005 Probability and Statistics Resit Preparation
Question 3
3(a). Let Xi be i.i.d. with mean θ and variance σ2. For T = (n + 2)−1 P Xi, find its bias, variance and
MSE as an estimator of θ. (6 marks)
3(b). An unknown Bernoulli proportion is estimated by the sample proportion. Find a sufficient sample
size to estimate it within 0.03 with confidence at least 0.95, uniformly over the proportion, using Cheby-
shev. (6
marks)
3(c). Give the frequentist interpretation of a realised 95% confidence interval. (3 marks)
3(d). Prove Markov’s inequality for a nonnegative random variable. (5 marks)
T otal: 20 marks
14
Worked solution and marking guidance
MATH40005 Probability and Statistics Resit Preparation
Question 3: solution and marking guide
3(a). E[T ] = nθ/(n + 2), so bias = −2θ/(n + 2). Variance = nσ2/(n + 2) 2. Hence MSE = (4 θ2 +
nσ2)/(n + 2)2.
6 marks; A:3, B:2, C:1
3(b). Var(ˆp) = p(1 − p)/n ≤ 1/(4n). Chebyshev gives P (|ˆp − p| ≥ 0.03) ≤ 1/[4n(0.03)2]. Require this at
most 0.05, so n ≥ 5555.56; take n = 5556.
6 marks; A:2, B:1, D:3
3(c). The parameter is fixed. The random interval procedure covers it in 95% of repeated samples
under the model. After observing the data, the interval either contains the parameter or it does not; the
frequentist statement is about the procedure, not a 95% probability for the fixed parameter.
3 marks; A:2, C:1
3(d). For a > 0, X ≥ a1{X≥a}. Taking expectations gives E[X] ≥ aP (X ≥ a), hence P (X ≥ a) ≤
E[X]/a.
5 marks; A:1, B:2, C:1, D:1
Question total: 20 marks
16
Bayesian updating and regression
MATH40005 Probability and Statistics Resit Preparation
Question 4
4(a). If Xi|θ iid∼ Exp(θ) and θ ∼ Γ(α, β) in rate parameterisation, find the posterior distribution. (5
marks)
4(b). Derive the least-squares estimates in yi = β0 + β1xi + ei. (6 marks)
4(c). In each risk group a drug has a lower disease rate than placebo, but the combined data show the
reverse. Name and explain the phenomenon. (3 marks)
4(d). Choose suitable plots for (i) a single continuous distribution, (ii) checking normality, and (iii) a
categorical frequency table. (3 marks)
4(e). State the two defining features of a nonparametric bootstrap sample and explain why duplicates
are allowed. (3 marks)
T otal: 20 marks
15
Worked solution and marking guidance
MATH40005 Probability and Statistics Resit Preparation
Question 4: solution and marking guide
4(a). The likelihood is θne−θ ∑ xi. Multiplying by the prior kernel θα−1e−βθ gives θα+n−1e−(β+∑ xi)θ.
Thus θ|x ∼ Γ(α + n, β + P xi).
5 marks; B:2, D:3
4(b). Let R(b0, b1) = P
i(yi − b0 − b1xi)2. Differentiating gives
∂R
∂b0
= −2
X
i
(yi − b0 − b1xi) = 0 , ∂R
∂b1
= −2
X
i
xi(yi − b0 − b1xi) = 0 .
The first equation gives b0 = ¯y−b1 ¯x. Substitution into the second gives P
i(xi−¯x)(yi−¯y)−b1
P
i(xi−¯x)2 =
0. Thus
ˆβ1 = Sxy
Sxx
, ˆβ0 = ¯y − ˆβ1 ¯x.
When Sxx > 0, the quadratic RSS has positive-definite Hessian on the identifiable parameter directions,
so this stationary point is the global minimum.
6 marks; A:3, B:2, D:1
4(c). This is Simpson’s paradox. Unequal allocation across groups with different baseline risks can reverse
the aggregate comparison; conditioning on the confounding group restores the within-group direction.
3 marks; A:2, C:1
4(d). (i) Histogram or density plot; (ii) normal Q-Q plot; (iii) bar chart (or pie chart, though a bar chart
is usually clearer).
3 marks; A:2, B:1
4(e). It is sampled with replacement from the empirical distribution and has the same size as the
original sample. Replacement makes repeated values possible and reproduces sampling variability under
the empirical distribution.
3 marks; A:1, B:1, C:1
Question total: 20 marks
17