PS - Module 2 Aartyh
PS - Module 2 Aartyh
Aarthy B
Division of Mathematics,
School of Advanced Sciences,
Vellore Institute of Technology, Chennai.
February 4, 2024
Module 2
Overview
1 Introduction
2 Problems
4 Mathematical Expectation
5 Covariance
Introduction
0 ≤ pi ≤ 1
n
P
pi = 1
i=1
Module 2
Introduction
xi 0 1 2
P(X = Xi ) P1 0.3 0.5
To find the value of P1 = P(X = 0), we know that the sum of all
probabilities is equal to 1.
f (x) ≥ 0, x ∈ R
R∞
f (x)dx = 1
−∞
Module 2
Introduction
Since
R ∞ f is a probability density function, we must have that
−∞ f (x)dx = 1, implying that
Z 2
C (4x − 2x 2 )dx = 1
0
3
=⇒ C =
8
Module 2
Introduction
d
[FX (x)] = f (x)
dx
f (x) ≥ 0
R∞
−∞ f (x)dx = 1
R x2
x1 f (x)dx = P(x1 ≤ x ≤ x2 )
Module 2
Problems
Problem 1
Problem 2
A random variable X has the following probability distribution:
Module 2
Problems
Problem 2 Contd.
Module 2
Problems
Problem 3
A random variable X has the following probability distribution:
Module 2
Problems
Problem 3 Contd.
Module 2
Problems
Problem 3 Contd.
Module 2
Problems
Problem 4
Problem 4 Contd.
Module 2
Problems
Problem 5
Problem 5 Contd.
Module 2
Problems
Problem 5 Contd.
Module 2
Problems
Problem 6
Problem 6 Contd.
Module 2
Problems
Problem 6 Contd.
Module 2
Problems
Problem 7
Problem 7 Contd.
Module 2
Problems
Problem 7 Contd.
Module 2
Problems
Problem 8
If probability density function is
Module 2
Problems
Problem 8 Contd.
Module 2
Problems
Problem 9
Problem 9 Contd.
Module 2
Problems
Problem 9 Contd.
Module 2
Problems
Problem 10
If the probability density function of a random variable X is given
by
Module 2
Problems
Problem 10 Contd.
Module 2
Problems
Problem 11
Module 2
Problems
Problem 11 Contd.
Module 2
Problems
Problem 12
Module 2
Problems
Problem 12 Contd.
Module 2
Problems
Problem 12 Contd.
Module 2
Problems
Problem 12 Contd.
Module 2
Problems
Problem 13
Module 2
Problems
Problem 13 Contd.
Module 2
Problems
Problem 13 Contd.
Module 2
Problems
Problem 14
Module 2
Problems
Problem 14 Contd.
Module 2
Problems
Problem 15
Module 2
Problems
Problem 15 Contd.
Module 2
Problems
Problem 15 Contd.
Module 2
Problems
Problem 15 Contd.
Module 2
Problems
Problem 16
Module 2
Problems
Problem 16 Contd.
Module 2
Problems
Problem 16 Contd.
Module 2
Problems
Problem 16 Contd.
Module 2
Problems
Problem 17
Module 2
Problems
Problem 17 Contd.
Module 2
Problems
Problem 17 Contd.
Module 2
Problems
Problem 17 Contd.
Module 2
Problems
Problem 17 Contd.
Module 2
Joint probability distribution
Problem 1
Module 2
Joint probability distribution
Problem 1 Contd.
Module 2
Joint probability distribution
Problem 1 Contd.
Module 2
Joint probability distribution
Problem 2
Problem 2 Contd.
Solution:
Y /X 1 2 P(Y )
2 3 5
1 12 12 12
3 4 7
2 12 12 12
5 7
P(X ) 12 12 1
i) M.D.F of X :
Y /X 1 2
5 7
P(X ) 12 12
Module 2
Joint probability distribution
Problem 2 Contd.
M.D.F of Y :
Y P(Y )
5
1 12
7
2 12
X 1 2
2 3
P(X |Y = 1) 5 5
3 4
P(X |Y = 2) 7 7
Module 2
Joint probability distribution
Problem 2 Contd.
Y P(Y |X = 1) P(Y |X = 2)
2 3
1 5 5
3 4
2 7 7
iii) P(X + Y ≤ 3)
X +Y 2 3
2 6
P(X + Y ) 12 12
3
iv) P(X > Y ) = P(X = 2, Y = 1) = 12
Module 2
Joint probability distribution
Problem 3
Find k for the function f (x, y ) = k(1 − x)(1 − y ), if 0 ≤ x, y ≤ 1.
Solution:
Z1 Z1
f (x, y )dxdy = 1
0 0
Z1 Z1
=⇒ k(1 − x)(1 − y )dxdy = 1
0 0
Z1 Z1
=⇒ k (1 − y )dy (1 − x)dx = 1
0 0
Module 2
Joint probability distribution
Problem 3 Contd.
Z1
x 2 1
=⇒ k (1 − y )dy x − =1
2 0
0
Z1
k
=⇒ (1 − y )dy = 1
2
0
1
y2
=⇒ y− =1
2 0
k
=⇒ =1
4
=⇒ k = 4
Module 2
Joint probability distribution
Problem 4
Consider the function f (x, y ) = e −(x+y ) , if x ≥ 0, y ≥ 0. Find the
Marginal density about X and Y . Also, check whether X and Y
are independent.
Solution:
i) M.D.F of X :
Z∞
fX (x) = f (x, y )dy
0
Zy
fX (x) = e −(x+y ) dy
0
Module 2
Joint probability distribution
Problem 4 Contd.
Zy
fX (x) = e −x e −y dy
0
fX (x) = e −x
Similarly, M.D.F of Y is
fY (y ) = e −y
Module 2
Joint probability distribution
Problem 4 Contd.
ii)
fX (x) = e −x and fY (y ) = e −y
Problem 5
2 2
Consider the function f (x, y ) = kxye −(x +y ) , if x ≥ 0, y ≥ 0. Find
k, the Marginal density about X and Y and f (X |Y ). Also, check
whether X and Y are independent.
Solution:
Z∞ Z∞
i) f (x, y )dxdy = 1
0 0
Z∞ Z∞
2 +y 2 )
=⇒ kxye −(x dxdy = 1
0 0
Module 2
Joint probability distribution
Problem 5 Contd.
Z∞ Z∞
−y 2 2
=⇒ k ye dy xe −x dy = 1
0 0
Z∞ Z∞
k −y 2
=⇒ ye dy e −t dt = 1(Put x 2 = t)
2
0 0
Z∞
k 2
=⇒ ye −y dy = 1
2
0
k
=⇒ =1
4
=⇒ k = 4
Module 2
Joint probability distribution
Problem 5 Contd.
f (x, y )
ii) f (X |Y ) =
f (y )
Z∞
fY (y ) = f (x, y )dx
0
Z∞
−y 2 2
fY (y ) = 4ye xe −x dx
0
−y 2
=⇒ fY (y ) = 2ye
2
∴ f (X |Y ) = 2xe −x
Module 2
Joint probability distribution
Problem 5 Contd.
iii) Similar to fY (y ),
2
fX (x) = 2xe −x
2 +y 2 )
=⇒ fX (x) × fY (y ) = 4xye −(x = f (x, y )
Module 2
Joint probability distribution
Problem 6
Module 2
Joint probability distribution
Problem 6 Contd.
Module 2
Joint probability distribution
Problem 6 Contd.
Module 2
Joint probability distribution
Problem 6 Contd.
Module 2
Joint probability distribution
Problem 6 Contd.
Module 2
Joint probability distribution
Problem 7
Problem 7 Contd.
Module 2
Joint probability distribution
Problem 7 Contd.
Module 2
Joint probability distribution
Problem 8
Module 2
Joint probability distribution
Problem 8 Contd.
Module 2
Joint probability distribution
Problem 8 Contd.
Module 2
Joint probability distribution
Problem 9
Module 2
Joint probability distribution
Problem 9 Contd.
Module 2
Joint probability distribution
Problem 10
Problem 10 Contd.
Module 2
Joint probability distribution
Problem 10 Contd.
Module 2
Joint probability distribution
Problem 11
Problem 11 Contd.
Module 2
Joint probability distribution
Problem 11 Contd.
Module 2
Joint probability distribution
Problem 12
Y |X 1 2 3
1 1/12 1/6 0
2 0 1/9 1/5
3 1/18 1/4 2/15
Problem 12 Cond.
Solution:
Y |X 1 2 3 P(Y )
1 1/12 1/6 0 3/12
2 0 1/9 1/5 14/45
3 1/18 1/4 2/15 79/180
P(X ) 5/36 19/36 5/15 1
i) M.D.F of X :
X 1 2 3
P(X ) 5/36 19/36 5/15
Module 2
Joint probability distribution
Problem 12 Contd.
ii) Conditional probability of Y given X = 2
P(Y = y |X = 2)
P(Y |X = 2) =
P(X = 2)
P(Y = 1|X = 2) 6
i) =
P(X = 2) 19
P(Y = 2|X = 2) 4
ii) =
P(X = 2) 19
P(Y = 3|X = 2) 9
iii) =
P(X = 2) 19
Y 1 2 3
P(Y = y |X = 2) 6/19 4/19 9/19
Module 2
Joint probability distribution
Problem 12 Contd.
iii)
Problem 13
Y |X 1 2 3 4
1 1/20 1/20 1/10 1/10
2 1/10 1/10 1/10 1/10
3 1/10 1/10 1/20 1/20
Problem 13 contd.
Y |X 1 2 3 4 P(Y )
1 1/20 1/20 1/10 1/10 6/20
2 1/10 1/10 1/10 1/10 4/10
3 1/10 1/10 1/20 1/20 6/20
P(X ) 5/20 5/20 5/20 5/20 1
i)
P(Y = 2, X = 4)
P(Y = 2|X = 4) =
P(X = 4)
1/10
=
5/20
2
=
5
Module 2
Joint probability distribution
Problem 13 contd.
2
ii) P(Y = 2) = 5
iii)
1
P(X = 4, Y = 2) =
10
1 2
P(Y = 2) =
P(X = 4) =
4 5
1
=⇒ P(X = 4) × P(Y = 2) = = P(X = 4, Y = 2)
10
∴ X = 4 and Y = 2 are independent.
Module 2
Joint probability distribution
Problem 14
For the following Joint Probability Distribution of (X , Y ):
Y |X 1 2 3
1 0.1 0.1 0.2
2 0.2 0.3 0.1
Find
i) Marginal distribution.
ii) Conditional probability of X given Y = 1.
iii) P((X + Y ) < 4).
iv) F (2, 2).
v) F (3, 2).
vi) FX (3).
vii) FY (1).
Module 2
Joint probability distribution
Problem 14 contd.
i)
Y |X 1 2 3 P(Y )
1 0.1 0.1 0.2 0.4
2 0.2 0.3 0.1 0.6
P(X ) 0.3 0.4 0.3 1
Module 2
Joint probability distribution
Problem 14 contd.
ii) Conditional probability of X given Y = 1
P(X = x|Y = 1)
P(X |Y = 1) =
P(Y = 1)
P(X = 1|Y = 1) 1
i) =
P(Y = 1) 4
P(X = 2|Y = 1) 1
ii) =
P(Y = 1) 4
P(X = 3|Y = 1) 1
iii) =
P(Y = 1) 2
X 1 2 3
P(X = x|Y = 1) 1/4 1/4 1/2
Module 2
Joint probability distribution
Problem 14 contd.
iii)
iv)
F (2, 2) = P(X ≤ 2, Y ≤ 2)
= P(X = 1, Y = 1) + P(X = 1, Y = 2)
+ P(X = 2, Y = 1) + P(X = 2, Y = 2)
= 0.7
Module 2
Joint probability distribution
Problem 14 contd.
v)
F (3, 2) = P(X ≤ 3, Y ≤ 2)
= P(X = 1, Y = 1) + P(X = 1, Y = 2) + P(X = 1, Y = 3)
+ P(X = 2, Y = 1) + P(X = 2, Y = 2) + P(X = 2, Y = 3)
=1
vi)
FX (3) = P(X ≤ 3, Y = y )
=1
Module 2
Joint probability distribution
Problem 14 contd.
vii)
FY (1) = P(X ≤ x, Y = 1)
= 0.4
Module 2
Joint probability distribution
Problem 15
Problem 15 contd.
Y |X 0 1 P(Y )
0 2/9 1/9 3/9
1 1/9 5/9 6/9
P(X ) 3/9 6/9 1
i)
2
P(X = 0, Y = 0) =
9
3 3
P(X = 0) =
P(Y = 0) =
9 9
1
=⇒ P(X = 0) × P(Y = 0) = ̸= P(X = 0, Y = 0)
9
Module 2
Joint probability distribution
Problem 15 contd.
ii) Marginal distribution is given in the table.
iii) For joint distribution, find F (0, 0), F (0, 1), F (1, 0) and F (1, 1).
2
F (0, 0) = P(X ≤ 0, Y ≤ 0) =
9
3
F (0, 1) = P(X ≤ 0, Y ≤ 1) =
9
3
F (1, 0) = P(X ≤ 1, Y ≤ 0) =
9
F (1, 1) = P(X ≤ 1, Y ≤ 1) = 1
X ≤0 X ≤1
2 3
Y ≤0 9 9
3
Y ≤1 9 1
Module 2
Joint probability distribution
Practice Problems I
Practice Problems II
5 The joint p.d.f. of two random variables X and Y is
1
f (x, y ) = (6 − x − y )
8
, 0 < x < 2, 2 < y < 4. Find
i.) Marginal p.d.f.’s of X and Y .
ii.) Conditional distributions of X and Y .
iii.) Are X and Y are independent?
6 The joint p.d.f. of X and Y is
. Find
i.) the value of k.
ii.) Marginal p.d.f. of X and Y .
iii.) Conditional Distributions of X and Y .
Module 2
Joint probability distribution
. Find
i.) the value of A.
ii.) Are X and Y are independent?
8 If
2 +y 2 )
f (x, y ) = 4xye −(x , x ≥ 0, y ≥ 0
. Test whether X and Y are independent. Also, find the
conditional distributions.
Module 2
Joint probability distribution
Practice Problems IV
9 If
9(1 + x + y )
f (x, y ) = , 0 < x < ∞, 0 < y < ∞
2(1 + x)4 (1 + y )4
. Find
i.) Marginal p.d.f. of X and Y .
ii.) Conditional Distributions of X and Y .
10 The joint p.d.f. of two random variables X and Y is
1
f (x, y ) = (6 − x − y )
8
, 0 < x < 2, 2 < y < 4. Find
i.) P(X < 1, Y < 3)
ii.) P(X + Y < 3)
iii.) P(X < 1 | Y < 3)
Module 2
Joint probability distribution
Practice Problems V
Practice Problems VI
13 Consider the J.P.D.F.
(
5 2
f (x, y ) = 16 x y , if 0 < y < x < 2
0, otherwise
Mathematical Expectation
Module 2
Mathematical Expectation
Variance
Module 2
Mathematical Expectation
Variance Properties
Module 2
Mathematical Expectation
Problem 1
Module 2
Mathematical Expectation
Problem 1 Contd.
Module 2
Mathematical Expectation
Problem 2
Module 2
Mathematical Expectation
Problem 2 Contd.
Module 2
Mathematical Expectation
Problem 2 Contd.
Module 2
Mathematical Expectation
Problem 3
Calculate expectation and variance of X , if the probability
distribution of the random variable X is given by,
Module 2
Mathematical Expectation
Problem 4
A variate X has the following probability distribution:
Module 2
Mathematical Expectation
Problem 5
Module 2
Mathematical Expectation
Problem 6
For the continuous probability function f (x) = kx 2 e −x when
x ≥ 0, find (i) k (ii) Mean (iii) Variance
Module 2
Mathematical Expectation
Problem 6 Contd.
Module 2
Mathematical Expectation
Problem 6 Contd.
Module 2
Mathematical Expectation
Problem 7
Suppose a continuous random variable X has the probability
density f (x) = K (1 − x 2 ) for 0 < x < 1 and f (x) = 0, otherwise.
Find (i) k (ii) Mean (iii) Variance.
Module 2
Mathematical Expectation
Problem 7 Contd.
Module 2
Mathematical Expectation
Problem 8
Module 2
Mathematical Expectation
Problem 8 Contd.
Module 2
Mathematical Expectation
Problem 9
The cumulative distribution function for a continuous random
variable X is
Module 2
Mathematical Expectation
Problem 9 Contd.
Module 2
Mathematical Expectation
Problem 10
Problem 10 Contd.
Module 2
Mathematical Expectation
Problem 10 Contd.
Module 2
Mathematical Expectation
Practice Problems I
1 Determine the mean and variance of the random variable X
having the following probability distribution.
Practice Problems II
3 Suppose the probability mass function of the discrete random
variable is
Practice Problems IV
6 A commuter train arrives punctually at a station every 25
minutes. Each morning, a commuter leaves his house and
casually walks to the train station. Let X denote the amount
of time, in minutes, that commuter waits for the train from
the time he reaches the train station. It is known that the
probability density function of X is
Practice Problems V
Problem 1
Problem 1
If X has mean 4, variance 9, while Y has mean −2 and variance 5
and the two variables are independent. Find
a.) E [XY ]
b.) E [XY 2 ]
Solution
Given E (X ) = 4, Var (X ) = 9, E (Y ) = −2, Var (Y ) = 5.
Problem 2
Problem 3
Y \X 0 1 2
3 9 3
0 28 28 28
3 3
1 14 14 0
1
2 28 0 0
Problem 4
Problem 4 Contd.
1−x
Z
fx (X ) = f (x, y )dy
0
1−x
Z 1−x
Z
= 3(x + y )dy = 3 (x + y )dy
0 0
" #1−x " #
y2 (1 − x)2
= 3 xy + = 3 x(1 − x) +
2 2
" #0
2
(1 − x )
=3 .
2
Module 2
Covariance
Z1
E [X ] = xfx (X )dx
0
Z1
3
= x(1 − x 2 )dx
2
0
Z1
3
= (x − x 3 )dx
2
0
" #1
3 x2 x4 3
= − = .
2 2 4 8
0
Module 2
Covariance
Problem 4 Contd.
" #
(1−y 2 )
Similarly E [Y ] = 3 2
1−y
Z1 Z
E (XY ) = xyf (X , Y )dxdy
0 0
1−y
Z1 Z
= xy 3(x + y )dxdy
0 0
1
Z Z 1−y
=3 (x 2 y + xy 2 )dxdy
0 0
Module 2
Covariance
Problem 4 Contd.
1−y
Z1 Z Z1 " 3 #1−y
x y x 2y 2
E (XY ) = 3 (x 2 y + xy 2 )dxdy = 3 + dy
3 2
0 0 0 0
Z1 " #1−y
(1 − y )3 y (1 − y )2 y 2
=3 + dy
3 2
0 0
" Z1 Z1 h #
1h i 1 2 i
=3 y − 3y 2 + 3y 3 − y 4 dy + 4 3
y + y − 2y dy
3 2
0 0
1
= .
10
Module 2
Covariance
Problem 4 Contd.
COV (X , Y ) = E [XY ] − E [X ]E [Y ]
!
1 3 3
= − ∗
10 8 8
1 9
= −
10 64
−13
= .
320
Module 2
Covariance
Problem 5 Try
Problem 6
If f (x) = e −x , x ∈ [0, ∞]. Find the mean variance and the third
moment about the origin.
Module 2
Covariance
Problem 6 Contd.
Let the r th raw moment be
Z∞
′
µr = x r f (x)dx
0
Z∞
= x r e −x dx
0
= Γ(r + 1) = r !.
′
If r = 1, µ1 = 1 and thus mean is 1.
′ ′
′ 2
If r = 2, µ2 = 2 and variance Var = µ2 − µ1 = 2 − 1 = 1.
If r = 3, µ13 = 6.
Module 2
Covariance
Problem 7
Problem 7 contd.
i.)
Z2
=⇒ y0 x(2 − x)dx = 1
0
Z2
=⇒ y0 (2x − x 2 )dx = 1
0
" #2
2x 2 x 3
=⇒ y0 − =1
2 3
0
" #
8 3
=⇒ y0 4 − = 1. Thus y0 = .
3 4
Module 2
Covariance
Problem 7 contd.
ii.) To find mean and variance. Let us find through the moments.
Z2
′
µr = x r f (x)dx
0
Z2
= x r y0 (2x − x 2 )dx
0
Z2
3
= x r (2x − x 2 )dx
4
0
Z2 !
3
= 2x r +1 − x r +2 dx
4
0
Module 2
Covariance
Problem 7 contd.
" #2
′ 3 2x r +2 x r +3
µr = −
4 r +2 r +3
0
" #
3 2×2 r +2 2 r +3
= −
4 r +2 r +3
" #
3 r +3 1 1
= 2 −
4 r +2 r +3
" #
3 r +3 1
= × (2 ) .
4 (r + 2)(r + 3)
Module 2
Covariance
Problem 7 contd.
If r = 1, then
′ 3 4 1
µ1 = × 2
4 3∗4
= 1.
If r = 2, then
′ 3 5 1
µ2 = × 2
4 4∗5
6
= .
5
2
′ ′
Var = µ2 − µ1
6 1
= − 12 = .
5 5
Module 2
Covariance
Problem 7 contd.
iii.) For median we have P(X ≤ M) = P(x > M) = 12 . Consider
ZM ZM
P(X ≤ M) = f (x)dx = y0 (2x − x 2 )dx
0 0
ZM
3
= (2x − x 2 )dx
4
0
" #M
3 2x 2 x 3
= − = 3M 2 − M 3 − 2 = 0.
4 2 3
0
√ √
The values for M are 1, 1 ± 3. But 1 ± 3∈
/ [0, 2]. Thus the
median is 1.
Module 2
Covariance
Problem 7 contd.
Problem 7 contd.
v.)
Z2
M.D. about Mean = |x − mean|f (x)dx
0
Z2
3
= |x − 1|x(2 − x)dx
4
0
Z1 Z2
3 3
= |x − 1|x(2 − x)dx + |x − 1|x(2 − x)dx
4 4
0 1
Z1 Z2
3 3
= (1 − x)x(2 − x)dx + (x − 1)x(2 − x)dx
4 4
0 1
Module 2
Covariance
Problem 7 contd.
v.)
Z1 Z2
3 3
M.D. about Mean = (x 3 − 3x 2 + 2x)dx + (3x 2 − x 3 − 2x)dx
4 4
0 1
" #1 " #2
3 x 4 3x 3 2x 2 3 33 x 4 2x 2
= − + + − −
4 4 3 2 4 3 4 2
" # "0 1
#
3 1 3 16 1
= −1+1 + (8 − − 4) − (1 − − 1)
4 4 4 4 4
3
= .
8
Module 2
Covariance
Problem 8
Problem 8 Contd.
i.)
Z1
=⇒ k(x − x 2 )dx = 1
0
Z1
=⇒ k (x − x 2 )dx = 1
0
" #1
x2 x3
=⇒ k − =1
2 3
0
" #
1 1
=⇒ k − = 1. Thus k = 6.
2 3
Module 2
Covariance
Problem 8 Contd.
ii.)
Z1
E [X ] = xf (x)dx
0
Z1
=6 x(x − x 2 )dx
0
" #1
x3 x4
=6 −
3 4
0
1
= .
2
1
Mode is also 2 (TRY).
Module 2
Covariance
Problem 9 (TRY)
(
sin(x)
2 , if 0 ≤ x ≤ π
Consider f (x) =
0, otherwise
Find the following:
i.) Mean
ii.) Mode
iii.) Median
iv.) P(0 ≤ x ≤ π2 ).
Module 2
Moment Generating Function
Problem 1
Module 2
Moment Generating Function
Problem 1 Contd.
Module 2
Moment Generating Function
Problem 1 Contd.
Module 2
Moment Generating Function
Problem 2
A random variable X has the probability function
f (x) = 21x , x = 1, 2, 3, · · ·
i) Find M.G.F
ii) Mean
Solution:
M.G.F = MX (t) = E (e tx )
X∞
= e tx f (x)
x=1
∞
X 1
= e tx
2x
x=1
∞ t x
X e
=
2
x=1
Module 2
Moment Generating Function
Problem 2 Contd.
t 2 t 3
et
e e
= + + + ···
2 2 2
t 2
et et
e
= 1+ + + ···
2 2 2
t −1
et
e
= 1−
2 2
e 2 − e −1
t t
=
2 2
t
e 2
=
2 2 − et
et
=⇒ MX (t) =
2 − et
Module 2
Moment Generating Function
Problem 2 Contd.
t
d e
Mean(X̄ ) =
dt 2 − e t t=0
(2 − e t )e t − e t (−e −t )
=
(2 − e t )2 t=0
(2 − e 0 )e 0 − e 0 (−e 0 )
=
(2 − e 0 )2
=2
Module 2
Moment Generating Function
Problem 3
The M.G.F of a random variable X is given by
et 4e 3t 2e 4t 4e 5t
MX (t) = + + +
3 15 15 15
Find the P.D.F of X .
Solution:
For discrete random variable,
MX (t) = E (e tx )
X
= e txi P(xi )
i
Hence,
x 1 3 4 5
P(x) 1/3 4/15 2/15 4/15
Module 2
Moment Generating Function
Problem 4
Find the M.G.F of a random variable whose moments are
µ′r = (r + 1)!3r and hence find its mean.
Solution:
The M.G.F is
∞ r
X t
MX (t) = µ′r
r!
r =0
∞
X (r + 1)!3r t r
=
r!
r =0
∞
X (r + 1)!(3t)r
=
r!
r =0
1
= 1 + 2(3t) + 3(3t)2 + · · · =
(1 − 3t)2
Module 2
Moment Generating Function
Problem 4 Contd.
d
Mean(X̄ ) = (MX (t))
dt t=0
d −2
= [1 − 3t]
dt t=0
= −2[[1 − 3t]−2 (−3)]t=0
= [6(1 − 3t)−3 ]t=0
= 6(1 − 0)−3
=⇒ µ′1 = 6
Module 2
Moment Generating Function
Problem 5
Also find
i) Mean
ii) Variance
iii) µ′3
iv) µ′4
Module 2
Moment Generating Function
Problem 5 Contd.
M.G.F = MX (t) = E (e tx )
Z ∞
= e tx f (x)dx
Z−∞∞
= e tx ke −kx dx
0
Z ∞
=k e tx e −kx dx
0
Z ∞
=k e −(k−t)x dx
0
−(k−t)x ∞
e −∞ e0
e
=k =k −
−(k − t) 0 −(k − t) −(k − t)
k
=⇒ MX (t) =
k −t
Module 2
Moment Generating Function
Problem 5 Contd.
d k
Mean µ′1 =
dt k − t t=0
(k − t)(0) − k(−1)
=
(k − t)2 t=o
1
=
k
d2
k
= µ′2
dt 2 k −t t=0
2
=⇒ = 2
k
Module 2
Moment Generating Function
Problem 5 Contd.
d3
k 6
µ′3 = =
dt 3 k −t k3
4 t=0
d k 24
µ′4 = =
dt 4 k −t t=0 k4
Module 2
Moment Generating Function
Problem 6
Find
i) M.G.F
ii) Four moments about the origin
iii) Mean and Variance
Module 2
Moment Generating Function
Problem 6 Contd.
M.G.F = MX (t) = E (e tx )
Z ∞
= e tx f (x)dx
Z−∞∞
= e tx 2e −2x dx
0
Z ∞
=2 e tx e −2x dx
0
Z ∞
=2 e −(2−t)x dx
0
−(2−t)x ∞
e −∞ e0
e
=2 =2 −
−(2 − t) 0 −(2 − t) −(2 − t)
2
=⇒ MX (t) = if |t| < 2
2−t
Module 2
Moment Generating Function
Problem 6 Contd.
t −1
MX (t) = 1 −
2
2 3 r
t t t t
=1+ + + + ··· + + ··· (1)
2 2 2 2
Problem 6 Contd.
1
r = 1 =⇒ µ′1 =
2
′ 1
r = 2 =⇒ µ2 =
2
3
r = 3 =⇒ µ′3 =
4
′ 3
r = 4 =⇒ µ4 =
2
1
Mean =
2
Var (X ) = µ′2 − (µ′1 )2
1 1 1
= − =
2 4 4
Module 2
Moment Generating Function
Problem 7
Find the M.G.F of the random variable X having P.D.F
x,
if 0 ≤ x < 1
f (x) = 2 − x, if 1 ≤ x < 2
0, otherwise
Solution:
Z ∞
MX (t) = e tx f (x)dx
−∞
Z1 Z 2 Z ∞
tx tx
= xe dx + (2 − x)e dx + 0e tx dx
0 1 2
Module 2
Moment Generating Function
Problem 7 contd.
tx tx 1 tx tx 2
e e e e
= x − 2
+ (2 − x) − (−1) 2
t t t t
t t
0 2t t t
1
e e 1 e e e
= − 2 + 2 + 0+ 2 − − 2
t t t t t t
t
1 − 2e + e 2t
=
t2
(e − 1)2
t
=⇒ M.G .F =
t2
Module 2
Moment Generating Function
Problem 8
Problem 8 Contd.
Module 2
Moment Generating Function
Problem 8 Contd.
Module 2
Moment Generating Function
Problem 9
Module 2
Moment Generating Function
Problem 9 Contd.
Module 2
Moment Generating Function
Problem 9 Contd.
Module 2
Moment Generating Function
Problem 10
Module 2
Moment Generating Function
Problem 10 Contd.
Module 2
Moment Generating Function
Practice Problems I
1 Find the probability distribution of the total number of heads
obtained in four tosses of a balanced coin. Hence obtain the
m.g.f of X , mean and variance of X .
2 Let the random variable X have the p.d.f.
( −x
1 2
e , if x > 0
f (x) = 2
0, otherwise
. Find the P(X > 3), moment generating function, mean and
variance of X .
Module 2
Moment Generating Function
Practice Problems II