LATTICES

advertisement
LATTICES
A lattice is a poset (L,  ) in which every subset { a, b} consisting of two elements has a least
upper bound and a greatest lower bound .
We denote LUB ({a, b}) by a  b and call it as join of a and b. Similarly we denote GLB
{a, b} by ab and call it as meet of a and b.
PROPERTIES OF LATTICES:
Using the binary operation is denoted by 
1. a  a= a
 idempotent
2. a  b= b  a
 commutative
3. (a  b)  c = a  (b  c)  associative
4. a  (a  b) = a
 absorption
Using the binary operation is denoted by 
1. a  a= a
 idempotent
2. a  b= b  a
 commutative
3. (a  b)  c = a  (b  c)  associative
4. a  (a * b) = a
 absorption
Exercise:
(1) Show that glb & lub are unique.
(2) Prove the lattices satisfy idempotent, commutative, associative and absorption
properties.
(3) Let (L, ≤) be a lattice on * &  denote glb & Lub respectively.
Prove:
a ≤ b  a * b = a,
a * b = a  a  b=b
(4) If L= {1, 2, 3, 5, 30} is a poset. Verify L is lattice under divisibility and verify it is
distributive or not.
COMPARABLE:
The elements a & b are said to be comparable, if one of them presides the other.
(i.e) a ≤ b or b ≤ a .Otherwise they are not comparable.
EXAMPLE:
Verify whether the given set A = {3, 5, 10} is comparable or not by the relation divisibility.
SOLUTION:
It is not comparable.
Because 10 / 5, but 5 / 3 .it is not possible.
So it is not comparable.
LINEAR ORDER SET (or) CHAIN (or) TOTALLY ORDERED SET:
A poset ‘S’ is said to be linear order set, if every pair of element in S are comparable.
(i.e) either x ≤ y (or) y ≤ x for all x, y  S.
EXAMPLE:
Show that {24, 2, 6} is comparable under divisibility relation.
SOLUTION:
24 / 2, 24 / 6, 6 / 2. So every pair of elements are comparable. Hence this set is called
linear order set.
UPPER BOUND, LOWER BOUND, LEAST UPPER BOUND AND A GREATEST LOWER
BOUND
Definition:
Let (S, ≤) be a poset and A  S , an element x  S is said to be upper bound for A if a ≤ x,
for all a  A.
An element x  S is said to be lower bound for A if a  x, for all a  A.
An element x  S is said to be least upper bound for A if x ≤ y, where y is any other upper
bound for A.
An element x  S is said to be greatest lower bound for A if x  y, where y is any other
lower bound for A.
PROBLEMS:
1. Let D30 = {1, 2, 3, 5, 6, 10, 15, 30} and let the relation D be the divides on D30.
(i.e) x r y if x divides y. Find
a) all lower bounds of 10 & 15
b) all g L b of 10 & 15
c) all upper bounds of 10 & 15
d) the lower bounds of 10 & 15
e) draw the hasse diagram. D30 with D.
2. A = {1, 2, 3, 4, 6, 8, 9, 12, 18, 24} ordered by divisibility. Draw the hasse diagram & find
a) L u b and g l b of {4, 6}
b) L u b and g l b of {12, 8}
THEOREM:
Let (L, ≤) be lattices  and  denote L u b and g l b respectively. Prove
a≤b  ab=a
ab = a ab=b
PROOF:
Case 1:
Prove a ≤ b  a  b = a
Already we know that
aρaa≤ab
(1)
(i.e) a is reflexive to g l b of a & b
by g l b ,
ab≤a
From (1) & (2)
ab = a
CONVERSE PART:
Prove a ≤ b if a  b = a
(i.e) g l b of a & b is ‘a’
It is possible only if a ≤ b
(i.e) a  b = a  a ≤ b
Hence a ≤ b  a  b = a
Case 2:
Prove a  b = a  a  b = b
Now let a  b = a
To prove a  b = b
By absorption
b = b  (b  a)
(2)
= b  (a  b)  (communicative)
= b  a  (given)
b=ab
Hence the proof.
Note:
If n is a positive integer and Dn is the set of a positive divisor of n, then Dn is a lattice under the
relation of divisibility.
Examples
D6 = {1, 2, 3, 6}
D12 = {1, 2, 3, 4, 6, 12}
D20 = {1, 2, 4, 5, 10, 20}
Definition:
Let (L,  ) be a lattice. A nonempty subset S of L is called a sublattice of L if a  b  S and
a  b  S whenever a  S and b  S.
Definition:
A lattice L is said to be bounded if it has a greatest element 1 and has a least element 0.
The lattice P(S) of all subsets of a set S is bounded, its greatest element is S and least element is φ .
Definition:
A lattice L is called distributive if for any elements a, b and c in L, we have the following
distributive laws:
(i) a  (b  c) = (a  b)  (a  c)
(ii) a  (b  c) = (a  b)  (a  c)
Definition:
Let (L,  ,  ,  , 0, 1) be a Lattice . An element b  L is said to be Complement of an
element a  L if a  b = 0 and a  b = 1.
Example:
1
a
b
0
c
Complements of a are b and c, Complements of b are a and c, Complements of c are a and b,
Complement of 0 is 1 and Complement of 1is 0.
Definition:
A lattice L is called complemented if it is bounded and if every element in L has atleast one
complement.
DIRECT PRODUCT:
Let (L, *,) and (S, , ) be two lattices . The algebraic system (L x S, ., +) in which
the binary operation + and on L x S such that for any (a1, b1), (a2, b2) in L x S
i.e., (a1, b1). (a2, b2) = (a1* a2, b1  b2)
(a1, b1)+ (a2, b2) = (a1 a2, b1  b2)
is the direct product of the lattices of (L ,* ,) and (S, , )
Hasse diagrams for (all lattices)
D12 = {1, 2, 3, 4, 6, 12}
12
D6 = {1, 2, 3, 6}
6
2
3
1
4
6
2
3
1
(b)
D20= {1, 2, 4, 5, 10, 20}
D24 = {1, 2, 3, 4, 6, 8, 12, 24}
20
24
4
10
2
5
8
12
4
6
2
3
1
1
(d)
(c)
D30 = {1, 2, 3, 5, 6, 10, 15, 30}
D42 = {1, 2, 3, 6, 7, 14, 21, 42}
42
30
10
6
3
2
15
5
1
(e)
105
21
5
3
1
(h)
14
2
3
1
(f)
D105 = {1, 3, 5, 7, 15, 21, 35, 105}
15
6
35
7
21
7
D72 = {1, 2, 3, 4, 6, 8, 9, 12, 18, 24, 36, 72}
72
24
36
12
18
8
9
4
6
2
3
1
(g)
The following Hasse diagram does not represent lattices
f
f
g
e
d
e
b
c
d
b
c
a
a
f ν g does not exist(i)
Neither d  e nor b  e exist (ii)
The lattice shown below is distributive
1
b
d
a
e
0
(iv)
Distributive law for all ordered triplets chosen from the elements a, b, c, and d holds.
Find the complements of D105= {1, 3, 5, 7, 15, 21, 35, and 105}
1’ = 105, 3’ = 35, 5’=21, 7’=15, 35’ =3, 21’=5, 15’= 7.
In D20 the elements 2 and 10 have no complements.
The Lattice Z+ under the usual partial order  is distributive.
The dual of a distributive Lattice is also distributive.
The Lattice Dn is distributive.
The Lattice shown in figure (v) and fig (vi) each have the property that every element has a
complement. c has two complements a and b.
The following lattices are not distributive.
1
1
a
a
b
c
c
0
(vi)
b
0
a  (b  c)  a  1  a
a  (b  c)  a  1  a
while[(a  b)  (a  c)]  b  0  0
while (a  b)  a  0  0  0
f
d
e
c
a
b
Non Distributive Non Complementory
Let A {1, 2, 3, 4, 6, 8, 9, 12, 18, 24} be ordered by relation “x divides y”. Draw the Hasse diagram
of A.
24
8
12
18
4
6
2
9
3
1
Exercise:
Draw the Hasse diagram for D36 by the divisor relation.
Consider the lattice L shown in the figure below L = {0, a, b, c, d, e}
l
d
e
c
a
b
0
(c)
A subset of L’ is a sub lattice of L i.e, it is closed under  and  .
Find the complement of a, b and c.
[ a  e  0, a  e  1.  a and e are complement, b and d are complement and c has no
complement.]
a) Which non-zero element and zero-elements are join irreducible?
(These non-zero elements with a unique immediate predecessor or are join irreducible. Hence
a, b, d, e are join irreducible)
(b) Which elements are atoms?
(These elements which immediately succeed are atoms, here a and b are atoms)
(c) Which of the following are sub lattice of L.
L1= {0, a, b, 1}
- Not a sub lattice since a a  b  c  L1
L2= {0, a, e, 1}
- Sub-lattice
L3= {a, e, d, 1}
- Sub-lattice
L4= {0, e, d, 1}
- Not a sub-lattice, since c  d  a  L 4
 THEOREM :
