Discrete Random Variables (Chapter 3) : Example 1
Discrete Random Variables (Chapter 3) : Example 1
Discrete Random Variables (Chapter 3) : Example 1
(Recall that an experiment consists of two things: what is done, and what is observed.)
Let Y be the number of Hs which come up.
Show that Y is a random variable.
The experiment here has 4 possible outcomes: TT, TH, HT, TT.
Also:
Y = 0 if the outcome is TT
Y = 1 if the outcome is TH or HT
Y = 2 if the outcome is HH.
STAT2001_CH03A Page 2 of 10
The probability that a discrete random variable Y takes on a particular value y is the
sum of the probabilities of all sample points in the sample space S that are associated
with y.
We write this probability P(Y = y).
The probability distribution (pr dsn) of a discrete random variable Y is any
information which provides P(Y = y) for each possible value y of Y.
This information may take the form of a list, table, function (formula) or graph.
Example 2
table
graph
P(Y = y)
0
1
2
1/4
1/2
1/4
STAT2001_CH03A Page 3 of 10
another graph
formula
1/ 4, y = 0, 2
P(Y = y ) =
1/ 2, y = 1
another formula
P (Y = y ) =
P (Y = y ) =
1
21+( y1)
y = 0,1,2
1
,
2(1+ | y 1|)
y {0,1, 2}
0 p ( y ) 1 for all y.
(Every value of the pdf must be at least 0 and no more than 1.)
2.
p( y ) = 1 .
y
STAT2001_CH03A Page 4 of 10
Example 3
1/ 4, y = 2
Thus Y has pdf p ( y ) =
1/ 8, y = 3
etc
(Equivalently, p ( y ) = 1/ 2 y , y = 1, 2,3,... )
We observe that Property 1 is satisfied, since 1/2, 1/4, 1/8, ... are all between 0 and 1.
Also,
STAT2001_CH03A Page 5 of 10
Example 4
124
567
1
=
6
5 + 1 5 1 5 + + 5
6 6 6 6 6
6
7 1 3 5 4
=
3 6 6
1
6
7
( identical terms)
3
(= 0.0781) .
7 1 5
Similarly, P(Y = 2) =
2 6 6
(= 0.2344) , etc.
7 1 y 5 7 y
We see that p( y ) = ,
y 6 6
y = 0,, 7 .
y = 0, , n (n = 1, 2, 3,...; 0 p 1) .
STAT2001_CH03A Page 6 of 10
y =0 y
m
m
Note: We have here used the binomial theorem: (a + b)m = a x b m x
x=0 x
Example 5
y = 0, ,10 .
P (Y 2) = 0.055
Hence P (Y = 3)
( = p (3) )
STAT2001_CH03A Page 7 of 10
Example 6
A coin is tossed once. Let Y be the number of heads that come up.
What is Ys distribution? Write down Ys pdf.
y = 1, 2,3,
y = 1, 2,3,
(0 p 1) .
STAT2001_CH03A Page 8 of 10
(1 p) y1 p = p (1 p) x
y =1
(put x = y 1)
x= 0
= p
1
= 1 (Property 2).
1 (1 p )
Example 8
Let Y be the number of 1-hr periods until the first malfunction (including the 1-hr
period in which that malfunction occurs). Then Y ~ Geo(p), where p = 0.02.
Eg: A malfunction in the 3rd 1-hr period means that Y = 3.
P (Y > 2) = q y1 p
where q = 1 p = 0.98
y =3
= pq 2 q y12
y =3
= pq 2 q x
(after putting x = y 3)
x=0
= pq 2
1
= q 2 = 0.982 = 0.9604.
1 q
STAT2001_CH03A Page 9 of 10
Example 9
Number the 9 marbles 1,2,...,9, with the first 3 being white and the last 6 black.
Then the sample points may be represented by writing 12345, 12346, ..., 56789.
Note: We don't write 13245, because this represents the same sample point as 12345.
I.e., the distinct sample points correspond to strings of numbers in increasing order.
9
We see that the number of sample points is nS = .
5
The sample points associated with the event Y = 2 are 12456, 12457, ..., 23789,
36
and the number of these is n2 = .
23
Note: We require 2 numbers to be from 1,2,3, and the other 3 from 4,5,6,7,8,9.
36
n2 23
Hence P(Y = 2) =
=
9
nS
5
3
6
4
1
n
Similarly, P(Y = 1) = 1 =
9
nS
5
(=
3(20) 10
=
= 0.4762).
126
21
(=
3(15)
5
=
= 0.3571), etc.
126
14
3 6
5 y
y
We see that Y has pdf p ( y ) =
,
9
5
y = 0,1, 2, 3 .
STAT2001_CH03A Page 10 of 10
N r
n y
y
p( y ) =
,
N
n
y = 0, , r subject to 0 n y N r
(N = 1,2,3,...; r = 1,2,...,N;
n = 1,2,...,N ).
Example:
Solution: