# Mean and variance of two stochastic variables combined

• April 9th 2010, 05:30 AM
Eva BSc
Mean and variance of two stochastic variables combined
Hi,

I'm stuck with a little problem that I need to use for my research.

Let X and N be stochastic random variables. I need to show that:

Mean:
E(sum(X)) = E(N) * E(X)

Variance:
var(sum(X)) = E(N) * var(X) + var(N) * (E(X))^2

Anyone knowing to do this?

Cheers, Eva
• April 9th 2010, 08:16 AM
Anonymous1
Quote:

Originally Posted by Eva BSc
Mean:
E(sum(X)) = E(N) * E(X)

When $N=n, \ \ S = \sum_i X_i$ has $E(S)=nE(X_i)$

Breaking things down according to the value of $N,$ we have...

$E[S] = \sum_{n=0}^{\infty} E(S|N=n)P(N=n) = \sum_{n=0}^{\infty} nE(X_i)P(N=n) = E(N)E(X_i)$
• April 9th 2010, 08:27 AM
Anonymous1
Quote:

Originally Posted by Eva BSc
Variance:
var(sum(X)) = E(N) * var(X) + var(N) * (E(X))^2

When $N=n, \ \ S = \sum_i X_i$ has $Var(S) = nVar(X_i)$ and hence,

$E(S^2|N=n)= nVar(X_i) + (nE(X_i))^2$

Then,

$E[S^2] = \sum_{n=0}^{\infty} E(S^2|N=n)P(N=n) =$ $\sum_{n=0}^{\infty} \{nVar(X_i) + n^2 (E(X_i))^2 \}P(N=n) = E(N)Var(X_i) + E(N^2) (E(X_i))^2$

So,

$Var(S) = E(S^2) - (E(S))^2 =$ $E(N)Var(X_i) + E(N^2)(E(X_i))^2 - (E(N)E(X_i))^2 = E(N)Var(X_i) + Var(N)(E(X_i))^2$
• April 9th 2010, 08:30 AM
Eva BSc
Thnx!
• April 9th 2010, 08:30 AM
Anonymous1
I had to prove this in my homework a while back. (Nerd)
• April 9th 2010, 08:38 AM
cgiulz
I've used this fact before, but never seen its proof. Thanks!
• April 10th 2010, 03:30 AM
Moo
• April 10th 2010, 12:26 PM
Anonymous1
Just to confirm, my instructor verified that the proof above is valid and correct...