Math 300 , Spring 2004, Day 20, W, March 17 Hit reload ...

Continuing with Expectation handout:

If X and Y are independent, then E(X · Y) =  E(X) · E(Y)  Proof.

--#B, Day 19:  E(X(X-1)) = E(X2-X) =E(X2)-E(X)   Then  E(X2) = E(X(X-1)) + E(X)
--E(X(X-1)) for Geometric dist. will give us a way to get the variance.

               x|   1          2          3           4            5                   n  
          P(x)|    p         qp       q2p        q3p        q4p              qn-1p
       x P(x)|   1p       2qp     3q2p      4q3p      5q4p             nqn-1
x(x-1)P(x)| 1·0p   2·1qp   3·2q2p   4·3q3p    5·4q4p     n(n-1)qn-1p

E(X) = Sumn=1 to inf. ( nqn-1p) =  1p + 2qp + 3q2p + 4q3p  + 5q4p +....+ nqn-1p + ....
        =                   p(1+ 2q + 3q2 + 4q3 + 5q4 +...+ nqn-1 + ..) =
        = p[deriv of (1+q+ q2 +  q3 +   q4  +  q5 +...+  qn. .)]   = p[deriv of (1/(1-q))] = ....= 1/p
 E(X(X-1)) =  Sumn=1 to inf. ( n(n-1)qn-1p) =  1·0p + 2·1qp + 3·2q2p + 4·3q3p + 5·4q4p +...   n(n-1)qn-1p +...
        =              qp(                 2·1 + 3·2q1 + 4·3q2 + 5·4q3 +... n(n-1)qn-2 +...)
        = qp[ 2nd deriv. of (1+q+ q2 +  q3 +      q4  +     q5 +........+  qn. .)]
        = qp[ 2nd deriv. of  (1/(1-q))] = qp[2(1-q)-3] and simplify to 2q/p2  .
     

VarX = E(X2) - (E(X))2      E(X2) = VarX + (E(X))2
Covariance:
 Cov(X, Y) = E[(X-E(X)) · (Y-E(Y))] (def.)    =  E(X · Y) - E(X) · E(Y)  (proof ok?)
    Var(X+Y) = Var(X) + Var(Y) + 2Cov(X, Y)    (a cov term for every pair, if summing more than 2)
         If X and Y are independent, Cov(X,Y) = 0, and we get our familiar Var sum.
  
 Var(X+Y) = E[(X-µx) + (Y-µy )]2 =  relabeling for clarity
                     E [  (a )        +   ( b )     ]2 = E(a2 + 2ab + b2) = var(X) + 2 cov(X,Y) + var(Y)
For Var(X+Y+Z) we have 3 terms,  c = (Z -µz),   E[a + b + c]2, get E( a2 + 2ab + b2+ 2ac + 2bc +c2)
   reorganized  = var(X)  + var(Y) + var(Z)+ 2 cov(X,Y)+  2 cov(X,Z)+ 2 cov(Y,Z) . 3 cross products.  3C2 pairs from (a,b,c)
For 4 variables, 4C2 cross products.

Variance of Hypergeometric, with handout, still to do..

HW: Variances
p. 233  #10

A. Show how to find Var(X) if you know E(X(X-1)) and E(X). (Hint: use (3), p.225, the results from problem B on Day19 (above), and simple algebra.)
B.  Find E(X(X-1)) for the Poisson distribution.    (Make a table: the beginning is shown on the bottom of the Algebra handout.
 Then you can use the trick on p. 76)  Then what will you do for the variance? 

#19a Var for geometric = q/p2. I'll do it a little different from Ash.  E(X(X-1) is begun above, then use #A
# 19b Var for neg. binomial.  Use the fact that Var of geometric is q/p2, and the "trick" of p. 82 of looking at the neg. binomial as the sum of k independent geometric random variables.  (You may do it for k = 3, as p. 82 does.)

HW:Covariances,  Ash p. 233
A.  Cov(X,Y) = 0 does not imply that X and Y are independent.  Show this is true using this example:
     x,y pair:  (0,3)     (1,1)     (2,3)      Graph, find Cov, Show X & Y dependent.
     prob:       1/4       1/2        1/4
#8 converses (Note that if E(XY) = E(X)E(Y),  then. Cov(X,Y) = 0.  Use this & your results from p.223#14)
#13, #14 (finding Covariances by brute force)

B.  To find Var(X+Y+Z+W), we need to find [a + b + c +d]2 .  I said there are 4C2 cross product terms.  Here's another way if you don't like binomial coefficients:  
  Fill in the "times table". Note the downward diagonal has the squared terms.  Every entry above the diagonal has its mate below the diagonal; just reflect across the diagonal (ac goes with ca, etc.). So the cross products are the entries below the diagonal.  How many?  Total number of entries is 42.
Subtract the number of diagonal (the squared) terms.  42- 4. 
42- 4 = 4(4-1).
These are the cross products above and below the diagonal; since ac = ca, divide by 2 to get the number of different cross products.
Dividing by 2 gives 4(4-1)/2 = 4C2.
   a  b  c  d
a |
b |
c |
d |

Convince yourself the same argument works for n terms, Var(X1 +...+Xn);
   (a1 +...+an).


Sievers home  Math300-Sp04/Dayp20.htm  7:30pm 3/16/04
This page belongs to Sally Sievers who is solely responsible for its content. Please see our statement of responsibility.