Every chain is distributive.
Chain means every pair of elements is comparable.
i.e., a ≤ b or b ≤ a
Here, consider two possible cases

a≤b≤c

a≥b≥c
Distributive means we have to prove
a*(bc)=(a*b)(a*c)
a  ( b * c ) = ( a  b ) * ( a  c)
Case (1):
Suppose a ≤ b ≤ c. Then
a*b=a
ab=b
a*c=a
ac=c
b*c=b
bc=c
a*(bc)=a*c=a
(1)
(a * b )  (a * c ) = a  a = a
(2)
From (1) and (2),
a*(bc)=(a*b)(a*c)
(A)
a(b*c)=ab=b
(3)
(a  b ) * (a  c ) = b * c = b
(4)
From (3) and (4),
a(b*c)=(ab)*(ac)
(B)
From (a) and (B), we have the distributive laws are true when a ≤ b ≤ c
Case (2) :
Suppose a ≥ b ≥ c. Then
a*b=b
ab=a
a*c=c
ac=a
b*c=c
bc=b
a*(bc)=a*b=b
(a * b )  (a * c ) = b  c = b
(1)
(2)
From (1) and (2)
a * ( b  c ) = (a * b )  (a * c )
(A)
a(b*c)=ac=a
(3)
(a  b ) * (a  c ) = a * a = a
(4)
From (3) and (4),
a(b*c)=(ab)*(ac)
(B)
From (a) and (B), we have the distributive laws are true when a ≥ b ≥ c
a(b*c)=(ab) *(ac)
COMPLETE LATTICE
Lattice is
complete if each of its non empty subset has lub and glb.
COMPLEMENT IN LATTICE
In a bounded lattice (L,  ,+,0,1) and a element b  L is called complement of an
element a  L if a*b=0 , a  b=1.
ORDER HOMOMORPHISM
Let (L,*,, 0, 1) and (S, Λ,\/, 0,1) be any two lattices, then
g: L S is called, order homomorphism, then a ≤ b => g(a)≤’g(b).
EX: Prove that direct product of two distributive lattice is
also a distributive lattice.
THEOREM :
Let (L, ≤) be a lattice for any a,b,c £ L. The following property is called
ISONTONICITY.
(ie) b ≤ c => a * b ≤ a * c
a  b≤ a  c
Proof:
Already we know that
a ≤ b  a*b=a
a * b=a a  b =b
CASE (i)
Given b ≤ c => b * c = b
(1)
PROOF:
A*b≤a*c
It is enough to prove
(a * b) * (a * c) = a * b
(a * b) * (a * c)=a* (b * a)* c
=a * (a * b) *c [commutative]
= (a* a) * (b * c)
= a * (b * c)
[By idompotent]
(a * b) * (a * c) = a * b
(a * b) ≤ a * c
(A)
CASE(ii)
B ≤ c => b  c= c
TO PROVE:
ab≤ac
It is enough to prove
(a  b) (a  c ) = a  c
(a b)  (a  c) =a  (b a)  c
= a  (a  b)  c
= (a  a)(b  c)
=ac
(a  b)  (a  c) = a c
A  b ≤a  c
(B)
Hence the theorem.
Theorem:
Let (L, ≤) be a lattice for any a, b, c, £ L if the following inequalites holds
a  (b*c) ≤ (a b)*(a c)
a*(b  c) ≤ (a* b)  (a * c)
Theorem:
If a ≤ b & c ≤ d then prove a * c ≤ b * d
Given:
a ≤ b=> a * b=a
a  b=b
c ≤ d=> c * d=c
c  d=d
PROOF:
a*c≤b*d
(a * c) * (b * d) =a * (c * b) * d
=a * (b * c) * d
= (a * b) * (c * d)
=a *c
a*c≤b*d
MODULAR INEQUALITY
Let (L, ≤) be a lattice for any a, b, c £ L then the following inequality holds in L. a ≤ c 
a  (b * c) ≤ (a  b) * c
CASE 1:
PROOF:
Let a ≤ c
-----(1)
a*c=a, ac=c
Already we know that,
b*c≤c
Since b * c is glb of b & c
b*c≤b, b*c≤c
By the definition of inequivalence
a  (b * c )≤ (a  b)*(a  c)
a  (b * c)≤ ( a  (b) * c)
[since a  c = c]
Conversely
Let a  (b * c) ≤ (a  b) * c
To prove a ≤ c
a≤ay
[for all y £ c]
≤ a  (b * c) [let y =glb of b & c]
≤ (a  b) * c
≤b*c
a ≤ c [since a  b is lub of a&b]
a≤ab
b≤ab
Hence the proof
Theorem:
If a, b, c are the elements of distributive lattice (L,*,)
a  b=a  c & a * b=a * c
(or)
(a  b=a  c) and (a*b=a*c)=>b=c
(L, * , ) a  b=a  c, a * b=a * c
TO PROVE:
b=c
By absorpion law
b = b  (b * a)
=b  (a * b)
=(b  a) * (b  c)
=(a  b) * (c  b)
=(a  c) * (c  b)
=(c  a) * (c  b)
=c  (a * b)
=c  (c * a)
b=c
Hence it is proved.
ALGEBRAIC SYSTEM
A lattice is an algebraic system with two binary operations * and  on L which are
both commutative and associative and satisfy the absorption law.
DISTRIBUTIVE LATTICE
A lattice L, *,  is called distributive lattice for any a, b, c £ L such that
a * (b  c)=(a * b)  (a * c)
a  (b * c)=(a  b) * (a  c)
Combinatorial Circuits
In a digital computer, there are only two possibilities written 0 and 1, for the
smallest, indivisible object. A bit in one part of a circuit is transmitted to another part of the
circuit as a voltage. Thus two voltages are needed-a high voltage can communicate 1 and a
low voltage can communicate 0.
A combinatorial trial circuits can be constructed using solid state devices called gates,
which are capable of switching voltage levels (bits).

