Module2 - Random Variable
Module2 - Random Variable
RANDOM VARIABLES
Discrete random variable:
1 Random variable, Discrete random variable
2 Probability Mass Function (P.M.F),
3 Cumulative Distribution Function (C.D.F),
4 Mean, Mathematical Expectation, Variance of Discrete random Variable.
Continuous random variable:
5 Continuous random variable
6 Probability Density Function
7 Relation between PDF and CDF
Mean, Expectation, Variance, Median, Mode, Mean Deviation of continuous Random
8
Variable.
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page1 of 24
Random variable:
A Random Variable X is a real valued function from sample space S to a real number R.
(OR)
A Random Variable X can be considered as function that maps all elements in the sample space S in to
points on the real line.
Ex1: In tossing of two coins, then the possible outcomes are S= {HH, HT, TH, TT}
Let ‘X’ denotes number of heads then ‘X’ takes the values 0,1,2. X(S)={0,1,2}
S X R
TT 0
HT 1
TH 2
HH 3
Types of Random Variable: There are two types of random variables (1) Discrete random variable
(2) Continuous random variable
(I) Discrete random variable: A random variable X is said to be discrete if it takes only finite or
countable set of values
Ex: (1) Number of students in a class. (2) Number of telephone calls received by a person.
Discrete Probability Distribution: Let X is a Discrete random variable with possible outcomes 𝑥1, 𝑥2, 𝑥3
…. 𝑥n, having probabilities P(𝑥1), P(𝑥2), P(𝑥3), ….. P(𝑥n) then {𝑥i, P(𝑥i)} for i=1 to n is called Discrete
Probability Distribution.
The discrete probability distribution {xi, P(xi)=pi} can be displayed in the form of table as shown below.
X=xn x1 x2 ----- xn
P(X)=P(X= xn)=Pn P1 P2 ------ Pn
Ex1: Tossing two coins simultaneously sample space S={HH, HT, TH, TT}
Let ‘X’ denotes number of Heads then ‘X’ takes the values X(S)={0,1,2}.
When X=0 then P(X=0)=1/4
When X=1then P(X=1)=1/2
When X=2 then P(X=2)=1/4 xi 0 1 2
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page2 of 24
Probability Mass Function (p.m.f) P(X): Let ‘X’ be a discrete random variable then its probability
function P(X) is said to be Probability mass function (p.m.f) and it’s must be satisfies following two
conditions
(a) P(X=x)= p(x)
(b) P(𝑥i)≥0 and ∑P(𝑥i)=1 for 𝑖=1,2……n
Ex1: In tossing of three coins find the probability distribution function & probability mass function
(or) not?
Sol: when tossing coin three times then S = {HHH, HHT, HTH, THH, HTT, THT, TTH, TTT}, n(s)=8
Let ‘X’ denotes number of Heads then ‘X’ takes the values 0,1,2,3
X=0 then P(X=0)=1/8, X=1 then P(X=1)=3/8, X=2 then P(X=2)=3/8, X=3 then P(X=3)=1/8
Therefore, the probability distribution is given by:
X 0 1 2 3
P(x) 1/8 3/8 3/8 1/8
Probability distribution P(X) is said to be p.m.f if it’s must be satisfies following two conditions:
1 3 3 1
(a) all P(𝑥i)≥0 (b) ∑3i=0 P(xi ) = P(0) + P(1) + P(2) + P(3) = 8 + 8 + 8 + 8 = 1
(II) Continuous random variable: A random variable which takes all the possible values between the
two limits is called continuous random variable.
Examples:
The speed of a motor bike when operated in first gear (0- 20 Km)
The temperature of the Hyderabad city (30oC -36oC)
The height, Age, weight, Time are continuous random variables.
Probability Density Function (P.D.F) f(x):
Let ‘X’ be a Continuous random variable then its probability function f(x) is said to be probability density
function (p.d.f.) or simply density function and it’s must be satisfies following two conditions
i) f(x)≥0 ∀ x ∈ (a, b)
∞
ii) Total area under the probability curve is 1 i.e, ∫−∞ f(x)dx = 1
b
iii) 𝑃(𝑎 < 𝑥 < 𝑏) = ∫a f(x)dx
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page3 of 24
𝐱
Ex1: The given distribution is PDF or not? 𝐟(𝐱) = 𝟐 , 𝟎 < 𝒙 < 𝟐
Cumulative Distribution Function (c.d.f): The cumulative distribution function of a random variable X
is given by
Properties:
a) If a<b then 𝑃[𝑎 < 𝑥 ≤ 𝑏] = 𝐹(𝑏) − 𝐹(𝑎)
b) 𝑃[𝑎 ≤ 𝑥 ≤ 𝑏] = 𝐹(𝑏) − 𝐹(𝑎) +𝑃[𝑋 = 𝑎]
c) 𝑃[𝑎 < 𝑥 < 𝑏] = 𝐹(𝑏) − 𝐹(𝑎) − 𝑃[𝑋 = 𝑏]
d) 𝑃[𝑎 ≤ 𝑥 < 𝑏] = 𝐹(𝑏) − 𝐹(𝑎) − 𝑃[𝑋 = 𝑏] + 𝑃[𝑋 = 𝑎]
e) P(x)=F(x)-F(x-1)
f) If x < y then F(x) < F(y)
g) 0 ≤ F(x) ≤ 1 for -<x< i.e; Cumulative distribution function always lies between 0 & 1.
h) F(-)=0 and F()=1,
Note: P(c < x < d) = P(c ≤ x ≤ d) = P(c ≤ x < d) = P(c < x ≤ d) Cumulative distribution function of f(𝑥) is
d
given by ∫c f(x)dx
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page4 of 24
Mathematical Expectation: The mathematical expectation of a random variable X is
∑ 𝑥 𝑃(𝑋 = 𝑥) ; 𝑓𝑜𝑟 𝑑. 𝑟. 𝑣 𝑋
∞
E(X) =
∫ x. f(x)dx ; 𝑓𝑜𝑟 𝑐. 𝑟. 𝑣 𝑋
{−∞
Note:
∑ 𝑥 𝑟 . 𝑃(𝑋 = 𝑥) ; 𝑓𝑜𝑟 𝑑. 𝑟. 𝑣 𝑋
1. if r is any positive integer then E(X r ) = { ∞
∫−∞ 𝑥 𝑟 . f(x)dx ; 𝑓𝑜𝑟 𝑐. 𝑟. 𝑣 𝑋
2. E(X) is also called the mean value of the probability distribution of random variable X and is denoted
by μ.
Variance: If X is a discrete random variable (or continuous random variable) with probability mass
function P(x) (or probability density function f(x)), then expected value of [X - E(X)]2 is called the
variance of X and it is denoted by V(X). i.e; V(X) = E(X − E(X))2
∴ V(X) = E(X 2 ) − {E(X)}2
Note: Variance is a characteristic of random variable X and it is used to measure dispersion (or variation)
of X.
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page5 of 24
Standard deviation: The positive square root of the variance is called standard deviation of random
variable X and is denoted by σ = √𝑉(𝑋)
Note: 𝛔2 is called variance of V(X).
Median: Median is the point which divides the entire distribution in to two equal parts. In case of
continuous distribution, median is the point which divides the total area in to two equal parts i.e,
M b 1
∫a f(x)dx = ∫M f(x)dx = 2 , ∀xϵ(a, b)
Mode: Mode is the value of x for which f(x) is maximum. i.e f ′(x) = 0 and f "(x) < 0 for x ∈ (a, b)
Mean Deviation: Mean deviation of continuous probability distribution function is defined as
∞
∫−∞|x − μ|f(x)dx
𝐗
(1) Let X be a random variable with E(X)=2 and 𝐄(𝐗 𝟐 − 𝐗) = 𝟗 find 𝐕 (𝟐) and 𝐕(𝟐 − 𝟑𝐗)
(2) Let X be a random variable with 𝐄(𝐗) = 𝟏𝟎 & 𝐕(𝐗) = 𝟐𝟓, find the positive value of a & b such
that 𝒀 = 𝒂𝑿 − 𝒃 has expectation 0 and variance 1.
Sol: Given that E(X) = 10 & V(X) = 25 and E(Y) = 0 & V(Y) = 1
E(aX − b) = 0 ⟹ aE(X) − b = 0 ⟹ 10a − b = 0
1
V(aX − b) = 1 ⟹ a2 𝑉(𝑋) = 1 ⟹ 25a2 = 1 ⟹ a =
5
10a − b = 0 ⟹ 2 − b = 0 ⟹ b = 2
(3) If X&Y are two random variable with means 2&3 and variances 1&2 find the mean &
variance of 𝒁 = 𝟐𝑿 − 𝟑𝒀.
Sol: Given that E(X) = 2 & E(Y) = 3 and V(X) = 1 & V(Y) = 2
E(Z) = 𝐸(2𝑋 − 𝑌) = 2𝐸(𝑋) − 𝐸(𝑌) = 1
V(Z) = 𝑉(2𝑋 − 𝑌) = (2)2 𝑉(𝑋) + (−1)2 𝑉(𝑌) = 6
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page6 of 24
Problems on Discrete Random Variable:
1. A random variable X has the following probability function.
X 0 1 2 3 4 5 6 7
P(X) 0 k 2k 2k 3k K2 2k2 7k2+k
a) Determine k.
b) P (x > 6), P (x ≤ 6), P (0 < x < 5), P (0 ≤ x ≤ 4), P (0 < x≤ 5), P (2 ≤ x < 6).
c) 𝐏|𝐗 − 𝟏| > 𝟑
d) 𝐏(𝟏. 𝟓 < 𝐗 < 𝟒. 𝟓⁄𝐗 > 𝟐)
e) Find Mean & Variance.
f) Find Cumulative Distribution Function.
g) If P (X ≤ k) > 1/2 find minimum of k.
Sol:
(a) Determine k
Since ∑ P(x) = 1
0+k+2k+2k+3k+k2+2k2+7k2+k = 1
10k2 + 9k = 1 10k2 + 9k -1 = 0 (k+1) (10k-1) = 0 k = -1 & k = 1/10
Since, probability can’t be negative, so k = 1/10
(b) P (x > 6), P (x ≤ 6), P (0 < x < 5), P (0 ≤ x ≤ 4), P (0 < x≤ 5), P (2 ≤ x < 6)
1 2 1 17
P(x > 6) = P(x = 7) = 7k 2 + k = 7 (10) + 10 = 100 = 0.17
17 83
P(x ≤ 6) = 1 − P(x = 7) = 1 − 100 = 100 = 0.83
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page7 of 24
P{(1.5 < X < 4.5) ∩ (𝑋 > 2)}
P(1.5 < X < 4.5⁄X > 2) =
𝑃(𝑋 > 2)
P{(X = 2,3,4) ∩ (𝑋 = 3,4,5,6,7)}
P(1.5 < X < 4.5⁄X > 2) =
𝑃(𝑋 = 3,4,5,6,7)
P(X = 3,4) 5𝑘 5
P(1.5 < X < 4.5⁄X > 2) = = 2
=
𝑃(𝑋 = 3,4,5,6,7) 10𝑘 + 6𝑘 7
(e) Find Mean & Variance.
Mean μ = E(X) = ∑ xP(x)
1 2 2 3 1 2 17 366
μ= 0∗0+1∗ +2∗ +3∗ +4∗ +5∗ +6∗ +7∗ = = 3.66
10 10 10 10 100 100 100 100
Variance σ2 = ∑ x 2 P(x) − μ2
1 2 2 3 1 2 17 84
∑ x 2 P(x) = 0 ∗ 0 + 1 ∗ +4∗ +9∗ + 16 ∗ + 25 ∗ + 36 ∗ + 49 ∗ =
10 10 10 10 100 100 100 5
84
σ2 = − (3.66)2 = 3.404
5
(f) Find Cumulative Distribution Function:
The definition of cumulative distribution function: F(x) = P (X ≤ x)
F(0) = P(X ≤ 0) = P(x = 0) = 0
1 1
F(1) = P(X ≤ 1) = P(x = 0) + P(x = 1) = 0 + =
10 10
1 2 3
F(2) = P(X ≤ 2) = P(x = 0) + P(x = 1) + P(x = 2) = 0 + + =
10 10 10
5
F(3) = P(X ≤ 3) = P(0) + P(1) + P(2) + P(3) =
10
8
F(4) = P(X ≤ 4) = P(0) + P(1) + P(2) + P(3) + P(4) =
10
81
F(5) = P(X ≤ 5) = P(0) + P(1) + P(2) + P(3) + P(4) + P(5) =
100
83
F(6) = P(X ≤ 6) = P(0) + P(1) + P(2) + P(3) + P(4) + P(5) + P(6) =
100
F(7) = P(X ≤ 7) = P(0) + P(1) + P(2) + P(3) + P(4) + P(5) + P(6) + P(7) = 1
Probability function is
X 0 1 2 3 4 5 6 7
1 2 2 3 1 2 17
P(x) 0
10 10 10 10 100 100 100
1 3 5 8 81 83
F(x) 0 1
10 10 10 10 100 100
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page8 of 24
(g) Since, If P(X ≤ k) > 1/2 and F(x) = P(X ≤ x)
1
P(X ≤ 0) = F(0) = 0 <
2
1 1
P(X ≤ 1) = F(1) = <
10 2
3 1
P(X ≤ 2) = F(2) = <
10 2
1 1
P(X ≤ 3) = F(3) = ≯
2 2
8 1
P(X ≤ 4) = F(4) = >
10 2
81 1
P(X ≤ 5) = F(5) = 100 > 2………. k = 4, 5, 6 7 Then k = 4 (minimum of k)
2. Let X be a random variable such that P(X=-2) = P(X=-1) = P(X=1) = P(X=2) and
P(X<0)=P(X=0)=P(X>0). Determine the p.m.f and c.d.f of X
Sol: Given values of X=-2, -1, 0, 1, 2
Given that P(X=-2)=P(X=-1)=P(X=1)=P(X=2)=k (Say) and missing term is P(X=0)
and also given that P(X<0)=P(X=0)
P(X=-2)+P(X=-1)= P(X=0)
K+K= P(X=0)
X -2 -1 0 1 2
P(X=0)=2k
P(x) K K 2k K K
The probability mass function is
since P(X=-2)+P(X=-1)+P(X=0)+P(X=1)+P(X=2)=1
6k=1 hence k=1/6
The cumulative distribution function: F(x) = P (X ≤ x)
1
F(−2) = P(X ≤ −2) = P(x = −2) =
6
2
F(−1) = P(X ≤ −1) = P(x = −2) + P(x = −1) = 2k =
6
4
F(0) = P(X ≤ 0) = P(x = −2) + P(x = −1) + P(x = 0) = 4k =
6
5
F(1) = P(X ≤ 1) = P(−2) + P(−1) + P(0) + P(1) =
6
F(2) = P(X ≤ 2) = P(−2) + P(−1) + P(0) + P(1) + P(2) = 1
X -2 -1 0 1 2
The PMF and CDF of X is P(x) 1/6 1/6 2/6 1/6 1/6
F(X) 1/6 2/6 4/6 5/6 1
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page9 of 24
𝟏
3. The probability function of an infinite discrete distribution is given by 𝑷(𝑿 = 𝒙) = 𝟐𝒙 for
x=1,2,3,4………(i) Verify it is a probability mass function (pmf) (ii) find mean (iii) variance (iv) P(X
is even) (v) 𝑷(𝑿 ≥ 𝟓) (vi) P(X is divisible by 3)
1
Sol: Given that P(X = x) = 2x for x=1,2,3….
∞ 1 1 1 1 1
∑ 𝑃(𝑋 = 𝑥) = (1 + + 2 + 3 + 4 + ⋯ … … … . . . . )
𝑥=1 2 2 2 2 2
Since (1 − 𝑥)−1 = 1 + 𝑥 + 𝑥 2 + 𝑥 3 + ⋯ ..
∞ 1 1 −1
∑ 𝑃(𝑋 = 𝑥) = (1 − ) = 1
𝑥=1 2 2
1
Hence 𝑃(𝑋 = 𝑥) = 2𝑥 is pmf
1 1 1 1
𝐸(𝑋 2 ) = {1.2 + 2.3 2 + 3.4 3 + 4.5 4 + ⋯ … … . } − 2
2 2 2 2
2 1 1 1
𝐸(𝑋 2 ) = {1 + 3 + 6 2 + 10 3 + ⋯ } − 2
2 2 2 2
Since (1 − 𝑥)−3 = 1 + 3𝑥 + 6𝑥 2 + 10𝑥 3 + ⋯ ..
1 1 −3
𝐸(𝑋 2 ) = (1 − ) − 2 = 8 − 2 = 6
2 2
Variance 𝑉(𝑋) = 𝐸(𝑋 2 ) − (𝐸(𝑋))2
𝑉(𝑋) = 6 − 4 = 2
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page10 of 24
(iv) P(X is even):
P(X is even)=P(X=2,4,6,8,….)
1 1 1 1
∑ 𝑃(𝑋 = 𝑥) = ∑ = + + +⋯
2x 22 24 26
𝑥=2,4,6.. 𝑥=2,4,6..
1 1 1 1
𝑃(𝑋 = 𝑒𝑣𝑒𝑛) = 2
(1 + 2 + 4 + 6 + ⋯ )
2 2 2 2
Since (1 − 𝑥)−1 = 1 + 𝑥 + 𝑥 2 + 𝑥 3 + ⋯ ..
1 1 −1 1
𝑃(𝑋 = 𝑒𝑣𝑒𝑛) = (1 − ) =
22 4 3
(v) 𝑷(𝑿 ≥ 𝟓)
1 1 1 1
𝑃(𝑋 ≥ 5) = ∑∞
𝑥=5 2x = 25 + 26 + 27 + ⋯
1 1 1
𝑃(𝑋 ≥ 5) = 5
(1 + + 3 + ⋯
2 2 2
Since (1 − 𝑥)−1 = 1 + 𝑥 + 𝑥 2 + 𝑥 3 + ⋯ ..
1 1 −1 1
𝑃(𝑋 ≥ 5) = 5 (1 − ) =
2 2 16
(vi) P(X is divisible by 3):
P(X is divisible by 3)=P(X=3,6,9,12,…..)
1 1 1 1 1 1 1 1
∑ 𝑃(𝑋 = 𝑥) = ∑ = + + + ⋯ = (1 + + + + ⋯)
2x 23 26 29 23 22 24 26
𝑥=3,6,9.. 𝑥=2,4,6..
Since (1 − 𝑥)−1 = 1 + 𝑥 + 𝑥 2 + 𝑥 3 + ⋯ ..
1 1 −1 1
∑ 𝑃(𝑋 = 𝑥) = (1 − ) =
23 8 7
𝑥=3,6,9..
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page11 of 24
Variance σ2 = ∑ x 2 P(x) – μ2
(d) V(2X+3)
V(2x+3)=4V(x)=4*2.877=11.55
𝒙+𝟏
5. A random Variable X takes the values 0,1,2,3…. With probability proportional to . Find
𝟓𝒙
Since P(X=x)=1
x+1
k =1
5x
1 2 2
k { + 2 + 3 + ⋯…} = 1
5 5 5
k {1 + 2𝑥 + 3x 2 + 4x 3 … … } = 1 where x=1/5
k(1 − 𝑥)−2 = 1
1 −2
k (1 − ) = 1
5
16
k=
25
16 x + 1
P(X = x) = , 𝑥 = 0,1,2,3 ….
25 5x
P(X ≤ 5) = P(X = 0) + P(X = 1) + P(X = 2) + P(X = 3) + P(X = 4) + P(X = 5)
16 2 3 4 5 6
P(X ≤ 5) = {1 + + 2 + 3 + 4 + 5 }
25 5 5 5 5 5
P(X ≤ 5) =
Mean 𝑬(𝑿) = ∑∞
𝒙=𝟎 𝒙. 𝑷(𝑿 = 𝒙)
∞ 16 x + 1
𝐸(𝑋) = ∑ 𝑥. x
𝑥=0 25 5
16 1.2 2.3 3.4
𝐸(𝑋) = {0 + + 2 + 3 + ⋯ ….
25 5 5 5
16 2 3 6
𝐸(𝑋) = . {1 + + 2 + ⋯ … . }
25 5 5 5
16 2 1
𝐸(𝑋) = 25 . 5 {1 + 3𝑥 + 6𝑥 2 + ⋯ … . } 𝑤ℎ𝑒𝑟𝑒 𝑥 = 5
Since (1 − 𝑥)−3 = 1 + 3𝑥 + 6𝑥 2 + ⋯ ..
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page12 of 24
32 1 −3 1
𝐸(𝑋) = (1 − ) =
125 5 2
Variance 𝑽(𝑿) = 𝑬(𝑿𝟐 ) − (𝑬(𝑿))𝟐
∞ ∞
2) 2
𝐸(𝑋 =∑ 𝑥 . 𝑃(𝑋 = 𝑥) = ∑ {𝑥(𝑥 + 2) − 2𝑥}𝑃(𝑋 = 𝑥)
𝑥=0 𝑥=1
∞ ∞
𝐸(𝑋 2 ) = ∑ 𝑥(𝑥 + 2)𝑃(𝑋 = 𝑥) − ∑ 2𝑥. 𝑃(𝑋 = 𝑥)
𝑥=0 𝑥=1
∞
𝐸(𝑋 2 ) = ∑ 𝑥(𝑥 + 2)𝑃(𝑋 = 𝑥) − 2𝐸(𝑋)
𝑥=0
∞ 16 (x + 1) 1
𝐸(𝑋 2 ) = ∑ 𝑥(𝑥 + 2) x
−2
𝑥=0 25 5 2
16 1 1 1 1
𝐸(𝑋 2 ) = {1.2.3 + 2.3.4 2 + 3.4.5 3 + 4.5.6 4 + ⋯ … … . } − 1
25 5 5 5 5
16 6 1 1
𝐸(𝑋 2 ) = . {1 + 4 + 10 2 + ⋯ } − 1
25 5 5 5
Since (1 − 𝑥)−4 = 1 + 4𝑥 + 10𝑥 2 +. . ..
16 6 1 −4 15
𝐸(𝑋 2 ) = (1 − ) − 1 =
25 5 5 8
15 1 13
Variance 𝑉(𝑋) = 𝐸(𝑋 2 ) − (𝐸(𝑋))2 = −4=
8 8
13
𝑉(𝑋) =
8
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page14 of 24
Tutorial Questions:
1. A random variable X has the following probability function Find the value of (a) k (b) 𝑃(𝑋 ≤ 2) (c)
𝑃(|𝑋| < 2) (d) c.d.f (e) mean (f) variance
-2 -1 0 1 2 3 X
P(X) 0.1 k 0.2 2k 0.3 3k
2. The probability mass function of a random variable is defined as P(X=0)=3c2, P(X=1)=4c-10c2,
P(X=2)=5c-1where c>0 and P(X=r)=0 if r ≠ 0,1,2 then (i) find the value of c (ii) P{(0<X<2)/ X>0}
(iii) distribution function of X (iv)largest value of X for which F(X)<1/2
3. If the random variable X takes the values 1,2,3,4 such that 2P(X=1)=3P(X=2)=P(X=3)=5P(X=4) then
find the probability distribution function and cumulative distribution function of X.
4. If P(X=x)=x/15, x=1,2,3,4,5. Find (i) P(X=1 or X=2) (ii) P{ (1/2<X<5/2)/ X>1}
5. Two dice are thrown. Let X assign to each point (a, b) in S the Maximum of its number i.e.,
X (a, b) max(a, b) .Find the probability distribution. Also find the mean and variance of the
distribution.
6. From a lot of 10 items containing 3 defectives, a sample if 4 items is are drawn at random. Let the
random variable x denote the number of defective items in the sample. Find the probability
distribution of X when the sample is drawn without replacement.
7. A fair coin is tossed until a head or five tails occurs. Find Expected Number E of tosses of the coin.
8. A player tosses two fair coins. He wins Rs.100/- If head appears, Rs.200/- If two heads appear. On
the other hand he losses Rs.500/- If no head appears, Determine the expected value E of the game and
is the game favorable to the player?
X -3 6 9
1 1 1
P(X)
6 2 3
1
9. Find the mean and variance of the uniform probability distribution given by f ( x) for
n
x 1, 2,3,.....n.
10. A player wins if he gets 5 on a single throw of a die, he loses if he gets 2 or 4. If he wins, he gets Rs.
50, if he losses he gets Rs.10, otherwise he has to play Rs.15. Find the value of the game to the
player. Is It favorable?
11. Let X denote the minimum of the two numbers that appears when a pair of fair dice is thrown once.
Determine the (i)Discrete probability distribution (ii) Expectation (iii) Variance
12. A player tosses 3 fair coins. He wins Rs. 500 if 3 heads appear, Rs. 300 if 2 heads appear, Rs. 100 if
1 head occurs. On the other hand, he loses Rs.1500 If 3 tails occur. Find the expected gain of the
player.
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page15 of 24
Problems on Continuous Random Variable:
1. A continuous random variable X has probability density function given by 𝐟(𝐱) = 𝐤𝐱 𝟐 , 𝟎 ≤ 𝐱 ≤ 𝟏
then find the value of (a) k (b) p(x<1/2) (c) p (x≥3/4)
∞
Sol: since f(x) is pdf so ∫−∞ f(x)dx = 1
1 1
(a)∫0 f(x)dx = 1 , ⇒ ∫0 kx 2 dx = 1 hence K=3
1 1 1
1 1 2 1
(b)P (X < 2) = P (0 < 𝑋 < 2) = ∫0 f(x)dx = ∫0 3x dx = 2 2 (x 3 )20 =8
3 3 1 1 37
(c)P (X ≥ 4) = P (4 < 𝑥 < 1) = ∫3 f(x)dx = ∫3 3x 2 dx = [x 3 ]13 = 64
4 4 4
2. In a continuous distribution, density function is given 𝐟(𝐱) = 𝐤𝐱(𝟐 − 𝐱), 𝟎 < 𝐱 < 𝟐, find
(a) Value of k
(b) Mean
(c) Variance
(d) Mean deviation
(e) C.D.F
𝟏 𝟏 𝟐
(f) 𝐏 {(𝐗 ≤ 𝟐) ∕ (𝟑 ≤ 𝐗 ≤ 𝟑)}
3
f(x) = (2x − x 2 ), 0 < x < 2
4
∞
∞ 2 2
2)
3 3
𝐸(𝑋 = ∫ x f(x)dx = ∫ 𝑥 . (2𝑥 − 𝑥 2 )dx = ∫(2𝑥 3 − 𝑥 4 )dx
2 2
4 4
−∞ 0 0
5 2
3 2x 4 x 6
E(𝑋 2 ) = [ − ] =
4 4 5 0 5
2 6 1
V(X) = E(X 2 ) − (E(X)) = 5 − 1 = 5
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page16 of 24
Mean deviation:
∞
2 𝑥 𝑖𝑓 𝑥 > 0
Mean deviation = ∫0 |x − 1| f(x)𝑑𝑥 since |x| = {
−𝑥 𝑖𝑓 𝑥 < 0
(𝑥 − 1) 𝑖𝑓 𝑥 − 1 > 0
|x − 1| = {−(𝑥 − 1)𝑖𝑓 𝑥 − 1 < 0
𝑥 = 1 𝑖𝑓 𝑥 − 1 = 0
2 1 2
3
Mean deviation =
8
Cumulative Distribution:
x x
1 1
𝑃 ((3 ≤ X ≤ 2))
1 1 2
P {(X ≤ ) ∕ ( ≤ X ≤ )} =
2 3 3 1 2
𝑃 (3 ≤ X ≤ 3)
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page17 of 24
1 1
2 2 1
1 1 3 3 x 3 2 3 71 71
𝑃 ( ≤ X ≤ ) = ∫ f(x)dx = ∫(2𝑥 − 𝑥 2 ) dx = [x 2 − ] = =
3 2 4 4 3 1 4 648 864
1 1 3
3 3
2 2
3 3 2
1 2 3 3 x 3 3 3 20 5
𝑃 ( ≤ X ≤ ) = ∫ f(x)dx = ∫(2𝑥 − 𝑥 2 ) dx = [x 2 − ] = =
3 3 4 4 3 1 4 81 27
1 1 3
3 3
71
1 1 2 864 71
P {(X ≤ ) ∕ ( ≤ X ≤ )} = =
2 3 3 5 160
27
The value of a such that 𝑷(𝑿 < 𝒂) = 𝑷(𝑿 > 𝒂)
𝑃(𝑋 < 𝑎) = 𝑃(𝑋 > 𝑎) = 1 − 𝑃(𝑋 < 𝑎)
a
1 1
2𝑃(𝑋 < 𝑎) = 1 ⟹ 𝑃(𝑋 < 𝑎) = ⟹ ∫ f(x) dx =
2 2
0
a a
3 1 x3 2 a3 2
∫(2𝑥 − 𝑥 2 ) dx = ⟹ [x 2 − ] = ⟹ a2 − = ⟹ a3 − 3a3 + 2 = 0
4 2 3 0 3 3 3
0
𝟎; 𝐱≤𝟏
𝟒
3.A random variable X has distribution function 𝐅(𝐱) = {𝐤(𝐱 − 𝟏) ; 𝟏 < 𝒙 ≤ 𝟑 then find
𝟏; 𝐱>𝟑
(a) Probability density function (b)k (c) Mean (d)Variance
Sol:
0; x≤1
d 3
a) We know that F(x) = f(x) = {4k(x − 1) ; 1 < 𝑥≤3
dx
0; x>3
∞
b) Since ∫−∞ f(x) dx = 1
1 3 ∞
Let x-1=t
3
x 13
μ = ∫ (x − 1)3 dx =
4 5
1
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page18 of 24
∞
c) σ2 = ∫−∞ x 2 f(x)dx − μ2
∞ 3 x2
∫−∞ x 2 f(x)dx = ∫1 4
(x − 1)3 dx
2 56
let x-1=t we get ∫0 (1 + t)2 𝑡 3 dt = 4
∞
56 169
σ2 = ∫ x 2 f(x)dx − μ2 = − = 7.24
4 25
−∞
𝐱; 𝟎≤𝐱<𝟏
4. The probability distribution of random variable X is 𝐟(𝐱) = {𝟐 − 𝐱; 𝟏 ≤ 𝐱 < 𝟐 then computes the
𝟎; 𝐱≥𝟐
cumulative distribution function of X and find 𝐏(𝐗 ≤ 𝟏. 𝟓)
d x
Sol: we have dx F(x) = f(x) or F(x) = ∫−∞ f(x)dx
x
If x<0 then F(x) = ∫−∞ f(x)dx = 0
x 0 x x x2
If 0≤x<1 then F(x) = ∫−∞ f(x)dx = ∫−∞ f(x)dx + ∫0 f(x)dx = 0 + ∫0 xdx = 2
x 0 1 x
If 1≤x<2 then F(x) = ∫−∞ f(x)dx = ∫−∞ f(x)dx + ∫0 f(x)dx + ∫1 f(x)dx
x 1 x 1 x
x2 x2 x2
F(x) = ∫ f(x)dx = 0 + ∫ xdx + ∫(2 − x)dx = [ ] + [2x − ] = 2x − − 1
2 0 2 1 2
−∞ 0 1
x 0 1 2 x
If x≥2 then F(x) = ∫−∞ f(x)dx = ∫−∞ f(x)dx + ∫0 f(x)dx + ∫1 f(x)dx + ∫2 f(x)dx
1 2 1 2
x2 x2
F(x) = 0 + ∫ xdx + ∫(2 − x)dx + 0 = [ ] + [2x − ] = 1
2 0 2 1
0 1
x2
; 0≤x<1
2
The cumulative distribution function is F(x) = x2
2x − 2 − 1; 1 ≤ x < 2
{ 1; x≥2
𝐏(𝐗 ≤ 𝟏. 𝟓):
1.5 0 1 1.5
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page19 of 24
5. The time one has to spend in point of a bank counter is observed to be a random variable with the
𝟏
(𝐱+𝟏); 𝟎≤𝐱<𝟏
𝟗
𝟒 𝟏 𝟑
(𝐱− ); 𝟏≤𝐗<
𝟗 𝟐 𝟐
𝟒 𝟓 𝟑
p.d.f. 𝐟(𝐱) = ( −𝐱); ≤𝐗<𝟐 Let be the events defined as
𝟗 𝟐 𝟐
𝟏
(𝟒−𝐱); 𝟐≤𝐱<𝟑
𝟗
𝟏
{𝟗 ; 𝟑≤𝐱<𝟔
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page20 of 24
1
P(A ∩ B) 3 2
P(A⁄B) = = =
P(A) 1 3
2
̅∩B
P(A ̅̅̅̅̅̅̅
̅) = P(A ∪ B) = 1 − P(A ∪ B) = 1 − P(A) − P(B) + P(A ∩ B)
1 1 1 1
̅∩B
P(A ̅) = 1 − − − =
2 2 3 3
̅∩B
A ̅) = 𝑃(𝑥 > 3) = 1
̅∩B
̅ means the waiting time more than 3 minutes i.e; P(A
3
𝒌𝐱𝐞−𝛌𝐱 , 𝐢𝐟 𝐱 ≥ 𝟎
6. A continuous random variable has the p.d.f 𝐟(𝐱) = { Then find k, Mean, and
𝟎, 𝐨𝐭𝐡𝐞𝐫 𝐰𝐢𝐬𝐞
Variance.
Sol:
∞ 0 ∞
a) Since ∫−∞ f(x) dx = 1 ⇒ ∫−∞ f(x) dx + ∫0 f(x) dx = 1
∞
⇒ ∫0 kxe−λx dx = 1
Since ∫ uv = uv1 − u′ v2 + u″ v3 − ⋯ … ..
∞
e−λx e−λx
⇒ k {𝑥 ( ) − 1 ((−𝜆)2 )} = 1
−𝜆 0
∞
𝑥 1
⇒ k{ − } =1
−𝜆e−λx 𝜆2 e−λx 0
1
⇒ k{(0 + 0) − (0 − )} = 1
𝜆2
k
⇒ λ2 = 1 ⇒ k = λ2
∞ 0 ∞
b) Mean 𝜇 = ∫−∞ x f(x)dx = ∫−∞ xf(x) dx + ∫0 xf(x) dx
∞ ∞
𝜇 = 0 + ∫0 x k xe−λx dx ⇒ λ2 ∫0 x 2 e−λx dx
∞
𝜇 = λ ∫ x 2 e−λx dx
2
Since ∫ uv = uv1 − u′ v2 + u″ v3 − ⋯ … ..
∞
e−λx e−λx e−λx
𝜇 = λ2 {(x 2 ) ( ) − (2𝑥) ((−𝜆)2 ) + 2 ((−𝜆)3 )}
−𝜆 0
∞
x2 2𝑥 2
𝜇 = λ2 { −λx
− 2 −λx + 3 −λx }
−𝜆e 𝜆 e −𝜆 e 0
2
𝜇 = λ2 {(0 + 0 + 0) − (0 + 0 − )}
𝜆3
2
𝜇=
𝜆
∞
c) Variance σ2 = ∫−∞ x 2 f(x)dx − μ2
∞ 0 ∞
Now ∫−∞ x 2 f(x)dx = ∫−∞ x 2 f(x) dx + ∫0 x 2 f(x) dx
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page21 of 24
∞ ∞
∫ x 2 f(x)dx = 0 + ∫ x 2 kx e−λx dx
−∞ 0
∞ ∞
∫ x 2 f(x)dx = λ2 ∫ x 3 e−λx dx
−∞ 0
∞ ∞
2 2 3)
e−λx e−λx e−λx e−λx
∫ x f(x)dx = λ {(x ( ) − (3x 2 ) ( ) + (6𝑥) ( ) + 6 ( )}
−𝜆 (−𝜆)2 (−𝜆)3 (−𝜆)4
−∞ 0
∞ ∞
2
x3 3x 2
2
6𝑥 6
∫ x f(x)dx = λ { − + + }
−𝜆e−λx 𝜆2 e−λx −𝜆3 e−λx 𝜆4 e−λx 0
−∞
∞
6
∫ x 2 f(x)dx = λ2 {(0 + 0 + 0 + 0) − (0 + 0 + 0 + )}
𝜆4
−∞
∞
6
∫ x 2 f(x)dx =
λ2
−∞
∞ 6 4 2
σ2 = ∫−∞ x 2 f(x)dx − μ2 = λ2 − λ2 = λ2
7. Experience has shown that while walking in a certain park, the time X (in minutes) between
seeing two people smoking has a density function of the form 𝒇(𝒙) = 𝝀𝒙𝒆−𝒙 , 𝒙 > 𝟎. Find λ and
cumulative distribution functions of X, mean and variance. Also find the probability that who
has just seen person smoking in 2 to 5 minutes.
∞ ∞
Sol: Since ∫−∞ f(x) dx = 1 ⇒ ∫0 f(x) dx = 1
∞
⇒ λ ∫0 xe−x dx = 1 Since ∫ uv = uv1 − u′ v2 + u″ v3 − ⋯ … ..
e−x e−x ∞
⇒ λ {𝑥 ( −1 ) − 1 ((−1)2 )} = 1 ⇒ λ{(0 + 0) − (0 − 1)} = 1 ⇒ λ = 1
0
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page22 of 24
e−x e−x e−x ∞
𝜇 = {(x 2 ) ( −1 ) − (2𝑥) ((−1)2 ) + 2 ((−1)3 )} = λ2 {(0 + 0 + 0) − (0 + 0 − 2)} = 2
0
σ = ∫ x 2 f(x)dx − μ2
2
−∞
∞ ∞
Now ∫−∞ x 2 f(x)dx = ∫0 x 3 e−x dx
∞ ∞
2 3)
e−x 2
e−x e−x e−x
∫ x f(x)dx = {(x ( ) − (3x ) ( ) + (6𝑥) ( )+6 ( )}
−1 (−1)2 (−1)3 (−1)4 0
−∞
∞
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page23 of 24
Tutorial Questions:
1. The length of the time (in minutes) that certain lady speaks on the telephone is found to be random
phenomenon, with probability function specified by p.d.f f(x) = 𝐴 e−x/5 , 𝑥 ≥ 0 (i) find the value of A and
what is the probability that the number of minutes she will talk over the phone is (a) more than 10 minutes
(b)less than 5 minutes (c) between 5 to 10 minutes.
1
2. If X is the continuous random variable has the density function f(x) = 4 , |𝑥| < 2 then find
k (1 x 2 ), for 0 x 1
3. If the probability density of a random variable is given by f ( x) Find the
0, otherwise
value of k and the probability that a random variable having this probability density will take on a value
(i) between 0.1 and 0.2 (ii) greater than 0.5.
x if 0 x 1
4. If X is the continuous random variable whose density function is f ( x) 2 x if 1 x 2
0, otherwise
Find E (25 X 2 30 X 5)
5. A random variable X gives measurements x between 0 and 1with a probability function
12 x3 21x 2 10 x, 1 1
f ( x) for 0 x 1 (i) Find P X and P X (ii) Find a number k
0, otherwise 2 2
1
such that P( X k )
2
6. For the continuous random variable X whose probability density function is given by
cx(2 x), if 0 x 2
f ( x)
0, otherwise Where C is constant. Find c, mean and variance of X.
7. The trouble shooting capacity of an IC chip in a circuit is a random variable X whose distribution
0, if x 3
function is given by F ( x) Where X denote the number of years. Find the
1 9 , for x 3
x2
probability that the IC chip will work properly (i)Less than 8 years (ii) Beyond 8 years (iii) Between 5
to 7 years.
..................................................................... ..................................................................................................... .
D. Ashok Reddy, Assistant Professor, RGUKT- Nuzvid Page24 of 24