0% found this document useful (0 votes)
66 views24 pages

Relation: Learning Outcomes

This document defines and provides examples of relations and different ways to represent relations visually. A relation R between sets A and B is a subset of the Cartesian product A x B. Relations can be represented using coordinate grid diagrams, directed graphs, and binary matrices. Coordinate grid diagrams plot the related pairs as points on a grid. Directed graphs draw arrows between related elements. Binary matrices use 1s and 0s to indicate whether pairs are related or not. The document provides examples of different types of relations and represents them in these three formats.

Uploaded by

Roshan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
66 views24 pages

Relation: Learning Outcomes

This document defines and provides examples of relations and different ways to represent relations visually. A relation R between sets A and B is a subset of the Cartesian product A x B. Relations can be represented using coordinate grid diagrams, directed graphs, and binary matrices. Coordinate grid diagrams plot the related pairs as points on a grid. Directed graphs draw arrows between related elements. Binary matrices use 1s and 0s to indicate whether pairs are related or not. The document provides examples of different types of relations and represents them in these three formats.

Uploaded by

Roshan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 24

CHAPTER 2

l RELATION

CHAPTER 2 Relation

LE AR NI NG OUTCOMES
By the end of this chapter, you should be able to:

1. Describe the concepts of relation, inverse relation, composition of relations,


relation on a set and digraph; and

2. Determine partial order and equivalence relation.

i. 25
RELATION l CHAPTER 2

INTRODUCTION
The relation concept is similar to the ‘family tree’. One member of the family is possibly
related to members of another family.

Source: http://www.personalized-creations.com/Family_Tree_Of_Life-3-d-Lg.jpg
http://www.theartfulstencil.com/images/FAML01family-tree-1-3.jpg

The mathematical notion of a relation such as the set theory is very general. It is one of
the key concepts of mathematics and the examples of relations occur throughout the subject.

Three special types of relation that are particularly important will be discussed in this
chapter: relation, digraph, equivalence relations, and order relations. We begin with
a look at the general concept of a relation and the various ways of visualizing relations.

2.1 Concept of Relation


The following mathematical definition of a ‘relation’ is surprisingly simple and very
general. Some authors refer to this as a binary relation because it relates two objects
whereby there is a generalisation of this which relates n objects.

Let A and B be sets. A relation from A to B (or between A and B) is a subset


of the Cartesian product A×B

The first important thing to describe a relation is a set; namely a set of ordered pairs.
If is a relation from to, we say that a ∈ A is related to b ∈ B if (a, b) ∈ R. Therefore, the

26
CHAPTER 2 l RELATION

relation R is simply the set of all related pairs of elements.

For the most part, we shall adopt the commonly used notation and write (a R b) to denote ‘a
is related to b’ and (a b) to denote (a, b) ∉ R or ‘a is not related to b’. If we define A = B,
then it will also refer to R as a relation on A.

Example 2.1a

Let A={cities of the world}, B={countries of the world} and R={(a,b): a is the
capital city of b}. Thus, (a R b) denotes ‘a is the capital city of b’. Examples are:
(Paris) R (France), (Moscow) R (Russia), (Tirana) R (Albania), etc. Also we
have:(London) (Zimbabwe), (Naples) (Italy), (New York) (United States),
etc.

Let A=B={1,2,3,4,5,6} and R={(a,b): a divides b}. Since R consists a small finite
set, we can list the elements of the relation. R={(1, 1), (1, 2), (1, 3), (1, 4), (1,
5), (1, 6), (2, 2), (2, 4), (2, 6), (3, 3), (3, 6), (4, 4), (5, 5), (6, 6) }. We can
represent R diagrammatically as shown in Figure 2.1 by plotting its elements on
the coordinate grid diagram of the Cartesian product A×B=A2.

A×A
7

A 4

1
2 3 4 5 6
A

Figure 2.1: Relation diagram

i. 27
RELATION l CHAPTER 2

Example 2.1b

