Quantitative Methods for MBAs
Practice Problems for FINAL
Angelo Mele
Problem 1
The joint probability distribution of X and Y is partially shown in the table below.
Y
0 1 2
0 0.11 0.24
X 1 0.09 0.15
2 0.17 0.27
0.3In addition you know the conditional probability
P (Y = 1|X = 0) = 0.5
1. Complete the table
Answer The table below contains the solution
Y
0 1 2
0 0.11 0.12 0.01 0.24
X 1 0.09 0.15 0.02 0.26
2 0.06 0.17 0.27 0.5
0.26 0.44 0.3
1
2. Compute the expected value of X (show your math)
E(X) = (0)(0.24) + (1)(0.26) + (2)(0.5) = 1.26
3. Compute the variance of X (show your math)
V (X) = (0− 1.26)2(0.24) + (1− 1.26)2(0.26) + (2− 1.26)2(0.5) = 0.6724
4. Compute the expected value of Y (show your math)
E(Y ) = (0)(0.26) + (1)(0.44) + (2)(0.3) = 1.04
5. Compute the Variance of Y (show your math)
V (Y ) = (0− 1.04)2(0.26) + (1− 1.04)2(0.44) + (2− 1.04)2(0.3) = 0.5584
6. Compute the covariance of X and Y (show your math)
COV (X,Y ) = (0− 1.04)(0− 1.26)(0.11) + (1− 1.04)(0− 1.26)(0.12) + (2− 1.04)(0− 1.26)(0.01) +
+ (0− 1.04)(1− 1.26)(0.09) + (1− 1.04)(1− 1.26)(0.15) + (2− 1.04)(1− 1.26)(0.02) +
+ (0− 1.04)(2− 1.26)(0.06) + (1− 1.04)(2− 1.26)(0.17) + (2− 1.04)(2− 1.26)(0.27) = 0.2996
7. Are X and Y independent? Explain how you get the result.
Problem 2
The joint probability distribution of X and Y is partially shown in the table below.
Y
0 1 2
2 0 0.2
X 3 0.1
5 0 0.1
0.6In addition you know the conditional probability
P (Y = 2|X = 2) = 0.5
P (X = 5|Y = 0) = 1
2
1. Complete the table
Answer The table below contains the solution
Y
0 1 2
2 0 0.1 0.1 0.2
X 3 0 0.1 0 0.1
5 0.6 0 0.1 0.7
0.6 0.2 0.2
2. Compute the expected value of X (show your math)
E(X) = (2)(0.2) + (3)(0.1) + (5)(0.7) = 4.2
3. Compute the variance of X (show your math)
V (X) = (2− 4.2)2(0.2) + (3− 4.2)2(0.1) + (5− 4.2)2(0.7) = 1.56
4. Compute the expected value of Y (show your math)
E(Y ) = (0)(0.6) + (1)(0.2) + (2)(0.2) = 0.6
5. Compute the Variance of Y (show your math)
V (Y ) = (0− 0.6)2(0.6) + (1− 0.6)2(0.2) + (2− 0.6)2(0.2) = 0.64
6. Compute the covariance of X and Y (show your math)
COV (X,Y ) = (0− 0.6)(2− 4.2)(0) + (1− 0.6)(2− 4.2)(0.1) + (2− 0.6)(2− 4.2)(0.1) +
+ (0− 0.6)(3− 4.2)(0) + (1− 0.6)(3− 4.2)(0.1) + (2− 0.6)(3− 4.2)(0) +
+ (0− 0.6)(5− 4.2)(0.6) + (1− 0.6)(5− 4.2)(0) + (2− 0.6)(5− 4.2)(0.1) = −0.62
7. Are X and Y independent? Explain how you get the result.
3
Problem 3
The joint probability distribution of X and Y is partially shown in the table below.
Y
1 4 6
2 0.1 0.5
X 3 0
5 0 0.1
0.4
In addition you know the conditional probability
P (Y = 6|X = 2) = 0.2
P (X = 5|Y = 1) = 0.25
1. Complete the table
Answer The table below contains the solution
Y
1 4 6
2 0.1 0.3 0.1 0.5
X 3 0.2 0 0.1 0.3
5 0.1 0 0.1 0.2
0.4 0.3 0.3
2. Compute the expected value of X (show your math)
E(X) = (2)(0.5) + (3)(0.3) + (5)(0.2) = 2.9
3. Compute the variance of X (show your math)
V (X) = (2− 2.9)2(0.5) + (3− 2.9)2(0.3) + (5− 2.9)2(0.2) = 1.29
4
4. Compute the expected value of Y (show your math)
E(Y ) = (1)(0.4) + (4)(0.3) + (6)(0.3) = 3.4
5. Compute the Variance of Y (show your math)
V (Y ) = (1− 3.4)2(0.4) + (4− 3.4)2(0.3) + (6− 3.4)2(0.3) = 4.44
6. Compute the covariance of X and Y (show your math)
COV (X,Y ) = (1− 3.4)(2− 2.9)(0.1) + (4− 3.4)(2− 2.9)(0.3) + (6− 3.4)(2− 2.9)(0.1) +
+ (1− 3.4)(3− 2.9)(0.2) + (4− 3.4)(3− 2.9)(0) + (6− 3.4)(3− 2.9)(0.1) +
+ (1− 3.4)(5− 2.9)(0.1) + (4− 3.4)(5− 2.9)(0) + (6− 3.4)(5− 2.9)(0.1) = −0.16
7. Are X and Y independent? Explain how you get the result.
Problem 4
Use the following table to solve the question
Student-t distributionP (Z < 1.282) = 0.9 P (Z < 1.645) = 0.95 P (Z < 2.326) = 0.99P (Z < 2.576) = 0.995 P (Z < 1.96) = 0.975 P (Z < 0.842) = 0.8
In a survey of 200 individuals we calculate a sample proportion of p = 0.42. Test the hypothesis
H0 : p = 0.4
H1 : p > 0.4
at significance level α = 0.05
1. Compute the bound(s) of the rejection region and the value of the test statistic for this test
Answer. The test statistics for the sample proportion is
p− p0√p0(1−p0)
n
≈ N (0, 1)
which is approximately normally distributed, according to the central limit theorem. This is a one-tail test sowe are looking for a rejection region bound that leaves 0.05 on the right. Using the table at the end of thebooklet we find P (Z < 1.645) = 0.95 which implies P (Z > 1.645) = 0.05. The rejection region is thenREJECT if p−p0√
p0(1−p0)
n
> 1.645
DO NOT REJECT otherwise.
2. Can you reject the null?
AnswerThe value of the test statistics is
p− p0√p0(1−p0)
n
=0.42− 0.4√
0.4(0.6)200
= 0.577
therefore we DONOTREJECT the null.
5
3. Can you reject at α = 0.01 significance level?
Answer. With a significance level of 0.01, the rejection region bound must leave 0.01 probability on the right,so our bound is 2.326 (because P (Z < 2.326) = 0.99 or P (Z > 2.326) = 0.01). The rejection region is:REJECT if p−p0√
p0(1−p0)
n
> 2.326
DO NOT REJECT otherwise.Since the test statistics value is 0.577 < 2.326, we DO NOT REJECT the null at 0.01 significance level.
Problem 5
Consider the 3 independent random variables
X ∼ Bernoulli(0.2)
Y ∼ Bernoulli(0.3)
S ∼ Bernoulli(0.5)
1. Compute the expected value of the variable W = X + S
E(W ) =
Answer.E(W ) = E(X + S) = E(X) + E(S) = [0.2(1) + 0.8(0)] + [0.5(1) + 0.5(0)] = 0.2 + 0.5 = 0.7
2. Compute the variance of the variable H = X + 5Y − 3S
V (H) =
Answer. The variables are independent, therefore we don’t need to consider the covariance terms.V (H) = V (X + 5Y − 3S) = V (X) + 52V (Y ) + 32V (S)Notice that the variance of a Bernoulli variable with parameter p is given by p(1− p), therefore we getV (H) = V (X) + 52V (Y ) + 32V (S) = 0.2(0.8) + 25(0.3)(0.7) + 9(0.5)(0.5) = 7.66
3. Are X an Y identically distributed? Explain.
Answer. NO, they both have Bernoulli distribution, but with different probability of success (0.2 for X and0.3 for Y ).
6
Problem 6
A playboy goes to a party in New York, where he meets 5 fabulous ladies. He asks each of them out, independently(i.e. making sure that they do not know he invited the others too). From his past experience, the playboy knowsthat his probability of success with a lady is p = 0.4.
1. What is the probability that all ladies reject the invitation? Explain your answer
Answer. The probability of rejection in one trial is 1 − p = 0.6. So the probability of n = 5 independentfailures is given by 0.65 = 0.07776. In alternative, you can also use the binomial formula to get the same answer
P (X = 0) =5!
5!0!0.400.65 = 0.07776
2. What is the probability that at least 1 lady accepts the invitation? Explain your answer
Answer. Using the binomial distribution formula
P (X ≥ 1) = 1− P (X = 0) = 1− 5!
5!0!0.400.65 = 1− 0.07776 = 0.92224
3. What is the probability that at most 4 lady accepts the invitation? Explain your answer
Answer. Using the binomial distribution formula
P (X ≤ 4) = 1− P (X = 5) = 1− 5!
0!5!0.450.60 = 1− 0.01024 = 0.98976
4. What is the probability that at least 1 and at most 3 ladies accept the invitation? Explain your answer
Answer. Using the binomial distribution formula
P (1 ≤ X ≤ 3) = P (X = 1) + P (X = 2) + P (X = 3)
=5!
4!1!0.410.64 +
5!
3!2!0.420.63 +
5!
2!3!0.430.62
= 0.2592 + 0.3456 + 0.2304
= 0.8352
Problem 7
Let X be the number of Emergency Room visits in a year. The probability distribution of X is given by the followingtable
x 0 1 2 3 4 5P (X = x) 0.45 0.3 0.15 0.05 0.03 0.02
1. What is the probability that a person would visit the emergency room more than twice in a year?
Answer. We are looking for the probability P (X > 2) which is equivalent to P (X > 2) = 0.1.
7
2. Suppose you randomly select n = 10 individuals: what is the probability that at least 1 of them visits theemergency room more than twice a year?
Answer. We define the variable Y to be the event that a person visits the emergency room more than twicea year. To answer the question we use the binomial distribution, with n = 10, y = 1 and p = 0.1.
P (Y ≥ 1) = 1− P (Y = 0) = 1− 10!
0!10!0.10(0.9)10 = 1− 0.3486784401 = 0.6513215599
Problem 8
To answer this question you cannot use the computer. You need to come up with the answers using only the dataprovided. Here are several probabilities for the standard normal distribution.
P (Z < 0.13) = 0.5517
P (Z < 1.22) = 0.8888
P (Z > −1.35) = 0.9115
Using only these probabilities and the properties of the distribution, compute the following probabilities. Explainyour answers and which properties of the distribution you used.
1. P (Z < 1.35)
Answer. Here we use the symmetry of the standard normal distribution. Because of the symmetry we haveP (Z < a) = P (Z > −a), so P (Z < 1.35) = P (Z > −1.35) = 0.9115.
2. P (Z > 1.22)
Answer. Here we use the fact that the area below the pdf must sum to 1. So P (Z > a) = 1− P (Z < a). Inour case, P (Z > 1.22) = 1− P (Z < 1.22) = 1− 0.8888 = 0.1112
3. P (Z > 0.13)
Answer. Here we use the fact that the area below the pdf must sum to 1. So P (Z > a) = 1− P (Z < a). Inour case, P (Z > 0.13) = 1− P (Z < 0.13) = 1− 0.5517 = 0.4483.
4. P (1.22 < Z < 1.35)
Answer. To compute this probability we use the properties of the cdf, i.e. P (a < Z < b) = P (Z <b) − P (Z < a). From the result in (A) we know P (Z < 1.35) = 0.9115 and from the probabilities above wehave P (Z < 1.22) = 0.8888, so the probability is
P (1.22 < Z < 1.35) = P (Z < 1.35)− P (Z < 1.22) = 0.9115− 0.8888 = 0.0226999999999999
8
5. P (0.13 < Z < 1.22)
Answer. Using the cdf
P (0.13 < Z < 1.22) = P (Z < 1.22)− P (Z < 0.13) = 0.8888− 0.5517 = 0.3371
6. For the variable X = 9 + 4Z, compute the probability P (9.52 < X < 14.4)
Answer. The probability is
P (9.52 < X < 14.4) = P
(9.52− (9)
4<X − (9)
4<
14.4− (9)
4
)= P (0.13 < Z < 1.35)
= P (Z < 1.35)− P (Z < 0.13) = 0.9115− 0.5517 = 0.3598
7. For the variable X = −12 + 7Z, compute the probability P (−11.09 < X < −2.55)
Answer. The probability is
P (−11.09 < X < −2.55) = P
(−11.09− (−12)
7<X − (−12)
7<−2.55− (−12)
7
)= P (0.13 < Z < 1.35)
= P (Z < 1.35)− P (Z < 0.13) = 0.9115− 0.5517 = 0.3598
Problem 9
Use the following table to solve the question
Student-t distributionP (t42 > 1.302) = 0.1 P (t42 > 1.682) = 0.05 P (t42 > 2.018) = 0.025P (t43 > 1.302) = 0.1 P (t43 > 1.681) = 0.05 P (t43 > 2.017) = 0.025P (t44 > 1.301) = 0.1 P (t44 > 1.68) = 0.05 P (t44 > 2.015) = 0.025
The height (in centimeters) of high schoolers, indicated by variable X, is normally distributed. We are interestedin estimating and make inference about the population mean µ. We collect an i.i.d. sample of n = 43 observations,with sample mean x = 156 and sample variance s2 = 324.
1. Construct a 80% confidence interval for µ
Answer. The confidence interval is such that
P
(−t42,0.1 <
x− µ0s√n
< t42,0.1
)= 0.8
or
P
(x− t42,0.1
s√n< µ < x+ t42,0.1
s√n
)= 0.8
From the table, we find P (t42 > t42,0.1) = 1.302, so the confidence interval is
x± t42,0.1s√n
= 156± 1.30218√43
= [152.426, 159.574]
9
2. Construct a 95% confidence interval for µ
Answer. The confidence interval is such that
P
(−t42,0.025 <
x− µ0s√n
< t42,0.025
)= 0.95
or
P
(x− t42,0.025
s√n< µ < x+ t42,0.025
s√n
)= 0.95
From the table, we find P (t42 > t42,0.025) = 2.018, so the confidence interval is
x± t42,0.025s√n
= 156± 2.01818√43
= [150.461, 161.539]
3. Construct a 90% confidence interval for µ
Answer. The confidence interval is such that
P
(−t42,0.05 <
x− µ0s√n
< t42,0.05
)= 0.9
or
P
(x− t42,0.05
s√n< µ < x+ t42,0.05
s√n
)= 0.9
From the table, we find P (t42 > t42,0.05) = 1.682, so the confidence interval is
x± t42,0.05s√n
= 156± 1.68218√43
= [151.383, 160.617]
Problem 10
Please compute the first derivative of the following functions:
1. f(x) = x6
Answer. f ′(x) = 6x5
2. f(x) = x3
Answer. f ′(x) = 3x2
3. f(x) = x11
Answer. f ′(x) = 11x10
10
4. f(x) = 3x3 + 4x6 + 6x5
Answer.
f ′(x) = 3 · 3x3−1 + 6 · 4x6−1 + 5 · 6x5−1
= 9x2 + 24x5 + 30x4
5. f(x) = 4x5 + 5x3 + 7x11
Answer.
f ′(x) = 5 · 4x5−1 + 3 · 5x3−1 + 11 · 7x11−1
= 20x4 + 15x2 + 77x10
6. f(x) = 8x6 + 7x5 + 3x8
Answer.
f ′(x) = 6 · 8x6−1 + 5 · 7x5−1 + 8 · 3x8−1
= 48x5 + 35x4 + 24x7
7. f(x) = ln(4x6 + 2x4 + 6x9
)Answer.
f ′(x) =1
4x6 + 2x4 + 6x9[6 · 4x6−1 + 4 · 2x4−1 + 9 · 6x9−1
]=
24x5 + 8x3 + 54x8
4x6 + 2x4 + 6x9
8. f(x) = ln(13x12 + 4x3 + 5x7
)Answer.
f ′(x) =1
13x12 + 4x3 + 5x7[12 · 13x12−1 + 3 · 4x3−1 + 7 · 5x7−1
]=
156x11 + 12x2 + 35x6
13x12 + 4x3 + 5x7
9. f(x) = 14x10+16x7+10x12
13x15+13x18+15x16
Answer.
f ′(x) =[(10)14x10−1+(7)16x7−1+(12)10x12−1][13x15+13x18+15x16]−[14x10+16x7+10x12][(15)13x15−1+(18)13x18−1+(16)15x16−1]
[13x15+13x18+15x16]2
=[140x9+112x6+120x11][13x15+13x18+15x16]−[14x10+16x7+10x12][195x14+234x17+(240x15]
[13x15+13x18+15x16]2
10. f(x) = 12x11+17x7+7x11
10x6+5x9+17x17
Answer.
f ′(x) =[(11)12x11−1+(7)17x7−1+(11)7x11−1][10x6+5x9+17x17]−[12x11+17x7+7x11][(6)10x6−1+(9)5x9−1+(17)17x17−1]
[10x6+5x9+17x17]2
=[132x10+119x6+77x10][10x6+5x9+17x17]−[12x11+17x7+7x11][60x5+45x8+(289x16]
[10x6+5x9+17x17]2
11. f(x) = 12x7+4x10+15x7
15x16+10x13+10x17
Answer.
f ′(x) =[(7)12x7−1+(10)4x10−1+(7)15x7−1][15x16+10x13+10x17]−[12x7+4x10+15x7][(16)15x16−1+(13)10x13−1+(17)10x17−1]
[15x16+10x13+10x17]2
=[84x6+40x9+105x6][15x16+10x13+10x17]−[12x7+4x10+15x7][240x15+130x12+(170x16]
[15x16+10x13+10x17]2
11
12. Compute the partial derivatives of the function f(x, y) = 4x5y13
Answer. The derivatives are:
∂f(x, y)
∂x= (5)4x5−1y13
= 20x4y13
∂f(x, y)
∂y= (13)4x5y13−1
= 52x5y12
13. Compute the partial derivatives of the function f(x, y) = 5x13y5
Answer. The derivatives are:
∂f(x, y)
∂x= (13)5x13−1y5
= 65x12y5
∂f(x, y)
∂y= (5)5x13y5−1
= 25x13y4
14. Compute the partial derivatives of the function f(x, y) = 4x5y4
Answer. The derivatives are:
∂f(x, y)
∂x= (5)4x5−1y4
= 20x4y4
∂f(x, y)
∂y= (4)4x5y4−1
= 16x5y3
15. Compute the partial derivatives of the function f(x) = 5x10y10 − 3x14y6 + 7x
Answer. The derivatives are:
∂f(x, y)
∂x= (10)5x10−1y10 − (14)3x14−1y6 + 7
= 50x9y10 − 42x13y6 + 7
∂f(x, y)
∂y= (10)5x10y10−1 − (6)3x14y6−1
= 50x10y9 − 18x14y5
16. Compute the partial derivatives of the function f(x) = 3x4y4 − 4x6y11 + 6x
Answer. The derivatives are:
∂f(x, y)
∂x= (4)3x4−1y4 − (6)4x6−1y11 + 6
= 12x3y4 − 24x5y11 + 6
∂f(x, y)
∂y= (4)3x4y4−1 − (11)4x6y11−1
= 12x4y3 − 44x6y10
17. Compute the partial derivatives of the function f(x) = 4x4y9 − 3x6y11 + 6x
12
Answer. The derivatives are:
∂f(x, y)
∂x= (4)4x4−1y9 − (6)3x6−1y11 + 6
= 16x3y9 − 18x5y11 + 6
∂f(x, y)
∂y= (9)4x4y9−1 − (11)3x6y11−1
= 36x4y8 − 33x6y10
Problem 11
The sample for variable x is
6 5 6 5 4
and the sample for variable y is
6 5 3 6 2
Please compute:
1. The mean, median, and mode of the sample for x and y
2. The variance and standard deviation for x and y
3. The covariance and correlation of the two variables
Answers.When there are few observations in the sample, it is convenient to create a table like this
xi yi (xi − x) (xi − x)2 (yi − y) (yi − y) (xi − x)(yi − y)1 6.000 6.000 0.800 0.640 1.600 2.560 1.2802 5.000 5.000 -0.200 0.040 0.600 0.360 -0.1203 6.000 3.000 0.800 0.640 -1.400 1.960 -1.1204 5.000 6.000 -0.200 0.040 1.600 2.560 -0.3205 4.000 2.000 -1.200 1.440 -2.400 5.760 2.880
Using the table we can compute all the quantities we need for the answers.
1. The mean of the sample x is computed using the formula x = 1n
∑ni=1 xi, i.e. we sum the entries of column xi
from the table and divide by the number of observations n = 5.
x =26
5= 5.2
To compute the median we sort the sample from the lowest to the highest value and find the value that leaves50% of the observations on the left side and 50% of the observation on the right side.
4 5 5 6 6
13
So the median of our sample is
xm = 5
For the mode we just look at the sample and find the most frequent value. In this sample the mode is therefore
x0 = 5.5
For variable y we do the same and obtain
y = 4.4
ym = 5
y0 = 6
2. The variance s2x and standard deviation sx are computed according to the formulas
s2x =1
n− 1
n∑i=1
(xi − x)2
sx =√s2x
We can compute the∑ni=1 (xi − x)
2by summing the column (xi − x)
2of the table, then dividing by n−1 = 4,
i.e.
s2x =2.8
4= 0.7 = 0.7
sx =√
0.7 = 0.837
For variable y we get
s2y =13.2
4= 3.3 = 3.3
sy =√
3.3 = 1.817
3. For the covariance we use the last column of the table. The formula is given by
sxy =1
n− 1
n∑i=1
(xi − x)(yi − y)
Therefore we obtain
sxy =
∑ni=1(xi − x)(yi − y)
n− 1
=2.6
4= 0.65
and the correlation is obtained by
rxy =sxysxsy
=0.65
0.837 · 1.817= 0.427
14
Problem 11
Suppose we have two random variables X and Y and we know that
X ∼ N (20, 36)
Y ∼ N (30, 25)
σXY = COV (X,Y ) = 0
1. Are X and Y independent? Explain your answer.
Answer. NO, they are not necessarily independent.The statement is: IF they are independent, THEN the covariance is zero.The opposite is not true (remember the third question in the second homework)
2. Are X and Y identically distributed? Explain your answer
Answer. NO, they have different mean and variance.
3. Compute the probabilities below. Explain your answer.Answer.P (X > 20) = 0.5. The normal distribution is symmetric around the mean.
P (Y = 30) = 0. With continuous distribution we can only compute probabilities for intervals. The probabilitythat the random variable takes on a specific value is zero.
4. Suppose we draw an i.i.d. sample of n = 30 observations from X. Compute the expected value and varianceof the sample mean X. Explain how you got the result.
AnswerThe sample mean for normally distributed i.i.d. data has sampling distribution X ∼ N (µX ,
σ2X
n ). As a conse-quence:E(X) = µX = 20
V (X) =σ2X
n = 3630 = 1.2
Problem 12
The sample for variable x is
2 3 7 7 6
and the sample for variable y is
5 5 5 2 4
Please compute:
1. The mean, median, and mode of the sample for x and y
2. The variance and standard deviation for x and y
3. The covariance and correlation of the two variables
15
xi yi (xi − x) (xi − x)2 (yi − y) (yi − y) (xi − x)(yi − y)1 2.000 5.000 -3.000 9.000 0.800 0.640 -2.4002 3.000 5.000 -2.000 4.000 0.800 0.640 -1.6003 7.000 5.000 2.000 4.000 0.800 0.640 1.6004 7.000 2.000 2.000 4.000 -2.200 4.840 -4.4005 6.000 4.000 1.000 1.000 -0.200 0.040 -0.200
Answers.When there are few observations in the sample, it is convenient to create a table like this
Using the table we can compute all the quantities we need for the answers.
1. The mean of the sample x is computed using the formula x = 1n
∑ni=1 xi, i.e. we sum the entries of column xi
from the table and divide by the number of observations n = 5.
x =25
5= 5
To compute the median we sort the sample from the lowest to the highest value and find the value that leaves50% of the observations on the left side and 50% of the observation on the right side.
2 3 6 7 7
So the median of our sample is
xm = 6
For the mode we just look at the sample and find the most frequent value. In this sample the mode is therefore
x0 = 7
For variable y we do the same and obtain
y = 4.2
ym = 5
y0 = 5
2. The variance s2x and standard deviation sx are computed according to the formulas
s2x =1
n− 1
n∑i=1
(xi − x)2
sx =√s2x
We can compute the∑ni=1 (xi − x)
2by summing the column (xi − x)
2of the table, then dividing by n−1 = 4,
i.e.
s2x =22
4= 5.5 = 5.5
sx =√
5.5 = 2.345
For variable y we get
s2y =6.8
4= 1.7 = 1.7
sy =√
1.7 = 1.304
16
3. For the covariance we use the last column of the table. The formula is given by
sxy =1
n− 1
n∑i=1
(xi − x)(yi − y)
Therefore we obtain
sxy =
∑ni=1(xi − x)(yi − y)
n− 1
=−7
4= −1.75
and the correlation is obtained by
rxy =sxysxsy
=−1.75
2.345 · 1.304= −0.572
Problem 13
The joint probability distribution of X and Y is partially shown in the table below.
Y
0 1 2
0 0.14 0.25
X 1 0.12 0.1
2 0.08 0.28
0.39
In addition you know the conditional probability
P (Y = 1|X = 0) = 0
1. Complete the table
Answer The table below contains the solution
17
Y
0 1 2
0 0.14 0 0.11 0.25
X 1 0.12 0.1 0 0.22
2 0.17 0.08 0.28 0.53
0.43 0.18 0.39
2. Compute the expected value of X (show your math)
E(X) = (0)(0.25) + (1)(0.22) + (2)(0.53) = 1.28
3. Compute the variance of X (show your math)
V (X) = (0− 1.28)2(0.25) + (1− 1.28)2(0.22) + (2− 1.28)2(0.53) = 0.7016
4. Compute the expected value of Y (show your math)
E(Y ) = (0)(0.43) + (1)(0.18) + (2)(0.39) = 0.96
5. Compute the Variance of Y (show your math)
V (Y ) = (0− 0.96)2(0.43) + (1− 0.96)2(0.18) + (2− 0.96)2(0.39) = 0.8184
6. Compute the covariance of X and Y (show your math)
COV (X,Y ) = (0− 0.96)(0− 1.28)(0.14) + (1− 0.96)(0− 1.28)(0) + (2− 0.96)(0− 1.28)(0.11) +
+ (0− 0.96)(1− 1.28)(0.12) + (1− 0.96)(1− 1.28)(0.1) + (2− 0.96)(1− 1.28)(0) +
+ (0− 0.96)(2− 1.28)(0.17) + (1− 0.96)(2− 1.28)(0.08) + (2− 0.96)(2− 1.28)(0.28) = 0.1512
7. Are X and Y independent? Explain how you get the result.
Problem 14
The table below contains the joint distribution of two indepedent variables: X (rows) and Y (columns).
Y=24 Y=34 Y=48 Y=56 Y=74X=12 0.01 0.03 0.01 0.04 0.01X=24 0.08 0.24 0.08 0.32 0.08X=51 0.01 0.03 0.01 0.04 0.01
18
1. Please compute the covariance and correlation of X and Y. Explain.
Answer. There is no need to compute the covariance. The variables are indepedent, therefore the covarianceis zero: σXY = COV (X,Y ) = 0 and ρXY = 0.
2. Compute the conditional probability of X = 24, given Y = 48.P (X = 24|Y = 48) =
Asnwer. There is no need to compute this using the usual formula P (X = 24|Y = 48) = P (X=24,Y=48)P (Y=48) .
The variables are independent, therefore the conditionals are equal to the marginals. This means that P (X =24|Y = 48) = P (X = 24).To obtain the marginal for X we sum the entries of the table by row, and we get
P (X = 24) = 0.8
3. Compute the conditional probability of X = 51, given Y = 34.P (X = 51|Y = 34) =
Asnwer. There is no need to compute this using the usual formula P (X = 51|Y = 34) = P (X=51,Y=34)P (Y=34) .
The variables are independent, therefore the conditionals are equal to the marginals. This means that P (X =51|Y = 34) = P (X = 51).To obtain the marginal for X we sum the entries of the table by row, and we get
P (X = 51) = 0.1
4. Compute the conditional probability of Y = 34, given X = 51.P (Y = 34|X = 51) =
Asnwer. There is no need to compute this using the usual formula P (Y = 34|X = 51) = P (Y=34,X=51)P (X=51) .
The variables are independent, therefore the conditionals are equal to the marginals. This means that P (Y =34|X = 51) = P (Y = 34).To obtain the marginal for Y we sum the entries of the table by column, and we get
P (Y = 34) = 0.3
Problem 15
The joint probability distribution of X and Y is partially shown in the table below.
Y
0 1 2
0 0.15 0.06 0.09
X 1 0.15 0.06 0.09
2
0.5 0.2 0.3
19
1. Compute the marginal probability of X (show your math)Answer. The first 2 entries are simple. We have all the joint probabilities for X = 0 and X = 1. So we get
P (X = 0) = P (X = 0, Y = 0) + P (X = 0, Y = 1) + P (X = 0, Y = 2)
= 0.15 + 0.06 + 0.09
= 0.3
P (X = 1) = P (X = 1, Y = 0) + P (X = 1, Y = 1) + P (X = 1, Y = 2)
= 0.15 + 0.06 + 0.09
= 0.3
For the remaining probability we just use the fact that the marginal probabilities have to sum to 1, so we have
P (X = 0) + P (X = 1) + P (X = 2) = 1
and we can back up P (X = 2)
P (X = 2) = 1− P (X = 0)− P (X = 1) = 1− 0.3− 0.3 = 0.4
Y
0 1 2
0 0.15 0.06 0.09 0.3
X 1 0.15 0.06 0.09 0.3
2 0.4
0.5 0.2 0.3
2. Complete the table of joint probabilities (show your math)Answer. To find the remaining joint probabilities, we use the fact that each column should sum up to themarginal probability of Y . So for the first column we get that the missing probability P (X = 2, Y = 0) is suchthat
p(Y = 0) = 0.5 = 0.15 + 0.06 + P (X = 2, Y = 0)
So P (X = 2, Y = 0) is equal to
P (X = 2, Y = 0) = 0.5− 0.15− 0.15 = 0.2
Using the same computations we also get
P (X = 2, Y = 1) = 0.2− 0.06− 0.06 = 0.08
P (X = 2, Y = 2) = 0.3− 0.09− 0.09 = 0.12
20
Y
0 1 2
0 0.15 0.06 0.09 0.3
X 1 0.15 0.06 0.09 0.3
2 0.2 0.08 0.12 0.4
0.5 0.2 0.3
3. Compute the expected value of X (show your math)
E(X) = (0)(0.3) + (1)(0.3) + (2)(0.4) = 1.1
4. Compute the variance of X (show your math)
V (X) = (0− 1.1)2(0.3) + (1− 1.1)2(0.3) + (2− 1.1)2(0.4) = 0.69
5. Compute the expected value of Y (show your math)
E(Y ) = (0)(0.5) + (1)(0.2) + (2)(0.3) = 0.8
6. Compute the Variance of Y (show your math)
V (Y ) = (0− 0.8)2(0.5) + (1− 0.8)2(0.2) + (2− 0.8)2(0.3) = 0.76
7. Compute the covariance of X and Y (show your math)
COV (X,Y ) = (0− 0.8)(0− 1.1)(0.15) + (1− 0.8)(0− 1.1)(0.06) + (2− 0.8)(0− 1.1)(0.09) +
+ (0− 0.8)(1− 1.1)(0.15) + (1− 0.8)(1− 1.1)(0.06) + (2− 0.8)(1− 1.1)(0.09) +
+ (0− 0.8)(2− 1.1)(0.2) + (1− 0.8)(2− 1.1)(0.08) + (2− 0.8)(2− 1.1)(0.12) = 0
8. Are X and Y independent? Explain how you get the result.
Problem 16
Last year 45% of all cars traveling on Maryland highways were exceeding the speed limit of 65 mph. A cop randomlyselects (i.i.d) n = 7 cars traveling on I-95, and records if they are above the speed limit.
(A) What is the probability that all the cars are traveling above speed limit?
Answer. This probability is p7 = 0.457 = 0.00373669453125.
(B) What is the probability that exactly 2 cars are driving above speed limit?
21
Answer. Using the binomial probability formula
P (X = 2) =7!
2!5!0.4520.555 = 0.21402168046875
(C) What is the probability that exactly 5 cars are driving above speed limit?
Answer. Using the binomial probability formula
P (X = 5) =7!
5!2!0.4550.552 = 0.11722149140625
(D) What is the expected number of cars exceeding the speed limit?
Answer. The expected value of the binomial distribution is E(X) = np = 7 · 0.45 = 3.15
Problem 17
Use the following table to solve the question
Normal DistributionP (Z < 1.282) = 0.9 P (Z < 1.645) = 0.95 P (Z < 2.326) = 0.99P (Z < 2.576) = 0.995 P (Z < 1.96) = 0.975 P (Z < 0.842) = 0.8
In a survey of 98 individuals we calculate a sample proportion of p = 0.44.
1. Compute a 99% confidence interval for the proportion
Answer. The confidence interval is such that:
P
−z1−α2 < p− p√p(1−p)n
< z1−α2
≈ 1− α
where the value z1−α2 is such that P (Z < z1−α2 ) = 1 − α2 . In our case 1 − α = 0.99 and so 1 − α/2 = 0.995.
From the table at the end of the exam booklet we get P (Z < 2.576) = 0.995. So the confidence interval is
p± 2.576
√p(1− p)
n= 0.44± 2.576
√0.44(1− 0.44)
98= [0.311, 0.569]
2. Compute a 95% confidence interval for the proportion
Answer. The confidence interval is such that:
P
−z1−α2 < p− p√p(1−p)n
< z1−α2
≈ 1− α
where the value z1−α2 is such that P (Z < z1−α2 ) = 1 − α2 . In our case 1 − α = 0.95 and so 1 − α/2 = 0.975.
From the table at the end of the exam booklet we get P (Z < 1.96) = 0.975. So the confidence interval is
p± 1.96
√p(1− p)
n= 0.44± 1.96
√0.44(1− 0.44)
98= [0.342, 0.538]
22
3. Compute a 90% confidence interval for the proportion
Answer. The confidence interval is such that:
P
−z1−α2 < p− p√p(1−p)n
< z1−α2
≈ 1− α
where the value z1−α2 is such that P (Z < z1−α2 ) = 1− α2 . In our case 1−α = 0.9 and so 1−α/2 = 0.95. From
the table at the end of the exam booklet we get P (Z < 1.645) = 0.95. So the confidence interval is
p± 1.645
√p(1− p)
n= 0.44± 1.645
√0.44(1− 0.44)
98= [0.358, 0.522]
4. Compute a 80% confidence interval for the proportion
Answer. The confidence interval is such that:
P
−z1−α2 < p− p√p(1−p)n
< z1−α2
≈ 1− α
where the value z1−α2 is such that P (Z < z1−α2 ) = 1− α2 . In our case 1− α = 0.8 and so 1− α/2 = 0.9. From
the table at the end of the exam booklet we get P (Z < 1.282) = 0.9. So the confidence interval is
p± 1.282
√p(1− p)
n= 0.44± 1.282
√0.44(1− 0.44)
98= [0.376, 0.504]
23