Tuples are ordered and sets are not
(1, 2) ≠ (2, 1) while {1, 2} = {2, 1}. Tuples also allow repetition: (1, 1) is a perfectly good pair.
A tuple has order and allows repetition, which a set does not. The Cartesian product collects every ordered pair, has size |A| · |B|, and is where relations and functions will live.
Core ideas
Sets forget order. Tuples remember it, and everything from relations to graphs needs that memory.
(1, 2) ≠ (2, 1) while {1, 2} = {2, 1}. Tuples also allow repetition: (1, 1) is a perfectly good pair.
|A × B| = |A| · |B|, because each of |A| first coordinates can be paired with each of |B| second ones. This is Combinatorics and Counting's product rule.
A × B and B × A contain different pairs unless A = B or one is empty. There is a natural bijection between them, which is a weaker statement.
The material
The definitions, the size formula, and where products get used.
An ordered pair (a, b) satisfies (a, b) = (c, d) exactly when a = c and b = d. More generally an n-tuple (a₁, …, aₙ) is equal to another exactly when they agree coordinate by coordinate.
A × B = {(a, b) : a ∈ A and b ∈ B}. The n-fold product A₁ × ⋯ × Aₙ is the set of n-tuples with aᵢ ∈ Aᵢ, and Aⁿ abbreviates A × ⋯ × A with n factors.
For finite sets, |A × B| = |A| · |B|, and |A₁ × ⋯ × Aₙ| is the product of the sizes.
Each pair is formed by choosing a first coordinate (|A| ways) and then a second (|B| ways, independently of the first). Distinct choices give distinct pairs, by the definition of pair equality, and every pair arises this way. So the count is |A| · |B|.
□
If either factor is empty the product is empty: there is no pair to form. A × ∅ = ∅ for every A, which the size formula also predicts.
{1, 2} × {a, b, c} has 2 · 3 = 6 elements: (1,a), (1,b), (1,c), (2,a), (2,b), (2,c). Note {a,b,c} × {1,2} contains (a,1), a different object from (1,a).
That last coincidence is worth pausing on. A subset of an n-element set is exactly a choice of in-or-out for each element, which is exactly a bit string of length n. The bijection between P(A) and {0,1}ⁿ is why both are counted by 2ⁿ. It is a preview of “Injective, Surjective, Bijective”, which names such a pairing a bijection, and of “Cardinality and Countability”, which makes it the definition of size.
|Aⁿ| = |A|ⁿ. With |A| = 2 this gives 2ⁿ; with |A| = 26 and n = 4 it gives the number of four-letter strings, 456 976.
Interactive
Enumerated while enumeration is possible
Method
Coordinates first, then count.
A × B takes its first coordinate from A. Reversing this silently produces a different set.
|A × B × C| = |A| · |B| · |C|. Independent choices multiply; this is the product rule Combinatorics and Counting states in general.
Vary the last coordinate fastest, exactly as truth table rows do. The pattern makes a missing tuple visible.
This is the whole content of “Binary Relations”: any set of pairs is a relation, and any relation is a set of pairs.
How many strings of length 4 use letters from {a, b, c}?
The second count is the pigeonhole principle arriving early, and by arithmetic rather than by argument: four positions, three letters, so some letter is used twice. “The Pigeonhole Principle” states it in general.
Describe the bijection explicitly: given a subset, produce its bit string; given a bit string, produce its subset. That construction is what “Injective, Surjective, Bijective” calls a bijection, what “Cardinality and Countability” turns into the definition of same size, and what Combinatorics and Counting uses constantly.
Something to change about this lesson? Write it down, tick it off when it is handled, and export the list when you want to act on it. Kept in this browser only: nothing is sent anywhere, and nobody is notified.
No recommendations yet for this lesson.