THE PIGEONHOLE PRINCIPLE. MARK FLANAGAN School of Electrical and Electronic Engineering University College Dublin

Similar documents
Topics to be covered

Discrete Mathematics. Spring 2017

What is counting? (how many ways of doing things) how many possible ways to choose 4 people from 10?

The Pigeonhole Principle

CSE 312: Foundations of Computing II Quiz Section #2: Combinations, Counting Tricks (solutions)

IMOK Maclaurin Paper 2014

MC215: MATHEMATICAL REASONING AND DISCRETE STRUCTURES

CSE 312: Foundations of Computing II Quiz Section #2: Inclusion-Exclusion, Pigeonhole, Introduction to Probability

CSE 312: Foundations of Computing II Quiz Section #2: Inclusion-Exclusion, Pigeonhole, Introduction to Probability (solutions)

12. 6 jokes are minimal.

Colouring tiles. Paul Hunter. June 2010

Solutions to Exercises on Page 86

With Question/Answer Animations. Chapter 6

Sec 5.1 The Basics of Counting

The Product Rule can be viewed as counting the number of elements in the Cartesian product of the finite sets

n r for the number. (n r)!r!

# 1. As shown, the figure has been divided into three identical parts: red, blue, and green. The figures are identical because the blue and red

CS100: DISCRETE STRUCTURES. Lecture 8 Counting - CH6

International Contest-Game MATH KANGAROO

Counting Things Solutions

(1). We have n different elements, and we would like to arrange r of these elements with no repetition, where 1 r n.

6.1 Basics of counting

Counting. Chapter 6. With Question/Answer Animations

Lecture 18 - Counting

MATHEMATICS ON THE CHESSBOARD

CHAPTER 5 BASIC CONCEPTS OF PERMUTATIONS AND COMBINATIONS

SHAPE level 2 questions. 1. Match each shape to its name. One is done for you. 1 mark. International School of Madrid 1

Counting: Basics. Four main concepts this week 10/12/2016. Product rule Sum rule Inclusion-exclusion principle Pigeonhole principle

Sets. Definition A set is an unordered collection of objects called elements or members of the set.

Week 1: Probability models and counting

1 Introduction. 2 An Easy Start. KenKen. Charlotte Teachers Institute, 2015

2018 AMC 10B. Problem 1

Outline. Content The basics of counting The pigeonhole principle Reading Chapter 5 IRIS H.-R. JIANG

Elementary Combinatorics

LESSON 2: THE INCLUSION-EXCLUSION PRINCIPLE

Student Outcomes. Classwork. Exercise 1 (3 minutes) Discussion (3 minutes)

Combinatorics: The Fine Art of Counting

Counting Things. Tom Davis March 17, 2006

TOPIC 2: HOW TO COUNT

COUNTING TECHNIQUES. Prepared by Engr. JP Timola Reference: Discrete Math by Kenneth H. Rosen

LEVEL I. 3. In how many ways 4 identical white balls and 6 identical black balls be arranged in a row so that no two white balls are together?

Whole Numbers WHOLE NUMBERS PASSPORT.

Grade 7/8 Math Circles. Visual Group Theory

12th Bay Area Mathematical Olympiad

THINGS TO DO WITH A GEOBOARD

UNIVERSITY OF NORTHERN COLORADO MATHEMATICS CONTEST

Intermediate Math Circles November 13, 2013 Counting II

INTERNATIONAL MATHEMATICS TOURNAMENT OF TOWNS Junior A-Level Paper, Spring 2014.

CHAPTER 7 Probability

Lecture 2: Sum rule, partition method, difference method, bijection method, product rules

HOMEWORK ASSIGNMENT 5

UK Junior Mathematical Challenge

Solutions to the 2004 CMO written March 31, 2004

Grade 6 Math Circles Combinatorial Games - Solutions November 3/4, 2015

8.2 Union, Intersection, and Complement of Events; Odds

Each diagram below is divided into equal sections. Shade three-quarters of each diagram. 2 marks. Page 1 of 27

Missing Sequence. You have 10 minutes to complete this test. Select the square that comes next in the sequence.

Solutions of problems for grade R5

Math 454 Summer 2005 Due Wednesday 7/13/05 Homework #2. Counting problems:

Introduction to Counting and Probability

CS1802 Week 3: Counting Next Week : QUIZ 1 (30 min)

Dragnet Abstract Test 4 Solution Booklet

Western Australian Junior Mathematics Olympiad 2017

Rubik s Revenge Solution Hints Booklet. Revenge - The Ultimate Challenge 2. Meet Your Revenge 3. Twisting Hints 5. General Hints 8. Notation System 12

PERMUTATIONS AND COMBINATIONS

ProCo 2017 Advanced Division Round 1

MATH 215 DISCRETE MATHEMATICS INSTRUCTOR: P. WENG

2. Nine points are distributed around a circle in such a way that when all ( )

Grade 7/8 Math Circles Game Theory October 27/28, 2015

Mathematical Olympiad for Girls

