Professional Documents
Culture Documents
Advanced Engineering Mathematics B.Tech. 2nd Year, III-Semester Computer Science & Engineering Lecture-3: Random Variables (Part-1)
Advanced Engineering Mathematics B.Tech. 2nd Year, III-Semester Computer Science & Engineering Lecture-3: Random Variables (Part-1)
Random Variables
Example (Ex-1:)
Suppose that a coin is tossed twice so that the sample space is
S = {HH, HT, TH, TT}. Let X represent the number of heads
that can come up. With each sample point we can associate a
number for X as shown below
Dr. Kamlesh Jangid, UD, RTU, Kota 3
Sample Point HH HT TH TT
X = Random Variable 2 1 1 0
There are two types of random variables follow as:
1. Discrete Random Variable: If a random variable assume
only a finite number or countably infinite numbers of values
of x, then X is called discrete random variable.
2. Continuous Random Variable: If a random variable takes an
infinite set of points in given interval or noncountably
infinite number of values of x, then X is called nondiscrete
or continuous random variable.
Remark
Random variable may be one-one or many one function.
Dr. Kamlesh Jangid, UD, RTU, Kota 4
Probability Distribution Function of a Discrete
Random Variable
Let X be a discrete random variable, and suppose that the
possible values that it can assume are given by x1 , x2 , x3 , ...,
arranged in some order. Suppose also that these values are
assumed with probabilities given by
Example (Ex-2:)
Find the probability function corresponding to the random
variable X of Example-1.
1
P(X = 0) = P(TT) =
4
1 1 1
P(X = 1) = P(HT ∪ TH) = P(HT) + P(TH) = + =
4 4 2
1
P(X = 2) = P(HH) =
4
The probability function is thus given by
X=x 0 1 2
P(X = x) = f (x) 1/4 1/2 1/4
where the sum is taken over all values u taken on by X for which
u ≤ x.
If X takes on only a finite number of values x1 , x2 , ..., xn , then the
distribution function is given by
Dr. Kamlesh Jangid, UD, RTU, Kota 9
0 −∞ < x < x1
x1 ≤ x < x2
f (x1 )
F(x) = f (x1 ) + f (x2 ) x2 ≤ x < x3
.. ..
. .
f (x ) + · · · + f (x ) xn ≤ x < ∞
1 n
Example (Ex-3:)
Find the distribution function for the random variable X of
Example-2.
0 −∞ < x < 0
0≤x<1
1/4
Sol.: The distribution function is F(x) =
3/4 1≤x<2
1 2≤x<∞
Dr. Kamlesh Jangid, UD, RTU, Kota 10
Probability Distribution Function of a Continuous
Random Variable
The probability distribution function or probability density
function (PDF) is the probability of the continuous random
variable falling within a particular range of values and defined as:
Z b
P(a < X < b) = f (x) dx (4)
a
Solution
R∞
(a) Since −∞
f (x)dx = 1 as f (x) is a density function. Thus
Z ∞ Z 3
1
f (x)dx = 1 ⇒ cx2 dx = 1 ⇒ c = .
−∞ 0 9
R2 R21 2 7
(b) P(1 < X < 2) = 1
f (x)dx = 1 9
x dx = 27
.
Solution
Here, X takes the values 0, 1, 2 and 3. First we find the
probability
7
C4 1
P(X = 0) = P(no defective) = 10 C
=
4 6
Dr. Kamlesh Jangid, UD, RTU, Kota 14
3
C1 ×7 C3 1
P(X = 1) = P(one defective) = 10 C
=
4 2
3 7
C2 × C2 3
P(X = 2) = P(two defective) = 10 C
=
4 10
3 7
C3 × C1 1
and P(X = 3) = P(three defective) = 10 C
=
4 30
(i) Hence, the probability distribution of X is given by
X 0 1 2 3
P(X) 1/6 1/2 3/10 1/30
1
(ii) P(X < 1) = P(X = 0) =
6
1
(iii) P(0 < X < 2) = P(X = 1) = .
2
Dr. Kamlesh Jangid, UD, RTU, Kota 15
Example (Ex-6:)
If a random variable X takes the values 1, 2, 3 and 4 such that
Solution
Let P(X = 3) = k, then from given relation, we get
k k k
P(X = 1) = , P(X = 2) = , and P(X = 4) = .
2 3 5
Example (Ex-7:)
A random variable X has the following probability distribution
X=x 0 1 2 3 4 5 6 7
P(x) 0 k 2k 2k 3k k2 2k2 7k2 + k
X 7
X
P(x) = 1 ⇒ P(X = x) = 1
x x=0
⇒ 0 + k + 2k + 2k + 3k + k2 + 2k2 + 7k2 + k = 1
1
⇒ 10k2 + 9k − 1 = 0 ⇒ k = or − 1
10
1
the value k = −1 is not possible, therefore k = .
10
Solution
Given
12.5x − 1.25 ; 0.1 ≤ x ≤ 0.5
f (x) =
0 ; elsewhere
Example (Ex-9:)
The diameter of an electric cable X is a continuous random
variable with
kx(1 − x) ; 0 ≤ x ≤ 1
f (x) =
0 ; elsewhere
Solution
(i) To find value of k, we use the property
Z ∞ Z 1
f (x)dx = 1 ⇒ kx(1 − x)dx = 1
−∞ 0
1
x2 x3
1 1
⇒k − =1⇒k − =1⇒k=6
2 3 0 2 3
Hence
f (x) = 6x(1 − x) ; 0 ≤ x ≤ 1.
P(A ∩ B)
P(A|B) =
P(B)
since
Z 2/5
1 2 2/5
P(B) = P <X< = 6x(1 − x)dx = (3x2 − 2x3 )1/2
2 5 1/2
and P (A ∩ B) = P (X = 1/2) = 0.
Thus
P (A|B) = 0.
Solution
(i) Since P(X > a) = 1 − P(X ≤ a)
∞ Z
1
(ii) Given P(X > b) = 0.05 ⇒ f (x)dx =
b 20
Z 1
1 1
⇒ 3x2 dx = ⇒ 1 − b3 =
b 20 20
31
19
⇒b=
20
Solution
d F(x) 2e−2x , x > 0
(a) The density function is f (x) = =
dx 0, x<0
= 1 − e−8 .