probability-continuous.rst
changeset 18 c18d218b854e
parent 17 db3d7a44583b
equal deleted inserted replaced
17:db3d7a44583b 18:c18d218b854e
   467 
   467 
   468 .. math:: norm(μ_X + μ_Y, σ_X² + σ_Y²)
   468 .. math:: norm(μ_X + μ_Y, σ_X² + σ_Y²)
   469 
   469 
   470 https://en.wikipedia.org/wiki/Sum_of_normally_distributed_random_variables
   470 https://en.wikipedia.org/wiki/Sum_of_normally_distributed_random_variables
   471 
   471 
       
   472 Sum of random number of i.i.r.v.
       
   473 ================================
       
   474 
       
   475 Let :math:`Y = X_1+...+X_N` is a sum of r.v. :math:`N` and all :math:`X_i` are
       
   476 i.i.r.v. Thus:
       
   477 
       
   478 .. math:: E[Y] = E[N]·E[X]
       
   479 
       
   480 .. math:: var[Y] = E[N]·var(X) + var(N)·(E[N])²
       
   481 
       
   482 Proofs:
       
   483 
       
   484 .. math::
       
   485 
       
   486    E[Y] = E[∑_{i=1..N}\ X_i] = E[E[∑_{i=1..n}\ X_i |N=n]] = E[∑_{i=1..n}\ E[X_i|N=n]]
       
   487 
       
   488    = E[∑_{i=1..n}\ E[X]] = E[N·E[X]] = E[N]·E[X]
       
   489 
       
   490 .. math::
       
   491 
       
   492    var[Y] = E[var(Y|N)] + var(E[Y|N]) = E[var(∑_{i=1..n}\ X_i |N=n)] + var(E[∑_{i=1..n}\ X_i |N=n])
       
   493 
       
   494    = E[N·var(X)] + var(N·E[X]) = E[N]·var(X) + var(N)·(E[X])²
       
   495