Вы находитесь на странице: 1из 14

www.gradeup.

co

1
www.gradeup.co

DISCRETE MATH

5 LATTICE

Partial Orders and Lattices


Relations can be used to order some or all the elements of a set. For instance, the set of Natural
numbers is ordered by the relation <= such that for every ordered pair (x,y) in the relation, the
natural number x comes before the natural number y unless both are equal.
Formally,
“A relation R on set A is called a partial ordering or partial order if it is reflexive, anti-symmetric
and transitive. A set A together with a partial ordering R is called a partially ordered set or poset.
The poset is denoted as (S,R).”

Example: Show that the inclusion relation ⊆ is a partial ordering on the power set of a set A.
Solution : Since every set S ⊆ S, ⊆ is reflexive. If S ⊆ R and R ⊆ S then
R = S, which means ⊆ is anti-symmetric. It is transitive as R ⊆ S and
S ⊆ T implies R ⊆ T.
Hence, ⊆ is a partial ordering on P(S), and (P(S), ⊆) is a poset.

Important Note: The symbol ≼ is used to denote the relation in any poset. The notation a ≺ b is
used to denote a ≼ b but a ≠ b.

Comparability:
Let a and b be the elements of a poset (S, ≼) then a. and b are said to comparable if either a ≼ b
or b ≼ a. Otherwise, a and b are said to be incomparable.

Example : In the poset (Z+ , | ) (where Z+ is the set of all positive integers and | is the divides
relation) are the integers 3 and 9 comparable? Are 7 and 10 comparable?
Solution : 3 and 9 are comparable since 3|9 i.e. 3 divides 9. But 7 and 10 are not comparable since
7 ∤ 10 and 10 ∤ 7.