Block 1 - Sets and Basic Combinatorics. Main Topics in Block 1:

Math 127: Equivalence Relations

Discrete Mathematics: Logic. Discrete Mathematics: Lecture 15: Counting

Year 2 s Book of Helpful Hints

COUNTING AND PROBABILITY

Combinatorics: The Fine Art of Counting

Review I. October 14, 2008

Basil wants to paint the word KANGAROO. He paints one letter each day. He starts on Wednesday. On what day will he paint the last letter?

The mathematics of Septoku

Facilitator Guide. Unit 2

Jong C. Park Computer Science Division, KAIST

Sec.on Summary. The Product Rule The Sum Rule The Subtraction Rule (Principle of Inclusion- Exclusion)

International mathematical olympiad Formula of Unity / The Third Millenium 2013/2014 year

Today s Topics. Sometimes when counting a set, we count the same item more than once

Objective. Materials. Find the lengths of diagonal geoboard segments. Find the perimeter of squares, rectangles, triangles, and other polygons.

Whole Numbers. Whole Numbers. Curriculum Ready.

Solving the 4 x 4 Cube

The Product Rule The Product Rule: A procedure can be broken down into a sequence of two tasks. There are n ways to do the first task and n

Chapter 1. Probability

Simple Counting Problems

Applications. 30 Prime Time

9.5 Counting Subsets of a Set: Combinations. Answers for Test Yourself

1. The empty set is a proper subset of every set. Not true because the empty set is not a proper subset of itself! is the power set of A.

Math236 Discrete Maths with Applications

1 P a g e

CPCS 222 Discrete Structures I Counting

Section Summary. Permutations Combinations Combinatorial Proofs

Grade 7/8 Math Circles February 21 st /22 nd, Sets

5. (1-25 M) How many ways can 4 women and 4 men be seated around a circular table so that no two women are seated next to each other.

Meet #5 March Intermediate Mathematics League of Eastern Massachusetts

Transcription:

THE PIGEONHOLE PRINCIPLE MARK FLANAGAN School of Electrical and Electronic Engineering University College Dublin

The Pigeonhole Principle: If n + 1 objects are placed into n boxes, then some box contains at least 2 objects. 3 Proof: Suppose that each box contains at most one object. Then there must be at most n objects in all. But this is false, since there are n+1 objects. Thus some box must contain at least 2 objects. This combinatorial principle was first used explicitly by Dirichlet (1805-1859). Even though it is extremely simple, it can be used in many situations, and often in unexpected situations. Note that the principle asserts the existence of a box with more than one object, but does not tell us anything about which box this might be. In problem solving, the difficulty of applying the pigeonhole principle consists in figuring out which are the objects and which are the boxes.

4 Problem 1. Prove that in a group of three people, there must be two of the same sex. Solution. There are only n = 2 sexes, but we have n + 1 = 3 people. Here the sexes are the boxes, and the people are the objects. Problem 2. Prove that among 13 people, there are two born in the same month. Solution. There are n = 12 months ( boxes ), but we have n+1 = 13 people ( objects ). Therefore two people were born in the same month. Exercise 1. How many people do you need to be able to say with certainty that two have the same birthday?

Problem 3. There are 8 guests at a party and they sit around an octagonal table with one guest at each edge. If each place at the table is marked with a different person s name and initially everybody is sitting in the wrong place, prove that the table can be rotated in such a way that at least 2 people are sitting in the correct places. 5 Solution. A typical arrangement is shown below, where the people aremarkeda,b,c,d,e,f,g,h, andtheplacenamesaremarked in circles. In this example, everybody is sitting in the wrong place; for example, guest E is sitting in guest A s place. E B A D H B C G C A F D H E F G

For each guest seated around the table, consider that person s distance to their name (measured, let s say, clockwise around the table). Since each guest is sitting in the wrong place, the possible distances are {1,2,3,4,5,6,7}. So while there are 8 guests, there are only 7 possible distances. Therefore by the pigeonhole principle, two guests have the same distance (clockwise) to their name. So rotating the table anticlockwise through this distance will ensure that both of these guests are seated in the correct places. As an illustration, notice that in the picture above, guests D and F are both at distance 2 from their correct positions, so rotating the table 2 places anticlockwise will seat them both correctly. 6

Problem 4. Seven points lie inside a hexagon of side length 1. Show that two of the points whose distance apart is at most 1. 7 Solution. Partition the hexagon into six parts as shown below. Now there are six parts (boxes), into which seven points (objects) are distributed. So some part contains at least 2 points. These points must be within distance 1 of each other. Exercise 2. Five points lie inside a rectangle of dimensions 3 4. Show that two of the points are at most a distance 5 apart.

Problem 5. Suppose we have 27 distinct odd positive integers all less than 100. [ Distinct means that no two numbers are equal]. Show that there is a pair of numbers whose sum is 102. What if there were only 26 odd positive integers? 8 Solution. There are 50 positive odd numbers less than 100: {1,3,5,,99}. We can partition these into subsets as follows: {1},{3,99},{5,97},{7,95},{9,93},,{49,53},{51}. Note that the sets of size 2 have elements which add to 102. There are 26 subsets (boxes) and 27 odd numbers (objects). So at least two numbers (in fact, exactly two numbers) must lie in the same subset, and therefore these add to 102.

