0% found this document useful (0 votes)
30 views26 pages

Probability Distributions and Random Variables

Uploaded by

sanaaaquarius
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views26 pages

Probability Distributions and Random Variables

Uploaded by

sanaaaquarius
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Department of Statistics & O.R.

Aligarh Muslim University Aligarh

BA/BSc II Semester

Probability and Probability Distributions

(STB 251)

by

Dr. Haseeb Athar


Unit - II
One Dimensional Random Variable
Contents:
• Definition of Random Variable
• Discrete Random Variable
• Continuous Random Variable
• Probability Mass Function
• Probability Density Function
• Distribution Function and it’s Properties
• Univariate Transformation

2 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Random Variable

Need for Random Variable


In any random experiment the points of the sample space may be numeric or non-numeric.
For example, if we roll a die, then sample space is S={1,2,3,4,5,6}, which is numeric. But,
when we toss two unbiased coins together, then sample space is S={HH, HT, TH, TT},
which is non-numeric or descriptive.
In the real world, the outcomes of many random experiments may be non-numeric. Thus, it is
inconvenient to deal with these descriptive outcomes mathematically. In scientific
community, we always feel convenient in dealing with numerical outcomes, whether the
outcomes of a random experiment results are numeric or non-numeric. Hence, for ease of
manipulation, we may assign a real number to each of the outcomes using a fixed rule or
mapping. For example, when we toss a coin, we get two outcomes, namely head or tail.
Instead of dealing the outcomes descriptively as head or tail; we can assume numerical
values, say ‘1’ to head and ‘0’ to tail. This interpretation is easy and attractive from
mathematical point of view and also practically meaningful.

Definition of Random Variable


A random variable (r.v.) is a real valued function defined over the sample space of a random
experiment.
Let X be a real valued function that assigns a real number X ( s ) to every element
s  S (i.e. X : S → R ) , where S is the sample space corresponding to the random experiment
E. Then X is called a random variable.
Example 2.1
Suppose that we toss two coins. The sample space associated with this experiment is
S = {HH , HT , TH , TT}.
Then we can define a random variable X as follows:
X: The number of heads obtained in two tosses. Then assigned numerical values to the
outcomes are

X(HH) = 2, X(HT) = 1, X(TH) = 1 , X(TT) = 0.

S X

2
HH
HT 1
TH
TT 0

Note that the set of possible values of the random variable X is

X = {0,1, 2}
Note: X is a single valued function.

3 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Discrete Random Variable
A random variable (r.v.) is said to be discrete if its set of possible values is either finite or
countably infinite.
Examples:
1. Roll a die and define
X: Number shown at top
Then set of possible values of X is {1,2,3,4,5,6}, which is finite set. Thus, X is a
discrete r.v.
2. Let X be the number of wattsap messages received between given time period. Then
set of possible values of is {0,1,2,3…}, which is countably infinite set. Thus, X is a
discrete random variable.

Probability Mass Function

Let X be a discrete r.v. having possible values x1, x2 ,..., xi ,... , then with each possible value
of X there associate a real number pi = P( X = xi ) = p( xi ) , such that

i) 0  p( xi )  1 for every i = 1, 2,..., 



ii)  p ( xi ) = 1
i =1

where, p( xi ) = P( X = xi ) is the probability that the r.v. X can take value xi . The set of
 p( xi ) is called probability mass function (pmf) and set of xi , p( xi ) is called probability
distribution.
Example 2.2: Two coins are tossed. Then sample space is {HH, HT, TH, TT}.
Define X: Number of heads coming up.
Here, set possible values of X is {0, 1, 2} and probability at each value of X is
1
P(TT)=P( X = 0) =
4
1
P(HT,TH) = P( X = 1) =
2
1
P(HH) = P( X = 2) =
4
Thus, probability distribution is
X : 0 1 2
P ( X = x) : 0.25 0.5 0.25

Here 0  p( xi )  1 and  p ( xi ) = 1
i =1

Therefore, above probability distribution is the valid probability distribution.

4 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Example 2.3: A shipment of 8 similar microcomputers to a retail outlet contains 3 that are
defective. If a school makes a random purchase of 2 of these computers, find the probability
distribution for the number of defectives.
Solution: The sample space associated with the experiment of purchasing two defective
computers is S = {NN, DN, ND, DD}
Let X be the number of defective computers purchased. Then the set of possible values of X
is {0, 1, 2}.
No. of ways in which out of 8 computers 2 computers can be selected = 8C2
Consider the following events
( X = 0) = {0 D and 2 N }  n( X = 0) = 3C0  5C2

( X = 1) = {1D and 1N }  n( X = 1) = 3C1  5C1

( X = 2) = {2 D and 0 N }  n( X = 2) = 3C2  5C0