A combinatorial circuit has no memory; previous inputs and the state of the system do
not affect the output of a combinatorial circuit. Circuits for which the output is a function
not only the inputs but also the state of the system, are called sequential circuits.
Definition

An AND gate receives inputs x1 and x2, where x1 and x2 are bits and produces output
denoted by x1 Λ x2, where
1 if x1  1 and x2  1
x1  x2  
0 otherwise
x1
x2
x1 Λ x2
AND gate:

An OR gate receives inputs x1 and x2, where x1 and x2 are bits and produces output
denoted by x1 ν x2, where
1 if x1  1 and x2  1
x1  x2  
0 otherwise
OR gate:
•
A NOT gate (or inverter) receives input x, where x is a bit and produces output denoted by
, where
x
1 if x  0
x
0 if x  1
NOT gate:
x
x
Logic table for the basic AND, OR and NOT circuits
AND
X1
X2
X1 Λ X2
1
1
1
1
0
0
0
1
0
0
0
0
X1
X2
X1 ν X2
1
1
1
1
0
1
0
1
1
0
0
0
OR
NOT
x
x
1
0
0
1
Logic Table
X1
X2
X3
y
1
1
1
0
1
1
0
0
1
0
1
0
1
0
0
1
0
1
1
0
0
1
0
1
0
0
1
0
0
0
0
1
The corresponding Boolean expression is (and is written as dnf here)
y  ( x1  x2 )  x3
 (( x1 x2 )  x3 ) '
 ( x1 x2 ) ' .x3
