the pigeonhole principle - hampden-sydney...

23
The Pigeonhole Principle Lecture 45 Section 9.4 Robb T. Koether Hampden-Sydney College Mon, Apr 16, 2014 Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 1 / 23

Upload: others

Post on 15-Oct-2020

5 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Pigeonhole PrincipleLecture 45Section 9.4

Robb T. Koether

Hampden-Sydney College

Mon, Apr 16, 2014

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 1 / 23

Page 2: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

1 The Pigeonhole Principle

2 Functions on Finite Sets

3 The Generalized Pigeonhole Principle

4 The Locker Door Problem

5 Assignment

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 2 / 23

Page 3: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Outline

1 The Pigeonhole Principle

2 Functions on Finite Sets

3 The Generalized Pigeonhole Principle

4 The Locker Door Problem

5 Assignment

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 3 / 23

Page 4: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Pigeonhole Principle

The Pigeonhole Principle (Version 1)If n > m and you put n pigeons into m pigeonholes, then at least atleast two pigeons are in the same pigeonhole.

The Pigeonhole Principle (Version 2)If A and B are finite sets and |A| > |B| and f : A→ B, then f is notone-to-one.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 4 / 23

Page 5: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Example

If a drawer contains 10 black socks and 10 blue socks, how manysocks must you draw at random in order to guarantee that youhave two socks of the same color?20?19?11?3?2?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 5 / 23

Page 6: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Example

A bag of jellybeans contains dozens of jelly beans of each of 8different colors. How many jellybeans must we choose in order toguarantee that we have at least two jellybeans of the same color?To guarantee three of the same color?To guarantee four of the same color?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 6 / 23

Page 7: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Example

If we choose 6 distinct integers from 1 to 9,At least one pair of them adds to 10. Why?At least two pairs of them have the same total. Why?

How many integers must we choose from 1 to 99 in order toguarantee that at least two distinct pairs of them will have thesame total?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 7 / 23

Page 8: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Outline

1 The Pigeonhole Principle

2 Functions on Finite Sets

3 The Generalized Pigeonhole Principle

4 The Locker Door Problem

5 Assignment

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 8 / 23

Page 9: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Functions on Finite Sets

TheoremLet A and B be finite sets with |A| = |B| and let f : A→ B. Then f isone-to-one if and only if f is onto.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 9 / 23

Page 10: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Functions on Finite Sets

Proof.Suppose that f is not onto.Then there exists y ∈ B such that y /∈ f (A).So |f (A)| < |B| = |A|.However, restrict the codomain of f to f (A) and we havef : A→ f (A).By the Pigeonhole Principle, f is not one-to-one.Thus, if f is one-to-one, then f is onto.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 10 / 23

Page 11: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Functions on Finite Sets

Proof.Suppose that f is not one-to-one.Then |f (A)| < |A| = |B|.Therefore, f (A) 6= B.Thus, f is not onto.Therefore, if f is onto, then f is one-to-one.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 11 / 23

Page 12: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Decimal Expansions

TheoremLet n

m be a rational number in reduced form. If the decimal expansionof n

m has not terminated after m significant digits, then it is a repeatingdecimal expansion. Furthermore, the repeating part of n

m can havelength no more than m.

Find the decimal expansions of 116 and 1

17 .

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 12 / 23

Page 13: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Outline

1 The Pigeonhole Principle

2 Functions on Finite Sets

3 The Generalized Pigeonhole Principle

4 The Locker Door Problem

5 Assignment

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 13 / 23

Page 14: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Generalized Pigeonhole Principle

The Generalized Pigeonhole PrincipleLet A and B be sets and let f : A→ B. If |A| > m|B| for some integerm, then there exists an element y ∈ B that is the image of at leastm + 1 elements of A.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 14 / 23

Page 15: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Example

In a group of 85 people, at least 4 must have the same last initial.If we select 30 distinct numbers from 1 to 100, there must be atleast three distinct pairs that have the same sum.What if we select 45 distinct numbers from 1 to 100?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 15 / 23

Page 16: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Outline

1 The Pigeonhole Principle

2 Functions on Finite Sets

3 The Generalized Pigeonhole Principle

4 The Locker Door Problem

5 Assignment

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 16 / 23

Page 17: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Locker Door Problem

Suppose we have a hallway with 1000 lockers, labeled 1 through1000.Each locker door is closed.We also have 1000 students, labeled 1 through 1000.We send each student down the hallway with the followinginstructions: If you are Student k , then reverse the state of everyk -th door, beginning with Door k .After all the students have been sent down the hallway, whichdoors will be open?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 17 / 23

Page 18: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Locker Door Problem

Suppose that we have only 10 doors and 10 students and that wewish to leave Doors 2, 4, 5, 8, and 9 open and the others closed.Which students should be send down the hallway?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 18 / 23

Page 19: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Locker Door Problem

Clearly, we must not send Student 1 down the hallway.Door 2 is closed, so we must send Student 2 down the hallway.Door 3 is closed, so we must not send Student 3 down thehallway.Door 4 is open, so we must not send Student 4 down the hallway.Door 5 is closed, so we must send Student 5 down the hallway.And so on.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 19 / 23

Page 20: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Locker Door Problem

Let D ⊆ {1, 2, 3, . . . , 1000}.Can we choose a set S of students so that if we send them downthe hallway, the doors in D will be open and the rest will be closed?Let S1, S2 be two distinct subsets of {1, 2, 3, . . . , 1000}.If we send the students in S1 down the hallway, will a different setof doors be left open than if we had sent the students in S2 downthe hallway?

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 20 / 23

Page 21: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

The Locker Door Problem

Let A = {1, 2, 3, . . . , 1000}.Define f : P(A)→ P(A) as follows.

For any set S ⊆ A, let f (A) be the set of doors left open after thestudents in S have been sent down the hallway.

Prove that f is a one-to-one correspondence.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 21 / 23

Page 22: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Outline

1 The Pigeonhole Principle

2 Functions on Finite Sets

3 The Generalized Pigeonhole Principle

4 The Locker Door Problem

5 Assignment

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 22 / 23

Page 23: The Pigeonhole Principle - Hampden-Sydney Collegepeople.hsc.edu/faculty-staff/robbk/Math262/Lectures... · The Generalized Pigeonhole Principle The Generalized Pigeonhole Principle

Assignment

AssignmentRead Sections 9.4, pages 554 - 563.Exercises 2, 4, 8, 13, 18, 19, 21, 25, 27, 30, 34, 37, page 563.

Robb T. Koether (Hampden-Sydney College) The Pigeonhole Principle Mon, Apr 16, 2014 23 / 23