University of Washington
Department of Mathematics Homework 1 Solution

MATH 394: Probability I

Instructor: Arman Jahangiri

Submission: Single PDF on Gradescope

Deadline: 10:00 PM Pacific Time on the listed due date

This homework is worth 50 points.

Across the quarter, there are eight homework assignments, worth 400 points total. Homework assignments together account for 40% of the final course grade. Further course policies can be seen in the MATH 394 syllabus.

Homework Policy

Submission and Deadline

Please:

Late Days

Each student is allotted six late days for the quarter. A late day extends a homework deadline by up to 24 hours without penalty. For example, submitting an assignment anytime between 10:01 PM on the due date and 10:00 PM the following day counts as one late day.

The following rules apply:

Once all late days have been exhausted, additional late submissions will incur a penalty of 10% per day, up to a maximum deduction of 50%. Assignments submitted more than five days late, or after solutions have been released, will not be accepted.

Submission Issues and Technical Difficulties

If a serious technical issue prevents a timely Gradescope submission, students may temporarily submit their assignment by email to the instructor at armanjg@uw.edu. In such cases:

Email submissions are intended only for genuine technical emergencies and should not be used as a substitute for timely Gradescope submission.

Problem 1.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 23.

Three people get into an empty elevator at the first floor of a building that has 10 floors. Each presses the button for their desired floor, unless one of the others has already pressed that button. Assume that they are equally likely to want to go to floors 2 through 10, independently of each other.

What is the probability that the buttons for 3 consecutive floors are pressed?

Solution

There are 9 possible destination floors, namely floors 2 through 10. Since the three people make their choices independently, it is natural to count ordered triples of desired floors. The total number of such triples is \[ 9^3. \]

For exactly three consecutive buttons to be pressed, the three desired floors must be distinct, and the set of floors must look like \[ \{j,j+1,j+2\}, \quad with \ j=2,\cdots , 8. \] The smallest possible starting floor is 2 and the largest possible starting floor is 8, so there are 7 possible consecutive triples of floors. Once such a triple of floors has been chosen, the three people may be assigned to those floors in \(3!\) different orders. Thus the number of favorable ordered triples is \[ 7\cdot 3!. \] Hence the desired probability is \[ \frac {7\cdot 3!}{9^3} = \frac {42}{729} = \frac {14}{243}. \]

Problem 2.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 3.

Fred is planning to go out to dinner each night of a certain week, Monday through Friday, with each dinner being at one of his ten favorite restaurants.

(a)
How many possibilities are there for Fred’s schedule of dinners for that Monday through Friday, if Fred is not willing to eat at the same restaurant more than once?
(b)
How many possibilities are there for Fred’s schedule of dinners for that Monday through Friday, if Fred is willing to eat at the same restaurant more than once, but is not willing to eat at the same place twice in a row or more?

Solution

(a) Fred is choosing restaurants for five ordered nights, and in this part no restaurant may be repeated. There are 10 choices for Monday, then 9 choices for Tuesday, then 8 choices for Wednesday, then 7 choices for Thursday, and finally 6 choices for Friday. Therefore the number of possible dinner schedules is \[ 10\cdot 9\cdot 8\cdot 7\cdot 6 = 30240. \]

(b) Now Fred may return to a restaurant later in the week, but he may not eat at the same restaurant on two consecutive nights. Monday can be chosen in 10 ways. On each of the remaining four nights, exactly one restaurant is forbidden, namely the restaurant from the previous night. Thus each of Tuesday through Friday has 9 available choices. The number of possible schedules is \[ 10\cdot 9^4 = 65610. \]

Problem 3.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 15–18.

Give story proofs for the following identities.

(a)
Show that \[ \sum _{k=0}^{n} {n \choose k}=2^n. \]
(b)
Show that \[ \sum _{k=0}^{n}{n \choose k}^2={2n \choose n}, \] for all positive integers \(n\).
(c)
Show that \[ \sum _{k=1}^{n} k{n \choose k}^2 = n{2n-1 \choose n-1}, \] for all positive integers \(n\).

Hint: Consider choosing a committee of size \(n\) from two groups of size \(n\) each, where only one of the two groups has people eligible to become the chair of the committee.

