The user is asking me to:
- State the strong pigeonhole principle
- Explain the basic version with mn+1 items in n containers
- Apply it to the Erdős-Szekeres theorem
Let me do this carefully.
Strong Pigeonhole Principle
The strong pigeonhole principle states: If n objects are placed into k containers, then at least one container contains at least ⌈n/k⌉ objects.
The specific statement the user mentions: If mn+1 items go into n containers, then at least one container has at least m+1 items.
This follows from the basic principle: If mn+1 items go into n containers, then the average number of items per container is (mn+1)/n > m, so by the pigeonhole principle, at least one container must have more than m items, meaning at least m+1 items.
Erdős-Szekeres Theorem
The Erdős-Szekeres theorem states: Any sequence of at least (r-1)(s-1)+1 distinct real numbers contains either an increasing subsequence of length r or a decreasing subsequence of length s.
The proof uses the strong pigeonhole principle elegantly.
Let me write this out properly.
Strong Pigeonhole Principle
If n objects are placed into k containers, at least one container contains at least ⌈n/k⌉ objects.
Specific form: If mn+1 objects are placed into n containers, at least one container contains at least m+1 objects.
Proof of specific form: Suppose each of the n containers contained at most m objects. Then the total number of objects would be at most nm, contradicting that there are mn+1 objects. ∎
Application: Erdős-Szekeres Theorem
Theorem: Any sequence of at least (r-1)(s-1)+1 distinct real numbers contains either an increasing subsequence of length r or a decreasing subsequence of length s (or both).
Proof:
For each position i in a sequence a₁, a₂, ..., aₙ where n ≥ (r-1)(s-1)+1, I'll track inc(i) as the longest increasing subsequence ending at aᵢ and dec(i) as the longest decreasing subsequence ending at aᵢ.
Suppose neither an increasing subsequence of length r nor a decreasing subsequence of length s exists. Then inc(i) ≤ r-1 and dec(i) ≤ s-1 for every position i. This means each index can be labeled with a pair (inc(i), dec(i)) where both coordinates come from {1, 2, ..., r-1} and {1, 2, ..., s-1} respectively, giving at most (r-1)(s-1) distinct pairs total.
Since we have n ≥ (r-1)(s-1)+1 positions but only (r-1)(s-1) possible pairs, the pigeonhole principle guarantees two indices i < j share the same pair: inc(i) = inc(j) and dec(i) = dec(j).
However, this leads to a contradiction. If aᵢ < aⱼ, then any increasing subsequence ending at aᵢ can be extended by appending aⱼ, so inc(j) ≥ inc(i) + 1. If aᵢ ≥ aⱼ, then any decreasing subsequence ending at aᵢ can be extended by appending aⱼ, so dec(j) ≥ dec(i) + 1. Either way, we cannot have both values equal, contradicting our assumption. any decreasing subsequence ending at aᵢ can be extended by appending aⱼ, so dec(j) ≥ dec(i) + 1, which contradicts our assumption that dec(i) = dec(j).
This forces aᵢ < aⱼ, but then inc(j) ≥ inc(i) + 1, also a contradiction. Since assuming inc(i) < r and dec(i) < s for all i leads to a contradiction, at least one element must have either an increasing subsequence of length r or a decreasing subsequence of length s.
Strong Pigeonhole Principle & Erdős-Szekeres Theorem
Strong Pigeonhole Principle
Statement: If mn+1 items are placed into n containers, then at least one container contains at least m+1 items.
General form: If n objects go into k containers, at least one container has ⌈n/k⌉ objects.
Proof: If each container contained ≤ m items, the total would be ≤ nm, contradicting that we have mn+1 items. ∎
Erdős-Szekeres Theorem
Theorem: Any sequence of at least (r−1)(s−1)+1 distinct real numbers contains either an increasing subsequence of length r or a decreasing subsequence of length s.
Proof via Pigeonhole Principle
Consider a sequence a1,a2,…,an where .
For each position i, define:
- inc(i) = length of longest increasing subsequence ending at ai
- dec(i) = length of longest decreasing subsequence ending at
Assume for contradiction that inc(i)<r and dec(i)<s for all i.
Then each position is labeled by a pair (inc(i),dec(i)) where:
- inc(i)∈{1,2,…,r−1}
- dec
By pigeonhole: There are only (r−1)(s−1) possible pairs, but we have (r−1)(s−1) positions. So two positions must have identical labels: .
Derive contradiction:
- If ai<aj: Any increasing subsequence ending at ai extends to , so ✗
Therefore, either some inc(i)≥r or some dec(i)≥s, giving the required subsequence. ∎