Relations
Reading
The reading for this section is in sections 9.1 and 9.5. In 9.1, the section on “Combining Relations” is optional.
You might consider reading section 9.6 also for another very important class of relations.
Some of the examples in this reading assume a bit of number theory. Feel free to ignore them for now, but do
take a look at example 1 in my summary below for a glimpse of what these examples are about.
Summary
Let X and Y be sets. A (binary) relation from X to Y is a subset of X × Y . Thus a relation R is a set of some
ordered pairs (x, y) with x ∈ X and y ∈ Y . We use the notation xRy to mean that (x, y) ∈ R. If X is a set, a
relation on X is a relation from X to itself; in other words, a subset of X × X.
There are many properties a relation may or may not satisfy. Here are some of the more important ones.
(1) A relation R on a set X is reflexive if xRx for all x ∈ X.
(2) A relation R on a set X is symmetric if xRy implies yRx for all x, y ∈ R.
(3) A relation R on a set X is transitive if xRy and yRz implies xRz for all x, y, z ∈ X.
(4) A relation R on a set X is antisymmetric if xRy and yRx implies x = y for all x, y ∈ X.
An equivalence relation on a set X is a reflexive, symmetric and transitive relation. We often denote equivalence
relations by symbols like ∼.
Example 1. Consider the relation
{(x, y) ∈ Z × Z : x − y is even}.
We write x ≡ y mod 2 when we want to indicate that (x, y) is an element of this relation. This is an important
relation! It is called congruence modulo 2, and we will discuss examples of this nature in further detail pretty soon.
For now, let us check that this is an equivalence relation.
• Clearly x ≡ x mod 2 since x − x = 0 is even. Thus this relation is reflexive.
• If x ≡ y mod 2, we know that x − y is even. But then −(x − y) = y − x must also be even, so y ≡ x mod 2.
Thus this relation is symmetric.
• If x ≡ y mod 2 and y ≡ z mod 2, then x − y and y − z are both even. Adding even numbers results in another
even number, so
(x − y) + (y − z) = x − z
is also even, which means that x ≡ z mod 2. Thus, this relation is transitive.
Let ∼ be an equivalence relation on a set X. For any x ∈ X, we write [x] for the set of all y ∈ X such that
x ∼ y. It is called the equivalence class of x. An equivalence class is an equivalence class of some element of X. If
an equivalence class is equal to [x] for some x ∈ X, we say that x is a representative for the equivalence class.
Proposition 2. Let ∼ be an equivalence relation on a set X.
(a) Every element of X is contained in some equivalence class.
(b) Any two equivalence classes are either disjoint, or else equal.
Proof. Note that since ∼ is reflexive, we know that x ∼ x so we have x ∈ [x] for all x ∈ X. Thus every element of
X is in some equivalence class.
Now suppose we have two equivalence classes [x] and [y]. Suppose that they are not disjoint. In other words,
there exists some z ∈ [x] ∩ [y]. This means that x ∼ z and y ∼ z. Since ∼ is symmetric, we must have z ∼ y as well,
and since x is transitive, we must have x ∼ y. Now to show that [x] = [y], we proceed as follows. First, suppose
we have an arbitrary element x0 ∈ [x]. Then x ∼ x0 . But y ∼ x, so by transitivity we get y ∼ x0 , so x0 ∈ [y]. This
1
shows that [x] ⊆ [y]. Conversely, suppose y 0 ∈ [y]. Then y ∼ y 0 , but we also have x ∼ y, so by transitivity we get
x ∼ y 0 , which means y 0 ∈ [x]. This shows that [y] ⊆ [x], proving that [x] = [y]. (It might be good practice to try to
write this proof using the words “without loss of generality.”)
We write X/ ∼ for the set of equivalence classes of X under the equivalence relation ∼. It is called the quotient
of X by ∼.
Example 3. We write Z/2Z for the quotient of Z by the equivalence relation of congruence modulo 2. How many
equivalence classes are there? What is an easy set of representatives for each of the equivalence classes?
Comments
(1) When dealing with equivalence relations, people often abuse notation by using an element of X to denote an
entire equivalence class in X/ ∼. This is something to watch out for: it’s confusing and irritatingly imprecise
when you’re getting used to the definitions, but it’s such a common practice that it’s basically standard, so you
have to force yourself to get used to it.
(2) Here’s a more abstract picture of what’s happening here. There’s a canonical map α : X → X/ ∼ which takes an
element x and assigns to it its equivalence class [x]. In other words, α(x) = [x]. Here are some things you should
figure out about this map. Is it injective? Is it surjective? Given some x ∈ X, what is α−1 (α(x)) = α−1 ([x])?
When someone asks you to “find a set of representatives”, really what they are asking you is to find a subset
X 0 ⊆ X such that the composite
X 0 → X → X/ ∼
is a bijection, where X 0 → X is the inclusion map.
Examples
Here is a list of examples of relations. For all of these that a relation on some set (as opposed to between two different
sets), decide which ones are reflexive, symmetric, antisymmetric, and transitive. For the ones that are equivalence
relations, figure out how many equivalence classes there are, and find representatives for each equivalence class.
(a) Let X be the set of people and R the relation “is a parent of” on X.
(b) Let X be the set of people and R the relation “is an ancestor of” on X.
(c) Let X be any set, and let ⊆ be the relation “is a subset of” on P (X).
(d) Let | be the relation “evenly divides” on Z. (For example, 2 | 36 but 5 - 36).
(e) Let R be the relation where xRy means bxc = byc for all x, y ∈ R.
(f) Let R = {(a, a), (a, b), (a, c), (b, b), (b, c), (c, c), (d, d)} on the set X = {a, b, c, d}.
(g) The relation “has a common factor greater than 1 with” on Z.
(h) The relation R = {(x, y) ∈ R × R : |x − y| < 1/1000}.
(i) Let f : X → Y be a function and let R = {(x, x0 ) ∈ X × X : f (x) = f (x0 )}.
(j) Let f : X → Y be a function and let R = {(x, y) ∈ X × Y : y = f (x)}.
2
© Copyright 2026 Paperzz