1 0DiscreteRandomVariables
1 0DiscreteRandomVariables
Random Variables
• Discrete Random Variable: A RV that can take only a finite set
of outcomes
FY ( ) 0 FY () 1
FY ( y ) is monotonica lly increasing in y
Exercise 1
Example 2 – Rolling 2 Dice (Red/Green)
Y = Sum of the up faces of the two die. Table gives value of y for all elements in S
Red\Green 1 2 3 4 5 6
1 2 3 4 5 6 7
2 3 4 5 6 7 8
3 4 5 6 7 8 9
4 5 6 7 8 9 10
5 6 7 8 9 10 11
6 7 8 9 10 11 12
Rolling 2 Dice – Probability Mass Function
Y PY(y)
2 1/36
3 2/36
4 3/36 # of ways 2 die can sum to y
PY ( y )
5 4/36 # of ways 2 die can result in
6 5/36
7 6/36
8 5/36
9 4/36
10 3/36
11 2/36
12 1/36
Rolling 2 Dice – Probability Mass Function
0.18
0.16
0.14
0.12
0.1
p(y)
0.08
0.06
0.04
0.02
0
2 3 4 5 6 7 8 9 10 11 12
y
Rolling 2 Dice – Cumulative Distribution Function
Y PY(y) FY(y)
2 1/36 1/36 y
3 2/36 3/36 FY ( y ) PY ( y )
4 3/36 6/36
2
5 4/36 10/36
6 5/36 15/36
7 6/36 21/36
8 5/36 26/36
9 4/36 30/36
10 3/36 33/36
11 2/36 35/36
12 1/36 36/36
Rolling 2 Dice – Cumulative Distribution Function
Dice Rolling - CDF
0.9
0.8
0.7
0.6
F(y)
0.5
0.4
0.3
0.2
0.1
0
1 2 3 4 5 6 7 8 9 10 11 12 13
y
Expected Values of Discrete RV’s
Mean : E (Y ) yPY ( y )
all y
Mean of a function g (Y ) : E g (Y ) g ( y ) PY ( y )
all y
Expected Values of Discrete RV’s
2
Variance : V (Y ) E (Y ) 2
2
( y ) PY ( y ) y 2 y PY ( y )
2 2
all y all y
y PY ( y ) 2 yPY ( y )
2 2
P ( y)
Y
all y all y all y
2 2
E Y 2 ( ) (1) E Y 2 2
8 5/36 40/36
9 4/36 36/36
10 3/36 30/36
11 2/36 22/36
12 1/36 12/36
Sum 36/36= 252/36=
1.00 7.00
Example – Rolling 2 Dice
y PY(y) yPY(y) y2 y2PY(y)
2 1/36 2/36 4 4/36
3 2/36 6/36 9 18/36
4 3/36 12/36 16 48/36
5 4/36 20/36 25 100/36
2 E Y 2 2 y 2 p ( y ) 2
12
6 5/36 30/36 36 180/36
y 2
7 6/36 42/36 49 294/36
8 5/36 40/36 64 320/36 54.8333 (7.0) 2 5.8333
9 4/36 36/36 81 324/36 5.8333 2.4152
10 3/36 30/36 100 300/36
11 2/36 22/36 121 242/36
12 1/36 12/36 144 144/36
Sum 36/36 252/36 1974/36=
=1.00 =7.00 54.833
Bernoulli Distribution
• An experiment consists of one trial. It can result in one of 2
outcomes: Success or Failure (or a characteristic being Present
or Absent).
• Probability of Success is p (0<p<1)
• Y = 1 if Success (Characteristic Present), 0 if not
p y 1
p ( y ) (Probability Density Function)
1 p y 0
• Expected value?
• Variance?
• Standard deviation?
Bernoulli Distribution
• An experiment consists of one trial. It can result in one of 2
outcomes: Success or Failure (or a characteristic being Present
or Absent).
• Probability of Success is p (0<p<1)
• Y = 1 if Success (Characteristic Present), 0 if not
p y 1
p ( y ) (Probability Density Function)
1 p y 0
1
E (Y ) yp ( y ) 0(1 p ) 1 p p
y 0
E Y 2 0 2 (1 p ) 12 p p
V (Y ) E Y 2 E (Y ) p p 2 p (1 p )
2
p (1 p )
Binomial Experiment
• Experiment consists of a series of n identical trials
• Each trial can end in one of 2 outcomes: Success or
Failure
• Trials are independent (outcome of one has no
bearing on outcomes of others)
• Probability of Success, p, is constant for all trials
• Random Variable Y, is the number of Successes in the
n trials is said to follow Binomial Distribution with
parameters n and p
• Y can take on the values y=0,1,…,n
• Notation: Y~Bin(n,p)
Binomial Distribution
n y
P (Y y ) p (1 p ) n y y 0,1,..., n
y
EXCEL Functions :
PY ( y ) is obtained by function : BINOMDIST( y, n, p,0)
FY ( y ) is obtained by function : BINOMDIST( y, n, p,1)
Binomial Distribution (n=10, p=0.50)
0.5
0.45
0.4
0.35
0.3
p(y)
0.25
0.2
0.15
0.1
0.05
0
0 1 2 3 4 5 6 7 8 9 10
y
Binomial Distribution(n=10,p=0.8)
0.35
0.3
0.25
0.2
p(y)
0.15
0.1
0.05
0
0 1 2 3 4 5 6 7 8 9 10
y
Binomial Distribution (n=10,p=0.10)
0.5
0.45
0.4
0.35
0.3
p(y)
0.25
0.2
0.15
0.1
0.05
0
0 1 2 3 4 5 6 7 8 9 10
y
Binomial Distribution – Expectations
E (Y ) np
Var (Y ) np (1 p )
np (1 p )
Poisson Distribution
Often used to model the number of incidences of
some characteristic in time or space (e.g. arrivals of
customers in a queue)
y
e
PY ( y ) y 0,1,2,...
y!
T
Poisson Distribution - Expectations
E (Y )
V (Y )
Excel Functions :
PY ( y ) : Poisson ( y, ,0)
FY ( y ) : Poisson ( y, ,1)