Stats 2 Week1-2 Mock
Stats 2 Week1-2 Mock
1. The joint probability mass function of two discrete random variables X and Y is given
by
X
1 2 3
Y
s 2 3 4 5
(a)
P (X + Y = s) 0.1 0.3 0.5 0.1
s 2 3 4 5
(b)
P (X + Y = s) 0.1 0.4 0.4 0.1
s 1 2 3 4 5
(c)
P (X + Y = s) 0.1 0.2 0.1 0.5 0.1
s 1 2 3 4 5
(d)
P (X + Y = s) 0.1 0.2 0.1 0.4 0.2
z1 1 2 3
(a)
P (max(X, Y ) = z1 ) 0.1 0.4 0.5
z1 1 2 3
(b)
P (max(X, Y ) = z1 ) 0.3 0.4 0.3
z1 1 2 3
(c)
P (max(X, Y ) = z1 ) 0.1 0.7 0.2
z1 1 2 3
(d)
P (max(X, Y ) = z1 ) 0.4 0.4 0.2
z2 1 2
(a)
P (min(X, Y ) = z2 ) 0.6 0.4
z2 1 2
(b)
P (min(X, Y ) = z2 ) 0.4 0.6
z2 1 2
(c)
P (min(X, Y ) = z2 ) 0.9 0.1
z2 1 2 3
(d)
P (min(X, Y ) = z2 ) 0.3 0.5 0.2
Solution:
We will use the table method to compute the distribution of max(X, Y ), min(X, Y )
and X + Y .
s 2 3 4 5
P (X + Y = s) 0.1 0.4 0.4 0.1
z1 1 2 3
P (max(X, Y ) = z1 ) 0.1 0.7 0.2
Page 2
(iii) Range of min(X, Y ) = {1, 2}
P (min(X, Y ) = 1) = fXY (1, 1) + fXY (1, 2) + fXY (2, 1) + fXY (3, 1) = 0.1 + 0.2 +
0.2 + 0.1 = 0.6
P (min(X, Y ) = 2) = fXY (2, 2) + fXY (3, 2) = 0.3 + 0.1 = 0.4
z2 1 2
P (min(X, Y ) = z2 ) 0.6 0.4
2. Consider two random variables X and Y with Joint PMF given in Table 1.1.
X 0 1 2
Y
0 1 1 1
12 8 24
1 1 3 1
4 8 8
Solution:
(i) • We can see from the table that fXY (x, y) = fX (x)fY (y) for all (x, y). There-
fore X and Y are independent.
Page 3
•
P (X ≤ 1) =P (X = 0) + P (X = 1)
1 1 1 3
= + + +
12 4 8 8
4 4 5
= + =
12 8 6
•
fXY (2, 1)
P (Y = 1 | X = 2) =
fX (2)
1/8 3
= =
4/24 4
3. In a book store, there are two types of books (Type 1 and Type 2). Let X denote the
number of books of Type 1 that is sold in a week. Let Y denote the number of books of
Type 2 that is sold in a week. Suppose X and Y follows the Poisson distribution with
parameters 2 and 3, respectively. Let Z denote the total number of books of Type 1
and Type 2 sold in a week. Assume that X and Y are independent.
Page 4
Solution:
Z represent the total number of books of Type I and Type II sold in a week.
4. Two chess games are played between Anand and Kasparov. The probability that
Anand wins the first game against Kasparov is 0.6, the probability that Anand wins
the second game given that he won the first is 0.8 and the probability that Anand wins
the second game given that he lost the first is 0.5. No game is drawn. Let X1 , X2 be
two random variables defined as
(
1 if Anand wins the i-th game
Xi =
0 if Kasparov wins the i-th game
3 12
1 25 25
X1 0 1
X2
1 12
(b) 0 5 25
1 3
1 5 25
Page 5
X1 0 1
X2
1 3
(c) 0 5 25
1 12
1 5 25
X1 0 1
X2
1 1
(d) 0 5 5
12 3
1 25 25
Answer: (c)
Solution:
Let X1 = 0 represents Anand loses first game against Kasparov and X1 = 1
represents Anand wins first game against Kasparov.
Similarly, X2 = 0 represents Anand loses second game against Kasparov and
X2 = 1 represents Anand wins second game against Kasparov.
Given, P (X1 = 1) = 0.6, P (X2 = 1|X1 = 1) = 0.8 and P (X2 = 1|X1 = 0) = 0.5.
Now,
P (X1 = 0) = 1 − P (X1 = 1)
= 1 − 0.6 = 0.4
Also,
P (X2 = 1, X1 = 1)
P (X2 = 1|X1 = 1) =
P (X1 = 1)
P (X2 = 1, X1 = 1)
0.8 =
0.6
P (X2 = 1, X1 = 1) = 0.8 × 0.6
12
P (X2 = 1, X1 = 1) = 0.48 =
25
The event X2 = 0|X1 = 1 is the complement of the event X2 = 1|X1 = 1.
Hence, P (X2 = 0|X1 = 1) = 1 − P (X2 = 1|X1 = 1) = 1 − 0.8 = 0.2.
Now,
P (X2 = 0, X1 = 1)
P (X2 = 0|X1 = 1) =
P (X1 = 1)
P (X2 = 0, X1 = 1)
0.2 =
0.6
P (X2 = 0, X1 = 1) = 0.2 × 0.6
3
P (X2 = 0, X1 = 1) = 0.12 =
25
Page 6
Similarly,
P (X2 = 1, X1 = 0)
P (X2 = 1|X1 = 0) =
P (X1 = 0)
P (X2 = 1, X1 = 0)
0.5 =
0.4
P (X2 = 1, X1 = 0) = 0.5 × 0.4
1
P (X2 = 1, X1 = 1) = 0.20 =
5
We can find the P (X2 = 0|X1 = 0) from the complement of event X2 = 1|X1 = 0
or from the properties of joint PMF that the sum of all joint probabilities will be
equal to 1.
1
Therefore, the P (X2 = 0|X1 = 0) = .
5
The above calculated joint probabilities are tabulated as follows:
X1 0 1
X2
1 3
0 5 25
1 12
1 5 25
Page 7
(i) Find the marginal distributions of X and Y . [3 marks]
(a) X ∼ Bernoulli(0.3) and Y ∼ Bernoulli(0.7)
(b) X ∼ Poisson(0.3) and Y ∼ Poisson(0.7)
(c) X ∼ Poisson(1.5) and Y ∼ Poisson(3.5)
(d) X ∼ Poisson(1.5) and Y ∼ Poisson(1.5)
solution:
Given, the number of customers visiting a KFC on a particular day is, N ∼
Poisson(5).
Given, the probability that a customer purchases a Classic Chicken Zingers is 0.3
which means the probability that a customer does not purchase a Classic Chicken
Zingers is 0.7. (Note that it is a Bernoulli trial).
Therefore, P (X = x|N = n) ∼ Binomial(N, 0.3) and P (Y = y|N = n) ∼
Binomial(N, 0.7).
Now, the marginal distribution of X is,
X ∼ Poisson(5 × 0.3)
X ∼ Poisson(1.5)
Page 8
2
(d) Y ∼ Geometric .
3
(e) Range of Y is {0, 1, 2, . . . , 10}
(f) Range of Y is {1, 2, 3, . . . }.
Solution:
Since X1 , X2 , · · · , X10 are i.i.d Bernoulli trials, Y = X1 +X2 +· · ·+X10 is number
of successes in 10 trials, which implies Y is a binomial distribution with n = 10
2
and p = .
3
The range of binomial distribution is {0, 1, · · · , ..n} so the range of Y is {0, 1, 2, · · · , 10}.
(ii) Find the value of P (X1 = 0 | Y = 8). Enter the answer correct to one decimal
place. [3 marks]
Answer: 0.2
Solution:
P (X1 = 0 and Y = 8)
P (X1 = 0|Y = 8) =
P (Y = 8)
P (X1 = 0 and Y = 8) means that first trail failed and 8 among the remaining 9 trials
are success.
1 9 2 81
P (X1 = 0 and Y = 8) = ( )
3 8 3 3
10 2 8 1 2
P (Y = 8) = ( )( )
8 3 3
1 9 2 8 1
8
( )
⇒ P (X1 = 0|Y = 8) = 3 3 3
10
2 1
8
( )8 ( )2
3 3
9!
= 8! = 0.2
10!
8! × 2!
1
7. Suppose X1 , X2 are two i.i.d. Binomial 10, samples. Let Y, Z be two random
3
variables defined as Y = X1 + X2 and Z = X1 X2 respectively. Which of the following
options are true? [4 marks]
Page 9
1
(a) Y ∼ Binomial 20,
3
1
(b) Y ∼ Binomial 10,
3
15! × 10!
(c) fZ|Y =15 (50) =
20! × 5!
15! × 10!
(d) fZ|Y =15 (50) = 2 ×
20! × 5!
Solution:
1
Given X1 and X2 are two i.i.d Binomial (10, ) samples, which means that each are
3
Bernoulli experiments with ten trials.
1
Y = X1 + X2 is similar to having to 20 Bernoulli trials with p = .
3
Given Z = X1 X2 , if X1 + X2 = 15, then the only way Z = 50 will happen is if
X1 = 5, X2 = 10 or X1 = 10, X2 = 5
2 × P (X1 = 5 and X2 )
fZ|Y =15 (50) =
P (Y = 15)
1 5 2 5 10 1 10
2 × 105
( ) ( ) 10 ( )
= 3 3 3
20 1 15 2 5
15
( ) ( )
10
3 3
2× 5
= 20
15
2 × 10! × 15!
=
20! × 5!
Z = max(X, Y ) − min(X, Y )
Find the value of P (Z ≥ 2). Enter the answer correct to two decimal places. [4
marks]
Solution:
Given, the random variable
X represents the units place of a two digit number,
Y represents the tens place of a two digit number.
Page 10
Now, Z = max(X, Y ) − min(X, Y ).
Observe that, max(X, Y ) − min(X, Y ) is equivalent to | X − Y |.
P (Z ≥ 2) = 1 − P (Z = 1) − P (Z = 0)
Z = 0 occurs when X = Y so, X can take 0, 1, 2, · · · , 10
10
P (Z = 0) =
100
Z = 1 occurs X − Y = 1 or Y − X = 1
Let us consider X − Y = 1, this can occur if (X, Y ) = (1, 0), (2, 1), · · · , (8, 7), (9, 8).
So, X − Y = 1 occurs in 9 cases. Same cases for Y − X = 1 scenario.
9∗2
⇒ P (Z = 1) =
100
⇒ P (Z ≥ 2) = 1 − 0.1 − 0.18 = 0.72.
Page 11