n( X = 0) 3C0  5C2 10
P( X = 0) = = 8
=
n( S ) C2 28

n( X = 1) 3C1  5C1 15
P( X = 1) = = 8 =
n( S ) C2 28

n( X = 2) 3C2  5C0 3
P( X = 2) = = 8
=
n( S ) C2 28

In general, for X = 0,1, 2 , we can write

n( X = x) 3C x  5C2− x
P( X = x) = = 8
n( S ) C2
Therefore, probability distribution of X is

X 0 1 2
P( X = x) 10/28 15/28 3/28

Finally, we can write


 3   5 
   
  x   2 − x  ; x = 0, 1, 2
P( X = x) =  8 
  
  2
0; otherwise
Note: The above probability distribution is Hypergeometric Distribution.

5 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Continuous Random Variable

A r.v. X is said to be continuous if it can take all possible values between certain limits.

Examples:
1. A class is given 30 min. test. Let X be the time taken by the student who finishes first.
Then set of all possible value of X is { X : 0  X  30} , which is infinite set. Hence, X is
a continuous random variable.
2. Let T be the lifetime of an item put on test. Then set of all possible values of T is
{T : 0  T  } , which is infinite set. Hence, T is a continuous random variable.
3. Let X be the number of points between 1 and 2. Then set of possible values of X is
{ X : 1  X  2} , which is infinite set. Hence, X is a continuous random variable.

Probability Density Function


 x  x
Consider the small interval  x − ,x+ of length  x → 0 around the point x . Let
 2 2 
f ( x ) be any continuous function of x , so that f ( x ) dx represents the probability that X

 x  x
falls in the infinitesimal interval  x − ,x+ . That is
 2 2 

x x
P( x −  X  x+ ) = f X ( x)dx
2 2

Then f ( x ) is called probability density


function (pdf), if it satisfies the following
conditions: f ( x ) dx

i) f ( x )  0 for every x
y = f ( x)

ii) − f ( x)dx = 1 x

iii) For any two real numbers a and b ,


− 
such that −  a  b   , then x x
(x − ) (x + )
b 2 2
P (a  X  b) = a f ( x )dx

6 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Remarks:
i) If X is a continuous random variable, then it can assume infinite number of values in
an interval. This interval may be finite or infinite.
For example:
X  (0,10) : finite interval
X  (0, ) : infinite interval
X  (−, ) : infinite interval
x
ii) P( X = x0 ) = 0 as x 0 f ( x)dx = 0 .
0

iii) P(a  X  b) = P(a  X  b)


= P ( a  X  b)
= P ( a  X  b)
Example 2.4: Suppose X is a continuous r.v. and f ( x ) be a continuous function of X and
defined as

f ( x) = 0, x  2
1
= (3 + 2 x), 2  X  4
18
= 0, otherwise
i) Show that f ( x ) is a pdf.
ii) Find the probability that a variate having this density will fall in the interval 2  X  3 .
Solution:
i) Here f ( x )  0 for every x in the given interval.
and
 2 4 
− f ( x)dx = − f ( x)dx + 2 f ( x)dx + 4 f ( x)dx
1 4
=0+  (3 + 2 x)dx + 0
18 2
=1
Hence f ( x ) is a density function.
3
ii) P (2  X  3) = 2 f ( x)dx

1 3 4
= 2
(3 + 2 x)dx = .
18 9

7 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Example 2.5: Check the validity of following density function.

f ( x) = 6 x(1 − x), 0  X  1
Solution: f ( x)  0  x  (0,1)
and
1 1
0 f ( x)dx = 0 6 x(1 − x)dx

= 6  0 xdx − 0 x 2 dx  = 1 .
1 1
 
Hence f ( x ) is a density function.

Example 2.6: Let X be a continuous random variable with pdf


f ( x) = kx, 0  X  1
= k, 1  X  2
= k (3 − x), 2  X  3
= 0, otherwise
Solution: We know that

− f ( x)dx = 1
1 2 3 
 0 f ( x)dx + 1 f ( x)dx + 2 f ( x)dx + 3 f ( x )dx = 1
1 2 3 
or 0 kx dx + 1 k dx + 2 (3 − x)k dx + 3 0. dx = 1
1 3
 x2   x2 
k   + k  x 1 + 3k  x 2 − k   + 0 = 1
2 3
or
 2  0  2  2

k 9k
or + k + 3k − + 2k = 1
2 2

1
 k= .
2
Practice Problem 2.1: Let X is a continuous random variable. Show that following the are
valid density functions.

i) f ( x) = px p−1,0  x  1
ii) f ( x) =  e− x , x  0.
iii) f ( x) = 1, 0  x  1 .
1
iv) f ( x) = , a xb
b−a

8 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Practice Problem 2.2: Let the r.v X has density function

