0% found this document useful (0 votes)
62 views22 pages

Chapter 2 Boolean Algebra & Logic Gates

The document discusses digital logic design and Boolean algebra. It defines basic binary operators like AND, OR, and NOT. It describes Boolean algebra postulates and theorems, including duality, DeMorgan's theorem, and absorption. Canonical forms like sum of products and product of sums are presented. Standard logic gates and their truth tables are defined, including AND, OR, NAND, NOR, XOR, and XNOR gates. DeMorgan's theorem is applied to transform gates between sum and product terms.

Uploaded by

natrix029
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
62 views22 pages

Chapter 2 Boolean Algebra & Logic Gates

The document discusses digital logic design and Boolean algebra. It defines basic binary operators like AND, OR, and NOT. It describes Boolean algebra postulates and theorems, including duality, DeMorgan's theorem, and absorption. Canonical forms like sum of products and product of sums are presented. Standard logic gates and their truth tables are defined, including AND, OR, NAND, NOR, XOR, and XNOR gates. DeMorgan's theorem is applied to transform gates between sum and product terms.

Uploaded by

natrix029
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 22

Princess Sumaya Univ.

Computer Engineering Dept.


Chapter 2:
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
1 / 28
Basic Definitions
Binary Operators
AND
z = x y = x y z=1 if x=1 AND y=1
OR
z = x + y z=1 if x=1 OR y=1
NOT
z = x = x z=1 if x=0
Boolean Algebra
Binary Variables: only 0 and 1 values
Algebraic Manipulation
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
2 / 28
Boolean Algebra Postulates
Commutative Law
x y = y x x + y = y + x
Identity Element
x 1 = x x + 0 = x
Complement
x x = 0 x + x = 1
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
3 / 28
Boolean Algebra Theorems
Duality
The dual of a Boolean algebraic expression is obtained
by interchanging the AND and the OR operators and
replacing the 1s by 0s and the 0s by 1s.
x ( y + z ) = ( x y ) + ( x z )
x + ( y z ) = ( x + y ) ( x + z )
Theorem 1
x x = x x + x = x
Theorem 2
x 0 = 0 x + 1 = 1
Applied to a valid
equation produces
a valid equation
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
4 / 28
Boolean Algebra Theorems
Theorem 3: I nvolution
( x ) = x ( x ) = x
Theorem 4: Associative & Distributive
( x y ) z = x ( y z ) ( x + y ) + z = x + ( y + z )
x ( y + z ) = ( x y ) + ( x z )
x + ( y z ) = ( x + y ) ( x + z )
Theorem 5: DeMorgan
( x y ) = x + y ( x + y ) = x y
( x y ) = x + y ( x + y ) = x y
Theorem 6: Absorption
x ( x + y ) = x x + ( x y ) = x
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
5 / 28
Operator Precedence
Parentheses
( . . . ) ( . . .)
NOT
x + y
AND
x + x y
OR
] ) ( [ x w z y x
] ) ( [
) (
) (
) (
) (
x w z y x
x w z y
x w z
x w
x w


Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
6 / 28
DeMorgans Theorem
)] ( [ e d c b a
)] ( [ e d c b a
) ) ( ( e d c b a
)) ( ( e d c b a
)) ( ( e d c b a
) ( e d c b a
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
7 / 28
Boolean Functions
Boolean Expression
Example: F = x + y z
Truth Table
All possible combinations
of input variables
Logic Circuit
x y z F
0 0 0 0
0 0 1 1
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
x
y
z
F
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
8 / 28
Algebraic Manipulation
Literal:
A single variable within a term that may be complemented
or not.
Use Boolean Algebra to simplify Boolean functions
to produce simpler circuits
Example: Simplify to a minimum number of literals
F = x + x y ( 3 Literals)
=x + ( x y )
=( x + x ) ( x + y )
= ( 1 ) ( x + y ) = x + y ( 2 Literals)
Distributive law (+ over )
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
9 / 28
Complement of a Function
DeMorgans Theorm



Duality & Literal Complement
C B A F
C B A F
C B A F
C B A F
C B A F
C B A F
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
10 / 28
Canonical Forms
Minterm
Product (AND function)
Contains all variables
Evaluates to 1 for a
specific combination
Example
A = 0 A B C
B = 0 (0) (0) (0)
C = 0
1 1 1 = 1
A B C Minterm
0 0 0 0 m
0

1 0 0 1 m
1
2 0 1 0 m
2
3 0 1 1 m
3
4 1 0 0 m
4
5 1 0 1 m
5
6 1 1 0 m
6
7 1 1 1 m
7
C B A
C B A
C B A
C B A
C B A
C B A
C B A
C B A
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
11 / 28
Canonical Forms
Maxterm
Sum (OR function)
Contains all variables
Evaluates to 0 for a
specific combination
Example
A = 1 A B C
B = 1 (1) + (1) + (1)
C = 1
0 + 0 + 0 = 0
A B C Maxterm
0 0 0 0 M
0

1 0 0 1 M
1
2 0 1 0 M
2
3 0 1 1 M
3
4 1 0 0 M
4
5 1 0 1 M
5
6 1 1 0 M
6
7 1 1 1 M
7
C B A
C B A
C B A
C B A
C B A
C B A
C B A
C B A
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
12 / 28
Canonical Forms
Truth Table to Boolean Function
A B C F
0 0 0 0
0 0 1 1
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 1
1 1 0 0
1 1 1 1
C B A F C B A C B A ABC
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
13 / 28
Standard Forms
Sum of Products (SOP)
ABC C B A C B A C B A F
AC
B B AC

) (
C B
A A C B

) (
B A
B A
C C B A


) 1 (
) (
) ( ) ( ) ( B B AC C C B A A A C B F
AC B A C B F
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
14 / 28
Standard Forms
Product of Sums (POS)
) ( A A C B
) ( B B C A
) ( C C B A
) ( ) ( ) ( A A C B C C B A B B C A F
C B B A C A F
C AB BC A C B A C B A F
) )( )( ( C B B A C A F
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
15 / 28
Two - Level Implementations
Sum of Products (SOP)



Product of Sums (POS)
AC B A C B F
) )( )( ( C B B A C A F
B
C
F
B
A
A
C
A
C
F
B
A
B
C
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
16 / 28
Logic Operators
AND



NAND (Not AND)
x y NAND
0 0 1
0 1 1
1 0 1
1 1 0
x y AND
0 0 0
0 1 0
1 0 0
1 1 1
x
y
x y
x
y
x y
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
17 / 28
Logic Operators
OR



NOR (Not OR)
x y OR
0 0 0
0 1 1
1 0 1
1 1 1
x y NOR
0 0 1
0 1 0
1 0 0
1 1 0
x
y
x + y
x
y
x + y
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
18 / 28
Logic Operators
XOR (Exclusive-OR)



XNOR (Exclusive-NOR)
(Equivalence)
x y XOR
0 0 0
0 1 1
1 0 1
1 1 0
x y XNOR
0 0 1
0 1 0
1 0 0
1 1 1
x
y
x y
x y
x y + x y
x
y
x y
x y + x y
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
19 / 28
Logic Operators
NOT (Inverter)



Buffer
x NOT
0 1
1 0
x Buffer
0 0
1 1
x x
x x
Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
20 / 28
Multiple Input Gates



Princess Sumaya University 4241 Digital Logic Design Computer Engineering Dept.
21 / 28
DeMorgans Theorem on Gates
AND Gate
F = x y F = (x y) F = x + y


OR Gate
F = x + y F = (x + y) F = x y
Change the Shape and bubble all lines

You might also like