Relation

**Operations on Relations**

### Subjects to be Learned

- set operations on relation
- composite relation
- properties of composite relation
- powers of relation

### Contents

**Set Operations**

A relation is a set. It is a set of ordered pairs if it is a binary relation,
and it is a set of ordered *n*-tuples if it is an *n*-ary relation.
Thus all the set operations apply to relations such as
,
,
and complementing.

For example, the union of the "less than" and "equality" relations on the set of
integers is the "less than or equal to" relation on the set of integers.
The intersection of
the "less than" and "less than or equal to" relations on the set of integers is
the "less than" relation on the same set. The complement of the "less than"
relation on the set of integers is the "greater than or equal to" relation on the
same set.

**Composite Relations**

If the elements of a set *A* are related to those of a set *B*, and those of
*B*
are in turn related to the elements of a set *C*, then one can expect a relation
between *A* and *C*. For example, if Tom is my father(parent-child relation)
and Sarah is a sister of Tom (sister relation),
then Sarah is my aunt (aunt-nephew/niece relation). Composite relations give that kind of relations.

**Definition(composite relation):**
Let *R*_{1} be a binary relation from a set *A* to a set *B*,
*R*_{2} a binary
relation from *B* to a set *C*. Then the **composite
relation** from *A*
to *C* denoted by
*R*_{1}R_{2}(also denoted by
*R*_{1}
R_{2} is defined as

*R*_{1}R_{2} =
{*<a, c>* |
*a*
*A*
*c*
*C*
*b* [*b*
*B*
*<a, b>*
*R*_{1}
*<b, c>*
*R*_{2} ] } .

In English, this means that an element *a* in *A* is related to an element *c* in
*C*
if there is an element *b* in *B* such that *a* is related to
*b* by *R*_{1}
and *b* is related to *c* by *R*_{2} .
Thus *R*_{1}R_{2} is a relation from *A* to *C* via
*B* in a sense. If *R*_{1} is a parent-child relation and
*R*_{2} is a sister relation, then *R*_{1}R_{2} is an
aunt-nephew/niece relation.

**Example 1:** Let
*A* = {*a*_{1} , a_{2}} , *B* = {*b*_{1} , b_{2} ,
b_{3}} , and *C* = {*c*_{1} , c_{2}} . Also let
*R*_{1} =
{*<a*_{1} , b_{1}> , *<a*_{1} , b_{2}> ,
*<a*_{2} , b_{3}> } ,
and
*R*_{2} =
{*<b*_{1} , c_{1}> , *<b*_{2} , c_{1}> ,
*<b*_{2} , c_{2}> , *<b*_{3} , c_{1}> } .
Then
*R*_{1}*R*_{2} =
{*<a*_{1} , c_{1}> , *<a*_{1} , c_{2}> ,
*<a*_{2} , c_{1}> } .

This is illustrated in the following figure. The dashed lines in the figure of *R*_{1}R_{2}
indicate the ordered pairs in *R*_{1}R_{2}, and dotted lines show ordered
pairs that produce the dashed lines. (The lines in the left figure are all supposed to be solid lines.)

**Example 2:** If *R* is the parent-child relation on a set of people *A*,
then *RR*, also denoted by *R*^{2}, is the grandparent-grandchild relation on *A*.

**More examples:**

The digraphs of *R*^{2} for several simple relations *R* are shown below:

**Properties of Composite Relations**

Composite relations defined above have the following properties.
Let *R*_{1} be a relation from *A* to *B*, and
*R*_{2} and *R*_{3} be relations
from *B* to *C*. Then
1. *R*_{1}(*R*_{2}R_{3}) = (*R*_{1}*R*_{2})R_{3}

2. *R*_{1}(*R*_{2}
*R*_{3}) =
*R*_{1}*R*_{2}
*R*_{1}*R*_{3}

3. *R*_{1}(*R*_{2}
*R*_{3})
*R*_{1}*R*_{2}
*R*_{1}*R*_{3}

Proofs for these properties are omitted.

**Powers of Relation**

Let *R* be a binary relation on *A*. Then
*R*^{n} for all positive integers *n*
is defined recursively as follows:

**Definition(power of relation):**

**Basis Clause:** *R*^{0} = *E*,
where *E* is the equality relation on *A*.

**Inductive Clause:** For an arbitrary natural number *n* ,
*R*^{n+1} = *R*^{n}R.

Note that there is no need for extremal clause here.

Thus for example *R*^{1} = *R*, *R*^{2} = *RR*,
and *R*^{3} = *R*^{2}R =
(*RR*)*R* = *R*(*RR*) = *RRR*.

The powers of binary relation *R* on a set *A* defined above have
the following properties.

1. *R*^{m+n} = *R*^{m}R^{n},

2. **(***R*^{m})^{n} = *R*^{mn}.

### Test Your Understanding of Properties of Operations on Relations

Indicate which of the following statements are correct and which are not.

Click True or False , then Submit. There are two sets of questions.

**
Next -- Closures of Binary Relation **

Back to Schedule

Back to Table of Contents