f ( x) = ke− x (1 − e− x ), x  0 .
Find the value of k such that f ( x ) is a density function.

Practice Problem 2.3: Suppose that the error in the reaction temperature, in 0C , for a
controlled laboratory experiment is a continuous random variable X having the following
probability density function:
1 2
 x ; −1  x  2
f ( x) =  3

0 ; elsewhere
a) Check the validity of above density function
b) Compute P ( 0  x  1)

Cumulative Distribution Function


Let X be a random variable, discrete or continuous. We define F to be the cumulative
distribution function (cdf) or distribution function (df) of the X , where F ( x) = P ( X  x ) .
• If X is a discrete random variable with pmf p( x) , then
F ( x) = P( X  x) =  p ( x)
x
• If X is a continuous random variable with pdf f ( x ) , then
x
F ( x) = P ( X  x ) = − f (t )dt

Properties of Distribution Function


1. The function F is non-decreasing. That is, if x1  x2 , then F ( x1 )  F ( x2 ) .

2. lim F ( x ) = 0 or F ( −) = 0
x →−

and lim F ( x) = 1 or F () = 1


x →

3. a) If F be the cdf of a continuous random variable with pdf f , then


d
i) f ( x) = F ( x) for all x at which F is differentiable.
dx
ii) P(a  X  b) = P( X  b) − P( X  a )
= F (b) − F (a)

b) If X is a discrete random variable with possible values x1, x2 ,..., and

x1  x2  ...  xi −1  xi  ... , then

i) P( X = xi ) = F ( xi ) − F ( xi −1 )

9 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
ii) P(a  X  b) = P( X  b) − P( X  a ) = F (b) − F (a)
P(a  X  b) = P(a  X  b) + P( X = a) = F (b) − F (a ) + p (a )
P(a  X  b) = P(a  X  b) − P( X = b) = F (b) − F (a) − p(b)
Discrete Case
Let the discrete random variable X takes values x1, x2 ,..., xn with respective probabilities
p1, p2 ,..., pn and let x1  x2  ...  xn . Then

F ( x1 −) = P( X  x1 ) = 0

F ( x1 ) = P( X  x1 ) = P( X  x1 ) + P( X = x1 ) = 0 + p1

F ( x2 ) = P( X  x2 ) = P( X  x2 ) + P( X = x2 ) = p1 + p2

F ( xi ) = P( X  xi ) = P( X  xi ) + P( X = xi ) = p1 + p2 + ... + pi −1 + pi

F ( xn ) = P( X  xn ) = P( X  xn ) + P( X = xn ) = p1 + p2 + ... + pn−1 + pn
Therefore,
 0 ; −   X  x1
p ; x  X  x
 1 1 2
 p1 + p2 ; x2  X  x3
F ( x) = P( X  x) = 

 p1 + p2 + ... + pi −1 + pi ; xi  X  xi +1

1; xn  X  
Example 2.7: Suppose that the random variable X assumes the values 0, 1 and 2 with
probabilities 10/28, 15/28 and 3/28 respectively.
i) Determine the distribution function of X .
ii) Using cdf, find F (−0.5), F (1.5), F (3.8), P(0.5  X  1.5) and P (1  X  2) .

Solution:

We know that
F ( x) = P( X  x) =  p ( x)
x
For X  0 : F (0) = P( X  0) = 0

10 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
10
For 0  X  1: F (1) = P ( X  1) = P ( X = 0) =
28
10 15 25
For 1  X  2 : F (2) = P( X  2) = P( X = 0) + P( X = 1) = + =
28 28 28
For X  2 (2  X  ) : F () = P( X  ) = P( X = −1) + P( X = 0) + P( X = 1)
10 15 3
= + + =1
28 28 28
Therefore, the cdf or df of random variable X is

 0 ; x0
 10
 ; 0  x 1
 28
F ( x) = P( X  x) = 
 25 ; 1  x  2
 28
1 ; x2

F (−0.5) = P( X  −0.5) = 0
25
F (1.5) = P( X  1.5) = F (1) =
28
F (3.8) = P( X  3.8) = F (2) = 1
P(0.5  X  1.5) = F (1.5) − F (0.5)
25 10 15
= − =
28 28 28
25 3
P(1  X  2) = F (2) − F (1) = 1 − =
28 28
Example 2.8: A random variable X has probability function
x +1
p( x) = , x = 0,1, 2
6
= 0, otherwise
i) Check, whether above is valid probability distribution.
ii) Find cumulative distribution function of X.

Solution: The probability distribution is given as


X : 0 1 2
P( X = x) : 1/6 1/3 1/2

i) Here 0  p ( x)  1 and  p( x) = 1
Therefore, above probability distribution is the valid probability distribution.

11 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
ii) In −  X  0 : F ( x) = P( X  0) = 0