i) Let A=B=Z+, the set of positive integers, and let (a R b) denote ‘a has the
same parity as b’; that is, either a and b are both even or they are both odd.
More precisely, R={(a,b): a–b is an integer multiple of 2. Thus,

1 R 1, 1 R 3, 1 R 5,…
2 R 2, 2 R 4, 2 R 6,…
3 R 1, 3 R 3, 3 R 5,…
R 2, 4 R 4, 4 R 6,…

ii) A picture for this relation is shown in Figure 2.2, where again we have plotted
the elements of R on the diagram for A×B.
Z+ × Z+
7

Z+ 4

1
1 2 3 4 5
Z+

Figure 2.2: Relation diagram R

There are various ways of representing relations visually, particularly relations between fi-
nite sets. In Figure 2.1 and Figure 2.2, the elements of R are marked on the coordinate grid
diagram of the Cartesian product A × B. It shows clearly R as a subset of A × B, but not
so good at showing the additional properties of the relation.

Alternatively, the finite sets are used to represent A and B as two side-by-side Venn dia-
grams with the elements arranged vertically as shown in Figure 2.3. An arrow is drawn from
(a ∈ A) to (b ∈ B) whenever (a R b). We refer to this as the arrow in Figure 2.3 as a
diagram of the relation. For example, the arrow diagram for the relation defined
in the Example 2.1b (ii) above is given in Figure 2.3.

28
CHAPTER 2 l RELATION

A B Unfortunately, Figure 2.3 does not show


very clearly, at a glance, which elements
are related to which number. For sets
1 1
larger than {1, 2, 3, 4, 5, 6}, diagrams
2 2 of this type would become too cluttered
and difficult to be used for illustrating
3 3 the relations between sets. However, for
relations on a set (i.e., where A = B),
4 4
there is a slight modification we can do
5 5 in order to clarify the diagram. Instead
of listing the elements of A twice, once
6 6 in each Venn diagram, we can represent
each element of A once by a point in the
Figure 2.3: Arrow diagram of relation plane as shown in Figure 2.2.

A directed arrow is still drawn from a to b if and only if a R b as shown in Figure 2.4
below. It shows an example of a directed graph or digraph and is called the directed graph
of the relation. If two elements a and b are such that (a R b) and (b R a), we will
usually connect their points in the directed graph by a single bi-directional arrow,
rather than two directed arrows. Further details of graph theory are discussed in Chapter 12.

6
5

2 3

Figure 2.3: Arrow diagram of relation

A third way to represent a relation is by a ‘binary matrix’. Let A = {a1, a2, ..., an} and B =
{b1, b2, ..., bn} be finite sets and let R be a relation from A to B. We defined the binary
matrix of R as a rectangular array of zeros and ones with n rows and m columns. The
rows correspond to the elements of A (in the order listed above) and the columns correspond
to the elements of B (again, in the order listed above) as shown in Figure 2.5. At the
intersection of the ith row jth column, we place a one if (ai R bj) or a zero if (ai bj).

i. 29
RELATION l CHAPTER 2

b1=1 b2=2 b3=3 b4=4 b5=5 b6=6

a1=1 1 1 1 1 1 1
a2=2 0 1 0 1 0 1
a3=3 0 0 1 0 0 1
a4=4 0 0 0 1 0 0
a5=5 0 0 0 0 1 0
a6=6 0 0 0 0 0 1

Figure 2.5: Binary matrix representing relation R

For example, the binary matrix representing the relation R on A = {1, 2, 3, 4, 5, 6} given
by (a R b) if and only if a divides b is shown in Figure 2.5 for Example 2.1b (ii).

1. For each of the following relations R on a set A draw its coordinate


grid diagram, directed graph, and binary matrix.
(a) A = {1, 2, 3, 4, 5, 6, 7, 8}; (a R b) if and only if a < b.
(b) A = {1, 2, 3, 4, 5, 6, 7, 8}; (a R b) if and only if a / b ∈ Z.
(c) A = {1, 2, 3, 4, 5, 6, 7, 8}; (a R b) if and only if a = 2b.
(d) A = ℘ {1, 2, 3}, the power set of {1, 2, 3}; (a R b) if and only if a ⊆
b.
(e) A = ℘ {1, 2, 3}, the power set of {1, 2, 3}; (a R b) if and only if a ⊂
b.

2. The binary matrices MR and MS for two relations R and S, respectively on


