The Pigeonhole
Principle
A deceptively simple idea with surprisingly powerful consequences: if you have more objects than containers, at least one container must hold more than one object.
What Is the Pigeonhole Principle?
Imagine you have 5 pigeons but only 4 pigeonholes. No matter how you assign pigeons to holes, at least one hole must contain 2 or more pigeons. This observation is the Pigeonhole Principle: one of the most fundamental tools in combinatorics and discrete mathematics.
Why Does This Matter?
The Pigeonhole Principle seems obvious, but it is an existence proof tool: it guarantees that something must exist without telling you exactly where. It appears throughout mathematics, computer science, and everyday life.
Everyday Illustrations
The Formal Statement
Here \( \lceil x \rceil \) is the ceiling function: the smallest integer \( \ge x \). For example, \( \lceil 7/3 \rceil = 3 \), so distributing 7 items among 3 bins guarantees at least one bin has \( \ge 3 \) items.
Visualizing \( \left\lceil \frac{n}{k} \right\rceil \)
Simple vs Generalized Form
| Simple Form | Generalized Form | |
|---|---|---|
| Condition | \( n > k \) | \( n \) objects, \( k \) containers |
| Conclusion | Some container has \( \ge 2 \) | Some container has \( \ge \lceil n/k \rceil \) |
| Best for | Quick existence proofs | Counting exact minimums |
| Example | 13 people → 12 months: 2 share a month | 50 people → 12 months: \( \ge \lceil 50/12 \rceil = 5 \) share a month |
How to Apply the Principle
Example 1: Handshakes
Problem: In a room of \( n \) people where \( n \ge 2 \), prove that at least two people have shaken the same number of hands.
Example 2: Remainders
Problem: Given any 5 integers, prove that at least two of them have the same remainder when divided by 4.
Example 3: Subset Sums
Problem: Given \( n \) integers \( a_1, a_2, \ldots, a_n \), prove there exists a consecutive subsequence \( a_{i+1} + a_{i+2} + \cdots + a_j \) whose sum is divisible by \( n \).
Visualizing Prefix Sums mod \( n \)
Example 4: Points in a Square
Problem: If 5 points are placed inside a unit square (side length 1), prove that at least two points are within distance \( \frac{\sqrt{2}}{2} \) of each other.
Common Mistakes
Summary of Key Applications
| Application | Pigeons | Holes | Conclusion |
|---|---|---|---|
| Birthday problem | 367 people | 366 days | 2 share a birthday |
| Remainders \( \pmod k \) | \( k+1 \) integers | \( k \) remainders | 2 share a remainder |
| Consecutive sums | \( n+1 \) prefix sums | \( n \) remainders | Divisible subsequence |
| Points in square | 5 points | 4 sub-squares | 2 points are close |
| Hash collisions | \( n \) keys | \( m < n \) slots | Collision guaranteed |
Question 1 of 5
A drawer contains socks of 5 different colors. What is the minimum number of socks you must pull out (blindfolded) to guarantee that at least two socks are the same color?
Question 2 of 5
In a group of 50 people, what is the minimum guaranteed number of people who share the same birth month?
Question 3 of 5
Among any 6 integers, which of the following is guaranteed by the Pigeonhole Principle?
Question 4 of 5
You place 10 points inside an equilateral triangle with side length 1. You divide it into 9 smaller congruent equilateral triangles. What can you conclude?
Question 5 of 5
In applying the Pigeonhole Principle to prove that among \( n+1 \) integers, at least two have the same remainder mod \( n \), what serves as the "holes"?