Unit I (Part 2)
Unit I (Part 2)
Simply,
MVS Page 1
Example-1 Consider the sample space of throwing of two dice
𝑋(1, 1) = 2, 𝑋(1, 2) = 3,
and in general 𝑋(𝑖, 𝑗) = 𝑖 + 𝑗.
Here 𝑋: 𝑆 →
∴ X is a random variable
MVS Page 2
Thus, Intuitively by a random variable RV we mean a real number X
connected with the outcome of a random experiment S.
Example-2
If S consists of two tosses of a coin, we may consider the random variable
which is the number of heads ( 0, 1 or 2)
Outcome HH HT TH TT
Value of X 2 1 1 0
Random Variable
MVS Page 3
There are two types of random variables
Def:
MVS Page 4
Also,
if the possible values are any of these
{1,2,3, … … }
{… … . . −2, −1,0,1,2,3, … … }
{0,2,4,6, … … }
{0,0.5,1.0,1.5,2.0, … . … }
any finite set
Def:
Examples:
1.Suppose the temperature in a city lies between 30⁰ and 45⁰
centigrade. The temperature can take any value in the interval 30⁰
to 45⁰.
2. The length of time I have to wait at the bus stop for a number 2 bus.
3.Blood pressure,
MVS Page 5
4. Weight
5. Speed of a car.
7. The distance the vehicle travels before stopping ,When brakes are
applied to a moving vehicle.
Also
If the possible values are any of these
MVS Page 6
Probability Mass Function:
If X is a discrete RV which can take the values 𝑥1, 𝑥2 ,…….𝑥𝑛
(i) 𝑝𝑖 > 0
(ii) ∑𝑖 𝑝𝑖 = ∑𝑖 𝑃(𝑋 = 𝑥𝑖 ) = 1
The collection of pairs {(𝑥1 , 𝑝1 ), (𝑥2 , 𝑝2 ), … … . . } ,is called the probability
distribution of the random variable X.
𝑋 = 𝑥𝑖 𝑥1 𝑥2 ……… 𝑥𝑖 𝑥𝑛
𝑃(𝑋 = 𝑥𝑖 ) 𝑝1 𝑝2 𝑝𝑖 𝑝𝑛
MVS Page 7
The curve 𝑦 = 𝑓(𝑥) is called probability curve of the Random variable X
𝑃(𝑋 = 𝑎) = ∫ 𝑓 (𝑥 )𝑑𝑥 = 0
𝑎
MVS Page 8
𝑃 (𝑎 ≤ 𝑋 ≤ 𝑏 ) = 𝑃 (𝑎 < 𝑋 ≤ 𝑏 ) = 𝑃 (𝑎 ≤ 𝑋 < 𝑏 )
= 𝑃 (𝑎 < 𝑋 < 𝑏 )
𝑏
= ∫𝑎 𝑓(𝑥 ) 𝑑𝑥
Probability as an Area
MVS Page 9
∞
𝑷(𝑿 > 𝒂) = ∫𝒂 𝒇(𝒙)𝒅𝒙=Area of the shaded
portion
1.
MVS Page 10
MVS Page 11
MVS Page 12
If X is an RV, discrete or continuous , then
𝑃(𝑋 ≤ 𝑥) is called the cumulative distributive function of 𝑋 or
simply distribution function of 𝑋 and it is denoted by 𝐹(𝑥)
MVS Page 13
The cumulative distribution function 𝐹 (𝑥 ) for a
continuous random variable 𝑋 expresses the probability that 𝑋 does not
exceed the value of 𝑥
MVS Page 14
Properties of the cdf 𝐹(𝑥)
1. 𝐹(𝑥) is a non decreasing function of 𝑥 i.e
𝑥1 < 𝑥2
⇒ 𝐹 (𝑥1 ) < 𝐹(𝑥2 )
2. 𝐹 (−∞) = 0 , 𝐹 (∞) = 1
∞
MVS Page 15
Note:
MVS Page 16
Mathematical Expectations
Definition: Let X be a continuous random variable with p.d.f. 𝑓 (𝑥 ).
given by
∞
𝐸 (𝑋) = ∫ 𝑥 𝑓(𝑥 ) 𝑑𝑥
−∞
MVS Page 17
Let 𝑔(𝑋) be any function of 𝑋. Then
∞
𝑖) 𝐸 [𝑔(𝑋)] = ∫−∞ 𝑔(𝑥 ) 𝑓(𝑥 ) 𝑑𝑥 , when 𝑋 is continuous RV
When 𝑋 is discrete
2. 𝐸 (𝑋 2 ) = 𝑥 2 𝑃(𝑋 = 𝑥 )
3. 𝐸 (𝑋 3 ) = ∑ 𝑥 3 𝑃(𝑋 = 𝑥)
etc
MVS Page 18
In case of Continuous random variable 𝑋
∞
1.𝐸 (𝑋) = ∫−∞ 𝑥 𝑓(𝑥 )𝑑𝑥
∞
2. 𝐸 (𝑋 2 ) = ∫ 𝑥 2 𝑓(𝑥 )𝑑𝑥
−∞
∞
3. 𝐸 (𝑋 3 ) = ∫−∞ 𝑥 3 𝑓(𝑥 )𝑑𝑥
etc
Expectation Properties:
Important Results:
∑ 𝑝𝑖 𝑥𝑖
∵ 𝑀𝑒𝑎𝑛 = ∑ 𝑝𝑖
= ∑ 𝑝𝑖 𝑥𝑖 as
1. 𝐸 (𝑋) = 𝜇 = 𝑚𝑒𝑎𝑛 =𝑥̅
∑ 𝑝𝑖 = 1
3. 𝐸 (𝑘𝑋) = 𝑘𝐸 (𝑋)
MVS Page 19
5. 𝐸 (𝑋 + 𝑌) = 𝐸 (𝑋) + 𝐸(𝑌), provided 𝐸 (𝑋) 𝑎𝑛𝑑 𝐸(𝑌) exists.
6. 𝐸 (𝑋 − 𝜇 ) = 𝐸 (𝑋 − 𝑥̅ ) = 0 why ?
1 1
8. 𝐸 ( ) ≠
𝑋 𝐸 (𝑋)
MVS Page 20
2.Variance:
Variance of the probability distribution of a random variable 𝑋
denoted by the symbol 𝜎 2 is defined as
= 𝑥𝑖 2 𝑝𝑖 + 𝜇 2 − 2𝜇 𝑥𝑖 𝑝𝑖
𝑖 𝑖
𝜎2 = ∑𝑛𝑖 𝑥𝑖 2 𝑝𝑖 + 𝜇 2 − 2𝜇 2 ∵ 𝜇 = ∑𝑛𝑖 𝑥𝑖 𝑝𝑖
𝜎2 = ∑𝑛𝑖 𝑥𝑖 2 𝑝𝑖 − 𝜇 2
𝜎2 = 𝐸 (𝑋 2 ) − [𝐸(𝑋)]2
Variance = 𝜎 2 = 𝐸 (𝑋 2 ) − [𝐸(𝑋)]2
Results:
𝑉(𝐾 ) = 0, where K is a constant
𝑉(𝐾 ) = 𝑉 (𝐾𝑋 0 ) = 𝐸(𝐾𝑋 0 )2 − [𝐸(𝐾𝑋 0 )]2
= 𝐸(𝐾)2 − [𝐸(𝐾)]2 = 𝐾 2 − 𝐾 2 = 0
MVS Page 21
i.e Variance of any constant = 0
2. 𝑉(𝑘𝑋 ) = 𝑘 2 𝑉(𝑋)
= 𝐾 2 𝐸(𝑋)2 − 𝐾 2 [𝐸(𝑋)]2
= 𝐾 2 {𝐸(𝑋 2 ) − 𝐾 2 [𝐸(𝑋)]2 }
= 𝐾 2 {𝐸(𝑋 2 ) − [𝐸(𝑋)]2 } = 𝐾 2 𝑉(𝑋)
Proof: Let 𝑌 = 𝑎𝑋 + 𝑏
𝑉 (𝑌) = 𝐸 (𝑌 2 ) − [𝐸(𝑌)]2
= 𝐸 ((𝑎𝑋 + 𝑏)2 ) − [𝐸(𝑎𝑋 + 𝑏)]2
= 𝑎2 {𝐸 (𝑋 2 ) − [𝐸(𝑋)]2 } = 𝑎2 𝑉(𝑋)
𝑉(𝑎𝑋 + 𝑏) = 𝑎2 𝑉(𝑋)
MVS Page 22
𝑉(𝑎𝑋 + 𝑏) = 𝑎2 𝑉(𝑋)
𝜇𝑟′ = 𝐸(𝑋 𝑟 )
MVS Page 23
Moment Generating Function (MGF)
𝑀𝑋 (𝑡) = 𝐸 [𝑒 𝑡𝑋 ]
𝐸 [𝑒 𝑡𝑋 ] = ∑𝑥 𝑒 𝑡𝑥 𝑝(𝑥),
If 𝑋 is aType equation
discrete here.
random variable with pmf 𝑝(𝑥),
MVS Page 24
𝑛
𝑡
𝐸 (𝑋 𝑛 ) = 𝑐𝑜𝑒𝑓𝑓𝑖𝑐𝑖𝑒𝑛𝑡 𝑜𝑓 𝑖𝑛 𝑀𝑋 (𝑡 )
𝑛!
We have
𝑀𝑋 (𝑡) = 𝐸 [𝑒 𝑡𝑋 ]
𝑡𝑋 (𝑡𝑋)2 (𝑡𝑋)3 (𝑡𝑋)𝑛
𝑀𝑋 (𝑡) = 𝐸 {1 + + + + −−−+ + − −}
1! 2! 3! 𝑛!
𝑡 𝑡2 2
𝑡𝑛
𝑀𝑋 (𝑡) = 1 + 𝐸 (𝑋) + 𝐸 (𝑋 ) + − − − + 𝐸 (𝑋 𝑛 ) + ⋯ …
1! 2! 𝑛!
𝑡 𝑡2 𝑡𝑛
= 1+ 𝜇1′ + 𝜇2′ + −−−+ 𝜇𝑛′ + ⋯ …
1! 2! 𝑛!
𝑛)
𝑡𝑛
∴ 𝐸 (𝑋 = 𝑐𝑜𝑒𝑓𝑓𝑖𝑐𝑖𝑒𝑛𝑡 𝑜𝑓 𝑖𝑛 𝑀𝑋 (𝑡)
𝑛!
Type equation here.
𝑑 𝑑 𝑡 𝑡2 𝑡𝑛
Also 𝑀𝑋 (𝑡) = {1 + 𝐸 (𝑋) + 𝐸 (𝑋 2 ) + − − − + 𝐸 (𝑋𝑛 )}
𝑑𝑡 𝑑𝑡 1! 2! 𝑛!
2
𝑛𝑡𝑛−1
= 𝐸 (𝑋) + 𝑡𝐸(𝑋 ) + … + 𝐸(𝑋𝑛 ) + ⋯.
𝑛!
Put 𝑡 = 0
𝑑
{
𝑑𝑡
𝑀𝑋 (𝑡)} = 𝐸(𝑋)
𝑡=0
MVS Page 25
Similarly
𝑑2
{ 2 𝑀𝑋 (𝑡)} = 𝐸 (𝑋 2 )
𝑑𝑡 𝑡=0
𝑑3
{ 3 𝑀𝑋 (𝑡)} = 𝐸 (𝑋 3 )
𝑑𝑡 𝑡=0
Etc
𝑑
𝐸 (𝑋) = ൜ 𝑀𝑋 (𝑡)ൠ
𝑑𝑡 𝑡=0
2) 𝑑2
𝐸 (𝑋 ={ 𝑀𝑋 (𝑡)}
𝑑𝑡 2 𝑡=0
3) 𝑑3
𝐸 (𝑋 ={ 𝑀𝑋 (𝑡)}
𝑑𝑡 3 𝑡=0
MVS Page 26
Example-1
𝑋= 𝑥 1 2 3 4 5 6
𝑃(𝑋 = 𝑥) 1 1 1 1 1 1
6 6 6 6 6 6
1+4+9+16+25+36 91
= =
6 6
𝟐)
91
𝟐 7 2 35
𝐕(𝐗) = 𝐄(𝐗 − (𝐄(𝐗)) = −( ) =
6 2 12
MVS Page 27
Example-2
𝑋 =𝑥 2 3 4 5 6 7 8 9 10 11 12
𝑃(𝑋 = 𝑥 ) 1 2 3 4 5 6 5 4 3 2 1
36 36 36 36 36 36 36 36 36 36 36
𝐸 (𝑋) = 𝑥. 𝑃(𝑥 ) =
𝑥
MVS Page 28
1 2 3 4 5
= 2( )+ 3( )+ 4( ) +5( ) +6( )
36 36 36 36 36
6 5 4 3 2 1
+7 ( ) + 8 ( ) + 9 ( ) + 10 ( ) + 11 ( ) + 12 ( )
36 36 36 36 36 36
=
252
= =7
36
Example-3
Solution:
𝑋=𝑥 0 1 2 3 4 5 6 7 8
𝑃(𝑋 = 𝑥) a 3a 5a 7a 9a 11a 13a 15a 17a
MVS Page 29
(i) Since 𝑃(𝑥) is a probability mass function , we have
∑8𝑖=1 𝑝(𝑥𝑖 ) = 1
a+3a+5a+7a+9a+11a+13a+15a+17a= 1
81a = 1
1
a=
81
1 8
𝑃(𝑋 ≥ 3) = 1 − 𝑃(𝑋 < 3) = 1 − =
9 9
(iii) 𝑃(0 < 𝑋 < 5) =
𝑃(𝑋 = 1) + 𝑃(𝑋 = 2) + 𝑃(𝑋 = 3) + 𝑃(𝑋 = 4)
16
= 𝑎 + 3𝑎 + 5𝑎 + 7𝑎 = 16𝑎 =
81
MVS Page 30
(iv) Distribution function of 𝑋
6 49
𝐹 (6) = 𝑃(𝑋 ≤ 6)=
81
7 64
𝐹 (7) = 𝑃(𝑋 ≤ 7)=
81
MVS Page 31
Example-4
MVS Page 32
Example-5
Solution:
MVS Page 33
Example-6
Solution:
MVS Page 34
Example-7
Let X a continuous random variable denotes the time a person waits for
an elevator to arrive .The PDf of X is
given by
Solution:
2
Mean=𝐸 (𝑋) = ∫0 𝑥 𝑓 (𝑥 )𝑑𝑥
Thus, we expect a person will wait 1 minute for the elevator on average
MVS Page 35
2 7 1
𝑉 (𝑋) = 𝐸 (𝑋 2 ) − (𝐸 (𝑋)) = − 12 =
6 6
Example-8
∞
Solution: Since 𝑓 (𝑥 ) is apdf , it satisfies ∫−∞ 𝑓 (𝑥 ) = 1
3
∫ 𝑐𝑥 2 dx = 1
0
3
𝑥3
𝑐[ ] = 1
3 0
1
𝑐=
9
MVS Page 36
21 7
b) 𝑃(1 < 𝑋 < 2) = ∫1 𝑥 2 𝑑𝑥 =
9 27
Example-9
MVS Page 37
b) 𝑃 ( 𝑋 < 2) =
𝑃 (𝑋 = −2) + 𝑃(𝑋 = −1) + 𝑃(𝑋 = 0) + 𝑃(𝑋 = 1)
1 1 1 2 1
= + + + =
10 15 5 15 2
MVS Page 38
Example-10
Solution:
We have ∑ 𝑝(𝑥 ) = 1
∴ 0 + 𝑘 + 2𝑘 + 2𝑘 + 3𝑘 + 𝑘 2 + 2𝑘 2 + 7𝑘 2 + 𝑘 = 1
i.e 10𝑘 2 + 9𝑘 = 1
(10𝑘 − 1)(𝑘 + 1) = 0
1
𝑘= or -1
10
1
∴𝑘=
10
MVS Page 39
Example-11
Solution:
MVS Page 40
𝑥2
−
Clearly for 𝑥 ≥ 0 , 𝑥𝑒 2 ≥ 0 and
∞ ∞
𝑥2
−2
∫ 𝑓 (𝑥 )𝑑𝑥 = ∫ 𝑥𝑒 𝑑𝑥
0 0
∞ −𝑡 𝑥2
= ∫0 𝑒 𝑑𝑡 𝑝𝑢𝑡 = t, xdx = dt
2
= −(𝑒 −∞ − 𝑒 0 ) = 1
∞
∫ 𝑓 (𝑥 )𝑑𝑥 = 1
0
MVS Page 41
Example-12
Solution:
Γ(𝑛) = ∫ 𝑥 𝑛−1 𝑒 −𝑥 𝑑𝑥
0
Γ(𝑛 + 1) = 𝑛!
∫ 𝑓 (𝑥 )𝑑𝑥 = 1
0
∞
∫ 𝑘𝑥 2 𝑒 −𝑥 𝑑𝑥 = 1
0
𝑘Γ(3) = 1
𝑘 (2) = 1
1
∴𝑘=
2
MVS Page 42
Mean of 𝑋 =
(or)
∞
Mean =𝐸 (𝑋) = ∫0 𝑥 𝑓(𝑥)𝑑𝑥
∞
1 2 −𝑥
=∫𝑥 𝑥 𝑒 𝑑𝑥
2
0
∞
1 1 3!
= ∫ 𝑥 3 𝑒 −𝑥 𝑑𝑥 = Γ(4) = = 3
2 2 2
0
2
𝑉 (𝑋) = 𝐸 (𝑋 2 ) − (𝐸 (𝑋))
∞
𝐸 (𝑋 2 ) = ∫ 𝑥 2 𝑓(𝑥)𝑑𝑥 =
0
∞ ∞
1 1 1 4!
= ∫ 𝑥 2 𝑥 2 𝑒 −𝑥 𝑑𝑥 = ∫ 𝑥 4 𝑒 −𝑥 𝑑𝑥 = Γ(5) = = 12
2 2 2 2
0 0
MVS Page 43
2
𝑉 (𝑋) = 𝐸 (𝑋 2 ) − (𝐸 (𝑋))
= 12 − 32 = 9
Example-13
Solution:
Given pdf of RV 𝑋 is
𝑓 (𝑥 ) = 3𝑥 2 ,0≤ 𝑥 ≤ 1
∴ ∫ 𝑓 (𝑥 )𝑑𝑥 = ∫ 𝑓 (𝑥 )𝑑𝑥
0 𝑎
𝑎 1
∴ ∫ 3𝑥 2 𝑑𝑥 = ∫ 3𝑥 2 𝑑𝑥
0 𝑎
[𝑥 3 ]𝑎0 = [𝑥 3 ]1𝑎
MVS Page 44
𝑎3 = 1 − 𝑎3
2𝑎3 = 1
1
𝑎3 =
2
∴ 𝑎 = 0.7937
MVS Page 45
Example-14
𝐹 (𝑥 ) = 1 − (1 + 𝑥 )𝑒 −𝑥 , 𝑥 ≥ 0
Find the pdf (𝑓(𝑥)) , mean and variance of 𝑋
Solution:
We have
𝐹 ′ (𝑥 ) = 𝑓 (𝑥 )
𝑑
i.e (𝐹(𝑥)) = 𝑓(𝑥)
𝑑𝑥
=
𝑑
𝑓 (𝑥 ) = {1 − (1 + 𝑥 )𝑒 −𝑥 }
𝑑𝑥
𝑓 (𝑥 ) = (1 + 𝑥 )𝑒 −𝑥 − 𝑒 −𝑥
∴ 𝑓 (𝑥 ) = 𝑥𝑒 −𝑥
MVS Page 46
∞
∞ ∞
= ∫0 𝑥 𝑥𝑒 −𝑥 𝑑𝑥 = ∫0 𝑥 2 𝑒 −𝑥 𝑑𝑥 ∞
Γ(𝑛) = ∫ 𝑥 𝑛−1 𝑒 −𝑥 𝑑𝑥
0
𝛤(𝑛 + 1) = 𝑛!
= Γ(3) = 2! = 2
𝐸 (𝑋 2 ) = ∫ 𝑥 2 𝑓(𝑥 )𝑑𝑥
0
∞ ∞
= ∫ 𝑥 2 𝑥𝑒 −𝑥 𝑑𝑥 = ∫ 𝑥 3 𝑒 −𝑥 𝑑𝑥
0 0
= Γ(4) = 3! = 6
2
𝑉 (𝑋) = 𝐸 (𝑋 2 ) − (𝐸 (𝑋))
=6−4=2
MVS Page 47
Example-15
𝑃 (𝐴∩𝐵)
Solution: We have 𝑃 (𝐴⁄𝐵 ) =
𝑃(𝐵)
1 7
∴ 𝑃 (( < 𝑋 < ) /𝑋 > 1) =
2 2
MVS Page 48
MVS Page 49