Note on the pigeonhole principle: What if n objects are placed in n boxes? Well, then we cannot assert that some box contains at least 2 objects. But note that the only way this can be avoided is if all of the boxes contain exactly one object. 9 Problem 6. There are n people present in a room. Prove that among them there are two people who have the same number of acquaintances in the room. Solution. Each person may have between 0 and n 1 acquaintances (inclusive). We imagine labelling each person with the number of acquaintances that person has. We have n people, and n possible values for the labels. We would like to show that some two people have the same label value. If there were more people than label values, we would be finished. But since there is the same number of label values as people, we appear to be stuck.

However, observe that the only way that no two people have the same label value is that everyone has a different label. Thus one person knows nobody, one person knows 1 person, and so on, and finally one person knows n 1 people. But this last person then knows everyone else, and in particular this means that there cannot be a person who knows nobody. This contradiction shows that there must indeed be two people who have the same number of acquaintances in the room. 10

The Generalized Pigeonhole Principle: If kn + 1 objects are placed in n boxes, then some box contains at least k+1 objects. 11 Proof: Suppose that each box contains at most k objects. Then there must be at most kn objects in all. But this is false, since there are kn + 1 objects. Thus some box must contain at least k +1 objects. Problem 7. Show that in a group of 15 people, at least three were born on the same day of the week. Solution. We have 15 = 2(7)+1 people (objects), and 7 weekdays (boxes). Here k = 2, n = 7. Therefore three people were born in the same day of the week. Exercise 3. How many people do you need to be able to assert with certainty that three have the same birthday?

Problem 8. In any group of six people, prove that there are either 3 mutual friends or 3 mutual strangers. 12 Solution. We can draw a diagram for this problem as follows. Representthesixpeoplebysixpointsinspacelabelled1,2,3,4,5,6, and we draw a red edge connecting two points if those people are friends, and a blue edge connecting them if they are strangers. Thus each pair of points is connected by either a red or blue line. We wish toprovethatinthisconfiguration,thereexistsatriangleallofwhose edges are the same colour. An example of an edge labelling is shown below; in this example, 146 is a red triangle. 1 2 6 3 5 4 Label the points 1,2,3,4,5,6, and let 36 denote the edge connecting point 3 and point 6, etc. To solve this problem, we begin by considering all the edges emanating from point 1.

13 2 3 1 4 5 6 There are 5 of these, but only two colours to paint them, red or blue. Therefore the pigeonhole principle guarantees that at least 3 of them have the same colour. [Here we have k = 2 and n = 2, i.e. kn+1 = 5 objects placed in n = 2 boxes.] Suppose, without loss of generality, that 12, 13 and 14 all have the same colour, let s say they are all red. 2 1 3 4 If any of 23, 24, 34 is red then we have a red triangle; for example, if 23 is red then the triangle 123 is red. Thus we may assume that 23, 24, 34 are all blue. But then the triangle 234 is a blue triangle! Therefore there must exist a triangle all of whose edges are the same colour.

Note that with 5 points, it is possible to colour all the edges red or blue without creating a monochromatic triangle; such a colouring is shown below. 14 This problem belongs to a whole class of related combinatorial problems called Ramsey Theory. To read more about this area, click here: Ramsey s Theorem

Exercise 4. [Difficult.] In the previous problem, prove that you can actually find two monochromatic triangles! 15 [Hint to get you started: From the previous problem we know that there is one monochromatic triangle. Suppose without loss of generality that 123 is a red triangle. Now consider the pair of edges 15 and 25. Can anything be said regarding these?] Note on the generalized pigeonhole principle: What if kn objects are placed in n boxes? This means that we cannot assert that some box contains at least k + 1 objects. But note that the only way this can be avoided is if all of the boxes contain exactly k objects.

Exercise 5. Seven boys and five girls are seated (in an equally spaced fashion) around a table with 12 chairs. Prove that there are two boys sitting opposite each other. 16 Exercise 6. Each square of a 3 7 board is coloured black or white. Prove that, for any such colouring, the board contains a subrectangle whose four corners are the same colour. Exercise 7. Prove that however one selects 55 distinct integers 1 x 1 < x 2 < x 3 <... < x 55 100, there will be a pair that differ by 9, a pair that differ by 10, a pair that differ by 12, and a pair that differ by 13. Show also that (surprisingly!) there need not be a pair of numbers that differ by 11. Exercise 8. Thedigitalsumofanumberisdefinedasthesumofits decimal digits. For example, the digital sum of 386 is 3+8+6 = 17. (a): 35 two-digit numbers are selected. Prove that there are three of them with the same digital sum. (b): 168 three-digit numbers are selected. Prove that it is possible to find eight of them of them with the same digital sum. Note that in the above, the first digit of a number is not allowed to be 0.