Ordered Pairs and Cartesian Products
What does it really mean to write ? Why can't we just treat it as the two-element set ? This innocent question turns out to matter enormously. The entire edifice of relations, functions, sequences, and coordinate geometry rests on one thing. It rests on being able to distinguish "first" from "second." If ordered pairs collapsed into unordered pairs, would equal . No function could ever tell inputs from outputs. The resolution, due to Kazimierz Kuratowski in 1921, is a small piece of mathematical engineering. It defines as a specific set built only from , , and the axioms of set theory. This is done so that the property we actually care about becomes a theorem. That property is that exactly when and . It becomes a theorem rather than an assumption. This matters because it shows something important about set theory. Set theory has no primitive notion of "order" built in. Yet it is already rich enough to construct order out of nothing but membership. Once ordered pairs are secured, the Cartesian product becomes well-defined. It is the set of all ordered pairs with first coordinate from and second coordinate from . It becomes a well-defined set, not just an informal "grid" of dots. This is the single construction that makes several things possible. It lets us define a relation as a set of ordered pairs. It lets us define a function as a special kind of relation. Eventually it lets us define a sequence as a function on the natural numbers. Every later notion in this chapter is built directly on top of . This article gives the Kuratowski definition. It proves the characterizing theorem rigorously. It defines the Cartesian product and establishes its basic algebraic properties. It shows exactly what goes wrong if the definition is weakened. It closes by placing ordered pairs in their proper role. That role is as the foundation for Relations as Sets of Ordered Pairs.
- An ordered pair must satisfy: iff and — order matters, unlike unordered pairs .
- Kuratowski's definition: , built entirely from the existing axioms of set theory.
- The Coordinate Theorem proves this definition works: it recovers exactly the equality condition we wanted, with no extra assumptions.
- The Cartesian product is a genuine set, constructible via the power set and separation axioms.
- is generally not commutative: unless or one of them is empty.
- Key idea: order is not primitive — it is manufactured from unordered sets by nesting braces so that one element is distinguishable as "the one that repeats."
Where this lives today
The Cartesian product is the literal foundation on which relations and functions are built: a relation from to is defined as any subset of , and a function is a relation satisfying an extra existence-and-uniqueness clause — both concepts are meaningless without first having available as a genuine set, which is exactly what this article establishes. In Relations as Sets of Ordered Pairs this becomes the starting definition. In computer science, ordered pairs and products underlie the type `A × B` (product types) in typed functional languages, tuple data structures, and relational database theory, where a table is literally a finite subset of a Cartesian product of column domains. In cryptography and coding theory, finite Cartesian products (an -fold product of the two-element set) are the ambient space for bit-strings. In probability and statistics, joint sample spaces for two random variables are modeled as , with joint distributions as measures on the product. In topology and analysis, the product topology on (and more generally on infinite products, via Cardinality and Cardinal Arithmetic-adjacent machinery) is defined using exactly this set, and recovers ordinary coordinate geometry as the special case .
Ask the tutor: How does the Kuratowski definition of ordered pairs let us define a relation from to purely as a subset of ?
Let and be sets (or elements of some universe of discourse). The ordered pair of and , denoted , is defined by
The element is called the first coordinate and the second coordinate of . Given sets and , the Cartesian product of and is the set
More generally, for an ordered -tuple is defined recursively by and
and the product of sets is the set of all such -tuples with .
Intuition
The unordered pair throws and into a set and forgets which one came first — and are literally the same set, since a set is determined solely by its members. To encode order, Kuratowski's trick is to build a set that contains a "marked" singleton alongside the full pair. In , the singleton flags as the distinguished element, while records both members. Reading the set back, you can tell which element was "first" by finding the element that appears in the smaller piece — this is the whole content of the Coordinate Theorem proved below, and the case needs a little extra care, handled in the proof. Once pairs are set up, is simply the set of every possible pairing of an element of with an element of , laid out as a rectangular grid when . The picture below shows a small concrete product with (horizontal) and (vertical), alongside the internal Kuratowski structure of a single pair.
Basic set-theoretic facts used in the proof
For any sets and , the collection defined above is genuinely a set, not merely a class.
We use the Axiom of Power Set and the Axiom Schema of Separation, standard tools of Zermelo–Fraenkel set theory assumed as prerequisites. First, if and , then and . By the power set axiom, is a set, and . Hence , so . Therefore every ordered pair with , is an element of the set , which we call . By Separation applied to with the formula
the collection
is a set.
∎This lemma is what allows us to speak of as an object we can quantify over, take subsets of (relations!), and apply further set operations to — it is not a mere shorthand for an infinite unwritten list.
Let be arbitrary sets. Then
where as above.
We prove both directions. The technique throughout is direct case analysis on set equality, using extensionality (two sets are equal iff they have the same elements) as the only equality principle for sets.
() The easy direction. Suppose and . Substituting for and for inside the definition,
This direction uses only the substitution of equals for equals, which is valid since is a congruence for the set-builder notation.
() The substantive direction. Suppose , i.e.
We split into two cases according to whether . Case 1: . Then , so the left side of collapses:
Thus says . The set has exactly one element, namely ; since a set with one listed element name can have at most two distinct members and , and here there is only one member total, we must have . From we get (a singleton determines its unique element by extensionality: the only element of is , and the only element of is , and these sets are equal, so their unique elements coincide). From , every element of equals ; in particular . So and , giving and , as required. (Since in this case, follows from .) Case 2: . Then (the right set has an element , since ), so the left side of , namely , has exactly two distinct elements. Since equates this to , the right side must also have exactly two distinct elements, and by extensionality the two sides have the same two elements. There are only two ways to match them up: Sub-case 2a: and . From , as before, . Substituting into , so . Since , either or . But by the case hypothesis, so . Hence and , as required. Sub-case 2b: and . From : this is a singleton equal to a set listed with (possibly repeated) elements ; every element of must equal (since has all elements equal to ), so and . From (using ): so is a singleton, meaning . But this contradicts the standing hypothesis of Case 2. Hence sub-case 2b is impossible under Case 2, and only sub-case 2a can occur. In both cases we conclude and . This completes the proof of (), and hence of the theorem.
∎The case split above is exactly why the naive guess "" fails and why the nested structure is needed: it is precisely engineered so that when the outer set degenerates to a singleton in a way that still lets us recover , while when the asymmetry between the singleton branch and the pair branch pins down which element was first.
The map is a well-defined injective assignment: distinct coordinate pairs (as pairs of sets in the ambient sense of "not both coordinates equal") always produce distinct Kuratowski sets .
This is the contrapositive of the Coordinate Theorem: if or , then it is not the case that ( and ), so by the theorem it is not the case that , i.e. .
∎Basic properties of the Cartesian product
Let be sets. Then: 1. . 2. , and symmetrically for the second factor. 3. , and symmetrically for the second factor. 4. . 5. If then and , for any set . 6. if and only if or . 7. If are both nonempty, then if and only if .
Each part is proved directly from the definition of and set-builder logic (extensionality plus first-order reasoning about the defining property " with ").
(1) By definition, . Since there is no with , the defining condition is never satisfied by any pair, so . Symmetrically for , using that there is no .
(2) We show both inclusions. () Let . Then for some and . If then ; if then . Either way . () Let . If , write with , so . If instead , the same argument with applies. So in both cases . Since both inclusions hold, the sets are equal by extensionality. The symmetric identity is proved identically with the roles of coordinates swapped.
(3) Similarly, iff and and , iff () and () — using that "" can be freely duplicated in a conjunction — iff and , iff . Every step is an "iff," so equality follows by extensionality. The second-factor version is symmetric.
(4) iff and and . Meanwhile iff [ and ] and NOT[ and ]. Since we are already assuming in the first conjunct, "NOT[ and ]" simplifies (given ) to "." Hence the two conditions on coincide, giving equality.
(5) Suppose . Let , so and . Then and , so . Hence . The argument for is identical with coordinates swapped.
(6) () is part (1). (, by contrapositive) Suppose and . Then there exist and , so , so .
(7) () If then trivially . () Suppose and . We show ; the reverse inclusion follows by the symmetric argument, giving by extensionality. Let . Since , pick some . Then , so by definition of there exist with . By the Coordinate Theorem, and . Since and , we conclude . As was arbitrary, .
∎Worked examples
Example 1 (computing a concrete Kuratowski pair and unwinding it). Let and , both finite sets of natural numbers, and consider the pair where the coordinate happens to be shared with the "wrong" set as well — a deliberately asymmetric, easily-confused case. By definition,
This is a set with two elements: the singleton and the pair-set . Let us verify by hand, using only the Coordinate Theorem, that this is genuinely different from . Suppose toward showing they're unequal we directly compare the two representations:
The first has as a member; does the second? The second's members are and . Is ? No, since (as elements) means these singletons have different unique elements. Is ? No, since but (as ). So is a member of the first set but not the second, hence the two outer sets are unequal by extensionality: . This matches the Coordinate Theorem's prediction directly: would require (comparing first coordinates), which is false, so the theorem guarantees inequality without any set manipulation — the hand computation above is simply that guarantee unpacked. Now let us list in full, to see the "grid," including the coincidence that appears in both and :
Each of these four is a distinct Kuratowski set:
Note collapses to the singleton , exactly as in Case 1 of the Coordinate Theorem's proof — this is the only pair here with equal coordinates, and it is the only one whose Kuratowski set has just one element rather than two. Compare with ; the two products share the single element but are otherwise disjoint as sets of pairs, illustrating Theorem 7 above: since (as ), we must have , which indeed holds since e.g. but (as , so no pair in has first coordinate ).
Example 2 (an infinite, asymmetric product and a subtlety about "diagonal" elements). Let and . Consider , an infinite set of ordered pairs — this models, for instance, the graph of a function once we restrict to pairs forming a valid function, foreshadowing Relations as Sets of Ordered Pairs. We compute a specific pair with a repeated numeral to stress-test the definition: take and (the same natural number used in two different roles, as an element of and as an element of ). Then
using that as sets (repetition in listing notation does not create new elements). So is a singleton set containing a singleton set. Contrast this with , which has two distinct elements since (because but ). Now here is the subtlety: is actually equal to the number , or to the singleton , under some encodings of natural numbers as sets (e.g. the von Neumann encoding where , , etc.)? This is worth checking carefully because a careless reader might worry the Kuratowski pair collides with a "coincidental" von Neumann numeral. Under the von Neumann encoding, and . Then , a set whose unique element is itself a singleton (namely ). So , while the numeral , a two-element set. These are visibly different sets (one has one element, the other has two), so no collision occurs — but the exercise shows why one must always unwind definitions explicitly rather than trust intuition when several set-theoretic constructions ( as von Neumann ordinals, and as Kuratowski pairs) are stacked together. This is exactly the kind of verification the Coordinate Theorem is designed to make routine: no matter what and "secretly" are as sets, reduces purely to , so no accidental collision between differently-motivated set constructions can ever corrupt the coordinate-recovery property.
Counterexample
Suppose we weaken the definition and instead try the naive candidate
dropping the requirement that one coordinate be additionally marked as a singleton. We claim the analogue of the Coordinate Theorem fails: there exist with but not ( and ). Take , , , . Then
since and list the same two elements and a set is determined solely by its membership (extensionality does not see listing order). So . But it is not true that and ; indeed . So the biconditional
fails for : the left side holds while the right side does not.
Diagnosis. The failure traces to dropping exactly one structural feature of the Kuratowski definition: the presence of the extra singleton that marks the first coordinate. Without it, retains only the information of membership, which is symmetric in by the very definition of a set, and no amount of clever notation recovers "which one was first" once that information has been discarded. This is precisely why every rigorous foundational treatment insists on the asymmetric nested form (or some equally asymmetric alternative, such as Norbert Wiener's or the type-theoretic pair) rather than the naive unordered pairing. It also shows the hypothesis " built asymmetrically into the definition" is not optional window-dressing — it is load-bearing for the entire theory of relations and functions that follows, since a function's graph must distinguish input from output.
Scope, edge cases & common traps
| Situation | What holds | What fails / must be checked |
|---|---|---|
| , a singleton, not a pair-looking two-element set | Do not assume always has exactly two elements as a set — Case 1 of the theorem handles this | |
| or empty | Students sometimes forget , not "the pair of empty sets" | |
| both nonempty, | always | Common trap: assuming is commutative "because multiplication is" |
| Associativity of tuples | as literal sets (elements are pairs-of-pairs vs. pairs, differently nested) | One must fix a convention (e.g. the recursive -tuple definition given above) rather than assume literal set equality |
| Infinite | still exists as a set, by Power Set + Separation | Do not need Choice for a binary product; Choice becomes relevant only for infinite products |
The mathematician behind it
Origins · 1 minKazimierz Kuratowski and how this was discovered
Kuratowski was a leading figure of the Warsaw School of Mathematics, working in point-set topology, set theory, and the foundations of mathematics during the interwar period. His 1921 definition of the ordered pair, published while he was still a young researcher, resolved a foundational gap: earlier treatments (including Norbert Wiener's 1914 definition and informal usage before that) either lacked full rigor or were more cumbersome. Kuratowski's version, , became the standard because of its economy — it uses only the pairing and union operations already available in set theory, with no extra primitive notions. Kuratowski also made major contributions to topology (Kuratowski's closure axioms, the Kuratowski–Zorn lemma formulation related to the Axiom of Choice) and to graph theory (Kuratowski's theorem characterizing planar graphs via forbidden and subdivisions).
Why can't we just use as the ordered pair, since we already have unordered pairs from set theory?
Because always, by extensionality — a set is completely determined by which elements it contains, with no notion of "first" or "second" built in. If we defined , then and would be the literal same object, which destroys the entire purpose of an ordered pair: distinguishing input from output in a function, or from in a coordinate. The Kuratowski trick fixes this by adding an extra singleton that marks which element is "first," making the outer set asymmetric between its two roles even though sets themselves have no order.
Does it matter which specific set we use to define , as long as some encoding works?
Not for the purposes of ordinary mathematics — what matters is only that the encoding satisfies the Coordinate Theorem: iff and . Kuratowski's and Wiener's earlier, more complicated encoding both work, and any bijective re-encoding satisfying the same characterizing property would serve equally well as a foundation. In practice almost everyone uses Kuratowski's version because it is the simplest, but all subsequent theorems about relations and functions are stated in terms of the behavior (the Coordinate Theorem), not the specific internal set, so switching encodings changes nothing about the mathematics built on top.
Is the Cartesian product the same size as when ?
Yes, if and are finite with and , then , by a direct counting argument: each of the choices for the first coordinate can be paired with each of the choices for the second, giving distinct pairs by the Coordinate Theorem (distinct coordinate choices always give distinct pairs). For infinite sets, cardinal arithmetic shows depends only on and as cardinals, which is developed further under Cardinality and Cardinal Arithmetic.
Why is the Cartesian product not commutative, even though multiplication of numbers is?
The notation "" is suggestive but the Cartesian product is a fundamentally different operation from numeric multiplication: it produces a set of pairs, not a number, and the identity of a pair depends on coordinate order by design (that is the entire point of the Coordinate Theorem). As shown in the algebraic properties theorem, holds only in the degenerate cases or one of empty. The sizes and do coincide (both equal ), which is likely the source of the intuition that "should" commute — but equality of cardinality is much weaker than equality of the sets themselves.
How does the ordered pair definition extend to triples and longer tuples?
The standard approach, given in the definition above, is recursive: define , treating a triple as a pair whose first coordinate is itself a pair. More generally . One can then prove, by induction using the Coordinate Theorem at each step, that -tuples are equal iff all corresponding coordinates are equal — the natural generalization of the binary case. This recursive definition is what allows to be built up as , consistent with how sequences and finite lists are later formalized.
Does defining as a set create any circularity, since and might themselves be sets built from pairs?
No circularity arises, because the definition only uses the pairing and union operations of set theory applied to whatever sets and already are — it never needs to "look inside" or to know they are, say, pairs themselves. The construction is purely extensional: it treats and as opaque sets and builds a new set around them. This is why Example 2 in this article could safely nest natural-number encodings inside pair encodings without any paradox: each layer of construction (numbers as von Neumann ordinals, pairs as Kuratowski sets) is independent and composes without circular reference.
Why do we need the Axiom of Power Set to show is a set, rather than just using Pairing and Union?
Pairing and Union alone let us build each individual pair as a set. But to collect all such pairs (ranging over all ) into a single set , we need Separation, which requires a starting "superset" to carve out of — otherwise Separation has nothing to work inside. The proof given above shows every pair with lives inside , and Power Set is exactly what guarantees that this bounding set exists, after which Separation extracts precisely from it.