'
 ( x1  x2 ) x3
'
'
'
 x1 x3  x2 x3
'
'
'
'
 x1 ( x2  x2 ) x3  ( x1  x1 ) x2 x3
'
'
'
'
'
'
 x1 x2 x3  x1 x2 x3  x1 x2 x3  x1 x2 x3
'
'
'
'
'
'
 x1 x2 x3  x1 x2 x3  x1 x2 x3
'
'
(b)
'
'
(c )
'
'
'
'
'
'
'
(a)
Ex: Find the combinatorial circuit corresponding to the Boolean expression
 

Y  x1  x2  x3  x3
x1
x2
x1  ( x 2  x3 )
x2
x3
x  x
2
3
Properties of Combinatorial Circuits
If , and  are as defined below
1 if x1  1 and x 2  1
x1  x 2  
0 otherwise
1 if x1  1 and x 2  1
x1  x 2  
0 otherwise
1 if x  0
x
0 if x  1
Then the following properties hold
(a) Associative Laws:
(a ν b) ν c = a ν (b ν c)
(a Λ b) Λ c=a Λ (b Λ c) for all a, b, c  Z2
(b) Commutative Laws:
a ν b= b ν a
a Λ b=b Λ a for all a, b, c  Z2
( x1  ( x 2  x3 ))  x3
(c) Distributive Laws:
a Λ (b ν c) = (a Λ b) ν (a Λ b)
a ν (b Λ c)=(a ν b) Λ(a Λ c) for all a, b, c  Z2
(d) Identity Laws:
aν0=a
a Λ 1=a for all a,b,c  Z2
(e) Complement laws:
a  a 1
a  a  0 for all a, b, c  Z 2
BOOLEAN FUNCTION AND SYNTHESIS OF CIRCUITS
Exclusive – OR of x1 and x2
The domain is the set of inputs and the range is the set of outputs. For exclusiveOR function given in the table below, the domain set is the set.
{(1, 1), (1, 0), (0, 1), (0, 0)} and the range is the set Z2={0,1}
X1
X2
X1  X2
1
1
0
1
0
1
0
1
1
0
0
0
By definition, an exclusive OR is true i.e X1  X2 is true if either x1 or x2 but not both true.
The logic table indicates this concept. The logic table with one output is a function. Let
x1 x2  X ( x1x2 )
'
'
 x1x2  x2 x1