In 0  X  1: F ( x) = P( X  1) = P( X = 0) = 1/ 6

In 1  X  2 : F ( x) = P( X  2) = P( X = 0) + P( X = 1)
1 1 1
= + =
6 3 2
In 2  X   (or X  2) : F ( x) = P( X  ) = P( X = 0) + P( X = 1) + P( X = 2)
1 1 1
= + + =1
6 3 2
Therefore, cdf of r.v. X is
 0 ; x0
1
 ; 0  x 1
6
F ( x) = P( X  x) = 
1 ; 1  x  2
2
1 ; x2

Example 2.9: A random variable X has the following probability function

X: −2 −1 0 1 2 3

P( X = x) : 0.1 k 0.2 2k 0.3 3k

i) Find k.
ii) Evaluate P( X  2), P( X  2), P (| X | 2) .
iii) Find the minimum value of k such that P ( X  1)  0.36 .
iv) Determine distribution function of X.
Solution: (i) We know that
 p ( x) = 1
 0.1 + k + 0.2 + 2k + 0.3 + 3k = 1

or k = 1/15

(ii) P( X  2) = P( X = −2) + P( X = −1) + P( X = 0) + P( X = 1)


= 0.1 + k + 0.2 + 2k = 0.3 + 3k
= 0.3 + 0.2 = 0.5
P( X  2) = 1 − P( X  2) = 1 − 0.5 = 0.5
P(−2  X  2) = P( X = −1) + P( X = 0) + P( X = 1)
= k + 0.2 + 2k = 3k + 0.2 = 0.2 + 0.2 = 0.4

12 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
(iii) P( X  1) = P( X = −2) + P( X = −1) + P( X = 0) + P ( X = 1)
= 0.1 + k + 0.2 + 2k
= 3k + 0.3
Now, we have

P ( X  1)  0.36
3k + 0.3  0.36
or 3k  0.06
 k = 0.02

(iv) The cdf of r.v. X is


0 ; X  −2
1
 ; − 2  X  −1
10
F ( x) = P( X  x) = 
14 ; −1  X  3
15
1 ; X 3

Example 2.10: 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).
Write down probability distribution of X. Also, determine distribution function of X.
Solution: Let
P( X = −2) = P( X = −1) = P( X = 1) = P( X = 2) = k

P( X  0) = P( X = 0) = P( X  0) = p .
Since P( X  0) + P( X = 0) + P( X  0) = 1
 3 p = 1 or p = 1/ 3
Therefore,
P( X  0) = P( X = 0) = P( X  0) = 1/ 3
1
Now P ( X  0) =
3
 P( X = −2) + P( X = −1) = 1/ 3
or 2k = 1/ 3
 k = 1/ 6
Therefore, probability distribution of X is
X: −2 −1 0 1 2
P( X = x) : 1/6 1/6 1/3 1/6 1/6

13 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Now we have to find distribution of X is
In −  X  −2 : F ( x) = P( X  −2) = 0
In −2  X  −1: F ( x) = P( X  −1) = P( X = −2) = 1/ 6
In −1  X  0 : F ( x) = P( X  0) = P( X = −1) + P( X = −2)
1 1 1
= + =
6 6 3
In 0  X  1: F ( x) = P( X  1) = P( X = −2) + P( X = −1) + P( X = 0)
1 1 1 2
= + + =
6 6 3 3
In 1  X  2 : F ( x) = P( X  2) = P( X = −2) + P( X = −1) + P( X = 0) + P( X = 1)
1 1 1 1 5
= + + + =
6 6 3 6 6
In −2  X   : F ( x) = P( X  ) = P( X = −2) + P( X = −1) + P( X = 0)
+ P( X = 1) + P( X = 2) = 1

Therefore, cdf of r.v. X is


 0 ; X  −2
1
 ; − 2  X  −1
6
1
 ; −1  X  0
3
F ( x) = P( X  x) = 
2 ; 0  X 1
3
5
 ; 1 X  2
6
 1 ; X  2

Example 2.11: The distribution function F ( x ) of a r.v. X is defined as follows:


F ( x) = A, −   X  −1
= B, − 1  X  0
= C, 0  X  2
= D, 2  X  
where A, B, C and D are constants. Determine the values of A, B, C and D , it is given that
1 2
P ( X = 0) = and P( X  1) =
6 3
Solution:
A = F (−) = 0

14 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
P( X = 0) = F (0) − F (−0) = C − B

1
 P ( X = 0) = C − B = (*)
6
P( X  1) = 1 − P( X  1)
= 1 − F (1) = 1 − C

2 2 1
 1− C = , then C = 1 − = .
3 3 3
1
Using (*), we get B =
6
and F ( ) = D = 1 .

Finally, A = 0, B = 1/ 6, C = 1/ 3 and D = 1 .

