
ДискретнаяМатематика / Student Solutions Manual / chapter 8
.pdf473
If p is not equal to 1/2 then 1 p cannot be equal to p since probabilities range from zero to one. Therefore b(n k; n; p) 6= b(k; n; p) when p 6= 1=2.
7.Suppose we draw three balls from an urn containing two red balls and three black balls. We do not replace the balls after we draw them. In terms of the hypergeometric distribution, what is the probability of getting two red balls? Compute this probability.
7. There are a total of m = 5 balls in the urn, r = 2 of them are red, and we draw n = 3 of them out. The probability of getting k = 2 red balls is given by the hypergeometric distribution,
P (X = 2) = |
C(r;k)C(m r;n k) |
|||
C(m;n) |
||||
|
||||
|
= C(2;2)C(3;1) |
|||
|
C(5;3) |
|||
|
= |
3 |
|
|
|
|
|
||
|
10 |
|
474
9.Compute the expectation E(X) of the random variable X that counts the number of heads in four ips of a coin that lands heads with frequency
1=3:
P
9. E(X) = xpX (x). In Exercise 4 we calculated pX (x) for all x. Sub-
stituting into the equation gives E(X) = 0pX (0) + 1pX (1) + 2pX (2) + 3pX (3) + 4pX (4) = 43 .
11.We have seen two ways to compute the expected value E(X) of a random variable X: One way is to use the de nition of expected value, summing
pX (x) over the range X of X: The other way is to use Theorem 2, summing X(!) p(!) over the domain of X. If you have not already done so, do Exercise 10 and then compute E(X) using the method you did not use the rst time. In general, which method do you think will be easier to carry out, and why?
11. Let = f(x1x2x3)jxi 2 f0; 1gg be the sample space for the experiment
where xi = 1 means that the ith ball drawn is red. De ne a probability density on as follows: p(111) = (2=5)3, p(110) = p(101) = p(011) = (2=3)2 3=5, p(100) = p(010) = p(001) = (3=5)2 2=5, and p(000) = (3=5)3.
Let X be a random variable such that X(!) = X(x1x2x3) = x1 + x2 + x3. Then E(X) = X(!)p(!) = 3p(111)+2p(110)+2p(101)+p(100)+2p(011)+ p(010) + p(001) = 6=5.
Let = f((000); (001); (010); (011); (100); (101); (110)g. De ne a probability density on in the following manner. For the outcome (001) the probability of picking a black ball on the rst draw is 3=5, the probability of picking another black ball on the second draw is then 2=4 since
475
there are only four balls left in the urn and two of them are black. Similarly, the probability of picking a red ball on the third draw is 2=3 since there are three balls left, two of which are red. Thus, p(001) = (3=5) (2=4) (2=3) = 1=5. Using the same method we calculate the probabilities for every outcome in , p(010) = 1=5, p(011) = 1=10, p(100) = 1=5, p(101) = 1=10, p(110) = 1=10, p(000) = 1=10. The random variable X is de ned in the same manner as in part (a). Now E(X) = (1=5) + (1=5) + 2 (1=10) + (1=5) + 2 (1=10) + 2 (1=10) = 6=5.
13.Wagga Wagga University has 15,000 students. Let X be the number of courses for which a randomly chosen student is registered. No student is registered for more than seven courses, and each student is registered for at least one course. The number of students registered for i courses where 1 i 7 is: 150, 450, 1950, 3750, 5850, 2550, and 300, respectively. Compute the expected value of the random variable X.
13. 3913.9
476
8.10 Exercises
1.Compute the variance V ar(X) of the random variable X that counts the number of heads in four ips of a fair coin.
1. First we de ne the sample space of the experiment. = fx1x2x3x4jxi 2 f0; 1gg. If xi = 1 the ith toss of the coin resulted in heads, otherwise the ith toss resulted in tails. Since the coin is fair we have a uniform probability density, so p(!) = 1=j j = 1=16 for all ! 2 . Next, we de ne the
random variable X. X(!) = X(x1x2x3x4) = x1 + x2 + x3 + x4. The equation for the variance of a random variable X is V ar(X) = E(X 2) 2.
We now nd the expected value of X, E(X) = 2 = . Thus, 2 = 4. To nd E(X2) we compute E(X2) = P!2 p(!)(X(!))2 = 5. Therefore, V ar(X) = 5 4 = 1.
3.De ne a random variable X on the sample space by setting X(!) = 3 for all ! 2 : What is E(X)? V ar(X)?
3. We are given that X(!) = 3 for all ! 2 . The expected value of X
!2 p(!) = 1 |
P 2 |
2 |
P |
2 |
P |
|
is then E(X) = |
!2 X(!)p(!) = |
!2 |
3 p(!) = 3 |
|
!2 p(!). Since |
|
P |
|
).2 E(X ) = 2 |
!2 p(!)(X(!)) = 9 |
!2 p(!) = 9. |
||
|
by de nition, we have that E(X) = 3. |
We do a similar |
P P
calculation for E(X
Thus, V ar(X) = E(X ) (E(X)) = 9 9 = 0.

477
5. Suppose we ip a fair coin n times. Let consist of n-tuples ! of H's and T 's. Let Xi(!) = 1 if the ith component of ! is an H; otherwise, let Xi(!) = 0:
(a)Do the Xi form an i.i.d. set of random variables?
(b)Let Y = (X1 + + Xn)=n: What is the mean and the variance of Y ?
(c)Suppose n = 100: Use Theorem 5 to give an upper bound for the probability that Y di ers from its mean by 0.1 or more.
5. (a) The experiment consists of n Bernoulli Trials. As Example 4 shows, sets of Bernoulli Trials give rise to independent, identically distributed random variables. Therefore the Xi's do form an i.i.d. set of random variables.
5. (b) The random variable Y is the average of a set of i.i.d. random variables with mean and variance 2. This random variable also has
mean , but has variance |
|
2 |
. Here = |
1 |
|
0 + 1 |
1 = 1 and 2 = |
|||||||||
|
|
|||||||||||||||
1 |
1 |
2 |
1 |
1 |
2 |
1 |
|
n |
12 |
|
2 |
21 |
|
|||
2 (0 2 ) |
|
+ 2 (1 |
2 ) |
|
= 4 |
. Thus, E(Y ) = |
|
and V ar(Y ) = |
|
. |
||||||
|
|
2 |
4n |
|||||||||||||
5. |
(c) We use The Law of Averages with 2 |
= |
1 , = 1 , n = 100, and |
|||||||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
4 |
2 |
|
|
= 0:1. P (jY 12 j 0:1) n 22 = 14 .
7. Let a random variable X have probability density function
x |
1 |
|
|
2 |
|
6 |
8 |
|
|
|
||
p(X = x) |
0.4 |
|
0.1 |
|
0.3 |
0.2 |
|
|
||||
Compute the variance and standard deviation of X with = 4: |
||||||||||||
7. 2 = V ar(X) = E(X |
2) 2 . First nd E(X2). E(X2) = x2pX (x) = |
|||||||||||
1(:4) +24(:1) + |
|
2 |
|
|
|
|
|
|
|
|
P |
|
|
|
36(:3) + 64(:2) = 24:4. Next, determine the variance, noting |
||||||||||
that = 16. |
|
= 24:4 |
16 = 8:4. Computing the standard deviation is |
|||||||||
straightforward. = |
( |
2) = p |
8:4 |
2:9 |
478
479
8.11 End of Chapter Materials
Starting to Review
1.What is a sample space? An outcome? An event?
1. An outcome is a possible result of an experiment. A sample space is the set of all possible outcomes of an experiment. An event is a subset of a sample space.
3.What condition on a probability density function p on the sample space makes p a uniform probability density function? De ne a uniform probability density function on the possible results of rolling a fair die. Compute the probability that the top face after the roll of a fair die shows more than 4 spots; an even number of spots and either one or ve spots.
3. A probability density function p on the sample space is uniform if p(!) = 1=j j for all ! 2 . The sample space of a single roll of a fair die is = f1; 2; 3; 4; 5; 6g. Note that j j = 6. Thus a uniform probability density function on the space is given by p(!) = 1=6 for all ! 2 . Let E1 = f5; 6g be the event that the top face after a roll of a fair die shows more than 4 spots. Then, p(E1) = p(f5; 6g) = p(5)+p(6) = 1=3. Similarly, de ne E2 = f2; 4; 6g to be the event that the top face after a roll of the die shows an even number of spots and E3 = f1; 5g to be the event that the top face shows either a one or a ve. Then, p(E2) = p(2) + p(4) + p(6) = 1=2
and p(E3) = p(1) + p(5) = 1=3.
480
5.Flip a fair coin 8 times. What is the probability of getting 5 heads? If the coin is biased and comes up heads only 40% of the time, what is the probability of ve heads out of 8 ips? Of six heads out of eight ips?
5. First de ne a |
|
8 |
|
8 |
|
f |
(x |
1; x2; : : : ; x8)jxi 2 fH; T gg. |
|||||||||
|
|
|
|
|
sample space. |
= |
|
|
|
|
|
|
|
||||
Note that |
j |
|
j |
= |
2 |
|
so p(!) = 2 |
|
for |
each ! |
2 |
. |
The probabil- |
||||
|
|
|
|
|
|
|
|
8 |
|
|
For the biased |
||||||
ity of getting exactly ve heads is C(8; 5) 2 |
|
0:22. |
coin we will use the Bernoulli Trial formula with n = 8, p = 0:4 and k = 5. We de ne a success as a coin toss resulting in heads. We wish to know the probability of obtaining exactly k = 5 successes. This is
given by b(8; 5; 0:4) = |
C(8; 5)(0:4)5 |
(:6) |
3 |
0:12. For k = 6, we have |
||||
|
6 |
(0:6) |
2 |
|
|
|||
b(8; 6; 0:4) = C(8; 6)(0:4) |
|
|
0:04. |
|
|
7.State Bayes' Rule. Compute the probability for rolling a fair die twice and getting 3 pips both times, knowing that the rst roll does result in 3 pips. What does your intuition suggest as an answer? Use Bayes' Rule to verify your intuition.
7. Bayes' Rule states that for any two events A and B in a sample space ,
if neither P (A) nor P (B) is zero, then P (BjA) = P (AjB)(P (B)=P (A)). Let = f(1; 1); (1; 2); ; (6; 6)g. The event that a 3 is rolled in the
rst roll is given by A |
= f(3; 1); (3; 2); ; (3; 6)g. Similarly, let B = |
f(1; 3); (2; 3); ; (6; 3)g. |
Note that P (A) = P (B) = 6=36 = 1=6. We |
want to nd P (BjA) using Bayes' Rule. P (BjA) = P (AjB)(P (B)=P (A)) =
481
(P (A \ B))=(P (B))(P (B)=P (A)) = (P (A \ B))=(P (A)) = P (f(3; 3)g)=P (B) = (1=36) (6=1) = 1=6.
9.De ne a random variable X that counts the number of tails that result from ipping a fair coin three times. Let the sample space for ipping the coin have a uniform probability density function. Compute the expectation or mean of X.
9. For this problem let 1 denote tails and 0 denote heads. Then = f(0; 0; 0); (0; 0; 1); (0; 1; 0); (0; 1; 1); ; (1; 1; 1)g. p(!) = 1=8 for all ! 2 since we have a uniform probability density and j j = 23 = 8. Let X be
the random variable de ned by X[(x; y; z)] = x + y + z where (x; y; z) 2 .
take it |
P |
!2 X(!) = (1=8)(0 + 1 + |
E(X) = |
!2 X(!)p(!). Since p(!) is constant over all ! in , we can |
|
1 + 2 + 1 + 2 + 2 + 3) = 3=2: |
P |
|
out of the summation. E(X) = (1=8) |
|

482
Review Questions
1.Let = f1; 2; 3; 4; 5; 6g, A = f1; 2; 3g, B = f3; 5; 6g, and C = f2; 4; 6g. Describe the following events:
(a)At least one of the events A; or B occurs
(b)Exactly one of the events A; or B occurs
(c)At least one of the events A; B; or C occurs
(d)Exactly one of the events A; B; and C occurs
(e)All three of the events A; B; and C occur
(f)Exactly two of the events A; B; or C occur
(g)At least two of the events A; B; or C occur
(h)None of the events A; B; and C occurs
(i)No more than one of the events A; B; or C occurs
(j)No more than two of the events A; B; or C occur
(k)A occurs, but neither B nor C occurs.
1. (a) A [ B = f1; 2; 3; 5; 6g
1. (b) (A \ B) [ (B \ A) = f1; 2; 5; 6g
1. (c) A [ B [ C = f1; 2; 3; 4; 5; 6g
1. (d) (A \ B [ C) [ (B \ A [ C) [ (C \ A [ B) = f1; 4; 5g
1. (e) A \ B \ C =