Combinatorics studies discrete arrangements and how to count them. To count a collection, identify its objects, decide when two descriptions represent the same object, and organise the collection so each object is counted once.
The existing counting, permutation and combination lessons establish the basic formulas. This page develops the arguments behind more demanding counts: bijections, double counting, overlaps, pigeonholes, paths and distributions with restrictions.
On this page
Count the same objects through a bijection
A bijection pairs every object in one finite collection with exactly one object in another, with no omissions or repetitions. The two collections therefore have the same size.
Consider six-position binary strings with exactly two ones. Each string is determined by the two positions occupied by its ones. For example, corresponds to the subset of . Every two-position subset produces exactly one such string, so the count is
This argument is stronger than noting that two formulas happen to match. It explains why the objects themselves correspond. A coding rule that sent two different strings to the same subset would not be a bijection.
Double-count a marked selection
Choose a three-person committee from seven people and designate one member as chair. Count these marked committees in two ways.
First choose the chair, then select the other two members from the remaining six:
Alternatively, choose the committee first, then select its chair:
Both procedures count each committee-with-chair exactly once. The same reasoning proves, for integers ,
An unmarked committee is a different object. Forgetting the chair divides this count by three, not by seven.
Correct overlapping counts with inclusion-exclusion
How many integers from 1 through 30 are divisible by two or three? There are 15 multiples of two and ten multiples of three. Five numbers are multiples of both because they are multiples of six.
Subtracting the overlap once corrects the fact that it was counted twice in the first two totals. Ten of the thirty integers belong to neither category.
For three sets, the corresponding rule is
Each pairwise intersection here includes objects in all three sets. An object belonging to all three was counted three times, then subtracted three times, so it must be added back once. Venn Diagrams gives a region-by-region way to track the same calculation.
Guarantee a repetition with the pigeonhole principle
If more than k objects are placed into k categories, at least one category contains more than one object. More generally, placing n objects into k labelled categories, with , guarantees that some category contains at least objects. The categories themselves need not all receive an object.
With 23 objects and five boxes, some box must contain at least five. If every box contained at most four, the total could not exceed twenty. This proves the guarantee without specifying which box is crowded.
A less obvious application begins with six distinct integers chosen from 1 through 10. Group the ten available integers into five pairs:
Selecting six numbers must completely select at least one pair. That pair sums to eleven. Five choices would not be enough to guarantee this: choosing takes only one number from each pair.
Grouping ten integers into five pairs
Diagram explanation and exact data
Six distinct selections occupy only five pair categories. If no pair were fully selected, at most five numbers could be chosen. At least one selected pair therefore sums to eleven.
| Pair | Members | Sum |
|---|---|---|
| 1 | 1, 10 | 11 |
| 2 | 2, 9 | 11 |
| 3 | 3, 8 | 11 |
| 4 | 4, 7 | 11 |
| 5 | 5, 6 | 11 |
Count paths by their steps
On an integer grid, travel from to using only unit steps east and north. Every route has seven steps: four east and three north. Choosing the three positions of the north steps determines the route.
Now require the route to pass through . The first segment needs two east and one north step, giving choices. The remaining segment needs two east and two north steps, giving choices.
Every allowed route reaches that point at most once, so this split counts each qualifying route once. The number avoiding it is .
Split a constrained route at its required point
Diagram explanation and exact data
There are 35 routes to (4,3). Three reach (2,1), and six continue from there to (4,3), giving 18 through-routes and 17 avoiding routes.
| Vertex (x,y) | Routes from origin |
|---|---|
| (0,0) | 1 |
| (1,0) | 1 |
| (2,0) | 1 |
| (3,0) | 1 |
| (4,0) | 1 |
| (0,1) | 1 |
| (1,1) | 2 |
| (2,1) | 3 |
| (3,1) | 4 |
| (4,1) | 5 |
| (0,2) | 1 |
| (1,2) | 3 |
| (2,2) | 6 |
| (3,2) | 10 |
| (4,2) | 15 |
| (0,3) | 1 |
| (1,3) | 4 |
| (2,3) | 10 |
| (3,3) | 20 |
| (4,3) | 35 |
Allowing west steps, diagonal steps or revisits would change the problem. The binomial count is tied to the stated move restrictions, not merely the endpoint coordinates.
Distribute identical objects into labelled groups
Suppose seven identical counters are distributed among three labelled boxes, with empty boxes allowed. Let the box counts be . We seek non-negative integer solutions of
Represent the seven counters by stars and separate the three groups with two bars. For example, **|***|** represents . The nine-symbol string is determined by the two bar positions:
Adjacent bars represent an empty middle box; a bar at an end represents an empty first or last box. The boxes are labelled, so and are different allocations.
If each box must contain at least one counter, place one in each first. Distributing the remaining four gives allocations.
Add an upper bound
Keep empty boxes allowed, but require . Start with the unrestricted 36 and subtract allocations with . Set . Then
There are excluded allocations. Therefore satisfy the upper bound. The shift is a bijection: each excluded allocation corresponds to exactly one solution of the smaller sum.
Check the counting object before accepting the answer
A valid count must include every permitted object once. Check order, repeated objects, labels, empty choices and overlapping categories. These questions decide whether a product, quotient, complement or case split is valid.
For example, the stars-and-bars calculation does not assign probabilities to the allocations. A physical experiment that throws seven distinguishable counters into boxes generally gives different probabilities to different box-count triples. A count becomes a probability only after a selection model specifies the weights.
Practice questions
- How many eight-position binary strings have exactly three ones?
- How many east/north routes go from to , and how many of them pass through ?
- How many non-negative integer triples satisfy ?
Check your answers
- Choose the three one-positions: .
- The total is . Through there are routes. Each segment’s step choices determine a unique complete route.
- Five stars and two bars give triples. Empty labelled boxes are included.
Related topics
Counting Principle, Permutations and Combinations provide focused technique references. Recurrence Relations counts arrangements through smaller cases, while Graph Theory: Introduction changes the emphasis from counting selections to describing connections.
