girgit.org

Relations and Functions

When is a relation an equivalence relation?

The big ideaA relation that is reflexive, symmetric and transitive all at once is an equivalence relation: it behaves like "is the same as, in some way".

In simple words

Some links mean "these two are alike in one way": same birthday month, same colour, same last digit. Links like that always follow three rules. Everything is like itself. If you are like me, I am like you. If you are like me and I am like her, you are like her. When all three rules hold, the link really does mean "same kind".

A relation R in a set A is an equivalence relation if it is reflexive, symmetric and transitive. It is one of the most useful ideas in mathematics, because it lets us treat different objects as "the same" for one purpose, and still reason correctly.

Equivalence relations you already know

  • Same birthday month, among the students in your class. You share a month with yourself; sharing works both ways; and if Arjun shares with Bina and Bina with Chetan, all three share a month.
  • Similar triangles. Every triangle is similar to itself, similarity works both ways, and two triangles similar to a third are similar to each other. Congruence works the same way.
  • Equality, "a = b", in any set. It is the smallest equivalence relation: R = {(a, a) : a ∈ A}.
  • Same remainder: in \( \mathbf{Z} \), a R b when 5 divides a − b.

Worked example: proving all three

Show that R = {(a, b) : 5 divides a − b} is an equivalence relation in \( \mathbf{Z} \), the set of integers.

  1. Reflexive. For any integer a, a − a = 0 = 5 × 0, so 5 divides it. Hence (a, a) ∈ R.
  2. Symmetric. If (a, b) ∈ R, then a − b = 5k for some integer k. So b − a = 5(−k), and −k is an integer. Hence (b, a) ∈ R.
  3. Transitive. If (a, b) and (b, c) are in R, then a − b = 5k and b − c = 5m. Adding, a − c = (a − b) + (b − c) = 5(k + m). Hence (a, c) ∈ R.

All three hold, so R is an equivalence relation. The trick in the last step, writing a − c as (a − b) + (b − c), works for any "n divides a − b" relation.

Ones that miss a property

RelationRSTWhy it fails
a ≤ b in \( \mathbf{R} \)YesNoYes2 ≤ 5, but not 5 ≤ 2
"is perpendicular to" (lines)NoYesNono line is perpendicular to itself
"is a friend of" (not counting yourself)NoYesNoyour friend's friend may be a stranger
"is taller than"NoNoYesnobody is taller than themselves
|a − b| ≤ 1 in \( \mathbf{R} \)YesYesNo|0 − 1| ≤ 1, |1 − 2| ≤ 1, but |0 − 2| = 2

(R, S, T stand for reflexive, symmetric, transitive.)

Guess first: does symmetric and transitive give reflexive?

Here is a tempting "proof". Take any a. If a R b, then by symmetry b R a. Now a R b and b R a, so by transitivity a R a. So every symmetric and transitive relation is reflexive. Guess: is this right?

See what happens
No. The proof quietly assumes that every a is related to some b. If an element is related to nothing at all, the argument never starts. In A = {1, 2, 3}, take R = {(1, 1), (2, 2), (1, 2), (2, 1)}. It is symmetric, and transitive (every chain stays inside {1, 2}, where all four pairs are present). But 3 is related to nothing, so (3, 3) is missing and R is not reflexive. The empty relation is an even simpler example. A neat one on real numbers: R = {(a, b) : ab > 0}. It is symmetric, and transitive because ab > 0 and bc > 0 give \( ac \cdot b^2 > 0 \), so ac > 0. Yet (0, 0) fails, since 0 × 0 = 0.

Try it: guess first, then let the rules add arrows for you and scrub back through the steps.

So the three properties are independent: you must check each one. The correct statement is: a symmetric and transitive relation is reflexive if every element is related to at least one element.

Combining equivalence relations

If R₁ and R₂ are both equivalence relations in A, then R₁ ∩ R₂ is also one: each of the three properties holds in both, so it holds for the pairs common to both. The union need not be. In {1, 2, 3}, let R₁ link 1 and 2, and R₂ link 2 and 3 (plus all (a, a) and the flipped pairs). R₁ ∪ R₂ has (1, 2) and (2, 3) but not (1, 3), so it is not transitive.

Another family that is always an equivalence relation: given any function f on X, the relation "a R b when f(a) = f(b)" (same output). For example, a R b when a² = b² in \( \mathbf{Z} \), which links each number with its negative.

Remember

  • Equivalence relation = reflexive + symmetric + transitive.
  • To prove: check all three for arbitrary elements. To disprove: one counterexample to one property.
  • Symmetric + transitive does not give reflexive: an element related to nothing breaks it.
  • The intersection of two equivalence relations is one; the union may not be.

Try it. Give a relation in {1, 2, 3} that is reflexive and transitive but not symmetric, and one that is reflexive and symmetric but not transitive.

Answer
One answer each: {(1, 1), (2, 2), (3, 3), (1, 3)} is reflexive and transitive, not symmetric. {(1, 1), (2, 2), (3, 3), (1, 2), (2, 1), (2, 3), (3, 2)} is reflexive and symmetric, but 1 → 2 → 3 needs (1, 3), so not transitive.

Words to know

Equivalence relation
A relation that is reflexive, symmetric and transitive.
Counterexample
One case that shows a general claim is false.
Divides
"5 divides a − b" means a − b is 5 times some integer.
\( \mathbf{Z} \)
The set of all integers: …, −2, −1, 0, 1, 2, ….

In the set of all people, "a and b have the same blood group" is:

  1. an equivalence relation
  2. symmetric but not transitive
  3. symmetric and transitive but not reflexive

Which relation in {1, 2, 3} is symmetric and transitive but not reflexive?

  1. {(1, 1), (2, 2), (3, 3)}
  2. {(3, 3)}
  3. {(2, 3), (3, 2)}

R = {(a, b) : a + b is even} in \( \mathbf{Z} \). R is:

  1. reflexive and symmetric but not transitive
  2. an equivalence relation
  3. not reflexive