You are on page 1of 5

Math 531 – Spring 2019

Homework 4 – Solutions

1. Suppose that 1% of the employees of a certain company use illegal drugs. This company
performs random drug tests that return positive results 99% of the time if the person is a
drug user. However, it also has a 2% false positive rate. The results of the drug test are
known to be independent from test to test for a given person.

(a) Steve, an employee at the company, has a positive test. What is the probability he is a
drug user?
(b) Knowing he failed his first test, what is the probability that Steve will fail his next drug
test?
(c) Steve just failed his second drug test. Now what is the probability he is a drug user?

Solution. Define events: D = {Steve is a drug user}, A1 = {Steve fails the first drug test}
and A2 = {Steve fails the second drug test}. Assume that Steve is no more or less likely
to be a drug user than a random person from the company, so P (D) = 0.01. The data
about the reliability of the tests tells us that P (Ai |D) = 0.99 and P (Ai |Dc ) = 0.02 for
i = 1, 2, and conditional independence P (A1 A2 |D) = P (A1 |D)P (A2 |D) and also the same
under conditioning on Dc .

(a)
99 1
P (A1 |D)P (D) 100 · 100 1
P (D|A1 ) = = 99 1 2 99 =
P (A1 |D)P (D) + P (A1 |Dc )P (Dc ) 100 · 100 + 100 · 100
3

(b)

P (A1 A2 ) P (A1 A2 |D)P (D) + P (A1 A2 |Dc )P (Dc )


P (A2 |A1 ) = =
P (A1 ) P (A1 |D)P (D) + P (A1 |Dc )P (Dc )
99 2 1 2 2 99
 
· + · 100 103
= 10099 100 1
100
2 99 = ≈ 0.3433.
100 · 100 + 100 · 100
300

(c)

P (A1 A2 |D)P (D)


P (D|A1 A2 ) =
P (A1 A2 |D)P (D) + P (A1 A2 |Dc )P (Dc )
99 2 1

100 · 100 99
= = ≈ 0.9612.
99 2 1 2 2 99 103
 
100 · +
100 ·
100 100

2. Prove the following alternative characterization of independence of n events. Suppose that


A1 , . . . , An are events for which

P (A∗1 A∗2 . . . A∗n ) = P (A∗1 )P (A∗2 ) . . . P (A∗n ) (1)

holds for all 2n possible choices A∗1 , . . . , A∗n . (Each A∗i can be either Ai or Aci .) Then A1 , . . . , An
are mutually independent.
Solution. We can assume that n ≥ 2 as the statement only makes sense for these values.
We will prove by induction. For n = 2 if we choose A∗1 = A1 and A∗2 = A2 in (1) then we get

P (A1 A2 ) = P (A1 )P (A2 )

which shows that A1 , A2 are independent.


Suppose now that the statement is true for any n events, we will show it for n + 1. This
means that we assume that

P (A∗1 A∗2 . . . A∗n+1 ) = P (A∗1 )P (A∗2 ) . . . P (A∗n+1 ) (2)

holds for all 2n+1 possible choices A∗1 , . . . , A∗n+1 .


We need to show that

P (Ai1 · · · Aik ) = P (Ai1 ) · · · P (Aik ) (3)

for all choices of 1 ≤ i1 < · · · < ik ≤ n + 1.


If we choose all indices (k = n + 1, ij = j for 1 ≤ j ≤ n + 1) then (3) follows from (2) by
choosing A∗j = Aj in (2) for all j.
If we have less than n + 1 indices then we can assume that the index n + 1 was not chosen
(otherwise we can relabel the indices). Then (3) would follow from the independence of
A1 , . . . , An , which (by our induction hypothesis) follows from (1). Thus we just have to show
that if (2) holds for all 2n+1 choices of A∗i , 1 ≤ i ≤ n + 1 then (1) holds for all 2n choices of
A∗j , 1 ≤ j ≤ n.
For a specific choice of A∗1 , . . . , A∗n apply (2) for A∗n+1 = An+1 and A∗n+1 = Acn+1 . This means
that

P (A∗1 A∗2 . . . A∗n An+1 ) = P (A∗1 )P (A∗2 ) . . . P (A∗n )P (An+1 )


P (A∗1 A∗2 . . . A∗n Acn+1 ) = P (A∗1 )P (A∗2 ) . . . P (A∗n )P (Acn+1 )

Adding the two equations we get

P (A∗1 A∗2 . . . A∗n An+1 ) + P (A∗1 A∗2 . . . A∗n Acn+1 ) = P (A∗1 A∗2 . . . A∗n )