Solution

(a) Consider a group of \(n\) people, and imagine forming a committee from this group. One way to make the committee is to decide, separately for each person, whether that person is included. Since each person has two possibilities, included or not included, the number of committees is \(2^n\).

The same committees can also be counted by their size. If the committee has \(k\) members, then it can be chosen in \(\binom {n}{k}\) ways. Since the committee may have any size from 0 to \(n\), the total number of committees is \[ \sum _{k=0}^{n}\binom {n}{k}. \] These two expressions count the same set of committees, and so \[ \sum _{k=0}^{n}\binom {n}{k}=2^n. \]

(b) Suppose there are two groups, each containing \(n\) people. We want to form a committee of size \(n\) from the combined group of \(2n\) people. If we ignore the two-group structure, this can be done in \[ \binom {2n}{n} \] ways.

Now count the same committees by the number \(k\) chosen from the first group. If \(k\) people are chosen from the first group, then \(n-k\) people must be chosen from the second group. This gives \[ \binom {n}{k}\binom {n}{n-k} \] committees. Since \(\binom {n}{n-k}=\binom {n}{k}\), the number with this value of \(k\) is \(\binom {n}{k}^2\). Summing over all possible values of \(k\) gives \[ \sum _{k=0}^{n}\binom {n}{k}^2. \] Both counts describe the same committees, and hence

(c) Again take two groups of \(n\) people each. We form a committee of size \(n\), and then choose a chair from the first group among those who are on the committee.

Count first according to the number \(k\) of committee members who come from the first group. The first group contributes \(k\) people in \(\binom {n}{k}\) ways, and the second group contributes the remaining \(n-k\) people in \(\binom {n}{n-k}=\binom {n}{k}\) ways. Once the committee has been chosen, there are \(k\) choices for the chair, since the chair must be one of the selected members from the first group. Thus this count gives \[ \sum _{k=1}^{n} k\binom {n}{k}^2. \]

There is a shorter count of the same chaired committees. Choose the chair first from the first group, which gives \(n\) choices. After the chair is chosen, we still need \(n-1\) additional committee members, and they may be chosen from the remaining \(2n-1\) people. This gives \[ n\binom {2n-1}{n-1}. \] The two counts are counting exactly the same objects, so

Problem 4.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 25.

A city with 6 districts has 6 robberies in a particular week. Assume the robberies are located randomly, with all possibilities for which robbery occurred where equally likely.

What is the probability that some district had more than 1 robbery?

Solution

It is easiest to count the complement. Treat the 6 robberies as distinguishable, for instance by the order in which they occurred. Each robbery may occur in any of the 6 districts, so there are \[ 6^6 \] equally likely assignments.

The complement of the event in the problem is the event that no district had more than one robbery. Since there are 6 robberies and 6 districts, this means that each district had exactly one robbery. The number of assignments with exactly one robbery in each district is \(6!\), since the robberies must be matched one-to-one with the districts.

Therefore \[ \mathbb {P}(\text {no district had more than one robbery}) = \frac {6!}{6^6}. \] It follows that \[ \mathbb {P}(\text {some district had more than one robbery}) = 1-\frac {6!}{6^6} = 1-\frac {720}{46656} = \frac {319}{324}. \]

Problem 5.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 5.

A knock-out tournament is being held with \(2^n\) tennis players. This means that for each round, the winners move on to the next round and the losers are eliminated, until only one person remains. For example, if initially there are \(2^4=16\) players, then there are 8 games in the first round, then the 8 winners move on to round 2, then the 4 winners move on to round 3, then the 2 winners move on to round 4, the winner of which is declared the winner of the tournament. There are various systems for determining who plays whom within a round, but these do not matter for this problem.

(a)
How many rounds are there?
(b)
Count how many games in total are played, by adding up the numbers of games played in each round.
(c)
Count how many games in total are played, this time by directly thinking about it without doing almost any calculation.

Hint: How many players need to be eliminated?

Solution