the set A = {1, 2, 3, 4, 5} are given below.

0 0 0 0 0 1 1 1 1 1
1 0 1 0 1 0 0 0 0 0
MR = and, MS =
1 1 0 1 0 1 1 1 0 0
1 1 1 0 1 1 0 0 1 1
1 0 0 1 0 0 0 0 0 0
Variable

(a) List the elements of R and S.


(b) Draw the directed graph of R and S.
Experiment

30
CHAPTER 2 l RELATION

3. A relation R between the sets A = {1, 2, 3} and B = (A) = {Ø, {1}, {2},
{3}, {1, 2}, {2, 3}, {1, 3}, {1, 2, 3}} has the following binary matrix.
(The rows and columns of the matrix correspond to the elements of
A and B as they are listed respectively).

0 1 0 0 1 0 1 1
0 0 1 0 1 1 0 1
0 0 0 1 0 1 1 1

List the elements of R and define (a R b) in words or symbols.

2.2 Inverse Relation

Let R be a relation which is a subset of the set of all pairs


{(x, y) | x belongs to x and y belongs to y }.

The inverse relation R -1


of R is the set {(y, x) | (x, y) belongs to R }.

Let we define R as a relation of the domain X with the range Y. So R is a set of pairs (x, y)
where x is an element of X and y is an element of Y. The inverse relation R−1 of R is the
set pairs (y, x) which are obtained from the pairs (x, y) in R by interchanging x and y.

If R = {(1, r), (1, s), (3, s)}, then R−1= {(r, 1), (s, 1), (3, s)}. If R is the relation {(x, y): y is the
husband of x}, then R−1 is the relation {(x, y): y is the wife of x}. If R is the relation {(x, y): y is
the cousin of x} or R is the relation {(x, y): x² + y²}, then R−1= R.

Inverse should not be confused with complement: For instance, if R is the relation “being
a son or daughter of”, then R−1 is the relation “being a parent of”.

i. 31
RELATION l CHAPTER 2

Types of2.2
Example Data Definition

Let us consider the relation R = {(2, 3), (4, 5), (1, 5), (3, 4)}.

Therefore, the inverse relation is the set R- 1 = {(3, 2), (5, 4), (5, 1), (4, 3)}.

Let us also notice that the domain of R = {2, 4, 1, 3} and the range of R = {3, 5, 4}
but the domain of R- 1 = {3, 5, 4} and the range of R- 1 = {2, 4, 1, 3}.

Given a relation R from a set A to set B, its inverse relation R−1 is the relation
from B to A defined by

x R−1 y if and only if y R x

(a) Let A = {1, 2, 3, 4} and let R be the relation on the A defined by R = {(1,
2), (1, 4), (2, 2), (2, 3), (3, 4), (4, 3), (4, 4)}
i. List the elements of R−1.
ii. Draw the directed graphs of both R and R−1.
iii. Write down the binary matrices of both R and R−1.

(b) Let R be a relation on a set A.


i. Describe the connection between the directed graphs of R and its
inverse R−1.
ii. Describe the connection between the binary matrices of R and its
inverse R−1.

2.3 Composition of Relations

Let R A×B be a relation from A to B and S B×C be a relation from B to


C. The composition of S and R is the relation T A×C defined by
T={(a,c): there is an element b of B such that (a,b) R and (b,c) S}.
This set is denoted by T=S R.

32
CHAPTER 2 l RELATION

The notation (S º R) may be read as “S composed with R” or “S circle R”. The relation S to R
is only defined if the types of S and R match up. For example, we can define the set
grandparent = parent º parent by:

where x is grandfather of y if there exists z.

Example 2.3a
Let R = {(1, 2), (2, 3), (3, 4), (4, 1)}, S = {(1, 2), (2, 1), (3, 4), (4, 3)}

Then;

R S = {(1, 1), (2, 4), (3, 3), (4, 2)}


S R = {(1, 3), (2, 2), (3, 1), (4, 4)}

Example 2.3b

If R is the relation “to be the father of”, and S is the relation “to be married to”, then
S R is the relation “to be the father in law of”.

i. 33
RELATION l CHAPTER 2

