You are on page 1of 2

1.

2 Lecture 2
1.2.1 Variance of a random variable

Denition 1.19. Let X be a r.v and we set = E(X). The variance is X is denoted by Var(X)
and
Var(X) := E((X )2 )
and the standard deviation of X is the square root of the variance.

Intuitively, the variance measures on average how much does the random variable deviate from
its expectation/mean.
Lemma 1.20. Given a random variable X then for any constant a, b R,

1. Var(X) = E(X 2 ) (E(X))2 .


2. Var(aX) = a2 Var(X)
3. Var(X + b) = Var(X)
4. Var(b) = 0

Proof. 1. We compute from denition and recall that E(X) =

Var(X) = E((X )2 )
= E(X 2 X + 2 )
(by linearity) = E(X 2 ) 2E(X) + 2
= E(X 2 ) 2 .

2. From denition

Var(aX) = E((aX a)2 )


(by linearity) = a2 E((X )2 )
= a2 Var(X).

3. We know that E(X + b) = + b, then from denition of the variance

Var(X + b) = E((X + b ( + b))2 )


= E((X )2 )
= Var(X).

4. We know that E(b) = b, which implies that Var(b) = E((b b)2 ) = 0.


Example 1.21. Suppose X is a random variable with density fX (x) = ex for x 0, then from

Var(X) = E(X 2 ) E(X)2


 
2 x
= x e dx ( xex dx)2
0 0

We need to use integration by parts



2
E(X ) = x2 ex dx
0


= x2 ex 0 + 2xex dx
0
= 2E(X)

5
We compute now E(X), by using integration by parts

E(X) = xex dx
0


= xex 0 + ex dx
0
=1
Therefore Var(X) = 2 1 = 1

1.2.2 Moment Generating Functions

We see that the variance is X is the second moment of X subtract the rst moment of X squared.
The moments of a random variable are very important objects and we shall introduce in the following
a method to obtain the moments of a random variable.
Denition 1.22. The moment generating function (mgf) of a r.v X is denoted by
MX (u) := E(euX )
and we say that the mgf of X exists if MX (u) is nite in some interval containing zero.
Remark 1.23. The moment generating function of X exists if there exists h > 0 such that the
MX (x) is nite for x [h, h].
Example 1.24. Let X be a r.v with density function fX (x) = ex for x > 0. Then the moment
generating function of X is

E(euX ) = eux ex dx
0

= e(u1)x dx
0
e(u1)x 
= 
u1 0
from which we see that 
1
1u u<1
E(euX ) =
u1
1
from which we can say that the mfg of X exists, since we can take a take h = 2 and the mgf of X
is nite on the interval [ 12 , 12 ].
Lemma 1.25. Suppose the moment generating function of a r.v X exists then
(r) dr
E(X r ) = lim MX (u) =: lim MX (u)
u0 u0 du

Proof. As almost always, we give only the proof for the continuous case. I give only a sketch proof,

dr dr
lim MX (u) = lim eux fX (x) dx
u0 du u0 du R
 r
dr
 d ux
(by magic , we interchange du and dx ) = lim e fX (x) dx
u0 R du

= lim xr eux fX (x) dx
u0 R
= lim E(X r euX )
u0
(by some more magic ) = E( lim X r euX ) = E(X r )
u0

You might also like