Total Order:
It is possible in a poset that for two elements (a and b neither a ≼ b nor b ≼ a i.e. the elements (a
and b are incomparable. But in some cases, such as the poset (Z+, ≤), every element is comparable
to every other element.
A poset (S, ≼) is called totally ordered if every two elements of S are comparable.
≼ is called a total order. A totally ordered set is also called a chain.

2
www.gradeup.co

Hasse Diagrams:
A partial order, being a relation, can be represented by a di-graph. But most of the edges do not
need to be shown since it would be redundant.
For instance, we know that every partial order is reflexive, so it is redundant to show the self-loops
on every element of the set on which the partial order is defined.
Every partial order is transitive, so all edges denoting transitivity can be removed.
The directions on the edges can be ignored if all edges are presumed to have only one possible
direction, conventionally upwards.
In general, a partial order on a finite set can be represented using the following procedure –
1. Remove all self-loops from all the vertices. This removes all edges showing reflexivity.
2. Remove all edges which are present due to transitivity i.e. if (a,b) and (b,c)
3. are in the partial order, then remove the edge (a,c). Furthermore if (c,d) is in the partial order,
then remove the edge (a,d).
4. Arrange all edges such that the initial vertex is below the terminal vertex.
5. Remove all arrows on the directed edges, since all edges point upwards
For example, the poset ({1, 2, 3, 4}, ≤) would be converted to a Hasse diagram like

The last figure in the above diagram contains sufficient information to find the partial ordering. This
diagram is called a Hasse Diagram.

Extremums in Posets : Elements of posets that have certain extremal properties are important for
many applications.
• Maximal Elements- An element a in the poset is said to be maximal if there is no element b in
the poset such that a ≺ b.
• Minimal Elements- An element a in the poset is said to be minimal if there is no element b in
the poset such that b ≺ a.
Maximal and Minimal elements are easy to find in Hasse diagrams. They are the topmost and
bottommost elements respectively.

3
www.gradeup.co

For example, in the hasse diagram described above, “1” is the minimal element and “4” is the
maximal element. Since maximal and minimal are unique, they are also the greatest and least
element of the poset.

Important Note : If the maximal or minimal element is unique, it is called


the greatest or least element of the poset respectively.

Bounds in Posets :
It is somtimes possible to find an element that is greater than or equal to all the elements in a
subset A of poset (S, ≼). Such an element is called the upper bound of A. Similarly, we can also
find the lower bound of A.
These bounds can be further constrained to get the least upper bound and the greatest lower
bound. These bounds are elements which are less than or greater than all the other upper bounds
or lower bounds respectively.

Example – Find the least upper bound and greatest lower bound of the following subsets {b, c},
{g, e, a}, {e, f}.

Solution: For the set {b,c}


The upper bounds are – e,f,h,i. So the least upper bound is e.
The lower bounds are – a. So the greatest lower bound is a.
For the set {g,e,a}.
The upper bounds are – h. So the least upper bound is h.
The lower bounds are – a. So the greatest lower bound is a.
For the set {e,f}
The upper bounds are – f,h,i. So the least upper bound is f.
The lower bounds are – e,c,b,a. So the greatest lower bound is e.

Lattices – A Poset in which every pair of elements has both, a least upper bound and a greatest
lower bound is called a lattice.
There are two binary operations defined for lattices –

4
www.gradeup.co

1. Join – The join of two elements is their least upper bound. It is denoted by ∨, not to be confused
with disjunction.
2. Meet – The meet of two elements is their greatest lower bound. It is denoted by ∧, not to be
confused with conjunction.

Sub Lattice – A sublattice of lattice L is a subset S ⊆ L such that if a, b ∈ S.


a ∧ b ∈ S and a ∨ b ∈ S.
Identities for join and meet –
•x∧x=x and x ∨ y = x
•x∧y=y∧x and x ∨ y = y ∨ x
• (x ∧ y) ∧ z = x ∧ (y ∧ z) and (x ∨ y) ∨ z = x ∨ (
• (x ∧ (y ∨ x) = x and x ∨ (y ∧ x) = x

Distributive laws may or may not hold true for a lattice:


1. x ∧ (y ∨ z) = (x ∧ y) ∨ (x ∧ z)
2. x ∨ (y ∧ z) = (x ∨ y) ∧ (x ∨ z)
Note – A lattice is called a distributive lattice if the distributive laws hold for it.
But Semidistributive laws hold true for all lattices:
1. x ∧ (y ∨ z) ≥ (x ∧ y) ∨ (x ∧ z)
2. x ∨ (y ∧ z) ≤ (x ∨ y) ∧ (x ∨ z)
Two important properties of Distributive Lattices —
1. In any distributive lattice a ∧ y = a ∧ x and a ∨ y = a ∨ x together imply that x = y .
2. lf a ∧ x = O and a ∨ x = I , where O and I are the least and greatest element of lattice, then a and
x are said to be a complementary pair. O and I are a trivially complementary pair.

EXAMPLES

1. Consider the set S = {a, b, c, d}. Consider the following 4 partitions 1 , 2 , 3 , 4 on S: 1 =

abcd , r2 = ab, cd , r3 = abc, d , r4 = a,b, c, d . Let p be the partial order on the set of

partitions S′ = 1 , 2 , 3 , 4  defined as follows: i p  j if and only if i refines  j . The poset

diagram for (S′, p) is :


GATE CS 2007

5
www.gradeup.co

Ans. C
Explanation: A partition is said to refine another partition if it splits the sets in the second
partition to a larger number of sets.
Therefore, the partial order contains the following ordered pairs-

(  ,  ) , (  ,  ) , (  ,  ) , (  ,  ) , (  ,  )
4 1 4 2 4 3 3 1 2 1

Corresponding Hasse diagram is Option C.

2. A relation R is defined on ordered pairs of integers as follows: (x,y) R(u,v) if x < u and y > v.
Then R is: GATE-CS-2006
A. Neither a Partial Order nor an Equivalence Relation
B. A Partial Order but not a Total Order
C. A Total Order
D. An Equivalence Relation
Ans. A
Explanation: An equivalence relation on a set x is a subset of x*x, i.e., a collection R of
ordered pairs of elements of x, satisfying certain properties. Write “x R y” to mean (x,y) is an
element of R, and we say “x is related to y,” then the properties are:
1. Reflexive: a R a for all a Є R,
2. Symmetric: a R b implies that b R a for all a,b Є R

6
www.gradeup.co

3. Transitive: a R b and b R c imply a R c for all a,b,c Є R.


An partial order relation on a set x is a subset of x*x, i.e., a collection R of ordered pairs of
elements of x, satisfying certain properties. Write “x R y” to mean (x,y) is an element of R, and
we say “x is related to y,” then the properties are:
1. Reflexive: a R a for all a Є R,
2. Anti-Symmetric: a R b and b R a implies that for all a,b Є R
3. Transitive: a R b and b R c imply a R c for all a,b,c Є R.
An total order relation a set x is a subset of x*x, i.e., a collection R of ordered pairs of elements
of x, satisfying certain properties. Write “x R y” to mean (x,y) is an element of R, and we say “x
is related to y,” then the properties are:
1. Reflexive: a R a for all a Є R,
2. Symmetric: a R b implies that b R a for all a,b Є R
3. Transitive: a R b and b R c imply a R c for all a,b,c Є R.
4. Comparability : either a R b or b R a for all a,b Є R.
As given in question, a relation R is defined on ordered pairs of integers as follows: (x,y) R(u,v)
if x < u and y > v , reflexive property is not satisfied here, because there is > or < relationship
between (x ,y) pair set and (u,v) pair set . Other way , if there would have been x <= u and
y>= v (or x=u and y=v) kind of relation among elements of sets then reflexive property could
have been satisfied. Since reflexive property in not satisfied here , so given realtion can not
be equivalence, partial order or total order relation.
So, option (A) is correct.

3. The following is the Hasse diagram of the poset [{a, b, c, d, e}, ≤]

The poset is
A. not a lattice
B. a lattice but not a distributive lattice
C. a distributive lattice but not a Boolean algebra
D. a Boolean algebra
Ans. B
Explanation:

7
www.gradeup.co

It is a lattice but not a distributive lattice.


Table for Join Operation of above Hesse diagram
V |a b c d e
________________
a |a a a a a
b |a b a a b
c |a a c a c
d |a a a d d
e |a b c d e

Table for Meet Operation of above Hesse diagram

^ |a b c d e
_______________
a |a b c d e
b |b b e e e
c |c e c e e
d |d e e d e
e |e e e e e

Therefore for any two element p, q in the lattice (A,<=)


p <= p V q ; p^q <= p
This satisfies for all element (a,b,c,d,e).
which has 'a' as unique least upper bound and 'e' as unique
greatest lower bound.
The given lattice doesn't obey distributive law, so it is
not distributive lattice,
Note that for b,c,d we have distributive law
b^(cVd) = (b^c) V (b^d). From the diagram / tables given above
we can verify as follows,
(i) L.H.S. = b ^ (c V d) = b ^ a = b
(ii) R.H.S. = (b^c) V (b^d) = e v e = e
b != e which contradict the distributive law.
Hence it is not distributive lattice.
so, option (B) is correct.

8
www.gradeup.co

4. The inclusion of which of the following sets into


S = {{1, 2}, {1, 2, 3}, {1, 3, 5}, (1, 2, 4), (1, 2, 3, 4, 5}}
is necessary and sufficient to make S a complete lattice under the partial order defined by set
containment ?
A. {1}
B. {1}, {2, 3}
C. {1}, {1, 3}
D. {1}, {1, 3}, (1, 2, 3, 4}, {1, 2, 3, 5)
Ans. A
Explanation: A partially ordered set L is called a complete lattice if every subset M of L has a
least upper bound called as supremum and a greatest lower bound called as infimum.
We are given a set containment relation.
So, supremum element is union of all the subset and infimum element is intersection of all the
subset.
Set S is not complete lattice because although it has a supremum for every subset, but some
subsets have no infimum.
We take subset {{1,3,5},{1,2,4}}.Intersection of these sets is {1}, which is not present in S.
So we have to add set {1} in S to make it a complete lattice
Thus, option (A) is correct.

5. Suppose L = {p, q, r, s, t} is a lattice represented by the following Hasse diagram:

For any x, y ∈ L, not necessarily distinct, x ∨ y and x ∧ y are join and meet of x, y respectively.
Let L3 = {(x,y,z): x, y, z ∈ L} be the set of all ordered triplets of the elements of L. Let pr be the
probability that an element (x,y,z) ∈ L3 chosen equiprobably satisfies x ∨ (y ∧ z) = (x ∨ y) ∧ (x
∨ 2). Then
A. Pr = 0
B. Pr = 1
C. 0 < Pr ≤ 1/5
D. 1/5 < Pr < 1
Ans. D

9
www.gradeup.co

Explanation:
Number of triplets in L3 = Number of ways in which we can choose 3 elements from 5 with
repetition
=5*5*5
= 125.
Now, when we take x = t, then the given condition for L is satisfied for any y and z. Here, y and
z can be taken in 5 * 5 = 25 ways.
Take x = r, y = p, z = p. Here also, the given condition is satisfied. So, pr > 25 / 125 > 1/5.
For x = q, y = r, z = s, the given condition is not satisfied
as q ⋁ (r ⋀ s) = q ⋁ p = q, while (q ⋁ r) ⋀ (q ⋁ s) = t ⋀ t = t.
So, pr ≠ 1.
Hence D choice.

Partial Orders and Lattices

Well Ordered Set –


Given a poset, (X, ≤) we say that ≤ is a well-order (well-ordering) and that is well-ordered by
≤ iff every nonempty subset of X has a least element. When X is non-empty, if we pick any two-
element subset, {a, b}, of X, since the subset {a, b} must have a least element, we see that
either a≤b or b≤a, i.e., every well-order is a total order.
E.g. – The set of natural number (N) is a well ordered.

Bounded Lattice:
A lattice L is said to be bounded if it has the greatest element I and a least element 0.
E.g. – D18= {1, 2, 3, 6, 9, 18} is a bounded lattice.

Hasse Diagram of D18


Note: Every Finite lattice is always bounded.

10
www.gradeup.co

Complemented Lattice:
A lattice L is said to be complemented if it is bounded and if every element in L has a complement.
Here, each element should have atleast one complement.
E.g. – D6 {1, 2, 3, 6} is a complemented lattice.

In the above diagram every element has a complement.

Distributive Lattice:
It is a lattice in which meet (∧) and join (∨) operations distribute over each other.
• x ∧ (y ∨ z) = (x ∧ y) ∨ (x ∧ z)
• x ∨ (y ∧ z) = (x ∨ y) ∧ (x ∨ z)

Note:
• A complemented distributive lattice is a boolean algebra or boolean lattice.
• A lattice is distributive if and only if none of its sublattices is isomorphic to N5 or M3.
• For distributive lattice each element has unique complement. This can be used as a theorm
to prove that a lattice is not distributive.

11
www.gradeup.co

EXAMPLES
7. If every two elements of a poset are comparable then the poset is called ________

A. sub ordered poset

B. totally ordered poset

C. sub lattice

D. semigroup
Ans. B

Explanation: A poset (P, <=) is known as totally ordered if every two elements of the poset
are comparable. “<=” is called a total order and a totally ordered set is also termed as a chain.

8. ______ and _______ are the two binary operations defined for lattices.

A. Join, meet

B. Addition, subtraction
C. Union, intersection
D. Multiplication, modulo division
Ans. A

Explanation: Join and meet are the binary operations reserved for lattices. The join of two

elements is their least upper bound. It is denoted by V, not to be confused with disjunction. The

meet of two elements is their greatest lower bound. It is denoted by ∧ and not to be confused

with a conjunction.

9. A ________ has a greatest element and a least element which satisfy 0<=a<=1 for every a in

the lattice(say, L).

A. semilattice

B. join semilattice
C. meet semilattice

D. bounded lattice

Ans. D
Explanation: A lattice that has additionally a supremum element and an infimum element which
satisfy 0<=a<=1, for every an in the lattice is called a bounded lattice. A partially ordered set

is a bounded lattice if and only if every finite set (including the empty set) of elements has a
join and a meet.

12
www.gradeup.co

10. The graph given below is an example of _________

A. non-lattice poset
B. semilattice
C. partial lattice
D. bounded lattice
Ans. A
Explanation: The graph is an example of non-lattice poset where b and c have common upper
bounds d, e and f but none of them is the least upper bound.

****

13
www.gradeup.co

14

Вам также может понравиться