Title: Algebra
1Algebra
Algebra defined by the tuple ?A, o1, ,
ok R1, , Rm c1, , ck? Where A is a
non-empty set oi is the function, oi Api? A
where pi is a positive integer Rj is a
relation on A ci is an element of
A EXAMPLE ?Z, , ?? Z is a set of integers
is addition operation ? is less than or
equal to relation
2Lattice Algebra
Lattice Algebra defined by the tuple ?A,
?, ? Where A is a non-empty set ?, are
binary operations And, the Following Axioms
Hold a ? a a a a a
(Idempotence) a ? b b ? a a b b
a (Commutativity) a ? (b ? c) (a ? b ) ? c
a (b c) (a b) c (Associativity) a ?
(a b) a a (a ? b) a
(Absorption) a,b,c ? A
3Distributive Lattice Algebra
Distributive Lattice Algebra A Lattice Algebra
plus the Following Distributive Laws Hold a
? (b c) (a ? b ) (a ? c) a
(b ? c) (a b) ? (a c) Complemented
Distributive Lattice Algebra 1) maximal element
1 2) minimal element 0 3) For any a ? A if
? xa? A such that a xa 0 4) For any a ? A
if ? xa ? A such that a ? xa 1 A Complemented
Distributive Algebra is a Boolean Algebra
4Distributive Lattice Examples
1
c is complement of a c is complement of b
1
a
c
No complement
b
a
0
0
a (b ? c) (a b) ? (a c)? a
1 a (a b) ? (a c) b ? 0
b No, non-distributive lattice!
5Boolean Algebra
?B, ?, , , 0, 1? 0, 1? B is a
unary operation over B ?, are binary
operations over B 0 is the identity element
wrt ? 1 is the identity element wrt
Ordered Set
Lattice
Dist. Lattice
Boolean Algebra
6Boolean Algebra Postulates
?B, ?, , , 0, 1? 0, 1? B For arbitrary
elements a,b,c ? B the Following Postulates
Hold Absorption a ? (a b) a a
(a ? b) a Associativity a ? (b ? c) (a ? b
) ? c a (b c ) (a b) c Commutativity
a ? b b ? a a b b a Idempotence a ?
a a a a a Distributivity a ? (b c)
(a ? b) (a ? c) a (b ? c) (a b) ? (a
c) Involution a a Complement a ? a 1
a a 0 Identity a ? 0 a a 1 a a
? 1 1 a 0 0 DeMorgans a ? b a b
a b a ? b
7Huntingtons Postulates
?B, ?, , , 0, 1? 0, 1? B All Previous
Postulates may be Derived Using Commutativi
ty a ? b b ? a a b b
a Distributivity a ? (b c) (a ? b) (a ?
c) a (b ? c) (a b) ? (a c) Complement
a ? a 1 a a 0 Identity a ? 0 a
a 1 a If Huntingtons Postulates Hold
for an Algebra then it is a Boolean Algebra
8DeMorgans Theorem
?B, ?, , , 0, 1? 0, 1? B Theorem Let F(x1,
x2,,xn) be a Boolean expression. Then, the
complement of the Boolean expression F(x1, x2,,
xn) is obtained from F as follows 1) Add
parentheses according to order of operation 2)
Interchange all occurrences of ? with 3)
Interchange all occurrences of xi with xi 4)
Interchange all occurrences of 0 with
1 EXAMPLE F a ? ( b c ) F a ( b
? c ) a ? (b c ) a ( b ? c )
9Principle of Duality
?B, ?, , , 0, 1? 0, 1? B Interchanging
all occurrences of ? with and/or interchanging
all occurrences of 0 with 1 in an identity,
results in another identity that holds. A is a
Boolean expression and AD is the Dual of
A 0D1 1D0 A, B and C are Boolean
Expressions if A B ? C then AD BD
CD if A B C then AD BD ? CD if
A B then AD BD
10Logic (Switching) Functions
B 0, 1 The set of all mappings Bn ? B for B
0,1 can be represented by Boolean expressions
and are called two-valued logic functions or
switching functions. The set Bn contains 2n
elements The total number of mappings or
functions is The notation we use is f Bn ?
B f can also be described through the use of an
expression
11Multi-dimensional Logic Functions
- fBn?Bm B0,1
- f is a vector of functions fi Bn?B where I 1
to m - Bn represents the set of all elements in the set
formed by n applications of the Cartesian Product
B? B ? ? B - Bn can also be interpreted geometrically as an
n-dimensional hypercube - The geometrical representations are referred to
as cubical representations - Each element in Bn is represents a geometric
coordinate a discrete hyperspace
12Cubical Representation
- Consider fB3?B B0,1
- The domain of f is a hypercube of dimension n
3 - The range of f is a hypercube of dimension n 1
(0,1,1)
(1,1,1)
(1,1,0)
f
(0,1,0)
0
1
(0,0,1)
(1,0,1)
(0,0,0)
(1,0,0)
NOTE These are (sideways) Hasse Diagrams for B3
and B1 !!!
13Some Definitions
- variable A symbol representing an element of B
- xi ? B
- literal xi or xi
- if xi0 then xi 1
- if xi 1 then xi 0
- product a Boolean expression composed of
literals and the ? operator - (e.g. x1?x3?x4)
- NOTE when two literals appear next to each
other, the ? operation is assumed to be present - (e.g. x1x3x4)
- cube another term for a product
- minterm an element of Bn for fBn? B such that
f 1 - j-cube a product composed of n-j literals
- f(x1, x2,,xn) a function f Bn ? B
- f(x1, x2,, xn) a multi-dimensional function f
Bn ?Bm
14Functions and Expressions
?B, , , , 0, 1? B 0, 1 A specific
function may be defined by an expression
EXAMPLE Consider the Boolean algebra defined
above. Each operation can be given a name and
defined by a personality matrix or table. The
table contains the operation result for each
element in B?B for a binary operation and for
each element in B for a unary operation.
NAME is OR
NAME is AND
NAME is NOT
EXAMPLE A function f B3? B can be specified by
an expression over some Boolean algebra. f(x1,
x2, x3) x1 x1 x2 x3
15Geometric Interpretation of a Function
?B, , , , 0, 1? B 0, 1 f(x1, x2, x3)
x1 x1 x2 x3
(0,1,1)
(1,1,1)
(1,1,0)
f
(0,1,0)
x2
0
1
x3
(0,0,1)
(1,0,1)
x1
(0,0,0)
(1,0,0)
f 1 denotes the on-set of the function
f on-set is a set of cubes in the domain of f
for which f 1 f 1x1, x1x2x3
16Geometric Description of a Function
? B, , , , 0, 1? B 0, 1 f(x1, x2, x3)
x1 x1 x2 x3
(0,1,1)
(1,1,1)
(1,1,0)
(0,1,0)
x2
x3
(0,0,1)
(1,0,1)
x1
(0,0,0)
(1,0,0)
- f ?(0,1,2,3,6) where each value represents a
0-cube - Each cube in f1x1, x1x2x3 covers 1 or more
0-cubes - x1 covers 000, 001, 010, 011 x1 is a 2-cube
- x1x2x3 covers 110 x1x2x3 is a 0-cube
17Geometric Description (cont)
? B, , , , 0, 1? B 0, 1 f(x1, x2, x3)
x1 x1 x2 x3 x1 x2 x3
(0,1,1)
(0,1,1)
(1,1,1)
(1,1,1)
(1,1,0)
(1,1,0)
(0,1,0)
(0,1,0)
x2
(0,0,1)
x3
(0,0,1)
(1,0,1)
(1,0,1)
x1
(0,0,0)
(1,0,0)
(0,0,0)
(1,0,0)
- minterm any 0-cube that is covered by any
element in f 1 - dont care is a variable that is not present
in a cube in f 1 - dont care is denoted by -
- f 1x1--, x1x2x3-x2x3, x1-x3, x1x2x3
- x2 and x3 are dont cares in cube x1
18Cube Sets
- f 1 is a set of all cubes for which f
1 (on-set) - f 0 is a set of all cubes for which f
0 (off-set) - f DC is a set of all cubes for which f dont
care (DC-set) - f is completely specified if any two of f 0, f
1 or f DC are given - f is incompletely specified proper subsets
are given for f 0, f 1 or f DC - f 1 is said to be a cover for f