(a) There are \(2^n\) players at the beginning. After each round, half of the players remain. Thus the numbers of players remaining after successive rounds are \[ 2^n,\;2^{n-1},\;2^{n-2},\ldots ,2,1. \] It takes \(n\) rounds to reduce the field from \(2^n\) players to one champion.

(b) In the first round, \(2^{n-1}\) games are played. In the second round, \(2^{n-2}\) games are played. Continuing in this way, the final round has one game. The total number of games is therefore \[ 2^{n-1}+2^{n-2}+\cdots +2+1 = 2^n-1. \]

(c) There is also a very direct way to see the same number. Every game eliminates exactly one player. To finish with one champion, the tournament must eliminate all the other players. Since there are \(2^n\) players at the start, the number of eliminated players is \[ 2^n-1. \] Thus the number of games is \(2^n-1\).

Problem 6.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 49.

A fair die is rolled \(n\) times. What is the probability that at least 1 of the 6 values never appears?

Solution

There are \(6^n\) equally likely sequences of \(n\) die rolls. We want the probability that at least one of the six faces is absent.

Let \(A_j\) be the event that face \(j\) never appears. The desired event is \[ A_1\cup A_2\cup \cdots \cup A_6. \] We count this union by inclusion-exclusion. If a particular set of \(k\) faces is missing, then each roll must be one of the remaining \(6-k\) faces, so there are \[ (6-k)^n \] sequences. There are \(\binom {6}{k}\) ways to choose the missing faces. Hence, using the inclusion-exclusion principle, we have \[ \mathbb {P}(A_1\cup \cdots \cup A_6) = \frac {1}{6^n} \sum _{k=1}^{6} (-1)^{k+1}\binom {6}{k}(6-k)^n. \] Writing the expression out gives

Problem 7.

Source: Blitzstein and Hwang, Introduction to Probability, Chapter 1, Problem 53.

Fred needs to choose a password for a certain website. Assume that he will choose an 8-character password, and that the legal characters are the lowercase letters \(a,b,c,\dots ,z\), the uppercase letters \(A,B,C,\dots ,Z\), and the numbers \(0,1,\dots ,9\).

(a)
How many possibilities are there if he is required to have at least one lowercase letter in his password?
(b)
How many possibilities are there if he is required to have at least one lowercase letter and at least one uppercase letter in his password?
(c)
How many possibilities are there if he is required to have at least one lowercase letter, at least one uppercase letter, and at least one number in his password?

Solution

There are \(62\) legal characters in total, namely \(26\) lowercase letters, \(26\) uppercase letters, and \(10\) digits.

(a) Count all 8-character passwords and subtract those with no lowercase letters. There are \(62^8\) passwords in total. If no lowercase letter appears, each character must be chosen from the \(26\) uppercase letters and the \(10\) digits, giving \(36^8\) such passwords. Therefore the number with at least one lowercase letter is

Final Answer for Part (a)

\[ 62^8-36^8 \]

(b) Now the password must contain at least one lowercase letter and at least one uppercase letter. Start with all \(62^8\) passwords. Subtract the passwords with no lowercase letters and the passwords with no uppercase letters. Each of these two forbidden classes has \(36^8\) passwords. Passwords with neither lowercase nor uppercase letters use only digits, and there are \(10^8\) of them. These digit-only passwords have been subtracted twice, so they must be added back once. The desired number is

Final Answer for Part (b)

\[ 62^8-2\cdot 36^8+10^8 \]

(c) Finally, require all three types of characters to appear. Again begin with \(62^8\) total passwords. Subtract the passwords missing lowercase letters, missing uppercase letters, or missing digits. These counts are \(36^8\), \(36^8\), and \(52^8\), respectively.

Now add back the passwords in which two of the three character types are missing. If lowercase and uppercase letters are both missing, only digits remain, giving \(10^8\) passwords. If lowercase letters and digits are both missing, only uppercase letters remain, giving \(26^8\) passwords. If uppercase letters and digits are both missing, only lowercase letters remain, again giving \(26^8\) passwords. Since a password cannot be missing all three character types and still have length 8, there is no further term. Thus the number of valid passwords is

Final Answer for Part (c)

\[ 62^8-2\cdot 36^8-52^8+10^8+2\cdot 26^8 \]