Practical Problem 1: From a lot containing 12 items, 4 of which are defective, 5 are chosen
at random. If X be the number of defectives found in the sample.
(a) Write down probability distribution of X,
i) if items are chosen by without replacement procedure.
ii) If items are chosen by with replacement procedure.
b) Check the validity of above written probability distributions.
c) Compute P( X  1) , P(1  X  3) and P( X  3) for both the cases
d) Determine cumulative distribution function of X. Also find the probability given in
(c) using cdf and compare.

Continuous Case:
Example 2.12: Suppose that the error in the reaction temperature, in 0C , for a controlled
laboratory experiment is a continuous random variable X having the following probability
density function:
1 2
 x ; −1  x  2
f ( x) =  3

0 ; elsewhere
a) Find the cdf
b) Compute P ( 0  X  1)

Solution: (a)

For x  −1
x x
F ( x ) =  f(t)dt =  0 dt = 0
- -

15 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
For -1  x  2
x −1 x x
1 1
F ( x ) =  f(t)dt =  0 dt +  t 2 dt =  t 2 dt
- - -1 3 -1 3

1 3
= ( x + 1)
9
For x  2
x −1 2 x
1
F ( x ) =  f(t)dt =  0 dt +  t 2 dt +  0 dt = 1
- - -1 3 2

Therefore, cdf is
 0 ; x  −1
1

F ( x) = P( X  x) =  ( x3 + 1) ; − 1  x  2
9
1 ; x2

(b) P(0  X  1) = F (1) − F (0)


2 1 1
= − =
9 9 9
Example 2.13: The probability density function of a random variable X is
 x, 0  X  1

f ( x ) =  2 − x, 1  X  2
0, X  2

Compute the cdf of X.
Solution:
For any x in X  0
x x
F ( x) = P ( X  x) = − f (t )dt = − 0. dt =0

For any x in 0  X  1

x x x2
F ( x ) = P ( X  x ) = 0 f (t )dt = 0 t dt =
2
For any x in 1  X  2
x
F ( x) = P( X  x) = − f (t )dt
0 1 x
= − f (t )dt + 0 f (t )dt + 1 f (t )dt
1 x
= 0 + 0 tdt + 1 (2 − t )dt
1 x2 1 x2
= + 2x − 2 − + = 2x −1−
2 2 2 2

16 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
For every x in X  2
x
F ( x) = P ( X  x) = − f (t )dt
0 1 2 
= − f (t )dt + 0 f (t )dt + 1 f (t )dt + 2 f (t )dt
1 2
= 0 + 0 tdt + 1 (2 − t )dt + 0
1 1
= + 2− 2+ =1
2 2
Therefore, cdf is
 0 ; X 0
 2
x ; 0  X 1
2
F ( x) = P( X  x) = 
 x2
 2 x − 1 − ; 1 X  2
2

 1; X  2
Example 2.14: The diameter of an electric cable, say X is assumed to be continuous random
variable with pdf
f ( x) = 6 x(1 − x), 0  X  1
i) Obtain the expression for the cdf of X.
ii) Determine a number b such that P( X  b) = 2 P( X  b) .
Solution: (i) The cdf of X is given by
x
F ( x) = P ( X  x ) = − f (t )dt

x
= 0 6t (1 − t )dt

= 3 x 2 − 2 x3 , X  1
(ii) We have given that
P ( X  b ) = 2 P ( X  b)
or P( X  b) = 2[1 − P ( X  b)]
2
or P ( X  b) =
3
2
 F (b ) =
3
 6b2 − 9b3 − 2 = 0
Now solve above equation to get the value of b.

17 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Example 2.15: Let X be a continuous rv with pdf given as

f ( x) = ke− x (1 − e− x ), X  0,   0.
Find k and compute the P( X  1) using cdf.
Solution: We know that

− f ( x)dx = 1
Thus,
 − x − x
0 ke (1 − e )dx = 1
Consider 1 − e− x = t   e− x dx = dt , then
k 1
 tdt = 1
 0
 k = 2
x
Now F ( x) = P ( X  x) = 0 f (t )dt

= 2 0 e − t (1 − e − t )dt
x

Again suppose 1 − e− t = z   e− t dt = dz and t = 0  z = 0; t = x  z = 1 − e− x


Therefore,
1−e− x
F ( x) = 2 0 z dz = 1 − 2e − x + e −2 x , X  0 .

Now P( X  1) = 1 − P( X  1)
= 1 − F (1)

= 2e− − e−2 ,   0 .
Practice Problem 2.5: Let X is a continuous random variable. Find cdf for following pdfs

i) f ( x) = px p−1,0  x  1
ii) f ( x) = px − p−1,1  x  
iii) f ( x) =  e− x , x  0.
iv) f ( x) = 1, 0  x  1 .
1
v) f ( x) = , a xb
b−a