Example 2.3c
Let A={1,2,3}, B={x,y}, and C={ , , , }, and let the relations R A×B and
S B×C be given by

R={(1,x),(1,y),(3,x)}
S={(x, ),(x, ),(y, ),(y, )}

Then

S R={(1, ),(1, ),(1, ),(1, ),(3, ),(3, )}

Since

(1,x) R and (x, ) S imply that (1, ) S R


(1,x) R and (x, ) S imply that (1, ) S R
(1,y) R and (y, ) S imply that (1, ) S R

(3,x) R and (x, ) S imply that (3, ) S R

2.4 Relation on a Set

In order to prove that a relation R on a set A will satisfy one of these four properties,
we need to show that the appropriate property is satisfied by an arbitrary element
or elements of A. For example, to prove that R is symmetric, we need to show that
(a R b) → (b R a), for arbitrary elements a, b ∈ A. In order to show that R does not
satisfy one of the properties, we need to find a particular element or elements of A
that show this. For example, to show that R is not symmetric, we need to find
particular elements a, b ∈ A such that (a R b) but (b a).

34
CHAPTER 2 l RELATION

Example 2.4a
Example 2.4a

Let R be the relation on the set of real numbers defined by:

(x R y) if and only if x y

Then;

i. R is reflexive because x x for every x R;


ii. R is not symmetric because, for example, 1=2 but 2 1, so (x R y) does not imply (y R x);
iii. R is anti-symmetric; if x y and y x then it follows that x = y;
iv. R is transitive because if x y and y z then it follows that x z.

Example 2.4b
Let A= Z+×Z+ and R be the relation on A defined by (a,b) R (c,d) if and only if
((a+d)=(b+c) ). Your task is to show that R is reflexive, symmetric, and
transitive, but not anti-symmetric. The solution,

i. For all positive integers a and b, ((a+b)=( b+a) ), so (a,b) R (a,b)


for every (a,b) A. Therefore R is reflexive.
ii. R is symmetric since if (a,b) R (c,d) then ((a+d)=(b+c)) which
implies that ((c+b)=(d+a) ), so (c,d) R (a,b).
iii. To show that R is transitive, suppose (a,b) R (c,d) and (c,d) R (e,f).
This means that

((a+d)=(b+c)) and ((c+f)=(d+e))

Adding these equations gives

a+d+c+f=b+c+d+e

So

a+f=b+e

Which means that (a,b) R (e,f). Therefore (a,b) R (c,d) and (c,d) R (e,f) implies
that (a,b) R (e,f), so R is transitive.

iv. Finally, in order to show that R is not anti-symmetric, we have to find a


counter-example; that is we need to find elements (a,b) and (c,d) of A such
that (a,b) R (c,d) and (c,d) R (a,b) but (a,b) (c,d).

i. 35
RELATION l CHAPTER 2

Example 2.4c

Let A = {a,b,c,d} and R = {(a, a), (a, b), (a, c), (b, a), (b, b), (b, c), (b, d), (d, d)}.
Then;

i. R is not reflexive since (c R c); therefore it is not true that (x R x) for every
x A;
ii. R is not symmetric since, for example, (a R c) but (c R a);
iii. R is not anti-symmetric since (a R b) and (b R a) but a b;
iv. R is not transitive since (a R b) and (b R d) but (a R d).

Example 2.4d

Consider the directed graph given in Figure 2.6 of a relation R on the set A
= {a, b, c, d, e}.

A
E

B
D

Figure 2.6: Directed graph of relation R

From Figure 2.6, we can see that:


i. R is not reflexive, since there is no arrow from c to itself, for example.
ii. R is symmetric, but not anti-symmetric because every arrow connecting
distinct points is bidirectional.
iii. R is not transitive as, there are arrows from a to d, and from d to b, but not
from a to b.

36
CHAPTER 2 l RELATION

Example 2.4e
A relation R on a four-elements set A has the following binary matrix:.

1 0 1 0
A= 1 1 0 0
0 0 1 1
0 1 0 1
Which of the properties does R satisfy? Solution,

