Chapter 3-Random - Variables
Chapter 3-Random - Variables
RANDOM VARIABLE
11/25/2021 1
11/25/2021 2
11/25/2021 3
11/25/2021 4
Two Types of Random Variables
• A discrete random variable can assume a countable
number of values.
– Number of steps to the top of the Eiffel Tower*
• A continuous random variable can assume any value
along a given interval of a number line.
– The time a tourist stays at the top
once s/he gets there
*Believe it or not, the answer ranges from 1,652 to 1,789. See Great Buildings
11/25/2021 5
• Discrete random variables
– Number of sales
– Number of calls
– Shares of stock
– People in line
– Mistakes per page
11/25/2021 6
For discrete
random variable
11/25/2021 7
11/25/2021 8
For discrete random variable
11/25/2021 9
11/25/2021 10
X
a) Find PMF of X
b) Find P(X>3)
11/25/2021 11
11/25/2021 12
CDF and PDF of Continuous Random Variable
For a continuous random variable X we have a function f, called the probability density
function (pdf). Every probability density function must satisfy
X X
11/25/2021 13
1. Example: Metal Cylinder Production
f ( x)
49.5 50.5 x
11/25/2021 14
This is the valid PDF as area under curve is 1
50.5
49.5
(1.5 6( x 50.0) 2 ) dx [1.5 x 2( x 50.0)3 ]50.5
49.5
x
F ( x) P( X x) f ( y )dy
dF ( x)
f ( x)
dx
P (a X b) P ( X b) P ( X a )
F (b) F (a)
P (a X b) P (a X b)
11/25/2021 16
Cumulative Distribution Function
x
F ( x) P( X x) (1.5 6( y 50.0) 2 ) dy
49.5
11/25/2021 17
X
11/25/2021 18
11/25/2021 19
11/25/2021 20
In mathematics, the moments of a function are quantitative
measures related to the shape of the function's graph
11/25/2021 21
11/25/2021 22
Discrete Random variable Example
Example: Two Boxes contains 7 balls each, numbered from 1 to 7. one ball is
selected randomly from the each Box. Let Random variable X be the difference of the
numbers (that is, the largest number minus the smallest number) of the selected
balls. Find the probability distribution or PMF of X, CDF and its mean, variance and
standard deviation.
11/25/2021 23
Step II: find random variable X (difference of highest to lowest value)
Step III. Find PMF (or probability distribution for discrete random variable)
11/25/2021 24
Find CDF: Do your self
Mean value or Expected of discrete random variable X
11/25/2021 25
11/25/2021 26
Continuous RV
11/25/2021 27
11/25/2021 28
11/25/2021 29
11/25/2021 30
11/25/2021 31
11/25/2021 32
Exercise :
Let the random variable X denote the time a person waits for an elevator to
arrive. Suppose the longest one would need to wait for the elevator is 2
minutes, so that the possible values of X (in minutes) are given by the
interval [0,2]. A possible pdf for X is given by calculate mean , varience and
SD.
Thus, we expect a person will wait 1 minute for the elevator on average.
11/25/2021 33
Now we calculate the variance and standard deviation of X, by first
finding the expected value of X2
11/25/2021 34
Exercise:
11/25/2021 35
Solution :
11/25/2021 36
Up to now we have studied Discrete Distributions and Continuous Distributions, we
explored probability distributions of one random variable, say X.
Here, we'll extend many of the definitions and concepts that we learned to the
case in which we have two random variables, say X and Y
P ( X xi , Y y j ) pij 0
satisfying p
i j
ij 1
– Continuous
f ( x, y) 0 satisfying
state space
f ( x, y)dxdx 1
11/25/2021 37
• Joint Cumulative Distribution Function
– Discrete
F ( x, y ) P ( X xi , Y y j )
F ( x, y )
i:xi x j: y j y
pij
– Continuous
x y
F ( x, y ) f ( w, z )dzdw
w z
11/25/2021 38
• Example : Air Conditioner Maintenance
– A company that services air conditioner units in
residences and office blocks is interested in how
to schedule its technicians in the most efficient
manner
– The random variable X, taking the values 1,2,3 and
4, is the service time in hours
– The random variable Y, taking the values 1,2 and 3,
is the number of air conditioner units
p ij 0.12 0.18
1 0.12 0.08 0.07 0.05 i j
0.07 1.00
11/25/2021 40
Conditional Probability Distribution for Discrete Random
Variables
11/25/2021 41
11/25/2021 42
11/25/2021 43
Continue...
11/25/2021 44
Conditional probability Distribution for Continuous Random Variables
(Conditional probability density function)
The probability distribution of a continuous random variable can be characterized
by its probability density function (pdf). When the probability distribution of the
random variable is updated, by taking into account some information that gives
rise to a conditional probability distribution, then such a distribution can be
characterized by a conditional probability density function.
11/25/2021 45
Continue..
11/25/2021 46
11/25/2021 47
11/25/2021 48
Exercise :
11/25/2021 49
11/25/2021 50
11/25/2021 51
Exercise :
11/25/2021 52
Solution:
11/25/2021 53
Continue..
11/25/2021 54
Exercise:
Solution:
11/25/2021 55
• A Gaussian random variable is one whose probability density function can
be written in the general form
11/25/2021 56
Special Distribution:
Continuous Probability Distributions
UNIFORM DISTRIBUTION
PDF CDF
11/25/2021 57
EXPONENTIAL DISTRIBUTION
PDF CDF
Applications: To model navigation and pilot errors, speech, and image processing.
11/25/2021 59
CAUCHY DISTRIBUTION
Application: A Cauchy distribution is a good indicator of how sensitive the tests are to heavy-
tail departures from normality.
BETA DISTRIBUTION
11/25/2021 60
Discrete Probability Distributions
BERNOULLI DISTRIBUTION
A single event is Bernoulli distributed if the probability of success is p and probability of
failure is q
BINOMIAL DISTRIBUTION
The probability b(k; n, p) that the event A occurs exactly k times in n Bernoulli trials.
This is called the binomial distribution, and b(k;n,p) is called a probability mass function
11/25/2021 61
POISSON DISTRIBUTION
In the regular Poisson distribution the cumulative distribution has unit jumps at random times
and not at discrete times. Thus, it is discrete in state but continuous in time.
Applications:
11/25/2021 62
GEOMETRIC DISTRIBUTION
11/25/2021 63
NEGATIVE BINOMIAL DISTRIBUTION
Let us now define the following events to find this distribution
HYPERGEOMETRIC DISTRIBUTION
The binomial distribution is obtained while sampling with replacement. Let us
select a sample of n microprocessor chips from a bin of N chips. It is known
that K of these chips are defective.
If we sample with replacement then the probability of any defective chip is K/N.
11/25/2021 64
The probability that k of them will be defective in a sample size of n is given by the
binomial distribution since each drawing of a chip constitutes a Bernoulli trial.
On the other hand, if we sample without replacement, then the probability for the first
chip is K/N, the probability for the second chip is (K- 1)/(N-1), and for each succeeding
sample the probability changes.
Hence the drawings of the chips do not constitute Bernoulli trials and binomial
distribution does not hold. Hence we have to use alternate methods to arrive at the
probability of finding k defective chips in n trials.
11/25/2021 65
Thank You...
11/25/2021 66