SlideShare a Scribd company logo
Relations and Functions (Continued)
Zero – one Matrices
Let R be the relationfrom A to B so that R is a subset of AxB. Let mij = (ai,bj) and assign the values
1 or 0 according the following rule
The mxn matrix formed by mij’s is called the matrix of the relation R, or the relation matrix R,
and is denoted by MR or M(R). Since M(R) contains only 0 and 1 as its elements M(R) is also
called the Zero – one matrix for R.
Directed graph or Digraph of R
Let R be a relation on a finite set A. Then R can be represented pictorially with arrows and the
elements within the circle, is called Directed graph of R or Digraph of R
Problems
1. Let A = {1,2,3,4} and let R be the relation on A defined by xRy if and only if “x divides y”
a) Write down R as a set of ordered pairs.
b) Draw the diagraph of R.
c) Determine the in-degree and out-degree of the vertices in the diagraph.
d) Write the matrix
Solution:
AxA = {(1,1),(1,2),(1,3),(1,4), (2,1), (2,2),(2,3), (2,4), (3,1), (3,2), (3,3), (3,4),
(4,1), (4,2), (4,3), (4,4)}
R = {(1,1), ),(1,2),(1,3),(1,4), (2,2), (2,4), (3,3), (4,4)} . The diagraph of R is
( )
( )




∉
∈
=
R
a
a
if
R
a
a
if
m
j
i
j
i
ij
,
0
,
1
Vertices 1 2 3 4
In-degree 1 2 2 3
Out-degree 4 2 1 1
The matrix representation is
2. If R={(x,y)|x ≥ y} is relation defined on a set A = {1,2,3,4}.
a) Write down R as a set of ordered pairs.
b) Draw the diagraph of R.
c) Determine the in-degree and out-degree of the vertices in the diagraph.
d) Write the matrix
Solution:
AxA = {(1,1),(1,2),(1,3),(1,4), (2,1), (2,2), (2,3), (2,4), (3,1), (3,2), (3,3), (3,4), (4,1),
(4,2), (4,3), (4,4)}
R = {(1,1),(2,1), (2,2),(3,1), (3,2), (3,3), (4,1), (4,2), (4,3), (4,4)}
The digraph of R is
( )














=
1
0
0
0
0
1
0
0
1
0
1
0
1
1
1
1
R
M
Vertices 1 2 3 4
In-degree 4 3 2 1
Out-degree 1 2 3 4
The matrix representation of R is
3. The matrix of the relation on the set A = {a,b,c,d,e} is
a) Write down R as a set of ordered pairs.
b) Draw the diagraph of R.
c) Determine the in-degree and out-degree of the vertices in the diagraph.
Solution:
R = {(a,a), (a,b), (b,c), (b,d), (c,d), (c,e), (d,b), (d,c), (e,a)}
[Answer for b and c as per previous examples]
4. The digraph of the relation on the set A = {a,b,c,d,e,f} is
a) Write down R as a set of ordered pairs.
b) Draw the matrix of R.
c) Determine the in-degree and out-degree of the vertices in the diagraph.
( )














=
1
1
1
1
0
1
1
1
0
0
1
1
0
0
0
1
R
M
















0
0
0
0
1
0
0
1
1
0
1
1
0
0
0
0
1
1
0
0
0
0
0
1
1
RESULTS
 (a,b)∈R or (a,b)∈S then (a,b)∈R∪S
 (a,b)∈R and (a,b)∈S then (a,b)∈R∩S
 is the complement of the set R in the universal set AXB.
 Rc
is the converse of R
 [(a,b)∈Rc
if and only if (b,a)∈R]
 If MR is the matrix of R then (MR)T
is the matrix of Rc
5. Let A=B = {1,2,3}, and R = {(1,1), (1,2),(2,3),(3,1)}, S = {(2,1),(3,1), (3,2),(3,3)}
a) Compute R∪S, R∩S, Rc
, Sc
b) Draw the diagraphs.
c) Determine the in-degree and out-degree of the vertices in the diagraphs.
d) Write the matrices.
Solution:
Given that R = {(1,1), (1,2),(2,3),(3,1)} and S = {(2,1),(3,1), (3,2),(3,3)}
R∪S = {(1,1), (1,2),(2,3),(2,1),(3,1), (3,2), (3,3)}
R∩S = {(3,1)}
AxB = {(1,1),(1,2),(1,3),(2,1), (2,2),
(2,3),(3,1), (3,2), (3,3)}
= {(1,3),(2,1), (2,2), (3,2), (3,3)}
= {(1,1),(1,2),(1,3), (2,2), (2,3)}
Rc
= {(1,1), (2,1), (3,2), (1,3)}
Sc
= {(1,2), (1,3), (2,3), (3,3)}
[Answer for c and d as per previous examples]
R
S
,
R
R
S
6. The digraphs of R and S are given as
a) Write R and S as ordered pairs
b) Compute R∪S, R∩S, Rc
, Sc
c) Determine the in-degree and out-degree of the vertices in the diagraphs.
d) Write the matrices.
COMPOSITION OF RELATION
R is a relation from A to B and S is a relation from B to C then RοS = {(a,c)|a∈A,c∈C, and
there exists b∈B with (a,b)∈A and (b,c)∈B}
1. Let A = {1,2,3,4} and R = {(1,1),(1,3),(3,2), (3,4),(4,2)} and S = {(2,1),(3,3),(3,4),(4,1)} be
relations on A. Find RοS, SοR, R2
, R3
, S2
, S3
.
Solution: Given that R = {(1,1),(1,3),(3,2), (3,4),(4,2)} and S = {(2,1),(3,3),(3,4),(4,1)}
RοS = {(1,3), (1,4), (3,1), (4,1)}
SοR = {(2,1), (1,3), (3,2), (3,4), (4,1), (4,3)}
RοR = R2
= {(1,1),(1,3),(1,2),(1,4),(3,2)}
R2
οR = R3
= {(1,1),(1,3),(1,2),(1,4)}
SοS= S2
= {(3,3),(3,4),(3,1)}
S2
οS = S3
= {(3,3),(3,4),(3,1)}
2. Let A = {1,2,3,4} and R = {(1,1),(1,2),(2,3),(3,3),(3,4)} be relation on A. Find R2
, R3
, R4
and
draw their graphs.
S
,
R
3. Let A = {a,b,c,d,e} and R = {(a,a),(a,b), (b,c), (c,d),(c,e), (d,e)} be relation on A. Find R2
. Verify
that M(R2
) = [M(R)]2
Solution:
R = {(a,a),(a,b), (b,c), (c,d),(c,e), (d,e)}
R = {(a,a),(a,b), (b,c), (c,d),(c,e), (d,e)}
R2
= {(a,a),(a,b),(a,c),(b,d),(b,e),(c,e)}
[M(R)]2
= M(R) M(R)
=
=
--------------------------------------- (1)
R2
= {(a,a),(a,b),(a,c),(b,d),(b,e),(c,e)}
M(R2
) = ---------(2)
∴By (1) and (2)
Hence M(R2
) = [M(R)]2
4. Let A = {1,2,3,4} and
Find the matrices RοS and SοR
















0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
1
1
0
0
0
0
0
1
1
1
















0
0
0
0
0
1
0
0
0
0
1
1
0
0
0
0
1
0
0
0
0
0
0
1
1
















0
0
0
0
0
1
0
0
0
0
1
1
0
0
0
0
1
0
0
0
0
0
0
1
1
















