Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

If $x_i$ is exponentially distributed $(i=1,...,n)$ with parameter $\lambda$ and $x_i$'s are mutually independent, what is the expectation of

$\left(\sum_{i=1}^n {x_i} \right)^2$

in terms of $n$ and $\lambda$ and possibly other constants?

Note: This question has gotten a statistical answer on The readers would take a look at it too.

share|cite|improve this question
Let $Z = \sum_{i=1}^{n} x_i$. Then it seems that you are asking for $E(Z^2)$. I think $Z$ has a hypo-exponential distribution. Here: – PEV Nov 27 '10 at 15:03
@PEV $Z$ has a Gamma distribution as noted in the answer on stats.SE. – Dilip Sarwate Jul 2 '12 at 15:59
up vote 6 down vote accepted

In what follows, $x_j$ are assumed to be independent.

$$ E[x_0^2] = \int_0^{\infty} \lambda t^2 e^{-\lambda t} dt = \frac{2}{\lambda^2} $$

$$ E[x_0 x_1] = \int_0^{\infty} \int_0^{\infty} \lambda^2 t_0 t_1 e^{-\lambda t_0} e^{-\lambda t_1 } dt_0 dt_1 = \frac{1}{\lambda^2} $$

$$ E[ (\sum_{j=0}^{n-1} x_j)^2 ] = n E[ x_0^2] + n(n-1) E[x_0 x_1] = \frac{ n^2 + n }{ \lambda^2 } $$

share|cite|improve this answer
The same question i've post on got a simpler answer. I decided to delete this question, but is this answer wrong? what is the difference between them? – Isaac Nov 27 '10 at 17:19
There is no difference. Both get the exact same answer. – user4143 Nov 27 '10 at 17:46
@user4143: I like your neat answer which doesn't need much statistical background. Would you mind to resubmit this answer at this question ? And as suggestion, please register to math.stackexchanges! we need you! ;) – Isaac Nov 27 '10 at 22:31

This problem is just a special case of the much more general problem of 'moments of moments' which are usually defined in terms of power sum notation. In particular, in power sum notation:

$$s_1 = \sum_{i=1}^{n} X_i$$

Then, irrespective of the distribution, the original poster seeks $E[s_1^2]$ (provided the moments exist). Since the expectations operator is just the 1st Raw Moment, the solution is given in the mathStatica software by:

[ The '___ToRaw' means that we want the solution presented in terms of raw moments of the population (rather than say central moments or cumulants). ]

Finally, if $X$ ~ Exponential($\lambda$) with pdf $f(x)$:

f = Exp[-x/λ]/λ;      domain[f] = {x, 0, ∞} && {λ > 0};

then we can replace the moments $\mu_i$ in the general solution sol with the actual values for an Exponential random variable, like so:

All done.

P.S. The reason the other solution posted here yields an answer with $\lambda^2$ in the denominator rather than the numerator is, of course, because it is using a different parameterisation of the Exponential distribution. Since the OP didn't state which version he was using, I decided to use the standard distribution theory textbook definition Johnson Kotz et al … just to balance things out :)

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.