Practice Problem 2.6: An unbiased die is rolled. If the die shows 1 or 2, a number is
selected at random from the interval [0, 1]. If the die shows 3, 4, 5 or 6, a number is selected
at random from the interval [1, 2]. Find the distribution function of the number selected.

18 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Univariate Transformation

Discrete Case
Let X be a discrete r.v. with pmf p( x) = P( X = x) . Suppose X is defined over A [e.g. if
X ~ B(n, p) , then A = {x | x = 0,1, 2,...n} ]. If we define another variable Y = w( x) , that
transforms A onto B and transformation is one to one (monotone transformation), then for
every x  A , there exists a unique y  B and vice-versa.

In such a case, the pmf of Y denoted by g ( y ) is given by


g ( y ) = P(Y = y ) = P(Y = w( x)) = P( X = x)
Example 2.16: Let the distribution of a discrete r.v. X is given as
X: 0 1 2 3 4
P( X = x) : 0.2 0.3 0.3 0.1 0.1
Find the distribution of Y = 2 X + 1 .
Solution: We have
A = {x | x = 0,1, 2,3, 4}

and B = { y | y = 1,3,5, 7,9}


Here transformation is monotone. Then
P(Y = 1) = P( X = 0) = 0.2
P (Y = 3) = P ( X = 1) = 0.3
and so on.
Therefore, the distribution of Y is
Y: 1 3 5 7 9
P( X = x) : 0.2 0.3 0.3 0.1 0.1
Example 2.17: The pmf of a discrete r.v. X is given by
x +1
p( x) = , x = 0,1..., 6
28
= 0, o.w.

19 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
3X + 2
Find the pmf of Y = .
2
Solution: We have
A = {x | x = 0,1, 2, , 6}

and B = { y | y = 1, 2.5, ,10}


Here transformation is monotone and
3X + 2 2y − 2
Y= x=
2 3
Therefore, the pmf of Y is
g ( y ) = P(Y = y ) = P ( X = x)

 2y − 2 
= P X = 
 3 

 2y − 2 
 3 +1 
= , y  B
 28 
 
2 y +1
g ( y) = , yB
 84
= 0, ow
Example 2.18: If the distribution of a discrete r.v. X is given by
e−  x
P( X = x) = , x = 0,1, 2,...;   0. : Poisson distribution
x!
Find the distribution of Y = 4 X .
Solution: We have
A = {x | x = 0,1, 2...}
and B = { y | y = 0, 4,8...}
Here transformation is monotone.
y
Also Y = 4 X  x = .
4
Therefore,
g ( y ) = P( X = x)
 y
= P X = 
 4
e −   ( y /4)
= , y = 0, 4,8...
( y / 4)!
= 0, ow

20 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Practice Problem 2.7: Let the pmf of a discrete r.v. X is
n
P ( X = x ) =   p x (1 − p ) n − x , x = 0,1,..., n
 x : Binomial distribution
= 0, ow

Find the pmf of Y = X 2 .


1
Practice Problem 2.8: Let X has pmf p( x) = , x = 1, 2,3 . Find the pmf of Y = 2 X + 1 .
3
Practice Problem 2.9: Let X has the pmf
1
p( x) = , x = 1, 2,3,...
2x
= 0, ow

Find pmf of Y = X 3 .
Practice Problem 2.10: Let the r.v. X has the pmf
x
p( x) = , x = 1, 2,3, 4,5
15
= 0, ow
1
Find the pmf of (i) Y = X − 1 , (ii) Z = X 2 − 1 , (iii) W = X and (iv) U = .
X
Remark: If the transformation from X to Y is not monotone, that means transformation is
many to one, then the pmf of Y can be obtained by adding the probabilities of all the possible
values of X that define a particular value of Y.

A B

-2
0
-1
0 1
1 2
2
2

2 to 1 transformation
Example 2.19: A discrete r.v. X takes values -2, -1, 0, 1, 1 each with probability 1/5. Find
the pmf of Y =| X | .
Solution: We have given that
1
p( x) = , x = −2, − 1, 0,1, 2
5
= 0, o.w.

21 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Here A = {x | x = −2, −1, 0,1, 2}
and therefore,

B = { y | y = 0,1, 2}
Since the member of elements in B is less than those in A, the transformation is not one to
one. Therefore, pmf of Y can be found as follows
1
P(Y = 0) = P ( X = 0) =
5

P(Y = 1) = P( X = −1or X = 1)
= P( X = −1) + P( X = 1)
1 1 2
= + =
5 5 5

P(Y = 2) = P( X = −2 or X = 2)
= P( X = −2) + P( X = 2)
1 1 2
= + =
5 5 5
which implies