i. Firstly, it is clear that R is reflexive since there are only ones along the
leading diagonal.
ii. R is not symmetric because the matrix is not symmetric about the leading
diagonal. In our case, there is a one in row 1, column 3, but a zero in row
3, column 1.
iii. R is anti symmetric; except for the leading diagonal wherever a one
appears in row i, column j, a zero appears in row j, column i. Note that
sometimes the value of zero may appear in both these places, for example,
in row 1, column 4 and row 4, column 1.
iv. R is not transitive. If we label the elements of the set a1,a2,a3,a4, in that
order, then a1 R a3 and a3 R a4 but a1 R a4. We leave it as an exercise to
discover whether there are any other counter-example to transitivity.

1. Let A = {a, b, c, d, e}. For each of the following relations R on A, determine


which of the four properties (reflexive, symmetric, anti-symmetric, transi-
tive) are satisfied by the relation. Justify your answer.

(a) R = {(a, a), (b, b), (c, c), (d, d), (e, e), (a, b), (b, c)}
(b) R = {(a, a), (a, d), (b, b), (c, c), (d, d), (d, e), (e, a), (e, e)}

2. For each of the following relations, determine which of the four


properties are satisfied by the relation. Justify your answers.

(a) A = {1, 2, 3, 4, 5, 6, 7, 8}, n R m if and only if n ≤ m.


(b) A = ℘ ({1, 2, 3}), B R C if and only if B ⊆ C.

Let A be any non-empty set and R = Ø be the empty relation on A. Which,


if any, of the four properties defined in definitions 2.4a is/are satisfied by R?
If A itself is empty, what are the properties to be satisfied?

i. 37
RELATION l CHAPTER 2

2.5 Digraph

In the case where R is a binary relation on A, we can also use a directed graph or digraph,
which consists of a set of nodes corresponding to the elements in A, joined by arrowed lines
indicating the relationship between the elements. For example, let A = {a1, a2, a3, a4} and R =
{(a1, a2); (a2, a1); (a3, a2); (a3, a3);}. The directed graph of this relation is shown in Figure 2.7.

A
a1

a4 a2

a3

Figure 2.7: Digraph of relation

Notice that the direction of the arrows matters. It is, of course, still possible to use
a diagram where the source and target sets are drawn separately as in Figure 2.2.

2.6 Partial Order

A partial order on a set is a relation which is reflexive, anti-symmetric, and


transitive. A set together with a partial order is called a partially ordered set or,
somewhat less elegantly, a poset.

38
CHAPTER 2 l RELATION

Example 2.6a

The ‘divisibility’ relation on the set of positive integers Z+, defined by (n R m) if and
only if n divides m, is a partial order. (Note: n divides m is frequently written n / m.)

Example 2.6b

The relation on the set of English words defined by ‘the word w1 is related to the
word w2 if w1=w2 or w1 comes before w2 in a dictionary’ is a partial ordering.
Normally, the ordering of words is usually in alphabetical order.

The next theorem says that any subset of a partially ordered set is automatically a
partially ordered set. It gives a way of generating many more examples of
partially ordered sets. We include the proving of the theorem in the exercise.

Let R be a partial order on a set A, and let B be any subset of A. Then:

S=Rn (B×B) is a partial order on B.

Although the definition of the relation S looks somewhat technical, it is the obvious relation
on B. For b1, b2 ∈ B, we have (b1 S b2) if and only if b1 R b2. Therefore, elements of B are
related by S is exactly the same way as they are related by R, when we consider them
as elements of A. This relation S is called the restriction of R to B, and we say that
B inherits the relation S from the relation R on A.

Let R be a partial order on a set A. The greatest element of A (if it exists) is


the element a such that (a R a ) for every (a A). Similarly, the least element
of A (if it exists) is the element ß such that (ß R a) for every (a A).

Returning to the example of the proper subsets of {a, b, c} ordered by inclusion, we can
verify that there is no greatest element according to our definition. However, each of the
two-element subsets can be regarded as the ‘largest possible’ in the sense that there
are no subsets which are ‘bigger’ than these. We formalise this idea in the definition of
‘maximal’ elements.

i. 39
RELATION l CHAPTER 2

Let A be a poset, with order relation R. An element x of A is maximal if, for


