# What is the formula of the expected value of a geometric random variable?

##### 2 Answers

If you have a geometric distribution with parameter

#### Explanation:

expected value

For example, if

hope that helped

#### Explanation:

Where

Note that

So, the expected value is given by the sum of all the possible trials occurring:

#E(X)=sum_(k=1)^ook(1-p)^(k-1)p#

#color(white)(E(X))=psum_(k=1)^ook(1-p)^(k-1)#

#color(white)(E(X))=p(1+2(1-p)+3(1-p)^2+4(1-p)^3+cdots)#

In my view, the previous step and the following step are the trickiest bits of algebra in this whole process. Pay close attention to how the

#color(white)(E(X))=p(sum_(k=1)^oo(1-p)^(k-1)+sum_(k=2)^oo(1-p)^(k-1)+sum_(k=3)^oo(1-p)^(k-1)+cdots)#

Note that

#color(white)(E(X))=p(1/(1-(1-p))+(1-p)/(1-(1-p))+(1-p)^2/(1-(1-p))+cdots)#

#color(white)(E(X))=1+(1-p)+(1-p)^2+cdots#

Which is another geometric series:

#color(white)(E(X))=1/(1-(1-p))#

#color(white)(E(X))=1/p#

So, the expected number of trials is