You are on page 1of 30

Symmetric relations

en.wikipedia.org
Chapter 1

Apartness relation

Apart redirects here. For the song by The Cure, see Wish (The Cure album). For the 2011 lm, see Apart (lm).

In constructive mathematics, an apartness relation is a constructive form of inequality, and is often taken to be more
basic than equality. It is often written as # to distinguish from the negation of equality (the denial inequality) , which
is weaker.

1.1 Description
An apartness relation is a symmetric irreexive binary relation with the additional condition that if two elements are
apart, then any other element is apart from at least one of them (this last property is often called co-transitivity or
comparison).
That is, a binary relation # is an apartness relation if it satises:[1]

1. (x#x)

2. x#y y#x

3. x#y (x#z y#z)

The negation of an apartness relation is an equivalence relation, as the above three conditions become reexivity,
symmetry, and transitivity. If this equivalence relation is in fact equality, then the apartness relation is called tight.
That is, # is a tight apartness relation if it additionally satises:

(x#y) x = y

In classical mathematics, it also follows that every apartness relation is the negation of an equivalence relation, and
the only tight apartness relation on a given set is the negation of equality. So in that domain, the concept is not useful.
In constructive mathematics, however, this is not the case.
The prototypical apartness relation is that of the real numbers: two real numbers are said to be apart if there exists
(one can construct) a rational number between them. In other words, real numbers x and y are apart if there exists
a rational number z such that x < z < y or y < z < x. The natural apartness relation of the real numbers is then the
disjunction of its natural pseudo-order. The complex numbers, real vector spaces, and indeed any metric space then
naturally inherit the apartness relation of the real numbers, even though they do not come equipped with any natural
ordering.
If there is no rational number between two real numbers, then the two real numbers are equal. Classically, then, if
two real numbers are not equal, one would conclude that there exists a rational number between them. However it
does not follow that one can actually construct such a number. Thus to say two real numbers are apart is a stronger
statement, constructively, than to say that they are not equal, and while equality of real numbers is denable in terms

2
1.2. REFERENCES 3

of their apartness, the apartness of real numbers cannot be dened in terms of their equality. For this reason, in
constructive topology especially, the apartness relation over a set is often taken as primitive, and equality is a dened
relation.
A set endowed with an apartness relation is known as a constructive setoid. A function f : A B where A and B
are constructive setoids is called a morphism for #A and #B if x, y : A. f (x) #B f (y) x #A y .

1.2 References
[1] Troelstra, A. S.; Schwichtenberg, H. (2000), Basic proof theory, Cambridge Tracts in Theoretical Computer Science, 43
(2nd ed.), Cambridge University Press, Cambridge, p. 136, ISBN 0-521-77911-1, MR 1776976, doi:10.1017/CBO9781139168717.
Chapter 2

Binary relation

Relation (mathematics)" redirects here. For a more general notion of relation, see nitary relation. For a more
combinatorial viewpoint, see theory of relations. For other uses, see Relation (disambiguation).

In mathematics, a binary relation on a set A is a collection of ordered pairs of elements of A. In other words, it is a
subset of the Cartesian product A2 = A A. More generally, a binary relation between two sets A and B is a subset
of A B. The terms correspondence, dyadic relation and 2-place relation are synonyms for binary relation.
An example is the "divides" relation between the set of prime numbers P and the set of integers Z, in which every
prime p is associated with every integer z that is a multiple of p (but with no integer that is not a multiple of p). In
this relation, for instance, the prime 2 is associated with numbers that include 4, 0, 6, 10, but not 1 or 9; and the
prime 3 is associated with numbers that include 0, 6, and 9, but not 4 or 13.
Binary relations are used in many branches of mathematics to model concepts like "is greater than", "is equal to", and
divides in arithmetic, "is congruent to" in geometry, is adjacent to in graph theory, is orthogonal to in linear
algebra and many more. The concept of function is dened as a special kind of binary relation. Binary relations are
also heavily used in computer science.
A binary relation is the special case n = 2 of an n-ary relation R A1 An, that is, a set of n-tuples where the
jth component of each n-tuple is taken from the jth domain Aj of the relation. An example for a ternary relation on
ZZZ is " ... lies between ... and ..., containing e.g. the triples (5,2,8), (5,8,2), and (4,9,7).
In some systems of axiomatic set theory, relations are extended to classes, which are generalizations of sets. This
extension is needed for, among other things, modeling the concepts of is an element of or is a subset of in set
theory, without running into logical inconsistencies such as Russells paradox.

2.1 Formal denition

A binary relation R between arbitrary sets (or classes) X (the set of departure) and Y (the set of destination or
codomain) is specied by its graph G, which is a subset of the Cartesian product X Y. The binary relation R itself
is usually identied with its graph G, but some authors dene it as an ordered triple (X, Y, G), which is otherwise
referred to as a correspondence.[1]
The statement (x, y) G is read "x is R-related to y", and is denoted by xRy or R(x, y). The latter notation corresponds
to viewing R as the characteristic function of the subset G of X Y, i.e. R(x, y) equals to 1 (true), if (x, y) G, and
0 (false) otherwise.
The order of the elements in each pair of G is important: if a b, then aRb and bRa can be true or false, independently
of each other. Resuming the above example, the prime 3 divides the integer 9, but 9 doesn't divide 3.
The domain of R is the set of all x such that xRy for at least one y. The range of R is the set of all y such that xRy
for at least one x. The eld of R is the union of its domain and its range.[2][3][4]

4
2.2. SPECIAL TYPES OF BINARY RELATIONS 5

2.1.1 Is a relation more than its graph?


According to the denition above, two relations with identical graphs but dierent domains or dierent codomains
are considered dierent. For example, if G = {(1, 2), (1, 3), (2, 7)} , then (Z, Z, G) , (R, N, G) , and (N, R, G) are
three distinct relations, where Z is the set of integers, R is the set of real numbers and N is the set of natural numbers.
Especially in set theory, binary relations are often dened as sets of ordered pairs, identifying binary relations with
their graphs. The domain of a binary relation R is then dened as the set of all x such that there exists at least one
y such that (x, y) R , the range of R is dened as the set of all y such that there exists at least one x such that
(x, y) R , and the eld of R is the union of its domain and its range.[2][3][4]
A special case of this dierence in points of view applies to the notion of function. Many authors insist on distin-
guishing between a functions codomain and its range. Thus, a single rule, like mapping every real number x to
x2 , can lead to distinct functions f : R R and f : R R+ , depending on whether the images under that
rule are understood to be reals or, more restrictively, non-negative reals. But others view functions as simply sets of
ordered pairs with unique rst components. This dierence in perspectives does raise some nontrivial issues. As an
example, the former camp considers surjectivityor being ontoas a property of functions, while the latter sees it
as a relationship that functions may bear to sets.
Either approach is adequate for most uses, provided that one attends to the necessary changes in language, notation,
and the denitions of concepts like restrictions, composition, inverse relation, and so on. The choice between the two
denitions usually matters only in very formal contexts, like category theory.

2.1.2 Example
Example: Suppose there are four objects {ball, car, doll, gun} and four persons {John, Mary, Ian, Venus}. Suppose
that John owns the ball, Mary owns the doll, and Venus owns the car. Nobody owns the gun and Ian owns nothing.
Then the binary relation is owned by is given as

R = ({ball, car, doll, gun}, {John, Mary, Ian, Venus}, {(ball, John), (doll, Mary), (car, Venus)}).

Thus the rst element of R is the set of objects, the second is the set of persons, and the last element is a set of ordered
pairs of the form (object, owner).
The pair (ball, John), denoted by RJ means that the ball is owned by John.
Two dierent relations could have the same graph. For example: the relation

({ball, car, doll, gun}, {John, Mary, Venus}, {(ball, John), (doll, Mary), (car, Venus)})

is dierent from the previous one as everyone is an owner. But the graphs of the two relations are the same.
Nevertheless, R is usually identied or even dened as G(R) and an ordered pair (x, y) G(R)" is usually denoted as
"(x, y) R".[5]

2.2 Special types of binary relations


Some important types of binary relations R between two sets X and Y are listed below. To emphasize that X and Y
can be dierent sets, some authors call such binary relations heterogeneous.[6][7]
Uniqueness properties:

injective (also called left-unique[8] ): for all x and z in X and y in Y it holds that if xRy and zRy then x = z. For
example, the green relation in the diagram is injective, but the red relation is not, as it relates e.g. both x = 5
and z = +5 to y = 25.
functional (also called univalent[9] or right-unique[8] or right-denite[10] ): for all x in X, and y and z in Y
it holds that if xRy and xRz then y = z; such a binary relation is called a partial function. Both relations in
the picture are functional. An example for a non-functional relation can be obtained by rotating the red graph
clockwise by 90 degrees, i.e. by considering the relation x=y2 which relates e.g. x=25 to both y=5 and z=+5.
6 CHAPTER 2. BINARY RELATION

Example relations between real numbers. Red: y=x2 . Green: y=2x+20.

one-to-one (also written 1-to-1): injective and functional. The green relation is one-to-one, but the red is not.

Totality properties (only denable if the sets of departure X resp. destination Y are specied; not to be confused with
a total relation):

left-total:[8] for all x in X there exists a y in Y such that xRy. For example, R is left-total when it is a function
or a multivalued function. Note that this property, although sometimes also referred to as total, is dierent
from the denition of total in the next section. Both relations in the picture are left-total. The relation x=y2 ,
obtained from the above rotation, is not left-total, as it doesn't relate, e.g., x = 14 to any real number y.
surjective (also called right-total[8] or onto): for all y in Y there exists an x in X such that xRy. The green
relation is surjective, but the red relation is not, as it doesn't relate any real number x to e.g. y = 14.
2.3. RELATIONS OVER A SET 7

Uniqueness and totality properties:

A function: a relation that is functional and left-total. Both the green and the red relation are functions.

An injective function: a relation that is injective, functional, and left-total.

A surjective function or surjection: a relation that is functional, left-total, and right-total.

A bijection: a surjective one-to-one or surjective injective function is said to be bijective, also known as
one-to-one correspondence.[11] The green relation is bijective, but the red is not.

2.2.1 Difunctional
Less commonly encountered is the notion of difunctional (or regular) relation, dened as a relation R such that
R=RR1 R.[12]
To understand this notion better, it helps to consider a relation as mapping every element xX to a set xR = { yY
| xRy }.[12] This set is sometimes called the successor neighborhood of x in R; one can dene the predecessor
neighborhood analogously.[13] Synonymous terms for these notions are afterset and respectively foreset.[6]
A difunctional relation can then be equivalently characterized as a relation R such that wherever x1 R and x2 R have a
non-empty intersection, then these two sets coincide; formally x1 R x2 R implies x1 R = x2 R.[12]
As examples, any function or any functional (right-unique) relation is difunctional; the converse doesn't hold. If one
considers a relation R from set to itself (X = Y), then if R is both transitive and symmetric (i.e. a partial equivalence
relation), then it is also difunctional.[14] The converse of this latter statement also doesn't hold.
A characterization of difunctional relations, which also explains their name, is to consider two functions f: A C
and g: B C and then dene the following set which generalizes the kernel of a single function as joint kernel: ker(f,
g) = { (a, b) A B | f(a) = g(b) }. Every difunctional relation R A B arises as the joint kernel of two functions
f: A C and g: B C for some set C.[15]
In automata theory, the term rectangular relation has also been used to denote a difunctional relation. This ter-
minology is justied by the fact that when represented as a boolean matrix, the columns and rows of a difunctional
relation can be arranged in such a way as to present rectangular blocks of true on the (asymmetric) main diagonal.[16]
Other authors however use the term rectangular to denote any heterogeneous relation whatsoever.[7]

2.3 Relations over a set


If X = Y then we simply say that the binary relation is over X, or that it is an endorelation over X.[17] In computer
science, such a relation is also called a homogeneous (binary) relation.[7][17][18] Some types of endorelations are
widely studied in graph theory, where they are known as simple directed graphs permitting loops.
The set of all binary relations Rel(X) on a set X is the set 2X X which is a Boolean algebra augmented with the
involution of mapping of a relation to its inverse relation. For the theoretical explanation see Relation algebra.
Some important properties that a binary relation R over a set X may have are:

reexive: for all x in X it holds that xRx. For example, greater than or equal to () is a reexive relation but
greater than (>) is not.

irreexive (or strict): for all x in X it holds that not xRx. For example, > is an irreexive relation, but is not.

coreexive relation: for all x and y in X it holds that if xRy then x = y.[19] An example of a coreexive relation
is the relation on integers in which each odd number is related to itself and there are no other relations. The
equality relation is the only example of a both reexive and coreexive relation, and any coreexive relation is
a subset of the identity relation.

The previous 3 alternatives are far from being exhaustive; e.g. the red relation y=x2 from the
above picture is neither irreexive, nor coreexive, nor reexive, since it contains the pair
(0,0), and (2,4), but not (2,2), respectively.
8 CHAPTER 2. BINARY RELATION

symmetric: for all x and y in X it holds that if xRy then yRx. Is a blood relative of is a symmetric relation,
because x is a blood relative of y if and only if y is a blood relative of x.

antisymmetric: for all x and y in X, if xRy and yRx then x = y. For example, is anti-symmetric; so is >, but
vacuously (the condition in the denition is always false).[20]

asymmetric: for all x and y in X, if xRy then not yRx. A relation is asymmetric if and only if it is both
anti-symmetric and irreexive.[21] For example, > is asymmetric, but is not.

transitive: for all x, y and z in X it holds that if xRy and yRz then xRz. For example, is ancestor of is transitive,
while is parent of is not. A transitive relation is irreexive if and only if it is asymmetric.[22]

total: for all x and y in X it holds that xRy or yRx (or both). This denition for total is dierent from left total
in the previous section. For example, is a total relation.

trichotomous: for all x and y in X exactly one of xRy, yRx or x = y holds. For example, > is a trichotomous
relation, while the relation divides on natural numbers is not.[23]

Right Euclidean: for all x, y and z in X it holds that if xRy and xRz, then yRz.

Left Euclidean: for all x, y and z in X it holds that if yRx and zRx, then yRz.

Euclidean: A Euclidean relation is both left and right Euclidean. Equality is a Euclidean relation because if
x=y and x=z, then y=z.

serial: for all x in X, there exists y in X such that xRy. "Is greater than" is a serial relation on the integers. But
it is not a serial relation on the positive integers, because there is no y in the positive integers such that 1>y.[24]
However, "is less than" is a serial relation on the positive integers, the rational numbers and the real numbers.
Every reexive relation is serial: for a given x, choose y=x. A serial relation can be equivalently characterized
as every element having a non-empty successor neighborhood (see the previous section for the denition of this
notion). Similarly an inverse serial relation is a relation in which every element has non-empty predecessor
neighborhood.[13]

set-like (or local): for every x in X, the class of all y such that yRx is a set. (This makes sense only if relations
on proper classes are allowed.) The usual ordering < on the class of ordinal numbers is set-like, while its inverse
> is not.

A relation that is reexive, symmetric, and transitive is called an equivalence relation. A relation that is symmetric,
transitive, and serial is also reexive. A relation that is only symmetric and transitive (without necessarily being
reexive) is called a partial equivalence relation.
A relation that is reexive, antisymmetric, and transitive is called a partial order. A partial order that is total is called
a total order, simple order, linear order, or a chain.[25] A linear order where every nonempty subset has a least element
is called a well-order.

2.4 Operations on binary relations


If R, S are binary relations over X and Y, then each of the following is a binary relation over X and Y:

Union: R S X Y, dened as R S = { (x, y) | (x, y) R or (x, y) S }. For example, is the union of >
and =.

Intersection: R S X Y, dened as R S = { (x, y) | (x, y) R and (x, y) S }.

If R is a binary relation over X and Y, and S is a binary relation over Y and Z, then the following is a binary relation
over X and Z: (see main article composition of relations)
2.4. OPERATIONS ON BINARY RELATIONS 9

Composition: S R, also denoted R ; S (or R S), dened as S R = { (x, z) | there exists y Y, such that (x, y)
R and (y, z) S }. The order of R and S in the notation S R, used here agrees with the standard notational
order for composition of functions. For example, the composition is mother of is parent of yields is
maternal grandparent of, while the composition is parent of is mother of yields is grandmother of.

A relation R on sets X and Y is said to be contained in a relation S on X and Y if R is a subset of S, that is, if x R y
always implies x S y. In this case, if R and S disagree, R is also said to be smaller than S. For example, > is contained
in .
If R is a binary relation over X and Y, then the following is a binary relation over Y and X:

Inverse or converse: R 1 , dened as R 1 = { (y, x) | (x, y) R }. A binary relation over a set is equal to its
inverse if and only if it is symmetric. See also duality (order theory). For example, is less than (<) is the
inverse of is greater than (>).

If R is a binary relation over X, then each of the following is a binary relation over X:

Reexive closure: R = , dened as R = = { (x, x) | x X } R or the smallest reexive relation over X containing
R. This can be proven to be equal to the intersection of all reexive relations containing R.
Reexive reduction: R , dened as R
= R \ { (x, x) | x X } or the largest irreexive relation over X
contained in R.
Transitive closure: R + , dened as the smallest transitive relation over X containing R. This can be seen to be
equal to the intersection of all transitive relations containing R.
Reexive transitive closure: R *, dened as R * = (R + ) = , the smallest preorder containing R.
Reexive transitive symmetric closure: R , dened as the smallest equivalence relation over X containing
R.

2.4.1 Complement
If R is a binary relation over X and Y, then the following too:

The complement S is dened as x S y if not x R y. For example, on real numbers, is the complement of >.

The complement of the inverse is the inverse of the complement.


If X = Y, the complement has the following properties:

If a relation is symmetric, the complement is too.


The complement of a reexive relation is irreexive and vice versa.
The complement of a strict weak order is a total preorder and vice versa.

The complement of the inverse has these same properties.

2.4.2 Restriction
The restriction of a binary relation on a set X to a subset S is the set of all pairs (x, y) in the relation for which x and
y are in S.
If a relation is reexive, irreexive, symmetric, antisymmetric, asymmetric, transitive, total, trichotomous, a partial
order, total order, strict weak order, total preorder (weak order), or an equivalence relation, its restrictions are too.
However, the transitive closure of a restriction is a subset of the restriction of the transitive closure, i.e., in general
not equal. For example, restricting the relation "x is parent of y" to females yields the relation "x is mother of
the woman y"; its transitive closure doesn't relate a woman with her paternal grandmother. On the other hand, the
10 CHAPTER 2. BINARY RELATION

transitive closure of is parent of is is ancestor of"; its restriction to females does relate a woman with her paternal
grandmother.
Also, the various concepts of completeness (not to be confused with being total) do not carry over to restrictions.
For example, on the set of real numbers a property of the relation "" is that every non-empty subset S of R with an
upper bound in R has a least upper bound (also called supremum) in R. However, for a set of rational numbers this
supremum is not necessarily rational, so the same property does not hold on the restriction of the relation "" to the
set of rational numbers.
The left-restriction (right-restriction, respectively) of a binary relation between X and Y to a subset S of its domain
(codomain) is the set of all pairs (x, y) in the relation for which x (y) is an element of S.

2.4.3 Algebras, categories, and rewriting systems


Various operations on binary endorelations can be treated as giving rise to an algebraic structure, known as relation
algebra. It should not be confused with relational algebra which deals in nitary relations (and in practice also nite
and many-sorted).
For heterogenous binary relations, a category of relations arises.[7]
Despite their simplicity, binary relations are at the core of an abstract computation model known as an abstract
rewriting system.

2.5 Sets versus classes


Certain mathematical relations, such as equal to, member of, and subset of, cannot be understood to be binary
relations as dened above, because their domains and codomains cannot be taken to be sets in the usual systems of
axiomatic set theory. For example, if we try to model the general concept of equality as a binary relation =, we
must take the domain and codomain to be the class of all sets, which is not a set in the usual set theory.
In most mathematical contexts, references to the relations of equality, membership and subset are harmless because
they can be understood implicitly to be restricted to some set in the context. The usual work-around to this problem
is to select a large enough set A, that contains all the objects of interest, and work with the restriction =A instead of
=. Similarly, the subset of relation needs to be restricted to have domain and codomain P(A) (the power set of
a specic set A): the resulting set relation can be denoted A. Also, the member of relation needs to be restricted
to have domain A and codomain P(A) to obtain a binary relation A that is a set. Bertrand Russell has shown that
assuming to be dened on all sets leads to a contradiction in naive set theory.
Another solution to this problem is to use a set theory with proper classes, such as NBG or MorseKelley set theory,
and allow the domain and codomain (and so the graph) to be proper classes: in such a theory, equality, membership,
and subset are binary relations without special comment. (A minor modication needs to be made to the concept of
the ordered triple (X, Y, G), as normally a proper class cannot be a member of an ordered tuple; or of course one
can identify the function with its graph in this context.)[26] With this denition one can for instance dene a function
relation between every set and its power set.

2.6 The number of binary relations


2
The number of distinct binary relations on an n-element set is 2n (sequence A002416 in the OEIS):
Notes:

The number of irreexive relations is the same as that of reexive relations.


The number of strict partial orders (irreexive transitive relations) is the same as that of partial orders.
The number of strict weak orders is the same as that of total preorders.
The total orders are the partial orders that are also total preorders. The number of preorders that are neither
a partial order nor a total preorder is, therefore, the number of preorders, minus the number of partial orders,
minus the number of total preorders, plus the number of total orders: 0, 0, 0, 3, and 85, respectively.
2.7. EXAMPLES OF COMMON BINARY RELATIONS 11

the number of equivalence relations is the number of partitions, which is the Bell number.

The binary relations can be grouped into pairs (relation, complement), except that for n = 0 the relation is its own
complement. The non-symmetric ones can be grouped into quadruples (relation, complement, inverse, inverse com-
plement).

2.7 Examples of common binary relations


order relations, including strict orders:

greater than
greater than or equal to
less than
less than or equal to
divides (evenly)
is a subset of

equivalence relations:

equality
is parallel to (for ane spaces)
is in bijection with
isomorphy

dependency relation, a nite, symmetric, reexive relation.

independency relation, a symmetric, irreexive relation which is the complement of some dependency relation.

2.8 See also


Conuence (term rewriting)

Hasse diagram

Incidence structure

Logic of relatives

Order theory

Triadic relation

2.9 Notes
[1] Encyclopedic dictionary of Mathematics. MIT. 2000. pp. 13301331. ISBN 0-262-59020-4.

[2] Suppes, Patrick (1972) [originally published by D. van Nostrand Company in 1960]. Axiomatic Set Theory. Dover. ISBN
0-486-61630-4.

[3] Smullyan, Raymond M.; Fitting, Melvin (2010) [revised and corrected republication of the work originally published in
1996 by Oxford University Press, New York]. Set Theory and the Continuum Problem. Dover. ISBN 978-0-486-47484-7.

[4] Levy, Azriel (2002) [republication of the work published by Springer-Verlag, Berlin, Heidelberg and New York in 1979].
Basic Set Theory. Dover. ISBN 0-486-42079-5.

[5] Megill, Norman (5 August 1993). df-br (Metamath Proof Explorer)". Retrieved 18 November 2016.
12 CHAPTER 2. BINARY RELATION

[6] Christodoulos A. Floudas; Panos M. Pardalos (2008). Encyclopedia of Optimization (2nd ed.). Springer Science & Business
Media. pp. 299300. ISBN 978-0-387-74758-3.

[7] Michael Winter (2007). Goguen Categories: A Categorical Approach to L-fuzzy Relations. Springer. pp. xxi. ISBN
978-1-4020-6164-6.

[8] Kilp, Knauer and Mikhalev: p. 3. The same four denitions appear in the following:

Peter J. Pahl; Rudolf Damrath (2001). Mathematical Foundations of Computational Engineering: A Handbook.
Springer Science & Business Media. p. 506. ISBN 978-3-540-67995-0.
Eike Best (1996). Semantics of Sequential and Parallel Programs. Prentice Hall. pp. 1921. ISBN 978-0-13-
460643-9.
Robert-Christoph Riemann (1999). Modelling of Concurrent Systems: Structural and Semantical Methods in the High
Level Petri Net Calculus. Herbert Utz Verlag. pp. 2122. ISBN 978-3-89675-629-9.

[9] Gunther Schmidt, 2010. Relational Mathematics. Cambridge University Press, ISBN 978-0-521-76268-7, Chapt. 5

[10] Ms, Stephan (2007), Reasoning on Spatial Semantic Integrity Constraints, Spatial Information Theory: 8th International
Conference, COSIT 2007, Melbourne, Australia, September 1923, 2007, Proceedings, Lecture Notes in Computer Science,
4736, Springer, pp. 285302, doi:10.1007/978-3-540-74788-8_18

[11] Note that the use of correspondence here is narrower than as general synonym for binary relation.

[12] Chris Brink; Wolfram Kahl; Gunther Schmidt (1997). Relational Methods in Computer Science. Springer Science &
Business Media. p. 200. ISBN 978-3-211-82971-4.

[13] Yao, Y. (2004). Semantics of Fuzzy Sets in Rough Set Theory. Transactions on Rough Sets II. Lecture Notes in Computer
Science. 3135. p. 309. ISBN 978-3-540-23990-1. doi:10.1007/978-3-540-27778-1_15.

[14] William Craig (2006). Semigroups Underlying First-order Logic. American Mathematical Soc. p. 72. ISBN 978-0-8218-
6588-0.

[15] Gumm, H. P.; Zarrad, M. (2014). Coalgebraic Simulations and Congruences. Coalgebraic Methods in Computer Science.
Lecture Notes in Computer Science. 8446. p. 118. ISBN 978-3-662-44123-7. doi:10.1007/978-3-662-44124-4_7.

[16] Julius Richard Bchi (1989). Finite Automata, Their Algebras and Grammars: Towards a Theory of Formal Expressions.
Springer Science & Business Media. pp. 3537. ISBN 978-1-4613-8853-1.

[17] M. E. Mller (2012). Relational Knowledge Discovery. Cambridge University Press. p. 22. ISBN 978-0-521-19021-3.

[18] Peter J. Pahl; Rudolf Damrath (2001). Mathematical Foundations of Computational Engineering: A Handbook. Springer
Science & Business Media. p. 496. ISBN 978-3-540-67995-0.

[19] Fonseca de Oliveira, J. N., & Pereira Cunha Rodrigues, C. D. J. (2004). Transposing Relations: From Maybe Functions
to Hash Tables. In Mathematics of Program Construction (p. 337).

[20] Smith, Douglas; Eggen, Maurice; St. Andre, Richard (2006), A Transition to Advanced Mathematics (6th ed.), Brooks/Cole,
p. 160, ISBN 0-534-39900-2

[21] Nievergelt, Yves (2002), Foundations of Logic and Mathematics: Applications to Computer Science and Cryptography,
Springer-Verlag, p. 158.

[22] Flaka, V.; Jeek, J.; Kepka, T.; Kortelainen, J. (2007). Transitive Closures of Binary Relations I (PDF). Prague: School
of Mathematics Physics Charles University. p. 1. Lemma 1.1 (iv). This source refers to asymmetric relations as strictly
antisymmetric.

[23] Since neither 5 divides 3, nor 3 divides 5, nor 3=5.

[24] Yao, Y.Y.; Wong, S.K.M. (1995). Generalization of rough sets using relationships between attribute values (PDF).
Proceedings of the 2nd Annual Joint Conference on Information Sciences: 3033..

[25] Joseph G. Rosenstein, Linear orderings, Academic Press, 1982, ISBN 0-12-597680-1, p. 4

[26] Tarski, Alfred; Givant, Steven (1987). A formalization of set theory without variables. American Mathematical Society. p.
3. ISBN 0-8218-1041-3.
2.10. REFERENCES 13

2.10 References
M. Kilp, U. Knauer, A.V. Mikhalev, Monoids, Acts and Categories: with Applications to Wreath Products and
Graphs, De Gruyter Expositions in Mathematics vol. 29, Walter de Gruyter, 2000, ISBN 3-11-015248-7.
Gunther Schmidt, 2010. Relational Mathematics. Cambridge University Press, ISBN 978-0-521-76268-7.

2.11 External links


Hazewinkel, Michiel, ed. (2001) [1994], Binary relation, Encyclopedia of Mathematics, Springer Science+Business
Media B.V. / Kluwer Academic Publishers, ISBN 978-1-55608-010-4
Chapter 3

Equivalence relation

This article is about the mathematical concept. For the patent doctrine, see Doctrine of equivalents.
In mathematics, an equivalence relation is a binary relation that is at the same time a reexive relation, a symmetric
relation and a transitive relation. As a consequence of these properties an equivalence relation provides a partition of
a set into equivalence classes.

3.1 Notation
Although various notations are used throughout the literature to denote that two elements a and b of a set are equivalent
with respect to an equivalence relation R, the most common are "a ~ b" and "a b", which are used when R is the
obvious relation being referenced, and variations of "a ~R b", "a R b", or "aRb" otherwise.

3.2 Denition
A given binary relation ~ on a set X is said to be an equivalence relation if and only if it is reexive, symmetric and
transitive. That is, for all a, b and c in X:

a ~ a. (Reexivity)
a ~ b if and only if b ~ a. (Symmetry)
if a ~ b and b ~ c then a ~ c. (Transitivity)

X together with the relation ~ is called a setoid. The equivalence class of a under ~, denoted [a] , is dened as
[a] = {b X | a b} .

3.3 Examples

3.3.1 Simple example


Let the set {a, b, c} have the equivalence relation {(a, a), (b, b), (c, c), (b, c), (c, b)} . The following sets are equivalence
classes of this relation:
[a] = {a}, [b] = [c] = {b, c} .
The set of all equivalence classes for this relation is {{a}, {b, c}} .

3.3.2 Equivalence relations


The following are all equivalence relations:

14
3.4. CONNECTIONS TO OTHER RELATIONS 15

Has the same birthday as on the set of all people.

Is similar to on the set of all triangles.

Is congruent to on the set of all triangles.

Is congruent to, modulo n" on the integers.

Has the same image under a function" on the elements of the domain of the function.

Has the same absolute value on the set of real numbers

Has the same cosine on the set of all angles.

3.3.3 Relations that are not equivalences


The relation "" between real numbers is reexive and transitive, but not symmetric. For example, 7 5 does
not imply that 5 7. It is, however, a total order.

The relation has a common factor greater than 1 with between natural numbers greater than 1, is reexive
and symmetric, but not transitive. (Example: The natural numbers 2 and 6 have a common factor greater than
1, and 6 and 3 have a common factor greater than 1, but 2 and 3 do not have a common factor greater than 1).

The empty relation R on a non-empty set X (i.e. aRb is never true) is vacuously symmetric and transitive, but
not reexive. (If X is also empty then R is reexive.)

The relation is approximately equal to between real numbers, even if more precisely dened, is not an equiv-
alence relation, because although reexive and symmetric, it is not transitive, since multiple small changes can
accumulate to become a big change. However, if the approximation is dened asymptotically, for example by
saying that two functions f and g are approximately equal near some point if the limit of f g is 0 at that point,
then this denes an equivalence relation.

3.4 Connections to other relations


A partial order is a relation that is reexive, antisymmetric, and transitive.

Equality is both an equivalence relation and a partial order. Equality is also the only relation on a set that
is reexive, symmetric and antisymmetric. In algebraic expressions, equal variables may be substituted for
one another, a facility that is not available for equivalence related variables. The equivalence classes of an
equivalence relation can substitute for one another, but not individuals within a class.

A strict partial order is irreexive, transitive, and asymmetric.

A partial equivalence relation is transitive and symmetric. Transitive and symmetric imply reexive if and only
if for all a X, there exists a b X such that a ~ b.

A reexive and symmetric relation is a dependency relation, if nite, and a tolerance relation if innite.

A preorder is reexive and transitive.

A congruence relation is an equivalence relation whose domain X is also the underlying set for an algebraic
structure, and which respects the additional structure. In general, congruence relations play the role of kernels
of homomorphisms, and the quotient of a structure by a congruence relation can be formed. In many important
cases congruence relations have an alternative representation as substructures of the structure on which they
are dened. E.g. the congruence relations on groups correspond to the normal subgroups.

Any equivalence relation is the negation of an apartness relation, though the converse statement only holds in
classical mathematics (as opposed to constructive mathematics), since it is equivalent to the law of excluded
middle.
16 CHAPTER 3. EQUIVALENCE RELATION

3.5 Well-denedness under an equivalence relation


If ~ is an equivalence relation on X, and P(x) is a property of elements of X, such that whenever x ~ y, P(x) is true if
P(y) is true, then the property P is said to be well-dened or a class invariant under the relation ~.
A frequent particular case occurs when f is a function from X to another set Y; if x1 ~ x2 implies f(x1 ) = f(x2 ) then
f is said to be a morphism for ~, a class invariant under ~, or simply invariant under ~. This occurs, e.g. in the
character theory of nite groups. The latter case with the function f can be expressed by a commutative triangle. See
also invariant. Some authors use compatible with ~" or just respects ~" instead of invariant under ~".
More generally, a function may map equivalent arguments (under an equivalence relation ~A) to equivalent values
(under an equivalence relation ~B). Such a function is known as a morphism from ~A to ~B.

3.6 Equivalence class, quotient set, partition


Let a, b X . Some denitions:

3.6.1 Equivalence class


Main article: Equivalence class

A subset Y of X such that a ~ b holds for all a and b in Y, and never for a in Y and b outside Y, is called an equivalence
class of X by ~. Let [a] := {x X | a x} denote the equivalence class to which a belongs. All elements of X
equivalent to each other are also elements of the same equivalence class.

3.6.2 Quotient set


Main article: Quotient set

The set of all possible equivalence classes of X by ~, denoted X/ := {[x] | x X} , is the quotient set of X by
~. If X is a topological space, there is a natural way of transforming X/~ into a topological space; see quotient space
for the details.

3.6.3 Projection
Main article: Projection (relational algebra)

The projection of ~ is the function : X X/ dened by (x) = [x] which maps elements of X into their
respective equivalence classes by ~.

Theorem on projections:[1] Let the function f: X B be such that a ~ b f(a) = f(b). Then there is a
unique function g : X/~ B, such that f = g. If f is a surjection and a ~ b f(a) = f(b), then g is a
bijection.

3.6.4 Equivalence kernel


The equivalence kernel of a function f is the equivalence relation ~ dened by x y f (x) = f (y) . The
equivalence kernel of an injection is the identity relation.

3.6.5 Partition
Main article: Partition of a set
3.7. FUNDAMENTAL THEOREM OF EQUIVALENCE RELATIONS 17

A partition of X is a set P of nonempty subsets of X, such that every element of X is an element of a single element
of P. Each element of P is a cell of the partition. Moreover, the elements of P are pairwise disjoint and their union
is X.

Counting possible partitions

Let X be a nite set with n elements. Since every equivalence relation over X corresponds to a partition of X, and
vice versa, the number of possible equivalence relations on X equals the number of distinct partitions of X, which is
the nth Bell number Bn:


1 kn
Bn = ,
e k!
k=0

where the above is one of the ways to write the nth Bell number.

3.7 Fundamental theorem of equivalence relations


A key result links equivalence relations and partitions:[2][3][4]

An equivalence relation ~ on a set X partitions X.

Conversely, corresponding to any partition of X, there exists an equivalence relation ~ on X.

In both cases, the cells of the partition of X are the equivalence classes of X by ~. Since each element of X belongs
to a unique cell of any partition of X, and since each cell of the partition is identical to an equivalence class of X by
~, each element of X belongs to a unique equivalence class of X by ~. Thus there is a natural bijection between the
set of all possible equivalence relations on X and the set of all partitions of X.

3.8 Comparing equivalence relations


See also: Partition of a set Renement of partitions

If ~ and are two equivalence relations on the same set S, and a~b implies ab for all a,b S, then is said to be a
coarser relation than ~, and ~ is a ner relation than . Equivalently,

~ is ner than if every equivalence class of ~ is a subset of an equivalence class of , and thus every equivalence
class of is a union of equivalence classes of ~.

~ is ner than if the partition created by ~ is a renement of the partition created by .

The equality equivalence relation is the nest equivalence relation on any set, while the trivial relation that makes all
pairs of elements related is the coarsest.
The relation "~ is ner than " on the collection of all equivalence relations on a xed set is itself a partial order
relation, which makes the collection a geometric lattice.[5]

3.9 Generating equivalence relations


Given any binary relation A X X on X , the equivalence relation generated by A is the intersection of the
equivalence relations on X that contain A . (Since X X is an equivalence relation, the intersection is nontrivial.)
18 CHAPTER 3. EQUIVALENCE RELATION

Given any set X, there is an equivalence relation over the set [XX] of all possible functions XX. Two such
functions are deemed equivalent when their respective sets of xpoints have the same cardinality, corresponding
to cycles of length one in a permutation. Functions equivalent in this manner form an equivalence class on
[XX], and these equivalence classes partition [XX].

An equivalence relation ~ on X is the equivalence kernel of its surjective projection : X X/~.[6] Conversely,
any surjection between sets determines a partition on its domain, the set of preimages of singletons in the
codomain. Thus an equivalence relation over X, a partition of X, and a projection whose domain is X, are three
equivalent ways of specifying the same thing.

The intersection of any collection of equivalence relations over X (binary relations viewed as a subset of X X)
is also an equivalence relation. This yields a convenient way of generating an equivalence relation: given any
binary relation R on X, the equivalence relation generated by R is the smallest equivalence relation containing
R. Concretely, R generates the equivalence relation a ~ b if and only if there exist elements x1 , x2 , ..., xn in X
such that a = x1 , b = xn, and (xi,xi )R or (xi,xi)R, i = 1, ..., n1.

Note that the equivalence relation generated in this manner can be trivial. For instance, the equivalence
relation ~ generated by any total order on X has exactly one equivalence class, X itself, because x ~ y for
all x and y. As another example, any subset of the identity relation on X has equivalence classes that are
the singletons of X.

Equivalence relations can construct new spaces by gluing things together. Let X be the unit Cartesian square
[0,1] [0,1], and let ~ be the equivalence relation on X dened by a, b [0,1] ((a, 0) ~ (a, 1) (0, b) ~ (1, b)).
Then the quotient space X/~ can be naturally identied (homeomorphism) with a torus: take a square piece of
paper, bend and glue together the upper and lower edge to form a cylinder, then bend the resulting cylinder so
as to glue together its two open ends, resulting in a torus.

3.10 Algebraic structure


Much of mathematics is grounded in the study of equivalences, and order relations. Lattice theory captures the
mathematical structure of order relations. Even though equivalence relations are as ubiquitous in mathematics as
order relations, the algebraic structure of equivalences is not as well known as that of orders. The former structure
draws primarily on group theory and, to a lesser extent, on the theory of lattices, categories, and groupoids.

3.10.1 Group theory


Just as order relations are grounded in ordered sets, sets closed under pairwise supremum and inmum, equivalence
relations are grounded in partitioned sets, which are sets closed under bijections and preserve partition structure.
Since all such bijections map an equivalence class onto itself, such bijections are also known as permutations. Hence
permutation groups (also known as transformation groups) and the related notion of orbit shed light on the mathe-
matical structure of equivalence relations.
Let '~' denote an equivalence relation over some nonempty set A, called the universe or underlying set. Let G denote
the set of bijective functions over A that preserve the partition structure of A: x A g G (g(x) [x]). Then the
following three connected theorems hold:[7]

~ partitions A into equivalence classes. (This is the Fundamental Theorem of Equivalence Relations, mentioned
above);

Given a partition of A, G is a transformation group under composition, whose orbits are the cells of the parti-
tion;

Given a transformation group G over A, there exists an equivalence relation ~ over A, whose equivalence classes
are the orbits of G.[8][9]

In sum, given an equivalence relation ~ over A, there exists a transformation group G over A whose orbits are the
equivalence classes of A under ~.
3.11. EQUIVALENCE RELATIONS AND MATHEMATICAL LOGIC 19

This transformation group characterisation of equivalence relations diers fundamentally from the way lattices char-
acterize order relations. The arguments of the lattice theory operations meet and join are elements of some universe
A. Meanwhile, the arguments of the transformation group operations composition and inverse are elements of a set
of bijections, A A.
Moving to groups in general, let H be a subgroup of some group G. Let ~ be an equivalence relation on G, such that a
~ b (ab1 H). The equivalence classes of ~also called the orbits of the action of H on Gare the right cosets
of H in G. Interchanging a and b yields the left cosets.
Proof.[10] Let function composition interpret group multiplication, and function inverse interpret group inverse.
Then G is a group under composition, meaning that x A g G ([g(x)] = [x]), because G satises the following
four conditions:

G is closed under composition. The composition of any two elements of G exists, because the domain and
codomain of any element of G is A. Moreover, the composition of bijections is bijective;[11]

Existence of identity function. The identity function, I(x)=x, is an obvious element of G;

Existence of inverse function. Every bijective function g has an inverse g1 , such that gg1 = I;

Composition associates. f(gh) = (fg)h. This holds for all functions over all domains.[12]

Let f and g be any two elements of G. By virtue of the denition of G, [g(f(x))] = [f(x)] and [f(x)] = [x], so that
[g(f(x))] = [x]. Hence G is also a transformation group (and an automorphism group) because function composition
preserves the partitioning of A.
Related thinking can be found in Rosen (2008: chpt. 10).

3.10.2 Categories and groupoids


Let G be a set and let "~" denote an equivalence relation over G. Then we can form a groupoid representing this
equivalence relation as follows. The objects are the elements of G, and for any two elements x and y of G, there exists
a unique morphism from x to y if and only if x~y.
The advantages of regarding an equivalence relation as a special case of a groupoid include:

Whereas the notion of free equivalence relation does not exist, that of a free groupoid on a directed graph
does. Thus it is meaningful to speak of a presentation of an equivalence relation, i.e., a presentation of the
corresponding groupoid;

Bundles of groups, group actions, sets, and equivalence relations can be regarded as special cases of the notion
of groupoid, a point of view that suggests a number of analogies;

In many contexts quotienting, and hence the appropriate equivalence relations often called congruences, are
important. This leads to the notion of an internal groupoid in a category.[13]

3.10.3 Lattices
The possible equivalence relations on any set X, when ordered by set inclusion, form a complete lattice, called Con
X by convention. The canonical map ker: X^X Con X, relates the monoid X^X of all functions on X and Con X.
ker is surjective but not injective. Less formally, the equivalence relation ker on X, takes each function f: XX to
its kernel ker f. Likewise, ker(ker) is an equivalence relation on X^X.

3.11 Equivalence relations and mathematical logic


Equivalence relations are a ready source of examples or counterexamples. For example, an equivalence relation with
exactly two innite equivalence classes is an easy example of a theory which is -categorical, but not categorical for
any larger cardinal number.
20 CHAPTER 3. EQUIVALENCE RELATION

An implication of model theory is that the properties dening a relation can be proved independent of each other
(and hence necessary parts of the denition) if and only if, for each property, examples can be found of relations
not satisfying the given property while satisfying all the other properties. Hence the three dening properties of
equivalence relations can be proved mutually independent by the following three examples:

Reexive and transitive: The relation on N. Or any preorder;


Symmetric and transitive: The relation R on N, dened as aRb ab 0. Or any partial equivalence relation;
Reexive and symmetric: The relation R on Z, dened as aRb "a b is divisible by at least one of 2 or 3.
Or any dependency relation.

Properties denable in rst-order logic that an equivalence relation may or may not possess include:

The number of equivalence classes is nite or innite;


The number of equivalence classes equals the (nite) natural number n;
All equivalence classes have innite cardinality;
The number of elements in each equivalence class is the natural number n.

3.12 Euclidean relations


Euclid's The Elements includes the following Common Notion 1":

Things which equal the same thing also equal one another.

Nowadays, the property described by Common Notion 1 is called Euclidean (replacing equal by are in relation
with). By relation is meant a binary relation, in which aRb is generally distinct from bRa. A Euclidean relation
thus comes in two forms:

(aRc bRc) aRb (Left-Euclidean relation)


(cRa cRb) aRb (Right-Euclidean relation)

The following theorem connects Euclidean relations and equivalence relations:

Theorem If a relation is (left or right) Euclidean and reexive, it is also symmetric and transitive.
Proof for a left-Euclidean relation
(aRc bRc) aRb [a/c] = (aRa bRa) aRb [reexive; erase T] = bRa aRb. Hence R is symmetric.
(aRc bRc) aRb [symmetry] = (aRc cRb) aRb. Hence R is transitive.

with an analogous proof for a right-Euclidean relation. Hence an equivalence relation is a relation that is Euclidean
and reexive. The Elements mentions neither symmetry nor reexivity, and Euclid probably would have deemed the
reexivity of equality too obvious to warrant explicit mention.

3.13 See also


Apartness relation
Conjugacy class
Equipollence (geometry)
Topological conjugacy
Up to
3.14. NOTES 21

3.14 Notes
[1] Garrett Birkho and Saunders Mac Lane, 1999 (1967). Algebra, 3rd ed. p. 35, Th. 19. Chelsea.

[2] Wallace, D. A. R., 1998. Groups, Rings and Fields. p. 31, Th. 8. Springer-Verlag.

[3] Dummit, D. S., and Foote, R. M., 2004. Abstract Algebra, 3rd ed. p. 3, Prop. 2. John Wiley & Sons.

[4] Karel Hrbacek & Thomas Jech (1999) Introduction to Set Theory, 3rd edition, pages 2932, Marcel Dekker

[5] Birkho, Garrett (1995), Lattice Theory, Colloquium Publications, 25 (3rd ed.), American Mathematical Society, ISBN
9780821810255. Sect. IV.9, Theorem 12, page 95

[6] Garrett Birkho and Saunders Mac Lane, 1999 (1967). Algebra, 3rd ed. p. 33, Th. 18. Chelsea.

[7] Rosen (2008), pp. 24345. Less clear is 10.3 of Bas van Fraassen, 1989. Laws and Symmetry. Oxford Univ. Press.

[8] Wallace, D. A. R., 1998. Groups, Rings and Fields. Springer-Verlag: 202, Th. 6.

[9] Dummit, D. S., and Foote, R. M., 2004. Abstract Algebra, 3rd ed. John Wiley & Sons: 114, Prop. 2.

[10] Bas van Fraassen, 1989. Laws and Symmetry. Oxford Univ. Press: 246.

[11] Wallace, D. A. R., 1998. Groups, Rings and Fields. Springer-Verlag: 22, Th. 6.

[12] Wallace, D. A. R., 1998. Groups, Rings and Fields. Springer-Verlag: 24, Th. 7.

[13] Borceux, F. and Janelidze, G., 2001. Galois theories, Cambridge University Press, ISBN 0-521-80309-8

3.15 References
Brown, Ronald, 2006. Topology and Groupoids. Booksurge LLC. ISBN 1-4196-2722-8.

Castellani, E., 2003, Symmetry and equivalence in Brading, Katherine, and E. Castellani, eds., Symmetries
in Physics: Philosophical Reections. Cambridge Univ. Press: 422-433.

Robert Dilworth and Crawley, Peter, 1973. Algebraic Theory of Lattices. Prentice Hall. Chpt. 12 discusses
how equivalence relations arise in lattice theory.

Higgins, P.J., 1971. Categories and groupoids. Van Nostrand. Downloadable since 2005 as a TAC Reprint.
John Randolph Lucas, 1973. A Treatise on Time and Space. London: Methuen. Section 31.

Rosen, Joseph (2008) Symmetry Rules: How Science and Nature are Founded on Symmetry. Springer-Verlag.
Mostly chpts. 9,10.

Raymond Wilder (1965) Introduction to the Foundations of Mathematics 2nd edition, Chapter 2-8: Axioms
dening equivalence, pp 4850, John Wiley & Sons.

3.16 External links


Hazewinkel, Michiel, ed. (2001) [1994], Equivalence relation, Encyclopedia of Mathematics, Springer Sci-
ence+Business Media B.V. / Kluwer Academic Publishers, ISBN 978-1-55608-010-4
Bogomolny, A., "Equivalence Relationship" cut-the-knot. Accessed 1 September 2009

Equivalence relation at PlanetMath


Binary matrices representing equivalence relations at OEIS.
22 CHAPTER 3. EQUIVALENCE RELATION
Chapter 4

Partial equivalence relation

In mathematics, a partial equivalence relation (often abbreviated as PER, in older literature also called restricted
equivalence relation) R on a set X is a relation that is symmetric and transitive. In other words, it holds for all
a, b, c X that:

1. if aRb , then bRa (symmetry)


2. if aRb and bRc , then aRc (transitivity)

If R is also reexive, then R is an equivalence relation.

4.1 Properties and applications


In a set-theoretic context, there is a simple structure to the general PER R on X : it is an equivalence relation on the
subset Y = {x X|x R x} X . ( Y is the subset of X such that in the complement of Y ( X \ Y ) no element is
related by R to any other.) By construction, R is reexive on Y and therefore an equivalence relation on Y . Notice
that R is actually only true on elements of Y : if xRy , then yRx by symmetry, so xRx and yRy by transitivity.
Conversely, given a subset Y of X, any equivalence relation on Y is automatically a PER on X. Hence, in set theory
one typically studies the equivalence relation associated with a PER, rather than the PER itself.
But in type theory, constructive mathematics and their applications to computer science, constructing analogues of
subsets is often problematic[1] in these contexts PERs are therefore more commonly used, particularly to dene
setoids, sometimes called partial setoids. Forming a partial setoid from a type and a PER is analogous to forming
subsets and quotients in classical set-theoretic mathematics.
Every partial equivalence relation is a difunctional relation, but the converse does not hold.
The algebraic notion of congruence can also be generalized to partial equivalences, yielding the notion of subcongruence,
i.e. a homomorphic relation that is symmetric and transitive, but not necessarily reexive.[2]

4.2 Examples
A simple example of a PER that is not an equivalence relation is the empty relation R = (unless X = , in which
case the empty relation is an equivalence relation (and is the only relation on X )).

4.2.1 Kernels of partial functions


For another example of a PER, consider a set A and a partial function f that is dened on some elements of A but
not all. Then the relation dened by

x y if and only if f is dened at x , f is dened at y , and f (x) = f (y)

23
24 CHAPTER 4. PARTIAL EQUIVALENCE RELATION

is a partial equivalence relation but not an equivalence relation. It possesses the symmetry and transitivity properties,
but it is not reexive since if f (x) is not dened then x x in fact, for such an x there is no y A such that
x y . (It follows immediately that the subset of A for which is an equivalence relation is precisely the subset on
which f is dened.)

4.2.2 Functions respecting equivalence relations


Let X and Y be sets equipped with equivalence relations (or PERs) X , Y . For f, g : X Y , dene f g to
mean:

x0 x1 , x0 X x1 f (x0 ) Y g(x1 )

then f f means that f induces a well-dened function of the quotients X/ X Y / Y . Thus, the PER
captures both the idea of denedness on the quotients and of two functions inducing the same function on the
quotient.

4.2.3 Equality of IEEE oating point values


IEEE 754:2008 oating point standard denes an EQ relation for oating point values. This predicate is symmetrical
and transitive, but is not reexive because of the presence of [NaN] values that are not EQ to themselves.

4.3 References
[1] http://ieeexplore.ieee.org/document/5135/

[2] J. Lambek (1996). The Buttery and the Serpent. In Aldo Ursini, Paulo Agliano. Logic and Algebra. CRC Press. pp.
161180. ISBN 978-0-8247-9606-8.

Mitchell, John C. Foundations of programming languages. MIT Press, 1996.

D.S. Scott. Data types as lattices. SIAM Journ. Comput., 3:523-587, 1976.

4.4 See also


Equivalence relation

Binary relation
Chapter 5

Symmetric relation

In mathematics and other areas, a binary relation R over a set X is symmetric if it holds for all a and b in X that a is
related to b if and only if b is related to a.
In mathematical notation, this is:

a, b X(aRb bRa)

5.1 Examples

5.1.1 In mathematics

is equal to (equality) (whereas is less than is not symmetric)

is comparable to, for elements of a partially ordered set

"... and ... are odd":

25
26 CHAPTER 5. SYMMETRIC RELATION

5.1.2 Outside mathematics

is married to (in most legal systems)

is a fully biological sibling of

is a homophone of

5.2 Relationship to asymmetric and antisymmetric relations


By denition, a relation cannot be both symmetric and asymmetric (where if a is related to b, then b cannot be related
to a (in the same way)). However, a relation can be neither symmetric nor asymmetric, which is the case for is less
than or equal to and preys on).
Symmetric and antisymmetric (where the only way a can be related to b and b be related to a is if a = b) are actually
independent of each other, as these examples show.

5.3 Additional aspects


A symmetric relation that is also transitive and reexive is an equivalence relation.
One way to conceptualize a symmetric relation in graph theory is that a symmetric relation is an edge, with the edges
two vertices being the two entities so related. Thus, symmetric relations and undirected graphs are combinatorially
equivalent objects.
5.4. SEE ALSO 27

5.4 See also


Asymmetric relation

Antisymmetric relation
Commutative property

Symmetry in mathematics

Symmetry
Chapter 6

Tolerance relation

In mathematics, a tolerance relation is a relation that is reexive and symmetric. It does not need to be transitive.

6.1 External links


Gerasin, S. N., Shlyakhov, V. V., and Yakovlev, S. V. 2008. Set coverings and tolerance relations. Cybernetics
and Sys. Anal. 44, 3 (May 2008), 333340. doi:10.1007/s10559-008-9007-y
Hryniewiecki, K. 1991, Relations of Tolerance

FORMALIZED MATHEMATICS, Vol. 2, No. 1, JanuaryFebruary 1991.

28
6.2. TEXT AND IMAGE SOURCES, CONTRIBUTORS, AND LICENSES 29

6.2 Text and image sources, contributors, and licenses


6.2.1 Text
Apartness relation Source: https://en.wikipedia.org/wiki/Apartness_relation?oldid=747411975 Contributors: Zundark, Toby Bartels,
Greenrd, Rich Farmbrough, MarSch, Salix alba, Chris the speller, Cydebot, David Eppstein, U66230200227, Bovineboy2008, Classi-
calecon, Trivialist, Tassedethe, Unzerlegbarkeit, Erik9bot, XxTimberlakexx, I dream of horses, TheHappiestCritic, WebTV3, Bender the
Bot and Anonymous: 5
Binary relation Source: https://en.wikipedia.org/wiki/Binary_relation?oldid=796087488 Contributors: AxelBoldt, Bryan Derksen, Zun-
dark, Tarquin, Jan Hidders, Roadrunner, Mjb, Tomo, Patrick, Xavic69, Michael Hardy, Wshun, Isomorphic, Dominus, Ixfd64, Takuya-
Murata, Charles Matthews, Timwi, Dcoetzee, Jitse Niesen, Robbot, Chocolateboy, MathMartin, Tea2min, Giftlite, Fropu, Dratman,
Jorge Stol, Jlr~enwiki, Andycjp, Quarl, Guanabot, Yuval madar, Slipstream, Paul August, Elwikipedista~enwiki, Shanes, EmilJ, Ran-
dall Holmes, Ardric47, Obradovic Goran, Eje211, Alansohn, Dallashan~enwiki, Keenan Pepper, PAR, Adrian.benko, Oleg Alexan-
drov, Joriki, Linas, Apokrif, MFH, Dpv, Pigcatian, Penumbra2000, Fresheneesz, Chobot, YurikBot, Hairy Dude, Koeyahoo, Trova-
tore, Bota47, Arthur Rubin, Netrapt, SmackBot, Royalguard11, SEIBasaurus, Cybercobra, Jon Awbrey, Turms, Lambiam, Dbtfz, Mr
Stephen, Mets501, Dreftymac, Happy-melon, Petr Matas, CRGreathouse, CBM, Yrodro, WillowW, Xantharius, Thijs!bot, Egrin,
Rlupsa, Marek69, Fayenatic london, JAnDbot, MER-C, TAnthony, Magioladitis, Vanish2, Avicennasis, David Eppstein, Robin S, Akurn,
Adavidb, LajujKej, Owlgorithm, Djjrjr, Policron, DavidCBryant, Quux0r, VolkovBot, Boute, Vipinhari, Anonymous Dissident, PaulTa-
nenbaum, Jackfork, Wykypydya, Dmcq, AlleborgoBot, AHMartin, Ocsenave, Sftd, Paradoctor, Henry Delforn (old), MiNombreDeGuerra,
DuaneLAnderson, Anchor Link Bot, CBM2, Classicalecon, ClueBot, Snigbrook, Rhubbarb, Hans Adler, SounderBruce, SilvonenBot,
BYS2, Plmday, Addbot, LinkFA-Bot, Tide rolls, Jarble, Legobot, Luckas-bot, Yobot, Ht686rg90, Lesliepogi, Pcap, Labus, Nallim-
bot, Reindra, FredrikMeyer, AnomieBOT, Floquenbeam, Royote, Hahahaha4, Materialscientist, Belkovich, Citation bot, Racconish,
Jellystones, Xqbot, Isheden, Geero, GhalyBot, Ernsts, Howard McCay, Constructive editor, Mark Renier, Mfwitten, RandomDSdevel,
NearSetAccount, SpaceFlight89, Yunshui, Miracle Pen, Brambleclawx, RjwilmsiBot, Nomen4Omen, Chharvey, SporkBot, OnePt618,
Sameer143, Socialservice, ResearchRave, ClueBot NG, Wcherowi, Frietjes, Helpful Pixie Bot, Koertefa, BG19bot, ChrisGualtieri,
YFdyh-bot, Dexbot, Makecat-bot, ScitDei, Lerutit, Jochen Burghardt, Jodosma, Karim132, Cosmia Nebula, Monkbot, Pratincola, ,
Neycalazans, Some1Redirects4You, The Quixotic Potato, Luis150902, Magic links bot and Anonymous: 114
Equivalence relation Source: https://en.wikipedia.org/wiki/Equivalence_relation?oldid=801840162 Contributors: AxelBoldt, Zundark,
Toby Bartels, PierreAbbat, Ryguasu, Stevertigo, Patrick, Michael Hardy, Wshun, Dominus, TakuyaMurata, William M. Connolley, AugPi,
Silversh, Ideyal, Revolver, Charles Matthews, Dysprosia, Hyacinth, Fibonacci, Phys, McKay, GPHemsley, Robbot, Fredrik, Romanm,
COGDEN, Ashley Y, Bkell, Tea2min, Tosha, Giftlite, Arved, ShaunMacPherson, Lethe, Herbee, Fropu, LiDaobing, AlexG, Paul Au-
gust, Elwikipedista~enwiki, FirstPrinciples, Rgdboer, Spearhead, Smalljim, SpeedyGonsales, Obradovic Goran, Haham hanuka, Kier-
ano, Msh210, Keenan Pepper, PAR, Jopxton, Oleg Alexandrov, Linas, Apokrif, MFH, BD2412, Salix alba, Alexb@cut-the-knot.com,
Mark J, Epitome83, Chobot, Algebraist, Roboto de Ajvol, YurikBot, Wavelength, RussBot, Nils Grimsmo, BOT-Superzerocool, Googl,
LarryLACa, Arthur Rubin, Pred, Cjfsyntropy, Draicone, RonnieBrown, SmackBot, Adam majewski, Melchoir, Stie, Srnec, Gilliam,
Gelingvistoj, Kurykh, Concerned cynic, Foxjwill, Vanished User 0001, Michael Ross, Jon Awbrey, Jim.belk, Feraudyh, CredoFromStart,
Michael Kinyon, JHunterJ, Vanished user 8ij3r8jwe, Mets501, Rschwieb, Captain Wacky, JForget, CRGreathouse, CBM, 345Kai,
Gregbard, Doctormatt, PepijnvdG, Tawkerbot4, Xantharius, Hanche, BetacommandBot, Thijs!bot, Egrin, Rlupsa, WilliamH, Rnealh,
Salgueiro~enwiki, JAnDbot, Thenub314, Magioladitis, VoABot II, JamesBWatson, MetsBot, Robin S, Philippe.beaudoin, Pekaje, Pomte,
Interwal, Cpiral, GaborLajos, Policron, Taifunbrowser, Idioma-bot, Station1, Davehi1, Billinghurst, Geanixx, AlleborgoBot, SieBot, Bot-
Multichill, This, that and the other, Henry Delforn (old), Aspects, OKBot, Bulkroosh, C1wang, Classicalecon, Wmli, Kclchan, Watch-
duck, Hans Adler, Qwfp, Cdegremo, Palnot, XLinkBot, Gerhardvalentin, Libcub, LaaknorBot, CarsracBot, Dyaa, Legobot, Luckas-bot,
Yobot, Ht686rg90, Gyro Copter, TheresNoTime, Andy.melnikov, ArthurBot, Xqbot, GrouchoBot, Lenore, RibotBOT, Antares5245,
FrescoBot, Sokbot3000, Anthonystevens2, ARandomNicole, Lost-n-translation, Tkuvho, SpaceFlight89, TobeBot, Miracle Pen, Emaus-
Bot, ReneGMata, AvicBot, General Rommel, TyA, Donner60, Gottlob Gdel, ClueBot NG, Bethre, Helpful Pixie Bot, BG19bot, Mark
Arsten, ChrisGualtieri, Rectipaedia, YFdyh-bot, Jochen Burghardt, Rushikeshjogdand1, David9550, Noix07, Adammwagner, Damon-
amc, Superegz, Razvan.belet, InternetArchiveBot, Anareth, Quiddital, Magic links bot and Anonymous: 113
Partial equivalence relation Source: https://en.wikipedia.org/wiki/Partial_equivalence_relation?oldid=794389308 Contributors: Zun-
dark, Charles Matthews, Malcohol, Smimram, Rgdboer, Kierano, Apokrif, Cjoev, Alex Bakharev, AndrewWTaylor, SmackBot, Bluebot,
Alan smithee, J. Finkelstein, Mets501, Blaisorblade, David Eppstein, R'n'B, Functor salad, Palnot, AnomieBOT, Erik9bot, Helpful Pixie
Bot, Some1Redirects4You and Anonymous: 6
Symmetric relation Source: https://en.wikipedia.org/wiki/Symmetric_relation?oldid=794388682 Contributors: Patrick, Looxix~enwiki,
William M. Connolley, Charles Matthews, MathMartin, Tea2min, Giftlite, Elektron, Ascnder, Paul August, Syp, Joriki, Apokrif, Isnow,
Salix alba, Margosbot~enwiki, Fresheneesz, Roboto de Ajvol, Laurentius, Bota47, Arthur Rubin, Incnis Mrsi, Unyoyega, Jdthood, Vina-
iwbot~enwiki, Gregbard, Krauss, Thijs!bot, Mouchoir le Souris, David Eppstein, Jamelan, Henry Delforn (old), ClueBot, Libcub, Addbot,
Luckas-bot, ArthurBot, Xqbot, Adavis444, RedBot, EmausBot, ZroBot, Zap Rowsdower, EdoBot, DASHBotAV, 28bot, Kasirbot, No-
suchforever, Aryan5496, Dualspace and Anonymous: 20
Tolerance relation Source: https://en.wikipedia.org/wiki/Tolerance_relation?oldid=794389477 Contributors: Michael Hardy, Apokrif,
Rjwilmsi, SmackBot, NickPenguin, Floridi~enwiki, Classicalecon, Gabrno, Rektroth and Anonymous: 1

6.2.2 Images
File:Ambox_important.svg Source: https://upload.wikimedia.org/wikipedia/commons/b/b4/Ambox_important.svg License: Public do-
main Contributors: Own work based on: Ambox scales.svg Original artist: Dsmurat, penubag
File:Bothodd.png Source: https://upload.wikimedia.org/wikipedia/commons/d/de/Bothodd.png License: Public domain Contributors:
Own work Original artist: Fresheneesz (talk) (Uploads)
File:E-to-the-i-pi.svg Source: https://upload.wikimedia.org/wikipedia/commons/3/35/E-to-the-i-pi.svg License: CC BY 2.5 Contribu-
tors: No machine-readable source provided. Own work assumed (based on copyright claims). Original artist: No machine-readable author
provided. Dermeister assumed (based on copyright claims).
30 CHAPTER 6. TOLERANCE RELATION

File:Graph_of_non-injective,_non-surjective_function_(red)_and_of_bijective_function_(green).gif Source: https://upload.wikimedia.


org/wikipedia/commons/b/b0/Graph_of_non-injective%2C_non-surjective_function_%28red%29_and_of_bijective_function_%28green%
29.gif License: CC BY-SA 3.0 Contributors: Own work Original artist: Jochen Burghardt
File:Set_partitions_5;_matrices.svg Source: https://upload.wikimedia.org/wikipedia/commons/b/b4/Set_partitions_5%3B_matrices.
svg License: CC BY 3.0 Contributors: Own work Original artist: <a href='//commons.wikimedia.org/wiki/File:Watchduck.svg' class='image'><img
alt='Watchduck.svg' src='https://upload.wikimedia.org/wikipedia/commons/thumb/d/d8/Watchduck.svg/40px-Watchduck.svg.png' width='40'
height='46' srcset='https://upload.wikimedia.org/wikipedia/commons/thumb/d/d8/Watchduck.svg/60px-Watchduck.svg.png 1.5x, https:
//upload.wikimedia.org/wikipedia/commons/thumb/d/d8/Watchduck.svg/80px-Watchduck.svg.png 2x' data-le-width='703' data-le-
height='806' /></a> Watchduck (a.k.a. Tilman Piesk)
File:Wiki_letter_w_cropped.svg Source: https://upload.wikimedia.org/wikipedia/commons/1/1c/Wiki_letter_w_cropped.svg License:
CC-BY-SA-3.0 Contributors: This le was derived from Wiki letter w.svg: <a href='//commons.wikimedia.org/wiki/File:Wiki_letter_w.
svg' class='image'><img alt='Wiki letter w.svg' src='https://upload.wikimedia.org/wikipedia/commons/thumb/6/6c/Wiki_letter_w.svg/
50px-Wiki_letter_w.svg.png' width='50' height='50' srcset='https://upload.wikimedia.org/wikipedia/commons/thumb/6/6c/Wiki_letter_
w.svg/75px-Wiki_letter_w.svg.png 1.5x, https://upload.wikimedia.org/wikipedia/commons/thumb/6/6c/Wiki_letter_w.svg/100px-Wiki_
letter_w.svg.png 2x' data-le-width='44' data-le-height='44' /></a>
Original artist: Derivative work by Thumperward

6.2.3 Content license


Creative Commons Attribution-Share Alike 3.0