every (a A), (x R a) implies (x=a). Similarly, an element y is minimal if, for
every (a A), (a R y) implies (a=y).

If we regard (a R b) as meaning ‘a is less than or equal to b’ in whatever sense, then an


element is maximal if there is no ‘greater’ element in the set, i.e. the element is related
only to itself. Similarly an element is minimal if there is no ‘smaller’ element in the set,
i.e. no other element is related to it.

Example 2.6c

Consider again the proper subsets of {a,b,c} ordered by inclusion. In this case,
there are three different maximal elements {a,b}, {b,c}, and {a,c}. There is a
single minimal element, namely the least element Ø.

Example 2.6d

Let A = {2,3,4,5,6,7,8}, ordered by divisibility: (x R y) if and only if x divides y.


There are four minimal elements, 2, 3, 5 and 7. If a divides 2, where (a A), then
(a=2); and similarly for 3, 5 and 7. The elements 5, 6, 7 and 8 are all maximal.
For (a A), if 5 divides a then a=5; and similarly for 6, 7 and 8.

Note that, with this ordering, A has no greatest or least element. Clearly, the only
candidates for a least element are the minimal elements, none of which is the
least element. For example, since (2 3) it is not true that (2 R a) for every
(a A), so 2 is not the least element. Also (3 2), (5 2) and (7 2) so neither 3
nor 5 nor 7 is the least element. Similar remarks apply to the maximal elements,
so there is no greatest element.

We have seen that a partially ordered set may have several minimal and/or maximal
elements. It can, however, have at most one greatest element and at most one least
element. That is, if a poset A has a greatest element α, then α is unique; and similarly for
a least element β. (We have, in fact, been tacitly assuming this by referring to the greatest
and least elements.) It is easy to see, for example, that A has at most one least element:
suppose β and β’ are two least elements. Then (β R β’) since β is a least element, and
(β’ R β), since β’ is a least element. Therefore, (β = β’) (by anti-symmetry), so there is only
one least element. The same kind of argument clearly works for the greatest element as well.

40
CHAPTER 2 l RELATION

The following theorem clarifies the connection between least and minimal elements and
between greatest and maximal elements.

Let A be a poset with partial order relation R. If A has a greatest element a,


then a is maximal and there are no other maximal elements. Similarly, if A has
a least element ß, then ß is minimal and there are no other minimal elements.

We prove the proposition for the greatest element only; the proof for the least element is
similar.

Let α be the greatest element and suppose (α R a) where a ∈ A. Since α is the greatest
element, we also know that (a R α). Therefore (a = α), by the anti-symmetric property, so
α is a maximal element.

Suppose, now, that x is a maximal element. Since α is the greatest element, we have (x R α).
By the maximal property of x, this implies (x = α), so α is the only maximal element.

We have seen that, in a partially ordered set, there may be elements a and b such that
neither (a R b) nor (b R a). For our most familiar order relation, ≤ on ℝ, this cannot occur.
A partial order such as this, where every pair of elements is related (at least one way round),
is called a ‘total order’.

A total order (or linear order) on a set A is a partial order R which satisfies
the following dichotomy law. For every pair a, b A, either (a R b) or (b R a)
(or both).

Note that there is a certain amount of redundancy in the definition of a total order,
in that the reflexive condition (which is included in the statement that R is a partial
order) follows from the dichotomy law. This is because if we let b = a, then this
last condition implies (a R a) for every a ∈ A. Thus, a total order could be defined
slightly more efficiently as a relation which is anti-symmetric, transitive, and
satisfies the dichotomy law.

i. 41
RELATION l CHAPTER 2

Example 2.6e

The relation on R is a total order. Any subset of a totally ordered set is also
totally ordered by the same relation (exercise: prove this). Thus the relation is a
total order on any set of real numbers.

Example 2.6f

Let R be the relation on R2 defined by (x1,y1) R (x2,y2) if and only if (x1 x2) and
(y1 y2). Again, we leave it as an exercise to show that R is a partial order. It is
not, however, a total order because, for example, (0,1) and (1,0) are not related.

1. Verify that the divisibility relation, (n R m) if and only if n divides m,


