Professional Documents
Culture Documents
Basic Definitions
Axiomatic Definition of Boolean Algebra
Basic Theorems and Properties of Boolean Algebra
Boolean Functions & Complement of Functions
Canonical and Standard Forms
Other Logic Operations
Digital Logic Gates
http://www.ece.stevens-tech.edu/~nader/courses/cpe358/cpe358.html
1
Boolean Algebra
Binary Operator
A binary operator defined on a set S of elements is a rule
that assigns to each pair of elements from S a unique
element from S.
Example: Given S={a,b,c,d,e,f,g} and a relation a*b = c
We say that * is a binary operator if:
1. It specifies a rule for funding c from the pair (a,b).
2. If a,b,c S.
However, * is not a binary operator if a,b S, when the
rule finds cS.
3
Common Axioms
Closure: A set S is closed with respect to a
binary operator if for every pair of elements of
S, the binary operator specifies a rule for
obtaining a unique element of S.
Example 1: The set of natural numbers
N={1,2,3,.} is closed with respect to
+(addition) since the sum of any two natural
numbers is also a natural number.
Example 2: The set of natural number is not
closed with respect to (subtraction) since the
difference of two natural numbers may be
negative.
4
xy
x+y
is distributive over +:
x (y+z)=(xy)+(xz)
It can be proved by a truth table.
10
11
(a) x + 0 = x
(b)
x1=x
(a) x + y = y + x
(b)
xy = yx
(a) x + x = 1
(b)
x x = 0
12
Theorem 1(a)
x+x =x
x + x = (x + x) 1
= (x + x) (x + x)
= x + x x
=x+0
=x
By axiom 1(b)
By axiom 4(a)
By axiom 3(b)
By axiom 4(b)
By axiom 1(a)
13
Theorem 1(b)
xx =x
xx =xx+0
= x x + x x
= x( x + x)
=x1
=x
By axiom 1(a)
By axiom 4(b)
By axiom 3(a)
By axiom 4(a)
By axiom 1(b)
14
Theorem 2(a)
x+1 =1
x + 1 = x1 + 1
= 1(x+1)
= ( x + x )(x + 1)
= x + x 1
= x + x
=1
By axiom 1(b)
By axiom 3(b)
By axiom 4(a)
By axiom 3(b)
By axiom 1(b)
By axiom 4(a)
15
Theorem 2(b)
x0=0
Can be found by using the duality principle on
Theorem 2(a)
Theorem 2(a): x + 1 = 1
We need to interchange OR and AND operators
and replace 1s by 0s and 0s by 1s.
x0=0
16
(a) x + 0 = x
(b)
x1=x
(a) x + y = y + x
(b)
xy = yx
(a) x + x = 1
(a) x + x = x
(a) x + 1 = 1
(b)
(b)
(b)
x x = 0
xx=x
x0=0
17
Theorem 3
(x) = x.
x
0
1
x
1
0
(x)
0
1
18
Theorem 4(a)
x + xy = x
x + xy = x1 + xy
= x(1 + y)
= x(y + 1)
=x1
=x
By axiom 1(b)
By axiom 3(a)
By axiom 2(a)
By Theorem 2(a)
By axiom 1(b)
19
Theorem 4(b)
x( x + y) = x by duality (from Theorem 4(a)).
A truth table can be used to prove the
correctness of the expression.
x
0
0
1
1
y
0
1
0
1
(x + y) x(x+y)
0
0
1
0
1
1
1
1
20
DeMorgans Theorem
(x + y) = xy
x
0
0
1
1
y
0
1
0
1
x+y
0
1
1
1
(x+y)
1
0
0
0
x
1
1
0
0
y
1
0
1
0
xy
1
0
0
0
21
Operator Precedence
The operator precedence for evaluating
Boolean expressions is
1. Parentheses
2. NOT
3. AND
4. OR
Example 1: (x + y)
Example 2: xy
22
Boolean Functions
Boolean functions express the logical relationship between
binary variables.
Example 1: F1 = x + yz
The function F1 is equal to 1 if x is equal to 1 or if both y
and z are equal to 1. Therefore F1=1 if x=1 or y=0 and
z=1 otherwise F1=0.
Example 2: F2 = xyz + xyz + xy
23
y
0
0
1
1
0
0
1
1
z
0
1
0
1
0
1
0
1
y
1
1
0
0
1
1
0
0
yz
0
1
0
0
0
1
0
0
F1=x+yz
0
1
0
0
1
1
1
1
24
F1
y
z
Gate Implementation of F1 = x + yz
F2 = xyz + xyz + xy
x
y
F2
26
F2 can be reduced:
F2 = xyz + xyz + xy = xz(y+y) + xy = xz + xy
x
y
F2
z
27
Algebraic Manipulation
Simply the following Boolean functions to a
minimum number of literals:
1.
2.
3.
4.
5.
x(x+y)
x+xy
(x+y)(x+y)
xy+xz+yz
(x+y)(x+z)(y+z)
28
Solution
1. x(x+y) = xx + xy = 0 + xy = xy
2. x+xy = (x+x)(x+y) = 1(x+y) = x+y
3. (x+y)(x+y) = xx+xy+yx+yy = x+ xy+yx+0 =
x(1+y+y) = x1 = x
4. xy+xz+yz = xy+xz+yz(x+x) =
xy+xz+yzx+yzx = xy(1+z)+xz(1+y)
= xy+xz
5. (x+y)(x+z)(y+z) = (x + y)(x +z) by duality
from functions 4.
29
Complement of Functions
The complement of a function F is F and
obtained from an interchange of 0s for 1s
and 1s for 0s in the value of F or by using
DeMorgans theorem:
(ABCF) = A + B + C + D++F
Example: Find the complement of functions
F1 and F2:
F1= xyz+xyz
F2= x(yz+yz)
30
Solution
F1= [xyz+xyz]=(xyz)(xyz)
= ( x + y +z )(x +y + z)
F2= [x(yz+yz)]= x+(yz+yz)
= x+(yz)(yz)
= x+(y+z)(y+z)
The complement of a function can be found by
taking its dual and complement each literal.
Example: The dual of F1 is (x+y+z)(x+y+z)
Complement each literal: (x+y+z)(x+y+z)
31
Canonical Forms
A binary variable can be written in its normal form x or
in its complement form x.
Combining two binary variable (x and y) with AND
operation: four possible combinations xy, xy, xy,
and xy. Each term is called a minterm or a standard
product.
Combining two binary variable (x and y) with OR
operation: four possible combinations (x+y), (x+y),
(x+y), and (x+y). Each combination is called a
maxterm or a standard sum.
For n variables, there are 2n possible minterms or
maxterms.
32
Maxterms
TERM
Designation
xyz
m0
x+y+z
M0
xyz
m1
x+y+z
M1
xyz
m2
x+y+z
M2
xyz
m3
x+y+z
M3
xyz
m4
x+y+z
M4
xyz
m5
x+y+z
M5
xyz
m6
x+y+z
M6
xyz
m7
x+y+z
M7
We have mj= Mj .
33
y
0
z
0
F1
0
F2
0
34
x
0
y
0
z
0
F1
0
F2
0
38
B
0
0
1
1
0
0
1
1
C
0
1
0
1
0
1
0
1
F=AC+B
1
1
0
0
1
1
0
1
39
Solution 3:
F=AC+B = B + AC
By using the distributed law:
F=(B+A)(B+C) =(A+B)(B+C)
We have:
A+B = A+B+CC = (A+B+C)(A+B+C)
B+C = B+C +AA = (A+B+C)(A+B+C)
F= (A+B+C)(A+B+C)(A+B+C)(A+B+C)
= (A+B+C)(A+B+C)(A+B+C)=M2M3M6
F(A,B,C)= (2,3,6)
41
42
Example:
F(A,B,C)= (0,1,4,5,7)
F(A,B,C) =(2,3,6)= m2+m3+m6
If we take the complement of F by DeMorgans theorem, we
obtain F in a different form:
F=(m2+m3+m6)= m2m3m6 = M2M3M6 = (2,3,6)
Question: Prove that F= (0,1,4,5,7)?
43
Example:
Given F(x,y,z)= (1,3,6,7),
1. Express F in a product of maxterms
2. Find F in a sum of minterms
3. Find F in a product of maxterms
Solution
1. F(x,y,z) = (0,2,4,5)
2. F(x,y,z) = (0,2,4,5)
3. F(x,y,z) = (1,3,6,7)
44
Standard Forms
The terms that form the function may contain any
number of literals.
Two types:
1. The sum of products (ex: F1=y+xy+xyz).
2. The product of sums (ex: F2=x(y+z)(x+y+z) )
A Boolean function may be express in nonstandard form
(ex: F3=AB+C(D+E)). The function is neither in
sum of products nor in product of sums.
Functions with Standard forms can be implemented
using two-level gating structure while functions
with non-standard form may need more than two
levels of gating structure.
45
x
0
0
1
1
y
0
1
0
1
F0 F1 F2 F3 F4 F5 F6 F7 F8 F9
0
0
0
0
0
0
0
1
0
0
1
0
0
0
1
1
0
1
0
0
0
1
0
1
0
1
1
0
0
1
1
1
1
0
0
0
1
0
0
1
1
0
1
0
1
0
1
1
1
1
0
0
1
1
0
1
1
1
1
0
xy
y
x+y
46
1
1
1
1
Boolean Functions
Operator Symbol
F0=0
Name
Comments
Null
Binary Constant 0
F1=xy
xy
AND
x and y
F2=xy
x/y
Inhibition
x, but not y
Transfer
Inhibition
y, but not x
Transfer
F3=x
F4=xy
y/x
F5=y
F6=xy+xy
xy
Exclusive-OR
F7=x+y
x+y
OR
x or y
F8=(x+y)
xy
NOR
Not-OR
F9=xy + xy
( x y )
Equivalence
x equals y
F10= y
Complement
Not y
F11= x + y
xy
Implication
If y, then x
F12= x
Complement
Not x
F13= x + y
xy
Implication
If x, then y
F14= (xy)
xy
NAND
Not-AND
F15=1
Identity
47
F=(x+y)
NOR
0
48
x
y
x
y
F=xy+xy
=xy
F=xy+xy
= (x y)
49
50
F=x+y+z
x
y
F=xyz
z
51
53