Variance of Geometric Distribution in terms of successes only

136 Views Asked by At

$$ Prove: var(X) = \frac{1-p}{p^2} $$

I solved for $$E[X^2]-E[X]^2$$

I did the following for $E(X)$

$$ E(X) = (\frac{1}{p}) $$

I did the following for $E(X^2)$

$$E(X^2)=\sum^\infty_n n^2p(1-p)^n$$

$$E(X^2)=p\sum^\infty_n n^2(1-p)^n$$

$$E(X^2)=p\left(\frac{p^2-3 p+2}{p^3}\right)$$

$$E(X^2)=\frac{p^2-3 p+2}{p^2}$$

I don't know where I make a mistake but when I solve it I end up with this instead: $$ V(X) = (\frac{p^2-5p+2p+1}{p^2}) $$

Where did I go wrong?

1

There are 1 best solutions below

5
On

For this version of the geometric distribution, the mean is $\frac{1-p}{p}$, not $\frac{1}{p}$. Correcting this in your work will lead you to the right expression for the variance.


If $E[X] = \sum_{n \ge 0} np(1-p)^n$, then $(1-p) E[X] = \sum_{n \ge 0} np(1-p)^{n+1} = \sum_{n \ge 1} (n-1) p(1-p)^n$ where the last equality is due to shifting the index $n$ by one. Thus, $$\begin{align} p E[X] &= E[X] - (1-p)E[X] \\ &= \sum_{n \ge 0}np(1-p)^n - \sum_{n \ge 1} (n-1) p (1-p)^n \\ &= \sum_{n \ge 1} p(1-p)^n \\ &= 1 - p. \end{align}$$