on the left side, because P (A) = P ((AB ∪ AB c ) = P (AB) + P (AB c ). (Here A = A∗1 A∗2 . . . A∗n
and B = An+1 .) On the right side we get

P (A∗1 )P (A∗2 ) . . . P (A∗n )P (An+1 ) + P (A∗1 )P (A∗2 ) . . . P (A∗n )P (Acn+1 ) = P (A∗1 )P (A∗2 ) . . . P (A∗n ),

since P (Acn+1 ) = 1 − P (An+1 ). But this gives

P (A∗1 A∗2 . . . A∗n ) = P (A∗1 )P (A∗2 ) . . . P (A∗n ),

which is exactly what we had to prove.

3. An urn contains 3 red balls and 2 yellow balls. You draw a ball without replacement until
you get a red ball. Let X be the number of draws you made.

(a) Find the possible values and the PMF of X.


(b) Let µX be the probability distribution of X on R. Imitating Example 2.10, give a formula
for µX (B) for an arbitrary subset B ⊂ R.
(c) Find the CDF F of X.

Solution.

(a) X is discrete and its possible values are {1, 2, 3}. The probabilities are found by counting.
3
P (X = 1) = .
5

2·3 3
P (X = 2) = P (first draw is yellow, second draw is read) = = .
5·4 10

2·1·3 1
P (X = 3) = P (draws 1 and 2 are yellow, draw 3 is red) = = .
5·4·3 10
(b) µX (B) can be computed Pby adding the probability mass function values for all i ∈ B
with 1 ≤ i ≤ 3: µX (B) = i∈B,1≤i≤3 P (X = i) = 35 1B (1) + 10
3 1
1B (2) + 10 1B (3)
(c) X is discrete, so its CDF will be piecewise constant with jumps at the possible values
1,2,3. The sizes of the jumps are equal to the PMF values.



 0, x < 1
3, 1 ≤ x < 2

F (x) = 59
10 , 2 ≤ x < 3




1, x ≥ 3.

4. Parts (a)–(e) below describe five different probability spaces. In each case, define a function
X : Ω → R such that X has probability distribution given by P (X = 0) = 14 and P (X =
1) = 34 , or explain why this cannot be done.
1
(a) Ω = {0, 1, 2, 3}, P {ω} = 4 for ω ∈ Ω.
1
(b) Ω = {0, 1, 2, 3, 4}, P {ω} = 5 for ω ∈ Ω.
(c) Ω = {1, 2, 3, . . . }, P {ω} = 2−ω for ω ∈ Ω.
(d) Ω = [0, 1], P (I) = length of I for intervals I ⊂ Ω.
Rb
(e) Ω = R, P ((−∞, 0]) = 0, and P ((a, b)) = a e−x dx for intervals (a, b) ⊂ (0, ∞).

Solution. If there is a solution then X = 1B is an indicator function of some event B in


the appropriate probability space. (The event B is the inverse image of the singleton {1}:
B = {ω ∈ Ω : X(ω) = 1} = {X = 1}.) Then P (X = 1) = P (B), P (X = 0) = P (B c ), which
means that we just have to check whether we can find an event B in the probability space
with P (B) = 3/4.
There is more than one correct answer to all parts except (b).

(a) E.g. B = {1, 2, 3} works. Then X(0) = 0 and X(ω) = 1 for ω ∈ {1, 2, 3}.
(b) Not possible because P (B) is multiple of 51 for each event B ⊂ Ω, and hence no event can
have probability 34 required for event B = {X = 1}.
(c) E.g. B = {1, 2} works. Then X(ω) = 1 for ω ∈ {1, 2} and X(ω) = 0 for ω ∈ {3, 4, 5, . . . }.
Then
P (X = 1) = P {1} + P {2} = 2−1 + 2−2 = 43
and P (X = 0) = 1 − P (X = 1) = 14 .
(d) E.g. B = [0, 1/4] works. Then
(
0, 0 ≤ ω ≤ 41
X(ω) = 1
1, 4 < ω ≤ 1.
R∞
(e) We can choose an interval [a, ∞) for B with 0 < a. Then we would need a e−x dx = 3/4,
which can be satisfied by a = log 43 .
Then X(ω) is defined as (
0, ω ≤ log 43
X(ω) =
1, ω > log 34 .
Then
4
Z log 3 4
P (X = 0) = P ((−∞, log ]) =4
3 e−x dx = 1 − e− log 3 = 1
4
0

and
Z ∞ 4
P (X = 1) = P ((log 4
3 , ∞)) = e−x dx = e− log 3 = 43 .
4
log 3

5. Drop a uniformly random point on the triangle with vertices at (0, 0), (5, 0) and (5, 2). Let
X be the x-coordinate of this random point. Find the CDF of X.
Solution. X takes its values in [0, 5]. Thus FX (x) = 0 for x ≤ 0 and FX (x) = 1 for x ≥ 5.
The area of the triangle is 5, and hence the probability of any (Borel) subset A of the triangle
is P (A) = 15 · area(A). For 0 ≤ x ≤ 5, the event {X ≤ x} happens if and only if the random
point falls in the triangle with vertices (0, 0), (x, 0) and (x, 2x/5), whose area is 12 ·x· 2x 2
5 = x /5.
Thus for 0 ≤ x ≤ 5,
x2 /5 x2
FX (x) = P (X ≤ x) = = .
5 25
Summary answer: 
0,
 x<0
x 2
FX (x) = 25 , 0 ≤ x < 5

1, x ≥ 5.

6. Let F be the CDF of a random variable X. Prove that lim F (t) = 1.


t→∞
Solution. To show lims→∞ F (s) = 1, we take an arbitrary ε > 0 and show the existence of
s0 such that s ≥ s0 implies F (s) ≥ 1 − ε.
First we claim that, as the integer parameter n → ∞,

{X ≤ n} % Ω. (4)
Here is the argument. Since X ≤ n implies X ≤ n + 1, the events {X ≤ n} are nested
nondecreasing. Let ω ∈ Ω be arbitrary. Then X(ω) is some real number, and we can take a
large enough integer m such that X(ω) ≤ m. Then

[
ω ∈ {X ≤ m} ⊂ {X ≤ n}.
n=1
S∞
Thus every sample point ω lies in n=1 {X ≤ n}. (4) is justified.
By (4) and the continuity of the probability measure we get F (n) = P (X ≤ n) → P (Ω) = 1
as n → ∞ along integers. Given ε > 0, pick n so that P (X ≤ n) ≥ 1 − ε. Then s ≥ n implies
1 ≥ F (s) ≥ F (n) ≥ 1 − ε. This proves lim F (s) = 1.
s→∞

You might also like