0% found this document useful (0 votes)
116 views4 pages

MATH 11300 Probability AUTUMN 2010: Problem Sheet 6 - Solutions

This document provides solutions to probability problems involving joint and conditional probability mass functions (pmfs). Specifically: 1) It finds the joint pmf pX,Y(x,y) and the conditional pmfs pX|Y(x|y) and pY|X(y|x) for two random variables X and Y. 2) It calculates the probabilities of events involving two geometrically distributed random variables X and Y. 3) It defines random variables X and Y based on rolling dice and finds their joint and marginal pmfs. 4) It expresses the conditional pmf pX|Y(x|12) in terms of the marginal pmfs pX(x), pY

Uploaded by

niksurveys
Copyright
© Attribution Non-Commercial (BY-NC)
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)
116 views4 pages

MATH 11300 Probability AUTUMN 2010: Problem Sheet 6 - Solutions

This document provides solutions to probability problems involving joint and conditional probability mass functions (pmfs). Specifically: 1) It finds the joint pmf pX,Y(x,y) and the conditional pmfs pX|Y(x|y) and pY|X(y|x) for two random variables X and Y. 2) It calculates the probabilities of events involving two geometrically distributed random variables X and Y. 3) It defines random variables X and Y based on rolling dice and finds their joint and marginal pmfs. 4) It expresses the conditional pmf pX|Y(x|12) in terms of the marginal pmfs pX(x), pY

Uploaded by

niksurveys
Copyright
© Attribution Non-Commercial (BY-NC)
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
You are on page 1/ 4

MATH 11300 Probability AUTUMN 2010

Problem Sheet 6 — Solutions


Questions marked * are to be handed in.

*1. (a) The marginal pmf for X is pX (x) = P(X = x). So

x 1 2 3 4
pX (x) 14 41 41 14

The conditional pmf for Y given X = x is

y 0 1
6−x x
pY | X (y | x) 6 6

(b) pX,Y (x, y) = pY | X (y | x)pX (x)

pX,Y (x, y) x = 1 x = 2 x = 3 x = 4 pY (y)


5 4 3 2 14
y=0 24 24 24 24 24
1 2 3 4 10
y=1 24 24 24 24 24
1 1 1 1
pX (x) 4 4 4 4

pX,Y (x,y)
(c) pX,Y (x, y) = pX | Y (x | y)pY (y), so pX | Y (x | y) = pY (y)
.

x 1 2 3 4
1 2 3 4
pX | Y (x | 1) 10 10 10 10

*2. (a) Using equally likely outcomes, or using the multiplication lemma,

pX,Y (x, y) y=0 y=1 y = 2 pX (x)


44×43 2×4×44 4×3 2256
x=0 52×51 52×51 52×51 52×51
2×4×44 2×4×4 384
x=1 52×51 52×51
0 52×51
4×3 12
x=2 52×51
0 0 52×51

(b) The marginal distribution pX (x) is given by the final column of the table.
pX,Y (x,0) 2256
(c) pX | Y (x | 0) = pY (0)
. Note that by symmetry pY (0) = pX (0) = 52×51
.

x 0 1 2
1892 352 12
pX | Y (x | 0) 2256 2256 2256

(d) X and Y are not independent, since it is not the case that pX,Y (x, y) = pX (x)pY (y)
for all x and y. For example
 2
12
pX,Y (2, 2) = 0 6= pX (2)pY (2) = .
2652
*3. Let X be the number of attempts of the husband, and Y the number of attempts of the
wife.
Both X and Y take values in the range 1,2,3,. . . .
Since they are independent,

P(X = x and Y = y) = P(X = x)P(Y = y) = p1 (1 − p1 )x−1 p2 (1 − p2 )y−1

(since X ∼ Geom(p1 ) and Y ∼ Geom(p2 )).

Sx∞be the event {X = x, Y = x}, and let A be the event {X = Y }. Then


(a) Let A
A = x=1 Ax , a disjoint union.

X ∞
X
P(A) = P(Ax ) = p1 p2 (1 − p1 )x−1 (1 − p2 )x−1
x=1 x=1

X p1 p 2
= p1 p1 [(1 − p1 )(1 − p2 )]m = .
m=0
1 − (1 − p1 )(1 − p2 )
S∞
(b) Let Bx = {X > x, Y = x} and let B = {X > Y }, so that B = x=1 Bx , a disjoint
union.

P(Bx ) = P(X > x, Y = x) = P(X > x)P(Y = x) by independence


= (1 − p1 )x p2 (1 − p2 )x−1

Therefore

X ∞
X
P(B) = P(Bx ) = (1 − p1 )x p2 (1 − p2 )x−1
x=1 x=1

X (1 − p1 )p2
= (1 − p1 )p2 [(1 − p1 )(1 − p2 )]m = .
m=0
1 − (1 − p1 )(1 − p2 )

*4. (a) An elementary outcome is ω = (r, g) with r, g = 1, 2, . . . , 6. There are 36 equally likely
sample points.
X takes values in 2,3,. . . ,12. Y takes values in 1, 2, . . . , 6.
By counting sample points we find the following joint pmf:

36 × pX,Y (x, y) x = 2 3 4 5 6 7 8 9 10 11 12 36 × pY (y)


y=1 1 0 0 0 0 0 0 0 0 0 0 1
y=2 0 2 1 0 0 0 0 0 0 0 0 3
y=3 0 0 2 2 1 0 0 0 0 0 0 5
y=4 0 0 0 2 2 2 1 0 0 0 0 7
y=5 0 0 0 0 2 2 2 2 1 0 0 9
y=6 0 0 0 0 0 2 2 2 2 2 1 11
36 × pX (x) 1 2 3 4 5 6 5 4 3 2 1

(b) The marginal pmfs of X and Y are given by the final row and column respectively.
1
(c) E(X) = 36 (2×1+3×2+4×3+5×4+6×5+7×6+8×5+9×4+10×3+11×2+12×1) = 7.
E(Y ) = 36 (1 × 1 + 2 × 3 + 3 × 5 + 4 × 7 + 5 × 9 + 6 × 11) = 161
1
36
.
(d) omega <- sample(1:6,2,replace=TRUE) samples a random sample point.
X <- function(omega) sum(omega) and Y <- function(omega) max(omega) cre-
ate the functions that correspond to the random variables X and Y defined above.
omegas <- matrix(sample(1:6,2*n.trials,replace=T),n.trials,2), as in pre-
vious sheets, rolls the dice 2*n.trials times and stores the values in a matrix with
n.trials rows and 2 columns.
X.vals <- apply(omegas,1,X) and Y.vals <- apply(omegas,1,Y) evaluate the
random variables at each sample point. Note that the nth X.val is jointly distributed
with the nth Y.val since they are both calculated from the same row of the omegas
matrix (i.e. they are both functions of the same sample point).
tabulate(X.vals)/n.trials and tabulate(Y.vals)/n.trials is an alternative to
looking at a histogram to see the marginal pmfs.
mean(X.vals) and mean(Y.vals) give the marginal sample means, which should be
close to E(X) and E(Y ) evaluated above.

5. Let X be the number of heads in the first 10 flips, and Y the total number of heads. X
takes values in 0, 1, . . . , 10. We want to know

pX,Y (x, 12)


pX | Y (x | 12) =
pY (12)

Firstly, notice that Y is the number of headsin 20 flips, so Y ∼ Bin(20, 21 ). Hence pY (y) =
20 1 y
(1 − 12 )20−y and therefore pY (12) = 20 1

y 2 12 220
.
We now find the values of pX,Y (x, 12) for x = 0, 1, . . . , 10.
Remember that pX,Y(x, y) = P(X = x, Y = y) = P(X = x)P(Y = y | X = x), and note
that P(X = x) = 10 1
x 210
since X ∼ Bin(10, 12 ).
Also note that you can represent Y as X + Z where Z ∼ Bin(10, 21 ) is the number of heads
in the last 10 flips, and so is independent of X. Therefore
 10  1
y−x 210
y = x, x + 1, . . . , x + 10
pY | X (y | x) = P(Z = y − x | X = x) = pZ (y − x) =
0 o.w.
10 1 10 1
  
x 210 12−x 210
2 ≤ x ≤ 10
Hence pX,Y (x, 12) = pX (x)pY | X (12 | x) =
0 o.w.

It follows that, for x = 2, 3, . . . , 10,


10 1 10 1 10 10
   
pX,Y (x, 12) x 210 12−x 210 x 12−x
pX | Y (x | 12) = = 20 1
 = 20
 ,
pY (12) 12 22 0 12

and pX | Y (x | 12) = 0 otherwise.


6. Let Y be the total number of students, and let X be the number of female students. The
question asks us to find
P(Y ≤ 13 | X = 10).
y
We know that Y ∼ Poi(10), so pY (y) = e−10 10y! .
A good assumption is that each student has a 50% chance of being female, so, given that
Y = y, X ∼ Bin(y, 12 ). Hence pX | Y (x | y) = xy 21y .
pX | Y (x | y)pY (y)
We know that pY | X (y | x) = pX (x)
so it remains to calculate
X X
pX (x) = pX,Y (x, y) = pY (y)pX | Y (x | y)
y y
∞ y
  ∞
−10 10 y 1 y!
X X
−10
= e y
=e 5y
y=x
y! x 2 y=x
y!(y − x)!x!

e−10 X 5z+x e−10 5x 5 5x
= = e = e−5
x! z=0 z! x! x!

[NB X ∼ Poi( 10
2
) — this is not an accident!]
Hence y 1 y
× e−10 10y!

y−x
x 2y −5 5
pY | X (y | x) = x = e
e−5 5x! (y − x)!
and

P(Y ≤ 13 | X = 10) = pY | X (10 | 10) + pY | X (11 | 10) + pY | X (12 | 10) + pY | X (13 | 10)
 
−5 25 125
= e 1+5+ +
2 3!
= 0.265.

You might also like