n/m, is a partial order on the set of positive integers.
What is the least element?

2. Show that the relation R on the plane ℝ² defined by (x1, y1) R (x2, y2)
if and only if (x1 ≤ x2) and (y1 ≤ y2) is a partial order.

3. More generally, show that if R is a partial order on a set A, then the


relation R × R defined by (x1, y1)(R × R)(x2, y2) if and only if
(x1 R x2) and (y1 R y2) is a partial order on the Cartesian product A × A.

4. Let A be a set of people. Under what circumstances does the relation


defined by (x R y) if and only if is younger than or the same age as
define a partial order on A? (Assume, say, that age is measured to the
nearest day.) In the situation where R is a partial order, show that it is
in fact a total order, and describe the greatest and least elements.

5. Let A be a poset with order relation R, and let a1, a2, ..., an be elements of
such that (a1 R a2), (a2 R a3),..., (an-1 R an), (an R a1). Show that a1 = a2 = ... =
an.

42
CHAPTER 2 l RELATION

2.7 Equivalence Relation

One of the most important types of relation is an equivalence relation on a set. In this sec-
tion, we define the notion of an equivalence relation and explore the close connection
between equivalence relations and partitions of a set.

Consider the relation R on the set of living people defined by: (x R y) if and only if x
resides in the same country as y. Assuming each person is resident in only one country,
the relation satisfies three obvious properties:
i. x resides in the same country as x; that is, R is reflexive;
ii. if x resides in the same country as y, then y resides in the same country as x; that is,
R is symmetric;
iii. if x resides in the same country as y, and y resides in the same country as z, then
x resides in the same country as z; that is, R is transitive.
Any given element x is related to everyone who lives in the same country as x and to
no one else. Therefore, the relation subdivides the set of living people into subsets
according to their countries of residence. This is an example of an equivalence relation,
which we now define formally.

A relation R on a set A is an equivalence relation if R is reflexive,


symmetric, and transitive.

Example 2.7a

Let A=R the set of real numbers, and define a relation R on A by


(x R y) if and only if (x2 = y2 ).

Then;

i. R is reflexive since (x2 = x2 ) for every real number x;


ii. R is symmetric since (x2 = y2 ) implies (y2 = x2 );
iii. R is transitive since (x2 = y2 ) and (y2 = z2 ) implies (x2 = z2 ).

i. 43
RELATION l CHAPTER 2

Example 2.7b

Let A=R2-{(0,0)}, the set of points in the plane except the origin, and define a
relation R on A by ((a,b) R (c,d)) if and only if (a,b) and (c,d) both lie on the same
straight line through the origin.

Clearly, R is both reflexive and symmetric. Also, it is not difficult to see that R is
transitive: if (a,b) and (c,d) both lie on the same straight line through the origin,
and similarly (c,d) and (e,f) both lie on the same straight line through the origin,
then so, too, do (a,b) and (e,f). Therefore, R is an equivalence relation.

Example 2.7c

Let A=Z, the set of integers, and define a relation R on A by (n R m) if and only if
n=2k m for some integer k. Show that R is an equivalence relation. Solution is,

i. Firstly, R is reflexive since n=20 n for every integer n.


ii. Secondly, if n=2k m then m=2-k n so (n R m) implies (m R n); therefore R
is symmetric.

Thirdly, suppose (n R m) and (m R p); then there exist integers k and l such that
n=2k m and m=2l p. Combining these two equations gives n=2k 2l p=2k+pp where
k+l is an integer. Thus, (n R m) and (m R p) implies (n R p), so R is transitive.

Example 2.7d

Consider the relation R defined on Z+ by (n R m) if and only if n divides m. R is not


an equivalence relation. To show this, we only need to show that one of the three
properties is not satisfied by R. Clearly, R is not symmetric since, for example, 2
divides 4 but 4 does not divide 2. (Note, however, that R is both reflexive and
transitive. In fact R is also anti-symmetric because if n divides m and m divides n
then n=m. Of course, these facts are not important in showing that R is not an
equivalence relation.)

44
CHAPTER 2 l RELATION

Let R be an equivalence relation on a set A, and let x A. The equivalence class


of x, denoted [x], is the set of all elements of A to which x is related:

[x] = {y A: (x R y)}

Note that, since R is symmetric, the equivalence class of x is also equal to {y ∈ A :


(y R x)}. In other words, the equivalence class of x can equally well be defined either
as the set of elements that are related to x or as the set of elements to which x is
related. Sometimes, if we need to emphasise the relation R, we refer to the
R -equivalence class of x which we denote by [x]R.

Example 2.7e

Let R be the equivalence relation on Z+ by (n R m) if and only if n-m is divisible by 2.


Then:

[1] = {1, 3, 5, 7, 9, . . .}
[2] = {2, 4, 6, 8, 10, . . .}
[3] = {1, 3, 5, 7, 9, . . .}
[4] = {2, 4, 6, 8, 10, . . .} etc.

In this example, there are clearly only two different equivalence classes—the sets of
even and odd positive integers respectively. Note that these two equivalence classes
form a partition of Z+.

Example 2.7f

Let R be the equivalence relation defined on the set of integers Z by (n R m) if and


only if n2=m2. For each integer n, only (n R n) and (n R (-n)), so the equivalence
class of n contains two integers, namely n and its negative:

[n]={n,-n}.

There is one exception: since 0 equals its negative, the equivalence class of 0
contains only itself, [0] = {0}.

i. 45
RELATION l CHAPTER 2

1. A relation R on the set of integers ℤ is defined by (n R m) if and


only if |n| = |m|. Show that R is an equivalence relation and determine
the corresponding equivalence classes.

2. Verify that each of the following are equivalence relations on the


plane ℝ² and describe the equivalence classes:

(a) ((x1, y1) R (x2, y2)) if and only if x1 = x2.


(b) ((x1, y1) R (x2, y2)) if and only if x1 + y1 = x2 + y2.
(c) ((x1, y1) R (x2, y2)) if and only if x1² + y1² = x2² + y2².

3. A relation R on ℤ+ × ℤ- is defined by

((m, n) R (p, q)) if and only if m + q = n + p.

Show that R is an equivalence relation and describe the equivalence


classes of (1, 1), (2, 1), (3, 1), (1, 2) and (1, 3). How are the set of
equivalence classes and the set of integers related?

4. Verify that (x R y) if and only if (x - y) ∈ ℤ defines an equivalence


relation on the set ℚ of rational numbers. Describe the equivalence
classes of 2, ¼ and -¼.

5. How many different equivalence relations are there on the sets (i)
{a, b, c}, and (ii) {a, b, c, d}?

46
CHAPTER 2 l RELATION

SUMMARY

1. This chapter discusses the concept of relation, inverse relation, composition


of relations, relations on a set, and digraph. It covers topics related to partial
order and equivalence relation. You should be able to, at the end of this chapter,
give the definition of relation such as

• inverse relation,
• composition of relations,
• relation on a set,
• digraph,
• partial order, and
• equivalence relation.

Glossary

(a R b) a is related to b by the relation R

(a b) anti symmetric if (a R b) then (a b)

R- inverse relation of R

SºR composition of relations S and R

(S, ≤) partially ordered set with ordering ≤

Ø empty set

i. 47
RELATION l CHAPTER 2

ℝ set of real number

ℤ+ set of positive integers

ℤ- set of negative integers

REFERENCES

Bernard K., & Robert, C. B. (1987). Discrete Mathematical Structure for Computer
Science. New Jersey, USA: Prentice Hall, Inc. Englewood Cliffs.

Garnier, R., Taylor, J. (2001). Discrete Mathematics for New Technology. United
Kingdom: Institute of Physics Publishing.

Goodaire, E. G., & Parmenter, M. M. (2006). Discrete Mathematics with Graph


Theory. New Jersey, USA: Prentice Hall PTR Upper Saddle River.

Rosen, K. H. (1999). Discrete mathematics and its applications. New York: McGraw-
Hill.

V, Borschev., & B, Partee. (2001). Linguistic 726: Mathematical Linguistics, Lecture 1.


Retrieved May 27, 2009, from University of Massachusetts, Amherst.
Web site: http://www.people.umass.edu/partee/726_01/lectures.html

48

You might also like