0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
1
1
0
0
0
0
0
1
1
1














=














=
0
0
0
1
0
0
0
1
0
1
0
0
1
1
0
0
M
0
0
0
0
0
0
1
0
1
0
0
0
0
1
1
1
M S
R
Solution:
R = {(1,1),(1,2),(1,3),(2,4),(3,2)}
S = {(1,3),(1,4),(2,3),(3,1),(4,1)}
RοS = {(1,3),(1,4),(1,1),(2,1),(3,3)}
Matrix of RοS =
SοR = {(1,2),(2,2),(3,1),(3,2),(3,3),(4,1),(4,2), (4,3)}
Matrix of SοR =
5. Let A = {1,2,3,4}, B = {w,x,y,z} and C={5,6,7}. Also the relations R1,R2 and R3 are defined as
R1={(1,x),(2,x),(3,y),(3,z)}, R2={(w,5),(x,6)} and R3 = {(w,5),(w,6)}. Find R1οR2, R1οR3,
M(R1), M(R2) and M(R1οR2). Also verify that M(R1οR2) = M(R1).M(R2)
Solution:
R1={(1,x),(2,x),(3,y),(3,z)}, R2={(w,5),(x,6)}
R1οR2 = {(1,6),(2,6)}
R1={(1,x),(2,x),(3,y),(3,z)},R3 = {(w,5),(w,6)}
R1οR3 = Φ
M(R1) =
M(R2) = M(R1οR2) =
M(R1).M(R2) =
= = M(R1οR2)














0
0
0
0
0
1
0
0
0
0
0
1
1
1
0
1














0
1
1
1
0
1
1
1
0
0
1
0
0
0
1
0














0
0
0
0
1
1
0
0
0
0
1
0
0
0
1
0














0
0
0
0
0
0
0
1
0
0
0
1














0
0
0
0
0
0
0
1
0
0
1
0














0
0
0
0
1
1
0
0
0
0
1
0
0
0
1
0














0
0
0
0
0
0
0
1
0
0
0
1














0
0
0
0
0
0
0
1
0
0
1
0
PROPERTIES OF RELATIONS
RELATION
If A and B are sets, a relation from A to B is any subset of AXB. Subsets of AXA are called relations on A.
REFLEXIVE
A relation R on a set A is called reflexive if for all x ∈A, (x,x)∈R
Example:
Let A = {1,2,3}
R = {(1,1),(2,2),(3,3)}
IRREFLEXIVE
A relation R on a set A is said to be irreflexive if (x,x)∉R for any x∈R.
Example:
Let A = {1,2,3}
R = {(1,3),(2,1),(3,2)}
SYMMETRIC
Relation R on a set A is called symmetric if (x,y)∈R⇒(y,x)∈R, for all x,y∈A
Example:
Let A = {1,2,3}
R = {(1,2),(2,1),(3,2),(2,3)}
TRANSITIVE
Relation R on a set A is called transitive if (x,y),(y,z)∈R⇒(x,z)∈R, for all x,y,z∈A
Example:
Let A = {1,2,3}
R = {(1,3),(3,2),(1,2)}
ANTISYMMETRIC
Given a relation R on a set A is called antisymmetric if for all a,b∈A,aRb and bRa⇒a=b.
Example:Let A = {1,2,3,4}. Determine the nature of the following relations on A.
 R1 = {(1,1),(1,2),(2,1),(2,2),(3,3),(3,4), (4,3),(4,4)}
R2 = {(1,2),(1,3),(3,1),(1,1),(3,3),(3,2), (1,4), (4,2),(3,4)}
Solution:R1 is reflexive, symmetry and transitive.R2 is transitive
Equivalence Relation
A relation R on a set is said to be an equivalence relation on A if (i)R is reflexive (ii) R is symmetric (iii) R is
transitive , on A.
1. Let A = {1,2,3,4} and R = {(1,1),(1,2),(2,1), (2,2),(3,4),(4,3),(3,3),(4,4)} be a relation A. Verify that R
is equivalence relation.
Solution:
We note that (1,1),(2,2),(3,3),(4,4) belongs to R. That is (a,a)∈R for all a∈A
∴R is reflexive relation.
Next, we note that (1,2),(2,1) and (3,4),(4,3)∈R. That is whenever (a,b)∈R then (b,a)∈R for a,b∈A
∴R is symmetry relation.
Finally, (1,2),(2,1),(1,1)∈R,
(2,1),(1,2),(2,2)∈R,
(4,3),(3,4),(4,4)∈R,
That is whenever (a,b)∈R,(b,c)∈R then for (a,c)∈R a,b,c∈A
∴R is transitive relation.
Hence R is an equivalence relation
2. Let A = {1,2,3,4,5,6, 7,8,9, 10, 11, 12}. On this set define the relation R by (x,y)∈R iff x – y is
multiple of 5.verify R is an equivalence relation.
Equivalence Classes
Let R be an equivalence relation on a set A and a∈A. Then the set of all those elements x of A which are
related to a by R is called equivalence class of a with respect to R. This equivalence class is denoted by
R(a) or [a], or
=[a] = R(a) = {x∈A | (x,a)∈R}
Example
Let R = {(1,1), (1,3), (2,2), (3,1), (3,3)}
[1] = {1,3}[2] = {2}[3] = {1,3}
a
a
Partition of a set
Let A be a nonempty set. Suppose there exists nonempty subsets A1,A2,……,Ak, o A such that the
following two conditions hold:
 A is the union of A1,A2,……,Ak i.e. A = A1UA2U……UAk
 Any two of the subsets A1,A2,……,Ak are disjoint; i.e. Ai∩Aj = Φ for i≠j
1. For the equivalence relation R = {(1,1), (1,2), (2,1),(2,2), (3,4),(4,3),(3,3),(4,4)} defined on the
set A = {1,2,3,4}, determined the partion induced.
Solution:
[1] = {1,2}, [2] = {1,2}, [3] = {3,4}, [4] = {3,4}
[1] and [3] are distinct.
Partion P = {[1],[3]} = {{1,2},{3,4}}
2. Let A = {a,b,c,d,e}. Consider the partion P = {{a,b},{c,d},{e}} of A. Find the equivalence relation
inducing the partion.
Solution:
P has {a,b} then (a,a),(a,b),(b,a),(b,b)∈R
P has {c,d} then (c,c),(c,d),(d,c),(d,d) ∈R
P has {e} then (e,e) ∈R
∴R = {(a,a),(a,b),(b,a),(b,b), (c,c),(c,d),(d,c), (d,d), (e,e)}
3. Let A = {1,2,3,4,5,6,7} and R be the equivalence relation on A that induces the partition A =
{1,2}∪{3}∪{4,5,7}∪{6}. Find R.
Solution:
R = {(1,1),(1,2),(2,1),(2,2),(3,3),(4,4),(4,5), (4,7),(5,5),(5,7),(5,4),(7,4),(7,5),(7,7),(6,6}}
4. Let A = {1,2,3,4,5}. Define a relation R on AxA by (x1,y1)R(x2,y2) iff x1+y1 = x2+y2
 Verify that R is an equivalence relation on AxA.
 Determine the equivalence classes [(1,3)], [(2,4)] and [(1,1)]
 Determine the partition of AxA induced by R.