Y : 0 1 2
g ( y) : 1/5 2/5 2/5

Example 2.20: The pmf of a discrete r.v. is

P( X = x) = k ( x2 + 1), x = −2, −1,0,1, 2

Find the value of k for which this is a valid pmf. Hence, find the distribution of Y = X 2 + 1.

Solution: Since  p( x) = 1
1
 k=
15
Hence pmf of X is
1 2
P( X = x) = ( x + 1), x = −2, −1, 0,1, 2
15
Here A = {x | x = −2, − 1, 0,1, 2}
and therefore,

B = { y | y = 1, 2,5}
Thus, the transformation is not monotone.

22 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Now
1
P(Y = 1) = P ( X = 0) =
15
P(Y = 2) = P( X = −1or X = 1)
= P( X = −1) + P( X = 1)
2 2 4
= + =
15 15 15

P(Y = 5) = P( X = −2 or X = 2)
= P( X = −2) + P( X = 2)
5 5 10 2
= + = =
15 15 15 3
y
15 , y = 1
g ( y) = 
 2 y , y = 2,5
 15

Continuous Case
Distribution Function Method of Transformation

Let X be a continuous r.v. with pdf f ( x ) and Y = h( x ) be a some function of X, then


distribution of Y can be obtained as below:
Let G ( y ) be the distribution function (df) of Y. That is
G ( y ) = P(Y  y )
= P ( h( X )  y )
= P( X  h −1 ( y ))
= F (h −1 ( y )), (*)
where F (.) is the distribution function of X.
Differentiating (*) w.r.t y, we get
d
g ( y ) = G( y ) = G( y)
dy
Example 2.21: Let X is uniformly distributed over the interval ( −1,1) . Find the pdf of
Y = X2.
Solution: We have given that X ~ U (−1,1) , then
1
f ( x) = , −1  x  1
2
= 0, elsewhere

Distribution of Y = X 2 is given by

23 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
G ( y ) = P (Y  y )
= P( X 2  y )
= P( X   y )
= P (− y  X  y)
y
= − y
f ( x)dx
1 y
=  dx = y
2 − y
 G( y) = y , y  (0,1)
Therefore, the pdf of Y is
1
g ( y) = G( y ) = , 0  y  1.
2 y
Example 2.22: Let X ~ U (0,1) . Find the pdf of Y = aX + b , using distribution function
method of transformation.
Solution: Since X ~ U (0,1) , therefore
f ( x) = 1, 0  x  1
and F ( x ) = x, 0  x  1
Let G ( y ) be the df of Y, then
G ( y ) = P (Y  y )
= P (aX + b  y )
y −b
= P( X  )
a
 y −b 
= F 
 a 
y −b
= , b  y  a+b
a
Therefore, the pdf of Y is

1
g ( y ) = G( y ) = , b  y  a+b
a
Example 2.23: Let the probability density function of X is
f ( x) = 6 x(1 − x), 0  x  1
= 0, elsewhere
Find the probability distribution of Y = X 3 .

Solution: Let G ( y ) be the df of Y at Y = y .

24 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Therefore,
G ( y ) = P (Y  y )
= P( X 3  y)
= P ( X  y1/3 )
y1/3
= 0 6 x (1 − x) dx
 G( y) = 3 y 2/3 − 2 y, 0  y  1.
Thus,
g ( y) = G( y) = 2 y −1/3 − 2

or g ( y) = 2( y −1/3 −1),0  y  1.

Jacobian Method of Transformation


Consider a continuous r.v. X having pdf f ( x ) defined over a one-dimensional space A.
Define one-to-one transformation Y = u ( X ) that maps A onto B, where B is some other one-
dimensional space. Let X = w( X ) be the inverse transformation such that Jacobian,
dx
J= = w( y ) exists and is continuous over B. Then pdf of Y is
dy
g ( y ) = f ( w( y )) | J |, y  B
= 0, elsewhere
Example 2.24: Let the r.v. X has pdf
f ( x ) = 2 x, 0  x  1
= 0, elsewhere

Find the pdf of Y = X 2 .


Solution: We have given that
A = {x | 0  x  1}

The transformation of Y = X 2 is monotone and A onto B, where


B = { y | 0  y  1}
Therefore, inverse transformation is given by
x = w( y ) = y1/2

dx 1 −1/2
and Jacobian | J |= = y .
dy 2
The pdf of Y is
g ( y ) = f ( x) | J |
1 −1/2
= 2 y1/2  y
2
= 1, 0  y  1.

25 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India
Example 2.25: A r.v. X has pdf
x2
f ( x) = ,0  x  3
9
Find the distribution of Y = X 3 .
Solution: We are given that
A = {x | 0  x  3}
The transformation of Y = X 3 is one-to-one and maps A onto B, where
B = { y | 0  y  27} .
The inverse transformation is given by
dx 1 −2/3
x = y1/3 and | J |= = y
dy 3
Therefore, the pdf of Y is

