State the distribution and the convention it uses
X∼NB(2,31),x=2,3,4,… X counts the trials up to and including the 2th success, so the smallest value X can take is 2.
Write down the probability function with r=2, p=31 and 1−p=32
P(X=x)=(1x−1)(31)2(32)x−2 The xth trial is the 2th success, and exactly 1 of the first x−1 trials are successes.
Quote the mean of a negative binomial distribution
E(X)=pr=312=6 The wait to the 2th success is 2 independent geometric waits, so the mean is 2 times 1/p.
Quote the variance of a negative binomial distribution
Var(X)=p2r(1−p)=(31)22×32=12 The variances of the 2 independent geometric waits add.
Use the relationship between the second moment, the variance and the mean
E(X2)=Var(X)+[E(X)]2=12+(6)2=48 Rearranging Var(X)=E(X2)−[E(X)]2.
Check by direct summation: partial sum up to x=2
x=2∑2x2P(X=x)=94≈0.44444 The partial sums increase towards E(X2)=Var(X)+[E(X)]2=48, confirming the quoted variance (limit ≈48.00000).
Check by direct summation: partial sum up to x=3
x=2∑3x2P(X=x)=916≈1.77778 The partial sums increase towards E(X2)=Var(X)+[E(X)]2=48, confirming the quoted variance (limit ≈48.00000).
Check by direct summation: partial sum up to x=4
x=2∑4x2P(X=x)=27112≈4.14815 The partial sums increase towards E(X2)=Var(X)+[E(X)]2=48, confirming the quoted variance (limit ≈48.00000).
Check by direct summation: partial sum up to x=5
x=2∑5x2P(X=x)=2431808≈7.44033 The partial sums increase towards E(X2)=Var(X)+[E(X)]2=48, confirming the quoted variance (limit ≈48.00000).
Check by direct summation: partial sum up to x=6
x=2∑6x2P(X=x)=2432768≈11.39095 The partial sums increase towards E(X2)=Var(X)+[E(X)]2=48, confirming the quoted variance (limit ≈48.00000).
Check by direct summation: partial sum up to x=7
x=2∑7x2P(X=x)=72911440≈15.69273 The partial sums increase towards E(X2)=Var(X)+[E(X)]2=48, confirming the quoted variance (limit ≈48.00000).
Record the probability of failing on a single trial
1−p=1−31=32 Every failure contributes one factor of 1−p.
Record the convention used throughout
X=number of trials up to and including the required success The A-Level convention counts TRIALS, not failures, so the support never includes 0.
Recall the geometric probability function
P(X=x)=(1−p)x−1p,x=1,2,3,… There are x−1 failures followed by one success on the xth trial.
State the final answer
E(X2)=48 This is the exact value requested.