Solution:
For all (x,y)∈AxA, we have x+y = x+y i.e. (x,y)R(x,y). ∴R is reflexive.
Let us consider (x1,y1),(x2,y2) ∈AxA. Also (x1,y1)R(x2,y2)i.e. x1+y1 = x2+y2.This gives x2+y2 =
x1+y1 which means (x2,y2)R(x1,y1). ∴R is symmetric.
Let us consider (x1,y1),(x2,y2) and (x3,y3) ∈AxA. Suppose that (x1,y1)R(x2,y2) and
(x2,y2)R(x3,y3).Then x1+y1 = x2+y2 and x2+y2= x3+y3.This gives x1+y1 = x3+y3 which means
(x1,y1)R(x3,y3). ∴R is transitive.
Thus, R is reflexive, symmetric and transitive. Hence R is an equivalence relation.
We note that
[(1,3)] = {(x,y)∈AxA|(x,y)R(1,3)}
= {(x,y)∈AxA|x+y = 1+3}
= {(1,3), (2,2), (3,1)}
Since A = {1,2,3,4,5}
Similarly [(2,4)] = {(1,5),(2,4),(3,3),(4,2), (5,1)}
[(1,1)] = {(1,1)}
To determine the partition induced by R, we have to find the equivalence classes of all elements
(x,y) of AxA with respect to R.
[(1,1)] = {(1,1)}
[(1,3)] = [(2,2)] = [(3,1)]
[(2,4)] = [(1,5)] = [(3,3)] = [(4,2)] = [(5,1)]
[(1,2)] = {(1,2),(2,1)} = [(2,1)]
[(1,4)] = {(1,4),(2,3),(3,2),(4,1)} = [(2,3)] = [(3,2)] = [(4,1)]
[(2,5)] = {(2,5), (5,2), (3,4), (4,3)} = [(3,4) = [(4,3)] = [(5,2)]
[(3,5)] = {(3,5), (5,3),(4,4)} = [(4,4)] = [(5,3)]
[(4,5)] = {(4,5),(5,4)} = [(5,4)]
[(5,5)] = {(5,5)}
Thus, [(1,1)], [(1,2)], [(1,3)], [(1,4)], [(1,5)], [(2,5)], [(3,5)], [(4,5)], and [(5,5)] are the only distinct
equivalence classes of AxA with respect to R. Hence the partition of AxA induced by R is
represented byAxA = [(1,1)] ∪ [(1,2)] ∪ [(1,3)] ∪ [(1,4)] ∪ [(1,5)] ∪ [(2,5)] ∪ [(3,5)] ∪ [(4,5)]∪
[(5,5)]
Partial Orders
A relation R on a set A is said to be a partial ordering relation or a partial order on A if
i. R is reflexive
ii. R is antisymmetric and
iii. R is transitive, on A
Poset
A set A with a partial order R defined on it is called a partially ordered set or an ordered set or
poset and it denoted by the pair (A,R).
Example:
 The relation ≤ on the set of integers Z is a poset (Z,≤)
 The relation ≥ on the set of integers Z is a poset (Z,≥)
 The relation  on the set of integers Z is not a poset (Z,), because reflexive does not exist.
 The relation  on the set of integers Z is not a poset (Z,), because reflexive does not exist.
Total Order
Let R be a partial order on a set A. Then R is called a total order on A if for all x,y∈A, either xRy or
yRx. In this case, the poset (A,R) is called totally order set.
The totally ordered set is also called a linearly ordered set or chain.
Example:
 The partial order relation ≤ is a totally order on the set R. Because, for any x,y∈R we have x ≤ y or
y ≤ x. Thus (R,≤) is a totally ordered set.
 The partial order relation ≥ is a totally order on the set R. Because, for any x,y∈R we have x ≥ y
or y ≥ x. Thus (R,≥) is a totally ordered set.
Hasse Diagrams
 It is the diagraph of partial orders
 Represent the vertices by dots (bullets)
 Draw the diagraph in such a way that all edges point upward.
 Don’t put arrows for the edges.
 This diagraph is called poset diagram or the Hasse diagram for the partial order.
 In the hasse diagram don’t include reflexive elements
In the hasse diagram don’t include transitive elements
1. Let A = {1,2,3,4} and R = {(1,1), (1,2),(2,2),(2,4),(1,3),(3,3),(3,4), (1,4),(4,4)}. Verify that R is
partial order on A. Also, write down the Hasse diagram for R.
Solution:
Since (1,1),(2,2),(3,3),(4,4) are in R. R is reflexive.
Also, (1,2) is in R but (2,1) is not in R. It is true for other elements in R. Hence R is
antisymmetry.
We note that (1,1), (1,2),(1,2) is in R, (2,2),(2,4),(2,4) in R (1,3),(3,3) (1,3) in R, (3,4), (4,4),
(3,4) is in R. Hence R is transitive. Hence R is partial order on A.
R for Hasse diagram is {(1,2), (1,3), (2,4), (3,4)} and the Hasse diagram is
2. Let A = {1,2,3,4,6,12}. On A, define the relation R by aRbiff a divides b. Prove that R is a partial
order on A. Draw the Hasse diagram for this relation.
Solution:
R = {(1,1),(1,2),(1,3),(1,4),(1,6),(1,12), (2,2),(2,4),(2,6),(2,12), (3,3),(3,6),(3,12), (4,4),(4,12),
(6,6),(6,12),(12,12)}
One can easily verify that R is a partial order.
R for Hasse diagram {(1,2),(1,3),(2,4),(2,6),(3,6),(3,12),(4,12),(6,12)} and the Hasse diagram is
3. Draw the Hasse diagram representing the positive divisors of 16.
Solution:
The divisors of 16 are A = {1,2,4,8,16}
R = {(1,1),(1,2),(1,4),(1,8),(1,16),(2,2),(2,4),(2,8),(2,16),(4,4),(4,8),(4,16), (8,8),(8,16),(16,16)}
R for the Hasse diagram is R = {(1,2),(2,4),(4,8),(8,16)} and the Hasse diagram is
4. Draw the Hasse diagram of the relation R on A = {1,2,3,4,5} whose matrix is MR =
5. The Hasse diagram of a partial order R on the set A = {1,2,3,4,5,6} is as given below. Write
down R as a subset of AxA. Construct its diagraph.
6. Determine the matrix of the partial order whose Hasse diagram is given below
















1
0
0
0
0
0
1
0
0
0
1
1
1
0
0
1
1
1
1
0
1
1
1
0
1
Extermal elements in Posets
Consider a Poset (A,R). We define below some special elements called extremal elements that
may exist in A
Maximal Element
An element a∈A is called a maximal element of A if there exists no element x ≠ a in A such that
aRx.
In other words, a∈A is a maximal element of A if whenever there is x∈A such that aRx then x = a.
Minimal Element
An element a∈A is called a minimal element of A if there exists no element x ≠ a in A such that
xRa.
In other words, a∈A is a minimal element of A if whenever there is x∈A such that xRa then x = a.
In simple words
a is maximal element of A iff in the Hasse diagram of R no edge starts at a.
a is minimal element of A iff in the Hasse diagram of R no edge terminates at a.
Greatest Element
An element a∈A is called a greatest element of A if xRa for all x∈A.
Least Element
An element a∈A is called a least element of A if aRx for all x∈A.
Example: In the following Hasse diagram let us find all extremal elements.
5 and 6 are maximal elements. Because no edge starts at 5 and 6.
 1 is the minimal element. Because no edge terminates at 1.
 No greatest element. Because no element has connection with all the elements.
 1 is least element. Because 1 is connected with all the elements.
Example: In the following Hasse diagram let us find all extremal elements.
 5 is the maximal element. Because no edge starts at 5.
 1 is the minimal element. Because no edge terminates at 1.
 5 is the greatest element. Because the element 5 has connection with all the elements.
 1 is least element. Because 1 is connected with all the elements.
Upper Bound
An element a∈A is called an upper bound of a subset B of A if xRa for all x∈B.
Least Upper Bound (LUB)
An element a∈A is called the least upper bound (LUB) of a subset B of A if the following two
conditions hold:
 a is an upper bound of B
 If a’ is an upper bound of B then aRa’
LUB is also known as Supremum
Lower Bound
An element a∈A is called a lower bound of a subset B of A if aRx for all x∈B.
Greatest Lower Bound (GLB)
An element a∈A is called the greatest lower bound (GLB) of a subset B of A if the following two
conditions hold:
 a is an lower bound of B
 If a’ is a lower bound of B then a’Ra
GLB is also known as Infimum
Example:For the following Hasse diagram find the LUB and GLB for B1 and B2, where B1 = {1,2}
and B2 = {3,4,5}
 1 and 2 related to 3,4,5,6,7,8. Hence 3,4,5,6,7,8 are upper bounds of B1 = {1,2}
 The upper bound 3 is related to all other upper bounds 4,5,6,7,8. Hence 3 is the LUB of B1. We
write LUB(B1) = 3
In A, there is no element x such that xR1 and xR2. Therefore B1 has no lower bounds.
Hence B1 has no GLB.
 3,4 and 5 are related to 6,7,8. Hence 6,7,8 are upper bounds of B2 = {3,4,5}
 No upper bound of B2 is related to other upper bounds.
 Hence B2 has no LUB.
 For each x∈B2, we have 1Rx. Hence 1 is lower bound. Similarly 2 and 3 are lower bounds.
 The lower bounds1 and 2 are related to the lower bound 3. Hence 3 is the GLB of B2. we write
GLB{B2} = 3.
1. Consider the Hasse diagram of a poset (A,R) given below
If B = {c,d,e} find (if they exist}
 All upper bounds of B
 The Least upper bound of B
 All lower bounds of B
 The Greatest lower bound of B
Solution:
From the Hasse diagram we note the following
All c,d,e of B are related to f,g,h. Hence f,g,h are upper bounds of B.
 The upper bound f of B is related to the upper bounds g and h.
 Hence f is the least upper bound of B. we write LUB{B} = f
From the Hasse diagram we also note that
 The elements a,b,c are related to f,g,h of B. Hence a,b,c are the lower bounds of B.
 The lower bounds a and b of B is related to the lower bound c of B.
 Hence c is the greatest lower bound of B. we write GLB{B} = c.
2. Consider the Hasse diagram of a poset (A,R) given below
If B = {c,d,e} find (if they exist}
 All upper bounds of B
 The Least upper bound of B
 All lower bounds of B
 The Greatest lower bound of B
Solution:
From the Hasse diagram we note the following
 All c,d,e of B are related to e,f,g. Hence e,f,g are upper bounds of B.
The upper bound e of B is related to the upper bounds f and g.
 Hence e is the least upper bound of B. we write LUB{B} = e
 By examining all upward paths to c,d,e we find that GLB{b} = a.
Theorem:If (A,R) is a poset and A is finite (nonempty), then A has at least one maximal element
and at least one minimal element.
Proof: Let a∈A. If a is not maximal. We can find an element x1∈A such that x1≠a and aRx1. If x1
is not maximal, we can find an element x2 ∈A such that x2 ≠ x1 and x1Rx2. Proceeding like this,
we end up with a finite chain of the form aRx1, x1Rx2, x2Rx3,………….Which cannot be extended
beyond a certain final stage because f is finite. Hence, we end up with some xk∈A which is a
maximal element of A. Thus, A has at least one maximal element.
A similar argument shows that A has at least one minimal element.
Theorem:Every poset has at most one greatest element and at least one least element.
Proof:Assume that a and b are greatest elements of (A,R). Then since b is greatest element we
have aRb. Similarly, since a is greatest element we have bRa. Thus, aRb and bRa. Since R is an
antisymmetric relation, it follows that a = b. Thus, two greatest elements of (A,R), if such exists
cannot be different. If (A,R) has a greatest element, then that element is unique. Thus, (A,R) has
at most one greatest element.
A similar argument shows hat (A,R) has at most one least element.
Theorem:If (A,R) is a poset and B⊆A, then B has at most one LUB and at most one GLB.
Proof:Assume that a and b are two LUB’s of B. Then a and b are upper bounds of B. Since b is an
upper bound of B and a is LUB of B, we have aRb. Similarly, Since a is an upper bound of B and b
is LUB of B, we have bRa. Since R is antisymmetric it follows that a = b.Hence B cannot have two
distinct LUB’s. This means that B has at most one LUB.
A similar argument shows that B has at most one GLB.
Lattice
Let (A,R) be a poset. This poset is called lattice if, for all x,y∈A, the elements LUB{x,y} and
GLB{x,y} exist in A.
Example
Consider the set N of natural numbers, and R be the partial order “less than or equal to”. Then
for any x,y∈N, we note that LUB{x,y} = max{x,y} and GLB{x,y} = min{x,y} and both these belongs
to N. Therefore the poset (N,≤) is a lattice.
Compiled by,
Dr. Chandra Naik, Dept.of CSE, AIET Mijar

More Related Content

PPTX
realtion ppt for disteane maths for engg
PPTX
Relations
PPTX
Relations
PPTX
Relation and function_xii
PDF
Relations
PPTX
Binary Relation-1 ssssssssssssssssssssssss
PDF
Chapter 2: Relations
PPTX
Discrete Structures_Relations_Lec 1.pptx
realtion ppt for disteane maths for engg
Relations
Relations
Relation and function_xii
Relations
Binary Relation-1 ssssssssssssssssssssssss
Chapter 2: Relations
Discrete Structures_Relations_Lec 1.pptx

Similar to Basic concepts of relations , digraph and POSETpdf (20)

PPT
PPTX
Key Guidelines for Low-Income Housing.ptx
PPTX
slide-week1_Introduction to Relation.pptx
PPT
PPT
Set theory
PDF
Lecture 3 (4).pdfbbbbbbbbbbbbbbbbbbbvvvvvvvvvvvvvvvvvvvvvvvvv
PDF
Lecture 3 (2).pdf,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
DOC
Final relation1 m_tech(cse)
DOC
Final relation1 m_tech(cse)
DOC
Final relation1 m_tech(cse)
PDF
PPTX
CMSC 56 | Lecture 14: Representing Relations
PDF
Relations
PPT
inbound38351872686383732942924290993.ppt
PPTX
CMSC 56 | Lecture 13: Relations and their Properties
PPTX
Relations in Discrete Math
PDF
Basic concepts of relations and functions. Onto functions and one to one func...
PPSX
Types of RELATIONS
PDF
Ncert class-12-mathematics-part-1
PPTX
dm_13_RelationsAndTheirProperties (1).pptx
Key Guidelines for Low-Income Housing.ptx
slide-week1_Introduction to Relation.pptx
Set theory
Lecture 3 (4).pdfbbbbbbbbbbbbbbbbbbbvvvvvvvvvvvvvvvvvvvvvvvvv
Lecture 3 (2).pdf,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
Final relation1 m_tech(cse)
Final relation1 m_tech(cse)
Final relation1 m_tech(cse)
CMSC 56 | Lecture 14: Representing Relations
Relations
inbound38351872686383732942924290993.ppt
CMSC 56 | Lecture 13: Relations and their Properties
Relations in Discrete Math
Basic concepts of relations and functions. Onto functions and one to one func...
Types of RELATIONS
Ncert class-12-mathematics-part-1
dm_13_RelationsAndTheirProperties (1).pptx
Ad

Recently uploaded (20)

PPT
Occupational Health and Safety Management System
PPTX
Safety Seminar civil to be ensured for safe working.
PPTX
communication and presentation skills 01
PDF
Categorization of Factors Affecting Classification Algorithms Selection
PDF
Integrating Fractal Dimension and Time Series Analysis for Optimized Hyperspe...
PDF
Abrasive, erosive and cavitation wear.pdf
PDF
Artificial Superintelligence (ASI) Alliance Vision Paper.pdf
PPT
Total quality management ppt for engineering students
PDF
737-MAX_SRG.pdf student reference guides
PPTX
Artificial Intelligence
PPTX
Fundamentals of Mechanical Engineering.pptx
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PPT
introduction to datamining and warehousing
PDF
PPT on Performance Review to get promotions
PPTX
CURRICULAM DESIGN engineering FOR CSE 2025.pptx
PDF
BIO-INSPIRED ARCHITECTURE FOR PARSIMONIOUS CONVERSATIONAL INTELLIGENCE : THE ...
PDF
EXPLORING LEARNING ENGAGEMENT FACTORS INFLUENCING BEHAVIORAL, COGNITIVE, AND ...
PDF
Human-AI Collaboration: Balancing Agentic AI and Autonomy in Hybrid Systems
PDF
Level 2 – IBM Data and AI Fundamentals (1)_v1.1.PDF
PPTX
introduction to high performance computing
Occupational Health and Safety Management System
Safety Seminar civil to be ensured for safe working.
communication and presentation skills 01
Categorization of Factors Affecting Classification Algorithms Selection
Integrating Fractal Dimension and Time Series Analysis for Optimized Hyperspe...
Abrasive, erosive and cavitation wear.pdf
Artificial Superintelligence (ASI) Alliance Vision Paper.pdf
Total quality management ppt for engineering students
737-MAX_SRG.pdf student reference guides
Artificial Intelligence
Fundamentals of Mechanical Engineering.pptx
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
introduction to datamining and warehousing
PPT on Performance Review to get promotions
CURRICULAM DESIGN engineering FOR CSE 2025.pptx
BIO-INSPIRED ARCHITECTURE FOR PARSIMONIOUS CONVERSATIONAL INTELLIGENCE : THE ...
EXPLORING LEARNING ENGAGEMENT FACTORS INFLUENCING BEHAVIORAL, COGNITIVE, AND ...
Human-AI Collaboration: Balancing Agentic AI and Autonomy in Hybrid Systems
Level 2 – IBM Data and AI Fundamentals (1)_v1.1.PDF
introduction to high performance computing
Ad

Basic concepts of relations , digraph and POSETpdf

  • 1. Relations and Functions (Continued) Zero – one Matrices Let R be the relationfrom A to B so that R is a subset of AxB. Let mij = (ai,bj) and assign the values 1 or 0 according the following rule The mxn matrix formed by mij’s is called the matrix of the relation R, or the relation matrix R, and is denoted by MR or M(R). Since M(R) contains only 0 and 1 as its elements M(R) is also called the Zero – one matrix for R. Directed graph or Digraph of R Let R be a relation on a finite set A. Then R can be represented pictorially with arrows and the elements within the circle, is called Directed graph of R or Digraph of R Problems 1. Let A = {1,2,3,4} and let R be the relation on A defined by xRy if and only if “x divides y” a) Write down R as a set of ordered pairs. b) Draw the diagraph of R. c) Determine the in-degree and out-degree of the vertices in the diagraph. d) Write the matrix Solution: AxA = {(1,1),(1,2),(1,3),(1,4), (2,1), (2,2),(2,3), (2,4), (3,1), (3,2), (3,3), (3,4), (4,1), (4,2), (4,3), (4,4)} R = {(1,1), ),(1,2),(1,3),(1,4), (2,2), (2,4), (3,3), (4,4)} . The diagraph of R is ( ) ( )     ∉ ∈ = R a a if R a a if m j i j i ij , 0 , 1
  • 2. Vertices 1 2 3 4 In-degree 1 2 2 3 Out-degree 4 2 1 1 The matrix representation is 2. If R={(x,y)|x ≥ y} is relation defined on a set A = {1,2,3,4}. a) Write down R as a set of ordered pairs. b) Draw the diagraph of R. c) Determine the in-degree and out-degree of the vertices in the diagraph. d) Write the matrix Solution: AxA = {(1,1),(1,2),(1,3),(1,4), (2,1), (2,2), (2,3), (2,4), (3,1), (3,2), (3,3), (3,4), (4,1), (4,2), (4,3), (4,4)} R = {(1,1),(2,1), (2,2),(3,1), (3,2), (3,3), (4,1), (4,2), (4,3), (4,4)} The digraph of R is ( )               = 1 0 0 0 0 1 0 0 1 0 1 0 1 1 1 1 R M
  • 3. Vertices 1 2 3 4 In-degree 4 3 2 1 Out-degree 1 2 3 4 The matrix representation of R is 3. The matrix of the relation on the set A = {a,b,c,d,e} is a) Write down R as a set of ordered pairs. b) Draw the diagraph of R. c) Determine the in-degree and out-degree of the vertices in the diagraph. Solution: R = {(a,a), (a,b), (b,c), (b,d), (c,d), (c,e), (d,b), (d,c), (e,a)} [Answer for b and c as per previous examples] 4. The digraph of the relation on the set A = {a,b,c,d,e,f} is a) Write down R as a set of ordered pairs. b) Draw the matrix of R. c) Determine the in-degree and out-degree of the vertices in the diagraph. ( )               = 1 1 1 1 0 1 1 1 0 0 1 1 0 0 0 1 R M                 0 0 0 0 1 0 0 1 1 0 1 1 0 0 0 0 1 1 0 0 0 0 0 1 1
  • 4. RESULTS (a,b)∈R or (a,b)∈S then (a,b)∈R∪S (a,b)∈R and (a,b)∈S then (a,b)∈R∩S is the complement of the set R in the universal set AXB. Rc is the converse of R [(a,b)∈Rc if and only if (b,a)∈R] If MR is the matrix of R then (MR)T is the matrix of Rc 5. Let A=B = {1,2,3}, and R = {(1,1), (1,2),(2,3),(3,1)}, S = {(2,1),(3,1), (3,2),(3,3)} a) Compute R∪S, R∩S, Rc , Sc b) Draw the diagraphs. c) Determine the in-degree and out-degree of the vertices in the diagraphs. d) Write the matrices. Solution: Given that R = {(1,1), (1,2),(2,3),(3,1)} and S = {(2,1),(3,1), (3,2),(3,3)} R∪S = {(1,1), (1,2),(2,3),(2,1),(3,1), (3,2), (3,3)} R∩S = {(3,1)} AxB = {(1,1),(1,2),(1,3),(2,1), (2,2), (2,3),(3,1), (3,2), (3,3)} = {(1,3),(2,1), (2,2), (3,2), (3,3)} = {(1,1),(1,2),(1,3), (2,2), (2,3)} Rc = {(1,1), (2,1), (3,2), (1,3)} Sc = {(1,2), (1,3), (2,3), (3,3)} [Answer for c and d as per previous examples] R S , R R S
  • 5. 6. The digraphs of R and S are given as a) Write R and S as ordered pairs b) Compute R∪S, R∩S, Rc , Sc c) Determine the in-degree and out-degree of the vertices in the diagraphs. d) Write the matrices. COMPOSITION OF RELATION R is a relation from A to B and S is a relation from B to C then RοS = {(a,c)|a∈A,c∈C, and there exists b∈B with (a,b)∈A and (b,c)∈B} 1. Let A = {1,2,3,4} and R = {(1,1),(1,3),(3,2), (3,4),(4,2)} and S = {(2,1),(3,3),(3,4),(4,1)} be relations on A. Find RοS, SοR, R2 , R3 , S2 , S3 . Solution: Given that R = {(1,1),(1,3),(3,2), (3,4),(4,2)} and S = {(2,1),(3,3),(3,4),(4,1)} RοS = {(1,3), (1,4), (3,1), (4,1)} SοR = {(2,1), (1,3), (3,2), (3,4), (4,1), (4,3)} RοR = R2 = {(1,1),(1,3),(1,2),(1,4),(3,2)} R2 οR = R3 = {(1,1),(1,3),(1,2),(1,4)} SοS= S2 = {(3,3),(3,4),(3,1)} S2 οS = S3 = {(3,3),(3,4),(3,1)} 2. Let A = {1,2,3,4} and R = {(1,1),(1,2),(2,3),(3,3),(3,4)} be relation on A. Find R2 , R3 , R4 and draw their graphs. S , R
  • 6. 3. Let A = {a,b,c,d,e} and R = {(a,a),(a,b), (b,c), (c,d),(c,e), (d,e)} be relation on A. Find R2 . Verify that M(R2 ) = [M(R)]2 Solution: R = {(a,a),(a,b), (b,c), (c,d),(c,e), (d,e)} R = {(a,a),(a,b), (b,c), (c,d),(c,e), (d,e)} R2 = {(a,a),(a,b),(a,c),(b,d),(b,e),(c,e)} [M(R)]2 = M(R) M(R) = = --------------------------------------- (1) R2 = {(a,a),(a,b),(a,c),(b,d),(b,e),(c,e)} M(R2 ) = ---------(2) ∴By (1) and (2) Hence M(R2 ) = [M(R)]2 4. Let A = {1,2,3,4} and Find the matrices RοS and SοR                 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 1 0 0 0 0 0 1 1 1                 0 0 0 0 0 1 0 0 0 0 1 1 0 0 0 0 1 0 0 0 0 0 0 1 1                 0 0 0 0 0 1 0 0 0 0 1 1 0 0 0 0 1 0 0 0 0 0 0 1 1                 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 1 0 0 0 0 0 1 1 1               =               = 0 0 0 1 0 0 0 1 0 1 0 0 1 1 0 0 M 0 0 0 0 0 0 1 0 1 0 0 0 0 1 1 1 M S R
  • 7. Solution: R = {(1,1),(1,2),(1,3),(2,4),(3,2)} S = {(1,3),(1,4),(2,3),(3,1),(4,1)} RοS = {(1,3),(1,4),(1,1),(2,1),(3,3)} Matrix of RοS = SοR = {(1,2),(2,2),(3,1),(3,2),(3,3),(4,1),(4,2), (4,3)} Matrix of SοR = 5. Let A = {1,2,3,4}, B = {w,x,y,z} and C={5,6,7}. Also the relations R1,R2 and R3 are defined as R1={(1,x),(2,x),(3,y),(3,z)}, R2={(w,5),(x,6)} and R3 = {(w,5),(w,6)}. Find R1οR2, R1οR3, M(R1), M(R2) and M(R1οR2). Also verify that M(R1οR2) = M(R1).M(R2) Solution: R1={(1,x),(2,x),(3,y),(3,z)}, R2={(w,5),(x,6)} R1οR2 = {(1,6),(2,6)} R1={(1,x),(2,x),(3,y),(3,z)},R3 = {(w,5),(w,6)} R1οR3 = Φ M(R1) = M(R2) = M(R1οR2) = M(R1).M(R2) = = = M(R1οR2)               0 0 0 0 0 1 0 0 0 0 0 1 1 1 0 1               0 1 1 1 0 1 1 1 0 0 1 0 0 0 1 0               0 0 0 0 1 1 0 0 0 0 1 0 0 0 1 0               0 0 0 0 0 0 0 1 0 0 0 1               0 0 0 0 0 0 0 1 0 0 1 0               0 0 0 0 1 1 0 0 0 0 1 0 0 0 1 0               0 0 0 0 0 0 0 1 0 0 0 1               0 0 0 0 0 0 0 1 0 0 1 0
  • 8. PROPERTIES OF RELATIONS RELATION If A and B are sets, a relation from A to B is any subset of AXB. Subsets of AXA are called relations on A. REFLEXIVE A relation R on a set A is called reflexive if for all x ∈A, (x,x)∈R Example: Let A = {1,2,3} R = {(1,1),(2,2),(3,3)} IRREFLEXIVE A relation R on a set A is said to be irreflexive if (x,x)∉R for any x∈R. Example: Let A = {1,2,3} R = {(1,3),(2,1),(3,2)} SYMMETRIC Relation R on a set A is called symmetric if (x,y)∈R⇒(y,x)∈R, for all x,y∈A Example: Let A = {1,2,3} R = {(1,2),(2,1),(3,2),(2,3)} TRANSITIVE Relation R on a set A is called transitive if (x,y),(y,z)∈R⇒(x,z)∈R, for all x,y,z∈A Example: Let A = {1,2,3} R = {(1,3),(3,2),(1,2)} ANTISYMMETRIC Given a relation R on a set A is called antisymmetric if for all a,b∈A,aRb and bRa⇒a=b. Example:Let A = {1,2,3,4}. Determine the nature of the following relations on A. R1 = {(1,1),(1,2),(2,1),(2,2),(3,3),(3,4), (4,3),(4,4)}
  • 9. R2 = {(1,2),(1,3),(3,1),(1,1),(3,3),(3,2), (1,4), (4,2),(3,4)} Solution:R1 is reflexive, symmetry and transitive.R2 is transitive Equivalence Relation A relation R on a set is said to be an equivalence relation on A if (i)R is reflexive (ii) R is symmetric (iii) R is transitive , on A. 1. Let A = {1,2,3,4} and R = {(1,1),(1,2),(2,1), (2,2),(3,4),(4,3),(3,3),(4,4)} be a relation A. Verify that R is equivalence relation. Solution: We note that (1,1),(2,2),(3,3),(4,4) belongs to R. That is (a,a)∈R for all a∈A ∴R is reflexive relation. Next, we note that (1,2),(2,1) and (3,4),(4,3)∈R. That is whenever (a,b)∈R then (b,a)∈R for a,b∈A ∴R is symmetry relation. Finally, (1,2),(2,1),(1,1)∈R, (2,1),(1,2),(2,2)∈R, (4,3),(3,4),(4,4)∈R, That is whenever (a,b)∈R,(b,c)∈R then for (a,c)∈R a,b,c∈A ∴R is transitive relation. Hence R is an equivalence relation 2. Let A = {1,2,3,4,5,6, 7,8,9, 10, 11, 12}. On this set define the relation R by (x,y)∈R iff x – y is multiple of 5.verify R is an equivalence relation. Equivalence Classes Let R be an equivalence relation on a set A and a∈A. Then the set of all those elements x of A which are related to a by R is called equivalence class of a with respect to R. This equivalence class is denoted by R(a) or [a], or =[a] = R(a) = {x∈A | (x,a)∈R} Example Let R = {(1,1), (1,3), (2,2), (3,1), (3,3)} [1] = {1,3}[2] = {2}[3] = {1,3} a a
  • 10. Partition of a set Let A be a nonempty set. Suppose there exists nonempty subsets A1,A2,……,Ak, o A such that the following two conditions hold: A is the union of A1,A2,……,Ak i.e. A = A1UA2U……UAk Any two of the subsets A1,A2,……,Ak are disjoint; i.e. Ai∩Aj = Φ for i≠j 1. For the equivalence relation R = {(1,1), (1,2), (2,1),(2,2), (3,4),(4,3),(3,3),(4,4)} defined on the set A = {1,2,3,4}, determined the partion induced. Solution: [1] = {1,2}, [2] = {1,2}, [3] = {3,4}, [4] = {3,4} [1] and [3] are distinct. Partion P = {[1],[3]} = {{1,2},{3,4}} 2. Let A = {a,b,c,d,e}. Consider the partion P = {{a,b},{c,d},{e}} of A. Find the equivalence relation inducing the partion. Solution: P has {a,b} then (a,a),(a,b),(b,a),(b,b)∈R P has {c,d} then (c,c),(c,d),(d,c),(d,d) ∈R P has {e} then (e,e) ∈R ∴R = {(a,a),(a,b),(b,a),(b,b), (c,c),(c,d),(d,c), (d,d), (e,e)} 3. Let A = {1,2,3,4,5,6,7} and R be the equivalence relation on A that induces the partition A = {1,2}∪{3}∪{4,5,7}∪{6}. Find R. Solution: R = {(1,1),(1,2),(2,1),(2,2),(3,3),(4,4),(4,5), (4,7),(5,5),(5,7),(5,4),(7,4),(7,5),(7,7),(6,6}} 4. Let A = {1,2,3,4,5}. Define a relation R on AxA by (x1,y1)R(x2,y2) iff x1+y1 = x2+y2 Verify that R is an equivalence relation on AxA. Determine the equivalence classes [(1,3)], [(2,4)] and [(1,1)] Determine the partition of AxA induced by R. Solution: For all (x,y)∈AxA, we have x+y = x+y i.e. (x,y)R(x,y). ∴R is reflexive.
  • 11. Let us consider (x1,y1),(x2,y2) ∈AxA. Also (x1,y1)R(x2,y2)i.e. x1+y1 = x2+y2.This gives x2+y2 = x1+y1 which means (x2,y2)R(x1,y1). ∴R is symmetric. Let us consider (x1,y1),(x2,y2) and (x3,y3) ∈AxA. Suppose that (x1,y1)R(x2,y2) and (x2,y2)R(x3,y3).Then x1+y1 = x2+y2 and x2+y2= x3+y3.This gives x1+y1 = x3+y3 which means (x1,y1)R(x3,y3). ∴R is transitive. Thus, R is reflexive, symmetric and transitive. Hence R is an equivalence relation. We note that [(1,3)] = {(x,y)∈AxA|(x,y)R(1,3)} = {(x,y)∈AxA|x+y = 1+3} = {(1,3), (2,2), (3,1)} Since A = {1,2,3,4,5} Similarly [(2,4)] = {(1,5),(2,4),(3,3),(4,2), (5,1)} [(1,1)] = {(1,1)} To determine the partition induced by R, we have to find the equivalence classes of all elements (x,y) of AxA with respect to R. [(1,1)] = {(1,1)} [(1,3)] = [(2,2)] = [(3,1)] [(2,4)] = [(1,5)] = [(3,3)] = [(4,2)] = [(5,1)] [(1,2)] = {(1,2),(2,1)} = [(2,1)] [(1,4)] = {(1,4),(2,3),(3,2),(4,1)} = [(2,3)] = [(3,2)] = [(4,1)] [(2,5)] = {(2,5), (5,2), (3,4), (4,3)} = [(3,4) = [(4,3)] = [(5,2)] [(3,5)] = {(3,5), (5,3),(4,4)} = [(4,4)] = [(5,3)] [(4,5)] = {(4,5),(5,4)} = [(5,4)] [(5,5)] = {(5,5)} Thus, [(1,1)], [(1,2)], [(1,3)], [(1,4)], [(1,5)], [(2,5)], [(3,5)], [(4,5)], and [(5,5)] are the only distinct equivalence classes of AxA with respect to R. Hence the partition of AxA induced by R is represented byAxA = [(1,1)] ∪ [(1,2)] ∪ [(1,3)] ∪ [(1,4)] ∪ [(1,5)] ∪ [(2,5)] ∪ [(3,5)] ∪ [(4,5)]∪ [(5,5)]
  • 12. Partial Orders A relation R on a set A is said to be a partial ordering relation or a partial order on A if i. R is reflexive ii. R is antisymmetric and iii. R is transitive, on A Poset A set A with a partial order R defined on it is called a partially ordered set or an ordered set or poset and it denoted by the pair (A,R). Example: The relation ≤ on the set of integers Z is a poset (Z,≤) The relation ≥ on the set of integers Z is a poset (Z,≥) The relation on the set of integers Z is not a poset (Z,), because reflexive does not exist. The relation on the set of integers Z is not a poset (Z,), because reflexive does not exist. Total Order Let R be a partial order on a set A. Then R is called a total order on A if for all x,y∈A, either xRy or yRx. In this case, the poset (A,R) is called totally order set. The totally ordered set is also called a linearly ordered set or chain. Example: The partial order relation ≤ is a totally order on the set R. Because, for any x,y∈R we have x ≤ y or y ≤ x. Thus (R,≤) is a totally ordered set. The partial order relation ≥ is a totally order on the set R. Because, for any x,y∈R we have x ≥ y or y ≥ x. Thus (R,≥) is a totally ordered set. Hasse Diagrams It is the diagraph of partial orders Represent the vertices by dots (bullets) Draw the diagraph in such a way that all edges point upward. Don’t put arrows for the edges. This diagraph is called poset diagram or the Hasse diagram for the partial order. In the hasse diagram don’t include reflexive elements
  • 13. In the hasse diagram don’t include transitive elements 1. Let A = {1,2,3,4} and R = {(1,1), (1,2),(2,2),(2,4),(1,3),(3,3),(3,4), (1,4),(4,4)}. Verify that R is partial order on A. Also, write down the Hasse diagram for R. Solution: Since (1,1),(2,2),(3,3),(4,4) are in R. R is reflexive. Also, (1,2) is in R but (2,1) is not in R. It is true for other elements in R. Hence R is antisymmetry. We note that (1,1), (1,2),(1,2) is in R, (2,2),(2,4),(2,4) in R (1,3),(3,3) (1,3) in R, (3,4), (4,4), (3,4) is in R. Hence R is transitive. Hence R is partial order on A. R for Hasse diagram is {(1,2), (1,3), (2,4), (3,4)} and the Hasse diagram is 2. Let A = {1,2,3,4,6,12}. On A, define the relation R by aRbiff a divides b. Prove that R is a partial order on A. Draw the Hasse diagram for this relation. Solution: R = {(1,1),(1,2),(1,3),(1,4),(1,6),(1,12), (2,2),(2,4),(2,6),(2,12), (3,3),(3,6),(3,12), (4,4),(4,12), (6,6),(6,12),(12,12)} One can easily verify that R is a partial order. R for Hasse diagram {(1,2),(1,3),(2,4),(2,6),(3,6),(3,12),(4,12),(6,12)} and the Hasse diagram is
  • 14. 3. Draw the Hasse diagram representing the positive divisors of 16. Solution: The divisors of 16 are A = {1,2,4,8,16} R = {(1,1),(1,2),(1,4),(1,8),(1,16),(2,2),(2,4),(2,8),(2,16),(4,4),(4,8),(4,16), (8,8),(8,16),(16,16)} R for the Hasse diagram is R = {(1,2),(2,4),(4,8),(8,16)} and the Hasse diagram is 4. Draw the Hasse diagram of the relation R on A = {1,2,3,4,5} whose matrix is MR = 5. The Hasse diagram of a partial order R on the set A = {1,2,3,4,5,6} is as given below. Write down R as a subset of AxA. Construct its diagraph. 6. Determine the matrix of the partial order whose Hasse diagram is given below                 1 0 0 0 0 0 1 0 0 0 1 1 1 0 0 1 1 1 1 0 1 1 1 0 1
  • 15. Extermal elements in Posets Consider a Poset (A,R). We define below some special elements called extremal elements that may exist in A Maximal Element An element a∈A is called a maximal element of A if there exists no element x ≠ a in A such that aRx. In other words, a∈A is a maximal element of A if whenever there is x∈A such that aRx then x = a. Minimal Element An element a∈A is called a minimal element of A if there exists no element x ≠ a in A such that xRa. In other words, a∈A is a minimal element of A if whenever there is x∈A such that xRa then x = a. In simple words a is maximal element of A iff in the Hasse diagram of R no edge starts at a. a is minimal element of A iff in the Hasse diagram of R no edge terminates at a. Greatest Element An element a∈A is called a greatest element of A if xRa for all x∈A. Least Element An element a∈A is called a least element of A if aRx for all x∈A. Example: In the following Hasse diagram let us find all extremal elements.
  • 16. 5 and 6 are maximal elements. Because no edge starts at 5 and 6. 1 is the minimal element. Because no edge terminates at 1. No greatest element. Because no element has connection with all the elements. 1 is least element. Because 1 is connected with all the elements. Example: In the following Hasse diagram let us find all extremal elements. 5 is the maximal element. Because no edge starts at 5. 1 is the minimal element. Because no edge terminates at 1. 5 is the greatest element. Because the element 5 has connection with all the elements. 1 is least element. Because 1 is connected with all the elements. Upper Bound
  • 17. An element a∈A is called an upper bound of a subset B of A if xRa for all x∈B. Least Upper Bound (LUB) An element a∈A is called the least upper bound (LUB) of a subset B of A if the following two conditions hold: a is an upper bound of B If a’ is an upper bound of B then aRa’ LUB is also known as Supremum Lower Bound An element a∈A is called a lower bound of a subset B of A if aRx for all x∈B. Greatest Lower Bound (GLB) An element a∈A is called the greatest lower bound (GLB) of a subset B of A if the following two conditions hold: a is an lower bound of B If a’ is a lower bound of B then a’Ra GLB is also known as Infimum Example:For the following Hasse diagram find the LUB and GLB for B1 and B2, where B1 = {1,2} and B2 = {3,4,5} 1 and 2 related to 3,4,5,6,7,8. Hence 3,4,5,6,7,8 are upper bounds of B1 = {1,2} The upper bound 3 is related to all other upper bounds 4,5,6,7,8. Hence 3 is the LUB of B1. We write LUB(B1) = 3
  • 18. In A, there is no element x such that xR1 and xR2. Therefore B1 has no lower bounds. Hence B1 has no GLB. 3,4 and 5 are related to 6,7,8. Hence 6,7,8 are upper bounds of B2 = {3,4,5} No upper bound of B2 is related to other upper bounds. Hence B2 has no LUB. For each x∈B2, we have 1Rx. Hence 1 is lower bound. Similarly 2 and 3 are lower bounds. The lower bounds1 and 2 are related to the lower bound 3. Hence 3 is the GLB of B2. we write GLB{B2} = 3. 1. Consider the Hasse diagram of a poset (A,R) given below If B = {c,d,e} find (if they exist} All upper bounds of B The Least upper bound of B All lower bounds of B The Greatest lower bound of B Solution: From the Hasse diagram we note the following
  • 19. All c,d,e of B are related to f,g,h. Hence f,g,h are upper bounds of B. The upper bound f of B is related to the upper bounds g and h. Hence f is the least upper bound of B. we write LUB{B} = f From the Hasse diagram we also note that The elements a,b,c are related to f,g,h of B. Hence a,b,c are the lower bounds of B. The lower bounds a and b of B is related to the lower bound c of B. Hence c is the greatest lower bound of B. we write GLB{B} = c. 2. Consider the Hasse diagram of a poset (A,R) given below If B = {c,d,e} find (if they exist} All upper bounds of B The Least upper bound of B All lower bounds of B The Greatest lower bound of B Solution: From the Hasse diagram we note the following All c,d,e of B are related to e,f,g. Hence e,f,g are upper bounds of B.
  • 20. The upper bound e of B is related to the upper bounds f and g. Hence e is the least upper bound of B. we write LUB{B} = e By examining all upward paths to c,d,e we find that GLB{b} = a. Theorem:If (A,R) is a poset and A is finite (nonempty), then A has at least one maximal element and at least one minimal element. Proof: Let a∈A. If a is not maximal. We can find an element x1∈A such that x1≠a and aRx1. If x1 is not maximal, we can find an element x2 ∈A such that x2 ≠ x1 and x1Rx2. Proceeding like this, we end up with a finite chain of the form aRx1, x1Rx2, x2Rx3,………….Which cannot be extended beyond a certain final stage because f is finite. Hence, we end up with some xk∈A which is a maximal element of A. Thus, A has at least one maximal element. A similar argument shows that A has at least one minimal element. Theorem:Every poset has at most one greatest element and at least one least element. Proof:Assume that a and b are greatest elements of (A,R). Then since b is greatest element we have aRb. Similarly, since a is greatest element we have bRa. Thus, aRb and bRa. Since R is an antisymmetric relation, it follows that a = b. Thus, two greatest elements of (A,R), if such exists cannot be different. If (A,R) has a greatest element, then that element is unique. Thus, (A,R) has at most one greatest element. A similar argument shows hat (A,R) has at most one least element. Theorem:If (A,R) is a poset and B⊆A, then B has at most one LUB and at most one GLB. Proof:Assume that a and b are two LUB’s of B. Then a and b are upper bounds of B. Since b is an upper bound of B and a is LUB of B, we have aRb. Similarly, Since a is an upper bound of B and b is LUB of B, we have bRa. Since R is antisymmetric it follows that a = b.Hence B cannot have two distinct LUB’s. This means that B has at most one LUB. A similar argument shows that B has at most one GLB. Lattice Let (A,R) be a poset. This poset is called lattice if, for all x,y∈A, the elements LUB{x,y} and GLB{x,y} exist in A. Example Consider the set N of natural numbers, and R be the partial order “less than or equal to”. Then for any x,y∈N, we note that LUB{x,y} = max{x,y} and GLB{x,y} = min{x,y} and both these belongs to N. Therefore the poset (N,≤) is a lattice. Compiled by, Dr. Chandra Naik, Dept.of CSE, AIET Mijar