# Mean and variance of two stochastic variables combined

• Apr 9th 2010, 04: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
• Apr 9th 2010, 07:16 AM
Anonymous1
Quote:

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

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

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

$\displaystyle 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)$
• Apr 9th 2010, 07:27 AM
Anonymous1
Quote:

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

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

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

Then,

$\displaystyle E[S^2] = \sum_{n=0}^{\infty} E(S^2|N=n)P(N=n) =$ $\displaystyle \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,

$\displaystyle Var(S) = E(S^2) - (E(S))^2 =$ $\displaystyle 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$
• Apr 9th 2010, 07:30 AM
Eva BSc
Thnx!
• Apr 9th 2010, 07:30 AM
Anonymous1
I had to prove this in my homework a while back. (Nerd)
• Apr 9th 2010, 07:38 AM
cgiulz
I've used this fact before, but never seen its proof. Thanks!
• Apr 10th 2010, 02:30 AM
Moo
• Apr 10th 2010, 11:26 AM
Anonymous1
Just to confirm, my instructor verified that the proof above is valid and correct...