The r.h.s is a Boolean function.
Definitions
Boolean Function
Let X (x1, x2, …, xn) be a Boolean expression. A function of the form
f (x1, x2,…….xn) =X (x1,x2,…….xn) is called a Boolean function.
Min Term
A min term in the symbols x1,x2,…….xn is a Boolean expression of the form y1Λy2
Λ……Λyn, where each yi is either xi or xi .
Disjunctive normal form (dnf)
Let mi  y1  y2  ......  yn , where
x j 
y j   is either x j or x j
x j 
The function f(x1, x2, …, xn)
=m1ν m2 ν……………..mk is called the disjunctive normal form (dnf)
Max Term
The terms of the form
Mi=y1 Λ y2 Λ ….. Λyn where
yj is either xj or xj, is called the max term.
Conjucative normal form (cnf)
Each Mi is of the form
Mi=y1 Λ y2 Λ….. Λyn where
Yj is either xj or xj; their –representation of the function with form of
f(x1, x2,…..xn) = M1ΛM2Λ….Mk is called the conjunctive normal form (cnf).
A combinatorial circuit using AND, OR and NOT gates that would compute an arbitrary function
Z2n into Z2 where Z2 = {0,1}.
A Gate is a function from Z2n into Z2.
The set of gates {g1,g2,……….gk} is said to be functionally complete if, given any
positive integer n and function f from Z2n into Z2, it is possible to construct a combinatorial
circuit that computes using only the gates g1,g2,…..gk.
Theorem:
The set of gates {AND, NOT}, {OR, NOT} are functionally complete
Proof:
x  y  x  y involution law
xy De Morgan’s law
We have
Therefore, an OR gate can be replaced by one AND gate and three NOT gates.A combinational
circuit using only AND and NOT gates that computes x  y
x
x y
y
Hence {AND, NOT} is functionally complete.
Similarly,” {OR, NOT} is functionally complete” can be established.
Definition
A NAND gate receives inputs X1 and X2 where X1 and X2 are bits and produces
output denoted by X1 ↑ X2,where
0
X1 ↑ X2 = 
1
if X 1  1 andX 2  1
otherwise
A NAND gate is drawn as shown below.
X1
X2
X2
X1 ↑ X2
Theorem:
The set {NAND} is a functionally complete set of gates
Proof:
First we observe that
x1  x 2  xy
x
y
s
c
Download