g ( y ) = f ( x) | J |

( y1/3 ) 2 1 −2/3
=  y , yB
9 3
1
= , 0  y  27 .
27
Example 2.26: A r.v. X has the pdf

f ( x) = 2 xe− x , x  0.
2

Determine the distribution of Y = X 2 .


Solution: We are given that A = {x | x  0}
The transformation is one-to-one (monotone) and A onto B, where B = { y | y  0}.

dx 1 −1/2
The inverse transformation is x = y1/2 and | J |= = y
dy 2
Hence, the pdf of Y is

g ( y ) = f ( x) | J |
1 −1/2
= 2 y1/2 e − ( y
1/ 2 2
)
 y , yB
2
 g ( y ) = e − y , y  0.

26 Lecture notes by Dr. Haseeb Athar, Department of Statistics & O.R., A.M.U., Aligarh, India

Common questions

Powered by AI

The cumulative distribution function (CDF) of a continuous random variable allows calculating the probability that the variable falls within a specific interval. For example, to find P(a < X ≤ b), where X is a continuous random variable with PDF f(x), calculate F(b) - F(a), where F(x) is the CDF found by integrating f(x) from -∞ to x. This property makes CDFs a versatile tool for evaluating probabilities over intervals .

Key properties of a cumulative distribution function (CDF) include: 1) F(x) is non-decreasing; if x1 ≤ x2, then F(x1) ≤ F(x2). 2) It approaches 0 as x approaches negative infinity, and it approaches 1 as x approaches positive infinity. 3) For continuous random variables, F'(x) equals the PDF f(x) where F is differentiable .

The properties of distribution functions, such as being non-decreasing, approaching 1 as x approaches infinity, and defining probabilities as differences of CDF values, guide practical probability calculations. These properties ensure consistency in calculating probabilities and support the application of integration in continuous distributions. Each property provides a framework to assess the behavior of probability distributions, enabling sound statistical inference and decision-making .

The Jacobian method involves transforming the PDF of a continuous random variable when a one-to-one (monotone) transformation is applied. If X has a PDF f(x) defined on a space A, a transformation Y=g(X) maps A onto a new space B. The Jacobian |dx/dy| is the derivative of the inverse transformation w(y), where w(y) is such that Y=w(X). The PDF of the transformed variable Y is g(y) = f(w(y)) * |J(y)|, where J(y) is the Jacobian determinant evaluated at y .

Consider a discrete random variable X with a pmf given by X : 0 1 2 3 4 with respective probabilities 0.2, 0.3, 0.3, 0.1, and 0.1. The transformation Y = 2X + 1 maps the domain of X onto a new domain B = {1, 3, 5, 7, 9}. Consequently, the probabilities are adjusted so that P(Y=1) = P(X=0) = 0.2, P(Y=3) = P(X=1) = 0.3, and so on, maintaining the total probability .

A monotone transformation in the context of discrete random variables allows for mapping one random variable's domain onto another's while maintaining the probability structure. When a random variable X is transformed into Y via a monotonic function Y=w(X), each value of X has a unique corresponding value of Y, preserving the relationship between their probabilities. Such transformations enable the derivation of the new probability mass function (pmf) of Y from the pmf of X .

When a continuous random variable X with a given PDF f(x) undergoes a transformation into another variable Y via Y=g(X), the PDF of Y is derived via the transformation's Jacobian. For instance, if X has a PDF of 2x, 0<x<1, and Y=X^2, the PDF of Y, g(y), is obtained by rewriting X=sqrt(y) and determining the Jacobian dx/dy. This yields g(y) = (1/√y) * (1/2√y) = 1, 0<y<1, illustrating how the transformation modifies the support and scale of the PDF .

A hypergeometric distribution differs from a binomial distribution primarily in sampling without replacement. In hypergeometric distribution, the probability changes after each draw because items are not replaced, affecting the composition of the population. In contrast, a binomial distribution involves sampling with replacement, keeping the probability constant across trials .

The cumulative distribution function (CDF) of a continuous random variable X, given its probability density function (PDF) f(x), is computed by integrating f(x) from -∞ to x. Mathematically, this is expressed as F(x) = ∫[from -∞ to x] f(t) dt. This integral provides the probability that the random variable X will take a value less than or equal to x .

To determine if a function is a valid probability density function (PDF), it must satisfy two main criteria: 1) The function f(x) must be non-negative for all x, i.e., f(x) ≥ 0 for all x. 2) The integral of f(x) over its entire domain must equal 1, that is ∫[over all x] f(x) dx = 1. If both conditions are met, the function is a valid PDF .

You might also like