The Pigeonhole Principle

Slides:



Advertisements
Similar presentations
The Pigeonhole Principle:
Advertisements

The Pigeon hole problem
Tutorial 2: First Order Logic and Methods of Proofs
Lecture 4 4.1,4.2 Counting. 4.1 Counting Two Important Principles: Product Rule and Sum Rule. Product Rule: Assume we need to perform procedure 1 AND.
PROOF BY CONTRADICTION
COUNTING AND PROBABILITY
Application: The Pigeonhole Principle Lecture 37 Section 7.3 Wed, Apr 4, 2007.
Recursively Defined Functions
The Pigeonhole Principle
after UCI ICS/Math 6A, Summer Counting-1 Counting: Product and Sum Rules Product Rule: Assuming a)We need to.
3.5 Paradox  1.Russell’s paradox  A  A, A  A 。  Russell’s paradox: Let S={A|A  A}. The question is, does S  S?  i.e. S  S or S  S?  If S  S,
3.3 The Characteristic function of the set  function from universal set to {0,1}  Definition 3.6: Let U be the universal set, and let A  U. The characteristic.
PIGEONHOLE PRINCIPLE. Socks You have a drawer full of black and white socks. Without looking in the drawer, how many socks must you pull out to be sure.
Discrete Structures Chapter 5 Pigeonhole Principle Nurul Amelina Nasharuddin Multimedia Department.
Copyright © Zeph Grunschlag, Counting Techniques Zeph Grunschlag.
CSE115/ENGR160 Discrete Mathematics 04/10/12
Pigeonhole.
Counting II: Pascal, Binomials, and Other Tricks Great Theoretical Ideas In Computer Science A. Gupta D. Sleator CS Fall 2010 Lecture 8Sept. 16,
1 The Pigeonhole Principle CS/APMA 202 Rosen section 4.2 Aaron Bloomfield.
Fall 2015 COMP 2300 Discrete Structures for Computation
The Pigeonhole (Dirichlet’s box) Principle
Counting. Why counting  Determine the complexity of algorithms To sort n numbers, how many instructions are executed ?  Count the number of objects.
Chapter The Basics of Counting 5.2 The Pigeonhole Principle
1 Lecture 3 (part 2) Functions – Pigeonhole Principle Reading: Epp Chp 7.4.
Fall 2002CMSC Discrete Structures1 One, two, three, we’re… Counting.
Math 170 Project #11 Part 2 Jeffrey Martinez Bianca Orozco Omar Monroy.
Chapter 2 Mathematical preliminaries 2.1 Set, Relation and Functions 2.2 Proof Methods 2.3 Logarithms 2.4 Floor and Ceiling Functions 2.5 Factorial and.
Elements of Combinatorics (Continuation) 1. Pigeonhole Principle Theorem. If pigeons are placed into pigeonholes and there are more pigeons than pigeonholes,
1 CSC 321: Data Structures Fall 2013 Counting and problem solving  mappings, bijection rule  sequences, product rule, sum rule  generalized product.
4.1.2 Pigeonhole principle:Strong Form  Theorem 4.2: Let q 1,q 2,…,q n be positive integers. If q 1 +q 2 +…+q n -n+1 objects are put into n boxes, then.
CS201: Data Structures and Discrete Mathematics I
The Pigeonhole Principle. The pigeonhole principle Suppose a flock of pigeons fly into a set of pigeonholes to roost If there are more pigeons than pigeonholes,
5.2 The Pigeonhole Principle
1 Melikyan/DM/Fall09 Discrete Mathematics Ch. 7 Functions Instructor: Hayk Melikyan Today we will review sections 7.3, 7.4 and 7.5.
1 Chapter 2 Pigeonhole Principle. 2 Summary Pigeonhole principle –simple form Pigeonhole principle –strong form Ramsey’s theorem.
Models of Computation: Automata and Formal Languages Sam M. Kim.
1 The Pigeonhole Principle CS 202 Epp section 7.3.
2/24/20161 One, two, three, we’re… Counting. 2/24/20162 Basic Counting Principles Counting problems are of the following kind: “How many different 8-letter.
Introduction Suppose that a password on a computer system consists of 6, 7, or 8 characters. Each of these characters must be a digit or a letter of the.
The Pigeonhole Principle Alan Kaylor Cline. The Pigeonhole Principle Statement Children’s Version: “If k > n, you can’t stuff k pigeons in n holes without.
1 The Pigeonhole Principle CS 202 Epp section ??? Aaron Bloomfield.
5-5 Indirect Proof. Indirect Reasoning: all possibilities are considered and then all but one are proved false. The remaining possibility must be true.
The Pigeonhole Principle. Pigeonhole principle The pigeonhole principle : If k is a positive integer and k+1 or more objects are placed into k boxes,
Pigeonhole Principle – Page 1CPTR311 – Discrete Structures CPTR311 Discrete Structures Pigeonhole Principle Reading: Kolman, Section 3.3.
Pigeonhole Principle. If n pigeons fly into m pigeonholes and n > m, then at least one hole must contain two or more pigeons A function from one finite.
Discrete Mathematics. Exercises Exercise 1:  There are 18 Computer Science (CS) majors and 325 Business Administration (BA) majors at a college.
Section The Pigeonhole Principle If a flock of 20 pigeons roosts in a set of 19 pigeonholes, one of the pigeonholes must have more than 1 pigeon.
Main Menu Main Menu (Click on the topics below) Pigeonhole Principle Example Generalized Pigeonhole Principle Example Proof of Pigeonhole Principle Click.
EXAMPLE 3 Write an indirect proof Write an indirect proof that an odd number is not divisible by 4. GIVEN : x is an odd number. PROVE : x is not divisible.
Section The Product Rule  Example: How many different license plates can be made if each plate contains a sequence of three uppercase English letters.
COUNTING Discrete Math Team KS MATEMATIKA DISKRIT (DISCRETE MATHEMATICS ) 1.
The Pigeonhole Principle
CSC 321: Data Structures Fall 2015 Counting and problem solving
PIGEONHOLE PRINCIPLE.
Discrete Structures for Computer Science
CSE322 PUMPING LEMMA FOR REGULAR SETS AND ITS APPLICATIONS
COCS DISCRETE STRUCTURES
CSC 321: Data Structures Fall 2016 Counting and proofs
The Pigeonhole Principle
PIGEONHOLE PRINCIPLE.
PIGEONHOLE PRINCIPLE.
COUNTING AND PROBABILITY
The Pigeonhole Principle
CS 220: Discrete Structures and their Applications
PIGEONHOLE PRINCIPLE.
CSC 321: Data Structures Fall 2018 Counting and proofs
The Pigeonhole Principle
The Pigeon hole problem
Representations of Integers
Pigeon-Hole Principle ( PHP )
Presentation transcript:

The Pigeonhole Principle

Example 1 In a room of 13 people, 2 or more people have their birthday in the same month. Proof: (by contradiction) 1. Assume the room has 13 people and no 2 people have their birthday in the same month. 2. There must be at least 13 different months. 3. Statement 2. is false, so the assumption is false.

Example 2 If 41 balls are chosen from a set of red, white, blue, garnet, and gold colored balls, then at least 12 red balls, 15 white balls, 4 blue, 10 garnet, or 4 gold balls chosen. Proof by contradiction: (use DeMorgan’s law) 1. Assume that 41 balls are chosen from this set and that at most 11 red, 14 white, 3 blue, 9 garnet, and 3 gold balls are chosen. 2. At most 40 balls were chosen, a contradiction.

The pigeonhole principle Let m1, m2, … , mn be positive integers. If m1 + m2 + . . . + mn - n + 1 objects are put into n boxes, Then either the 1st box has at least m1, or the 2nd box has at least m2, or …, or the nth box has at least mn objects.

Proof by Contradiction Assume m1 + m2 + . . . + mn - n + 1 objects are put into n boxes, and the 1st box has at most m1 - 1, and the 2nd box has at most m2 - 1, and …, and the nth box has at most mn - 1 objects. Then, at most m1 + m2 + . . . + mn - n objects are in the boxes, a contradiction.

Another Form of Pigeonhole Principle If A is the average number of pigeons/hole, then some hole contains at least A pigeons and some hole contains at most A pigeons.

Intuition A A A Cannot have all holes contain less than the average. Cannot have all holes contain more than the average.

Proof of Alternate Principle By contradiction: Assume A is the average number of pigeons/hole. Assume every hole contains at most A - 1 pigeons or every hole contains at least A + 1 pigeons. 3. Let n denote the number of holes. 4. Assume every hole contains at most A - 1 pigeons. 5. All holes contain at most n(A - 1 ) < nA pigeons, a contradiction.

5. Assume every hole contains at least A + 1 pigeons. 6. All holes contain at least n(A + 1) > nA pigeons, a contradiction. 7. Therefore, some hole contains at least A pigeons and some hole contains at most A pigeons.

Applications of pigeonhole principle If n + 1 pigeons are distributed among n holes, then some hole contains at least 2 pigeons. If 2n + 1 pigeons are distributed among n holes, then some hole contains at least 3 pigeons. If kn + 1 pigeons are distributed among n holes, then some hole contains at least k + 1 pigeons. The average number of pigeons/hole = k + 1/n and  k + 1/n  = k + 1.

Applications ... In any group of 367 people, there must be at least 1 pair with the same birthday. If 4 different pairs of socks are scrambled in the drawer, only 5 socks need to be selected to guarantee finding a matching pair. In a group of 61 people, at least 6 were born in the same month.

Applications ... If 401 letters were delivered to 50 houses, then some house received at most 8 letters. If x1, x2, …, x8 are distinct integers, then some pair of these have the same remainder when divided by 7.

Applications ... Given a set of 7 distinct integers, there are 2 whose sum or difference is divisible by 10. Set this up so that there are 6 pigeon holes. Partitioning the integers into equivalence classes according to their remainder when divided by 10 yields too many classes. Consider: {[0]}, {[1],[9]}, {[2],[8]}, {[3],[7]}, {[4],[6]}, {[5]}. If 2 integers are in the same set either their difference is divisible by 10 or their sum is divisible by 10.

Applications ... Suppose Then, 50 chairs are arranged in a rectangular array of 5 rows and 10 columns. 41 students are seated randomly in the chairs (1 student/chair). Then, some row contains at least 9 students some row contains at most 8 students some column contains at least 5 students some column contains at most 4 students.

Applications ... A patient has 45 pills, with instructions to take at least 1 pill/day for 30 days. Prove: there is a period of consecutive days in which the patient takes a total of 14 pills. 1. Let ai be the number of pills taken through the end of the ith day. 2. 1  a1 < a2 < . . . < a30  45. 3. a1 + 14 < a2 + 14 < . . . < a30 + 14  45 + 14 = 59

5. 2 of these integers must be the same. 4. We have: 60 integers: a1, a2 , . . . , a30 , a1 +14, a2 +14 , . . . , a30 +14 59 holes. 5. 2 of these integers must be the same. 6. They cannot both be in a1, a2 , . . . , a30 . 7. They cannot both be in a1 +14, a2 +14 , . . . , a30 +14. 8. One is in each: ai = aj + 14, for some i and j. 9. For that i and j, ai - aj = 14. 10. That is, aj+1+aj+2 + . . . + ai = 14.