# Find the Mean for Non-Negative Integer-Valued Random Variable

Let $X$ be a non-negative integer-valued random variable with finite mean. Show that $$E(X)=\sum^\infty_{n=0}P(X>n)$$

This is the hint from my lecturer.

"Start with the definition $E(X)=\sum^\infty_{x=1}xP(X=x)$. Rewrite the series as double sum."

For my opinion. I think the double sum have the form of $\sum\sum f(x)$, but how to get this form? And how to continue?

• This is probably a duplicate. – Michael Hardy Jun 22 '14 at 18:34
• May I know the link? – karfai Jun 22 '14 at 18:35
• Let $p_i=\Pr(X=i)$. Our sum is $(p_1 + p_2+p_3+\cdots)+(p_2+p_3+\cdots)+(p_3+\cdots)+\dots$. Note $p_1$ appears once, $p_2$ appears twice, $p_3$ appears three times, and so on. – André Nicolas Jun 22 '14 at 18:41

The sum in the first row is $P(X>0)$; that in the second row is $P(X>1)$; that in the third row is $P(X>2)$, and so on.
you could also proof this using telescoping series: \begin{align*} \sum_{x=0}^\infty xP(X=x)&=\sum_{x=0}^\infty x(P(X>x-1)-P(X>x))\\ &=\sum_{x=0}^\infty xP(X>x-1)-\sum_{x=0}^\infty xP(X>x)\\ &= \sum_{x=1}^\infty xP(X>x-1)-\sum_{x=1}^\infty (x-1)P(X>x-1)\\ &=\sum_{x=1}^\infty (x-(x-1))P(X>x-1)\\ &=\sum_{x=1}^\infty P(X>x-1)\\ &=\sum_{x=0}^\infty P(X>x) \end{align*}
$\sum_{n=0}^{\infty}P(X>n)=\sum_{n=1}^{\infty}\sum_{x=n+1}^{\infty}P(X=x)=\sum_{x=0}^{\infty}\sum_{n=0}^{x-1}P(X=x)=\sum_{x=0}^{\infty}xP(X=x)=EX$
The interchange of the infinite sums is justified since $X$ has finite mean.