Uploaded by Youssef AlYoussef

Probability Assignment

advertisement
Probability Assignment
SOLUTION)
I) We are given the cumulative distribution function (CDF) F(x) of the discrete
random variable X. We can determine the probability mass function (PMF) f(x)
from the CDF as follows:
𝑓(𝑥) = 𝐹(𝑥) − 𝐹(𝑥 − 1)
Applying this, we get:
Probability Assignment
𝑓(0) = 𝐹(0) − 𝐹(−1) = 0 − 0 = 0
𝑓(1) = 𝐹(1) − 𝐹(0) = 0.1 − 0 = 0.1
𝑓(2) = 𝐹(2) − 𝐹(1) = 0.7 − 0.1 = 0.6
𝑓(3) = 𝐹(3) − 𝐹(2) = 0.7 − 0.7 = 0
𝑓(4) = 𝐹(4) − 𝐹(3) = 0.7 − 0.7 = 0
𝑓(5) = 𝐹(5) − 𝐹(4) = 0.7 − 0.7 = 0
𝑓(6) = 𝐹(6) − 𝐹(5) = 1 − 0.7 = 0.3
We therefore get the following PMF:
0.1
𝑥 = 1,
𝑓(𝑥) = 𝑃(𝑋 = 𝑥) = 0.6
𝑥 = 2,
{0.3
𝑥 = 6,
and 0 otherwise.
We can now easily determine each of the required probabilities:
a) 𝑃(𝑋 ≤ 3.5) = 𝑃(𝑋 ≤ 3) = 𝑓(1) + 𝑓(2) = 0.1 + 0.6 = 𝟎. 𝟕
b) 𝑃(𝑋 > 5) = 𝑓(6) = 𝟎. 𝟑
c) 𝑃(𝑋 ≤ 5.2) = 𝑃(𝑋 ≤ 5) = 𝑓(1) + 𝑓(2) = 0.1 + 0.6 = 𝟎. 𝟕
d) 𝑃(𝑋 > 7) = 𝟎
e) 𝑃(1 ≤ 𝑋 ≤ 2) = 𝑓(1) + 𝑓(2) = 0.1 + 0.6 = 𝟎. 𝟕
f) 𝑃(𝑋 < 2) = 𝑓(1) = 𝟎. 𝟏
g) 𝑃(𝑋 = 2) = 𝑓(2) = 𝟎. 𝟔
h) 𝑃(𝑋 ≤ 2) = 𝑓(1) + 𝑓(2) = 0.1 + 0.6 = 𝟎. 𝟕
Probability Assignment
II) The mean 𝜇 and variance σ2 are given by:
𝜇 = 𝐸[𝑋] = ∑ 𝑥𝑓(𝑥)
𝑥
𝜎 2 = ∑(𝑥 − 𝜇)2 𝑓(𝑥)
𝑥
Therefore, the mean is:
𝜇 = 1(0.1) + 2(0.6) + 6(0.3) = 𝟑. 𝟏
The variance is:
𝜎 2 = (1 − 3.1)2 (0.1) + (2 − 3.1)2 (0.6) + (6 − 3.1)2 (0.3) = 𝟑. 𝟔𝟗
Probability Assignment
SOLUTION)
a) The distribution that describes the random variable X representing the number of
test repetitions until the student achieves the University requirement is the
geometric distribution, with the probability of success on each independent trial
being p = 0.3.
𝑋 ~ 𝑔(𝑥; 0.3)
The PMF of X is:
𝑓(𝑥) = 0.3(0.7)𝑥−1
𝑥 = 1, 2, 3, …
Probability Assignment
b) The average number of trials by any student to achieve the requirements is the
mean 𝜇 of the random variable X. The mean of any geometric random variable is
the reciprocal of p, therefore:
𝜇=
1
1
=
= 𝟑. 𝟑𝟑
𝑝 0.3
c) The probability that a student takes the test 4 times until the requirement is
achieved is found by:
𝑃(𝑋 = 4) = 𝑔(4; 0.3) = 0.3(0.7)4−1 = 𝟎. 𝟏𝟎𝟐𝟗
d) The probability that a student achieves the requirement at the 6th trial given that
he did not achieve it in the first and second trails is:
𝑃(𝑋 = 6|𝑋 > 2) =
=
𝑃(𝑋 = 6) ∩ 𝑃(𝑋 > 2) 𝑃(𝑋 = 6)
=
𝑃(𝑋 > 2)
𝑃(𝑋 > 2)
𝑃(𝑋 = 6)
𝑃(𝑋 = 6)
=
1 − 𝑃(𝑋 ≤ 2) 1 − 𝑃(𝑋 = 1) − 𝑃(𝑋 = 2)
0.3(0.7)6−1
0.3(0.7)5
0.3(0.7)5
=
=
=
1 − 0.3(0.7)1−1 − 0.3(0.7)2−1 1 − 0.3 − 0.3(0.7) 0.7(1 − 0.3)
0.3(0.7)5
=
= 0.3(0.7)3 = 𝟎. 𝟏𝟎𝟐𝟗
2
0.7
Probability Assignment
e) We can see that the answers to part (c) and (d) are the same. This is due to the
memoryless property of the geometric distribution.
In part (d), we are given that the student did not meet the requirements in the first
and second trials. He will therefore need 4 more trials to achieve the requirements at
the 6th trial. Because of the memoryless property of the geometric distribution, the
probability of this happening is the same as that of achieving the requirements at the
4th trial, which is the case in part (c).
f) The random variable Y representing the amount the student needs to pay in dollars
is given by:
𝑌 = 100 + 20𝑋
The expectation of Y is:
𝐸[𝑌] = 𝐸[100 + 20𝑋] = 𝐸[100] + 𝐸[20𝑋] = 100 + 20𝐸[𝑋]
100 + 20 (
1
) = 𝟏𝟔𝟔. 𝟔𝟕
0.3
The variance of Y is:
𝜎 2 [𝑌] = 𝜎 2 [100 + 20𝑋] = 202 𝜎 2 [𝑋] = 400 (
1 − 0.3
) = 𝟑𝟏𝟏𝟏. 𝟏𝟏
0.32
Probability Assignment
SOLUTION)
a) Let X denote the binomial random variable representing the number of free lifts
the student will get:
𝑋 ~ 𝑏(𝑥; 𝑛, 𝑝)
where n is the number of trials and p is the probability of success on a trial.
𝑛
𝑓(𝑥) = ( ) 𝑝 𝑥 𝑞 𝑛−𝑥
𝑥
𝑥 = 0, 1, 2, … , 𝑛
where q = 1 – p.
We are told that the probability of a free lift is 0.4, hence p = 0.4. The probability
that the student will get a lift only twice in a week of five days (n = 5) is:
5
𝑃(𝑋 = 2) = 𝑏(2; 5, 0.4) = ( ) (0.4)2 (1 − 0.4)5−2 = 𝟎. 𝟑𝟒𝟓𝟔
2
Probability Assignment
b) Let Y denote the geometric random variable representing the day on which the
student gets his/her first free lift:
𝑌 ~ 𝑔(𝑥; 𝑝)
where p is the probability of success on a trial.
𝑓(𝑥) = 𝑝𝑞 𝑥−1
𝑥 = 0, 1, 2, …
where q = 1 – p.
As earlier, p = 0.4. The probability that the student will get his/her first lift on the
third day is therefore:
𝑃(𝑌 = 3) = 0.4(1 − 0.4)3−1 = 0.4(0.6)2 = 𝟎. 𝟏𝟒𝟒
c) The number of times the student needs to get a taxi is a binomial random
variable. Since the student needs to get a taxi if he/she does not get a lift, the
probability of getting a taxi is 1 – 0.4 = 0.6.
The expected value of a binomial random variable is 𝜇 = 𝑛𝑝. Therefore, in 20 days,
we expect that the student will need to get a taxi 0.6(20) = 12 times. We are told that
the student needs to pay 20 QAR for the taxi, so the expected amount of money to
be paid in 20 days is:
12(20) = 𝟐𝟒𝟎 𝐐𝐀𝐑
Probability Assignment
SOLUTION)
Let X be the random variable representing the number of calls coming per minute
into a hotel reservation. We are told that this random variable would follow a Poisson
distribution. Therefore, X has the following PDF:
𝑒 −𝜆𝑡 (𝜆𝑡)𝑥
𝑓(𝑥) =
𝑥!
𝑥 = 0, 1, 2, 3, …
where 𝜆 is the average number of calls coming per minute.
a) We are told that the mean number of calls per minute is 3, which gives us the
value of 𝜆. As for t, this would simply be 1 since it is a 1-minute period. The
probability that no calls come in a given 1-minute period is:
𝑒 −3 (3)0
𝑃(𝑋 = 0) =
= 𝑒 −3 = 𝟎. 𝟎𝟒𝟗𝟖
0!
Probability Assignment
b) In this part, the period is of length two minutes and so we have to adjust the value
of t to 2. We would thus have 𝜆𝑡 = 3(2) = 6. The probability that at least two
calls will arrive in a given two-minute period is:
1
𝑒 −6 (6)𝑥
𝑃(𝑋 ≥ 2) = 1 − 𝑃(𝑋 < 2) = 1 − ∑
= 𝟎. 𝟗𝟖𝟐𝟔
𝑥!
𝑥=0
c) In this part, the period is of length five minutes and so we have to adjust the value
of t to 5. We would thus have 𝜆𝑡 = 3(5) = 15. The probability that at most two
calls will arrive in a given five-minute period is:
2
𝑒 −15 (15)𝑥
𝑃(𝑋 ≤ 2) = ∑
= 𝟑. 𝟗𝟑𝟎𝟖 × 𝟏𝟎−𝟓
𝑥!
𝑥=0
Probability Assignment
SOLUTION)
The probability density function (PDF) can be obtained from the cumulative
distribution function (CDF) by taking its derivative:
𝑓(𝑥) =
𝑑𝐹(𝑥)
𝑑𝑥
Taking the derivative for each interval, we end up with the following PDF:
𝑓(𝑥) =
0.2
0≤𝑥<4
0.05
4≤𝑥<8
{0
otherwise
We now find the mean 𝜇:
∞
4
8
𝜇 = 𝐸[𝑋] = ∫ 𝑥𝑓(𝑥) 𝑑𝑥 = ∫ 0.2𝑥 𝑑𝑥 + ∫ 0.05𝑥 𝑑𝑥
−∞
4
8
= 0.1𝑥 | + 0.025𝑥 | = 0.1(16) + 0.025(64 − 16) = 𝟐. 𝟖
0
4
2
4
0
2
Probability Assignment
The variance 𝜎 2 is defined as:
𝜎 2 = 𝐸[𝑋 2 ] − (𝐸[𝑋])2 = 𝐸[𝑋 2 ] − 𝜇 2
We first find 𝐸[𝑋 2 ]:
∞
𝐸[𝑋
2]
4
2
8
= ∫ 𝑥 𝑓(𝑥) 𝑑𝑥 = ∫ 0.2𝑥 𝑑𝑥 + ∫ 0.05𝑥 2 𝑑𝑥
−∞
2
0
4
1 3 4 1 3 8
1 3
1 3
176
(4 ) +
(8 − 43 ) =
=
𝑥 | +
𝑥 | =
15
60
15
60
15
0
4
∴ 𝜎2 =
176
𝟐𝟗𝟐
− (2.8)2 =
≅ 𝟑. 𝟖𝟗𝟑
15
𝟕𝟓
Probability Assignment
SOLUTION)
The uniformly distributed random variable X representing the weight of motors
delivered by the shipping company is given as:
0.1
𝑓(𝑥) = {
0
1200 < 𝑥 < 1210
otherwise
a) The mean motor weight is:
∞
1210
𝜇 = 𝐸[𝑋] = ∫ 𝑥𝑓(𝑥) 𝑑𝑥 = ∫
−∞
2
1210
0.1𝑥 𝑑𝑥 = 0.05𝑥 |
1200
1200
∴ 𝜇 = 0.05(1210)2 − 0.05(1200)2 = 𝟏𝟐𝟎𝟓
Alternatively, we could have used the fact that the mean of any uniformly distributed
random variable over the interval (A, B) is simply the average of A and B. In our
case, A and B are 1200 and 1210 respectively. Their average is 1205 which agrees
with the result obtained by integration.
Probability Assignment
The standard deviation is the positive root of the variance. Therefore, to obtain the
standard deviation of X, we first find its variance:
𝜎 2 = 𝐸[𝑋 2 ] − (𝐸[𝑋])2 = 𝐸[𝑋 2 ] − 𝜇 2
∞
𝐸[𝑋
2]
1210
2
= ∫ 𝑥 𝑓(𝑥) 𝑑𝑥 = ∫
−∞
=
1200
1 3 1210
0.1𝑥 𝑑𝑥 =
𝑥 |
30
1200
2
1
4356100
(12103 − 12003 ) =
30
3
∴ 𝜎2 =
4356100
25
− (1205)2 =
3
3
Alternatively, we could have used the fact that the variance of any uniformly
distributed random variable over the interval (A, B) is:
(𝐵 − 𝐴)2 (1210 − 1200)2 25
𝜎 =
=
=
12
12
3
2
which agrees with the result found by integration.
In any case, the standard deviation can be readily obtained from the variance by
taking its positive square root:
𝜎 = √𝜎 2 = √
25
𝟓√𝟑
=
≅ 𝟐. 𝟖𝟖𝟕
3
𝟑
Probability Assignment
b) The proportion of motors within specifications is:
1205
𝑃(1195 < 𝑋 < 1205) = ∫
1195
1205
𝑓(𝑥) 𝑑𝑥 = ∫
0.1 𝑑𝑥
1200
1205
= 0.1𝑥 |
= 0.1(1205 − 1200) = 𝟎. 𝟓
1200
Therefore, half of the motors will be within the weight specifications.
Probability Assignment
SOLUTION)
Let the random variable T denote the reaction time. We are told that this random
variable follows a normal distribution with a mean of 0.5 seconds and a standard
deviation of 0.05 seconds.
a) The required probability is P(T > 0.5). Since T is a normal random variable, we
need to convert it to the standard normal random variable Z in order to use the
table providing the areas under the normal curve:
𝑃(𝑇 > 0.5) = 𝑃 (𝑍 >
0.5 − 0.5
) = 𝑃(𝑍 > 0) = 𝟎. 𝟓
0.05
We could have arrived at this result straight away because 0.5 seconds is the mean;
the probability that any normal random variable exceeds its mean is always 50%.
Probability Assignment
b) The required probability is P(0.496 < T < 0.502). Again, we convert to the
standard normal random variable Z in order to use the table values:
𝑃(0.496 < 𝑇 < 0.502) = 𝑃 (
0.496 − 0.5
0.502 − 0.5
<𝑍<
)
0.05
0.05
= 𝑃(−0.08 < 𝑍 < 0.04) = 𝑃(𝑍 < 0.04) − 𝑃(𝑍 < −0.08) = 0.5160 − 0.4681
∴ 𝑃(0.496 < 𝑇 < 0.502) = 𝟎. 𝟎𝟒𝟕𝟗
c) Our goal here is to find the value a such that:
𝑃(𝑇 > 𝑎) = 0.90
This is equivalent to:
𝑃(𝑇 < 𝑎) = 0.10
Converting to the standard normal random variable Z and using the table, we get:
𝑃 (𝑍 <
𝑎 − 0.5
𝑎 − 0.5
) = 0.10 →
= −1.28
0.05
0.05
∴ 𝑎 = −1.28(0.05) + 0.5 = 𝟎. 𝟒𝟑𝟔
The reaction time that is exceeded 90% of the time is therefore 0.436 seconds.
Probability Assignment
SOLUTION)
Let X denote a hypergeometric random variable representing the number of pages
in error within the 100 pages sampled randomly from the lot of 1000 pages:
𝑋 ~ ℎ(𝑥; 𝑁, 𝑛, 𝑘)
𝑓(𝑥) =
(𝑘𝑥 )(𝑁−𝑘
)
𝑛−𝑥
(𝑁
)
𝑛
Here, n is the size of the random sample of pages selected, N is the total number of
pages, of which k are the pages in error and N – k are the pages not in error. The
probability that at least 30 of the pages in error is in the randomly selected sample is
P(X ≥ 30).
In this problem, we have N = 1000 and n = 100. In such cases when n is small relative
to N, the binomial distribution can be used to approximate the hypergeometric
distribution. We are told that the printer produces an error on 50 of 1000 pages, so
we take p, the binomial parameter which is the probability that a page is in error to
be:
𝑝=
𝑘
50
=
= 0.05
𝑁
1000
Probability Assignment
We can also use another approximation; because n is large, the binomial distribution
can be approximated well by the normal distribution. If X is a binomial random
variable whose mean is 𝜇 = 𝑛𝑝 and variance is 𝜎 2 = 𝑛𝑝𝑞 = 𝑛𝑝(1 − 𝑝), then the
following standard normal random variable Z can be used to approximate the
binomial distribution:
𝑍=
𝑋 − 𝑛𝑝
√𝑛𝑝(1 − 𝑝)
The required probability can therefore be approximated as:
𝑃(𝑋 ≥ 30) = 1 − 𝑃(𝑋 < 30) = 1 − ℎ(< 30; 1000, 100, 50)
≈ 1 − 𝑏(< 30, 100, 0.05)
≈ 1 − 𝑃 (𝑍 <
29.5 − 100(0.05)
) = 1 − 𝑃(𝑍 < 11.24) ≅ 1 − 1 = 𝟎
√100(0.05)(1 − 0.05)
Note that a continuity correction of 0.5 was used in the conversion from the discrete
binomial distribution to the continuous normal distribution (30 to 29.5).
Note as well that in reality, the probability is extremely small but not exactly 0; the
calculations merely lack the precision required for the exact extremely small value.
This makes sense because if only 50 pages are in error out of the total 1000 pages,
then it is extremely unlikely for there to be 30 or more pages in error within a sample
of just 100 pages.
Probability Assignment
If the question was instead to find the probability that at least one of the pages in
error is in the sample, we would have proceeded as follows:
𝑃(𝑋 ≥ 1) = 1 − 𝑃(𝑋 < 1) = 1 − 𝑃(𝑋 = 0)
= 1 − ℎ(0; 1000, 100, 50) ≈ 1 − 𝑏(0, 100, 0.05)
≈ 1 − 𝑃 (𝑍 <
0.5 − 100(0.05)
√100(0.05)(1 − 0.05)
) = 1 − 𝑃(𝑍 < −2.06)
≅ 1 − 0.0197 = 𝟎. 𝟗𝟖𝟎𝟑
If we were to compute the probability using the hypergeometric distribution without
any approximations, the result would be:
𝑃(𝑋 ≥ 1) = 1 − 𝑃(𝑋 < 1) = 1 − 𝑃(𝑋 = 0)
1−
(50
)(950
)
0
100
(1000
)
100
= 1 − 0.00448 = 𝟎. 𝟗𝟗𝟓𝟓𝟐
We can therefore see how the approximation did a fairly reasonable job.
Probability Assignment
SOLUTION)
We can let the random variable X denote the distance between major cracks in a
highway. We are told that this random variable follows an exponential distribution
with a mean of 10 km. We can therefore express the PDF of X as follows:
1 −𝑥
𝑒 10
10
𝑓(𝑥) = {
𝑥>0
o. w.
0
a) The probability that there are no major cracks in a 20 km stretch of the highway
means the distance between major cracks is more than 20 km. The required
probability is therefore:
𝑥 ∞
1 −𝑥
−10
10
𝑃(𝑋 > 20) = ∫ 𝑓(𝑥) 𝑑𝑥 = ∫
𝑒
𝑑𝑥 = −𝑒
|
20
20 10
20
∞
= −𝑒
−∞
+
∞
20
−10
𝑒
= 𝑒 −2 =
1
= 𝟎. 𝟏𝟑𝟓𝟑
𝑒2
Probability Assignment
b) Using the relationship between the exponential probability distribution and the
Poisson process, we can consider a random variable Y representing the number
of major cracks in a 20 km stretch of the highway. From the mean of X, we can
see that we expect an average of one major crack per 10 km. Therefore, in a 20
km stretch of the highway, we expect the mean number of major cracks to be
two. We conclude that for the Poisson random variable Y, we have 𝜆𝑡 = 2. The
PDF of Y would therefore be:
𝑒 −2 (2)𝑦
𝑓(𝑦) =
𝑦!
𝑦 = 0, 1, 2, …
Using this, we can easily calculate the probability that there are two major cracks in
a 20 km stretch:
𝑒 −2 (2)2
2
𝑃(𝑌 = 2) =
= 2 = 𝟎. 𝟐𝟕𝟎𝟕
2!
𝑒
c) The fact that there were no major cracks in the first 10 km inspected has no
impact on the likelihood of major cracks in the next 20 km. This is because the
exponential distribution is memoryless. We therefore only have to find the
probability that no major cracks occur in a 20 km stretch, which is essentially the
same as part (a):
𝑃(𝑋 > 20) = 𝑒 −2 = 𝟎. 𝟏𝟑𝟓𝟑
Download