0% found this document useful (0 votes)
19 views37 pages

CE 212 Digital Systems Ch4

Uploaded by

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

CE 212 Digital Systems Ch4

Uploaded by

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

CE 212-DigitaL Systems

Adapted from Dr. Ashraf Al Suyyagh slides by Eng. Marwa Al-Tahaineh

CHARLES KIME & THOMAS KAMINSKI © 2008 PEARSON EDUCATION, INC. 1


Chapter 4
CE 212-DigitaL Systems

© 2008 PEARSON EDUCATION,INC. 2


Overview
Introduction
Cost of Boolean Functions
Structure of Karnaugh Maps (K-Maps) Simplification Using the Map
Don’t Care Conditions
Additional Gates and Circuits
 Other Gate Types
XOR and XNOR Functions
 Buffers and Three-State Buffers (CH 4)

© 2008 PEARSON EDUCATION,INC. 3


Introduction
The cost of a digital circuit is directly proportional to the complexity of its logic function or expression.
Smallest/optimal expressions are desirable!
 Goal: to Obtain the simplest implementation for a given function.
To achieve the simplest implementation of a given function (i.e. Optimization):
Boolean identities and theories help reduce circuit complexity, they do not always guarantee the simplest or most
efficient solution.
Karnaugh Maps (k-Maps): a graphical technique, takes up to functions of six variables
Computer-based logic tools: Can minimize a large set of Boolean equations efficiently and quickly.

 Optimization requires a cost criterion to measure the simplicity of a circuit.

© 2008 PEARSON EDUCATION,INC.


4
Cost Calculations Criteria
Different cost criteria we will use:
 Literal cost (L):
• A literal is a variable or its complement (A, A’, B, B’).
• Literal cost is simply the number of all variable appearances in a Boolean expression.

© 2008 PEARSON EDUCATION,INC. 5


Cost Calculations Criteria (Cont.)
Gate input cost (G) :It is the number of literals plus the number of terms excluding single variable terms.

 Gate input cost with NOTs (GN): It is G plus the number of distinct complemented literals(inverters).

© 2008 PEARSON EDUCATION,INC. 6


Cost Criteria– Selection Criteria
Two circuits for the same function F:

F = ABC + A’B’C’ F = (A+C’)(B’+C)(A’+B)


Cost: L = 6 , G = 8, GN = 11 Cost: L = 6, G = 9, GN = 12
Same function and same literal cost, but first circuit has better gate input count and better gate input count with
NOTs. Select it!

© 2008 PEARSON EDUCATION,INC. 7


Karnaugh Maps (K-map)
•A K-map is a representation of a truth table function using a collection of squares.
• Each square represents a minterm (if it has a 1), or a maxterm (if it has a 0).
• Each square corresponds to the value of each row in the truth table, therefore, for an n-variable function, there are
2^n squares.
• The squares are NOT filled in the same order as in the truth table. This is because the squares are labelled such
that adjacent squares differ in the value of one variable.
• Alternative algebraic expressions for the same function are derived by recognizing patterns of squares.
• Given certain rules and these patterns, we can possibly minimize the function to an optimum or near optimum
SOP/POS standard forms with two-level AND/OR or OR/AND circuit implementations

© 2008 PEARSON EDUCATION,INC. 8


Two-Variable K-Maps
The rows are the values of x
The column are the values of y

Note
The order is determined by the rule that each square differs
from adjacent squares by only one bit flip, like grey code. The
squares have different values for either x or y.

© 2008 PEARSON EDUCATION,INC. 9


Two-Variable K-Maps (Example 1)
In two variable K-Map We can combine any two adjacent squares or the entire four.

© 2008 PEARSON EDUCATION,INC. 10


Two-Variable K-Maps (Example 2)

© 2008 PEARSON EDUCATION,INC. 11


Two-Variable K-Maps (Example 3)
F(x,y)= ∑ (1,2)

© 2008 PEARSON EDUCATION,INC. 12


Three-Variable K-Maps

The order is such


that there is 1- bit
flip in the binary
values of the index
between adjacent
squares

© 2008 PEARSON EDUCATION,INC. 13


Three-Variable K-Maps(Cont.)
Green shaded area is where the value of x = 1

Orange shaded area is where the value of y = 1 Blue shaded area is where the value of z = 1

© 2008 PEARSON EDUCATION,INC. 14


Three-Variable K-Maps
▪ The two main tasks involved in using a map are entering values into map and reading product terms from it
▪ Alternative labelings are practical and simpler in light of the relationship we observed in the preceding
slide:
Note that X is the most significant, and Z the least significant on the K-map labelling

© 2008 PEARSON EDUCATION,INC. 15


Simplifying Boolean Functions using Maps
1. Enter the function on the K-Map
• Function can be given in truth table, shorthand notation, SOP,…etc.
2. Combining squares for simplification:
• Must be rectangles that include power of 2 squares {1, 2, 4, 8, …}
•Goal: Fewest rectangles that cover all 1’s → as large as possible.
3. Determine if any rectangle is not needed (redundant coverings).
4. Read-off the SOP terms from the covered rectangles.

© 2008 PEARSON EDUCATION,INC. 16


Combining Squares
By combining squares, we reduce the number of literals in a product term, reducing the literal cost, thereby reducing
the other two cost criteria.
A. Two variable Map:

every two adjacent terms that form a


2×1 rectangle correspond to a
f(A,B) = A′ + B′ product term with one variable.

© 2008 PEARSON EDUCATION,INC. 17


Combining Squares( Cont.)
2. Group of four cells rectangles:

© 2008 PEARSON EDUCATION,INC. 18


Three-Variable K-Maps(Exampel-1)

© 2008 PEARSON EDUCATION,INC. 19


Combining Squares(Cont.)
B. Three-Variable Maps:
1. Group of two cells rectangles

© 2008 PEARSON EDUCATION,INC. 20


Three-Variable K-Maps(Exampel-2)
Use a K-map to find an optimum SOP equation for

© 2008 PEARSON EDUCATION,INC. 21


Three-Variable K-Maps(Exampel-3)

© 2008 PEARSON EDUCATION,INC. 22


Four-Variable K-Maps

© 2008 PEARSON EDUCATION,INC. 23


Four-Variable K-Maps(Cont.)
Note that W is the most significant, and Z the least
significant on the K-map labelling.

© 2008 PEARSON EDUCATION,INC. 24


Four-Variable K-Maps(Cont.)
Groups of Four cells:

© 2008 PEARSON EDUCATION,INC. 25


Four-Variable K-Maps(Cont.)
Group of eight cells rectangles:

© 2008 PEARSON EDUCATION,INC. 26


Four-Variable K-Maps(Exampel-1)

© 2008 PEARSON EDUCATION,INC. 27


Four-Variable K-Maps(Exampel-2)

© 2008 PEARSON EDUCATION,INC. 28


Simplification as POS
To find the optimum POS solution for the function F , instead of SOP solution?
1. Place the rectangles over the 0’s instead of 1’s. This basically means we are working with F′ instead of F.
2. Write the simplest SOP expression as before.
3. complement the SOP expression(F′ )′ using DeMorgan’s rule to get POS.
EX) Find the optimum POS solution for:

Apply DeMorgan’s Law:

© 2008 PEARSON EDUCATION,INC. 29


Simplification as POS (Example-2)
SOP Solution (in Blue):
1. Combine the 1’s in the K-map of F.

POS Solution (in Red):


1. Find the optimized SOP for F′ by combining rectangles over the 0’s
in the k-map of F.
2. Complement F′ to obtain the optimized POS for F.

© 2008 PEARSON EDUCATION,INC. 30


Basic Identities of Boolean Algebra

© 2008 PEARSON EDUCATION,INC. 31


Some Properties of Identities & the
Algebra
The identities above are organized into pairs.
The dual of an algebraic expression is obtained by interchanging (+) and (·) and interchanging 0’s and 1’s.
The identities appear in dual pairs. When there is only one identity on a line the identity is self-dual, i. e., the
dual expression = the original expression.
▪ Unless it happens to be self-dual, the dual of an expression does not equal the expression itself.

© 2008 PEARSON EDUCATION,INC. 32


Useful Boolean Theorems

© 2008 PEARSON EDUCATION,INC. 33


Example 1: Boolean Algebraic Proof

© 2008 PEARSON EDUCATION,INC. 34


Example 2: Boolean Algebraic Proofs

© 2008 PEARSON EDUCATION,INC. 35


Example 3: Boolean Algebraic Proofs

© 2008 PEARSON EDUCATION,INC. 36


Example 3: Boolean Algebraic Proofs

© 2008 PEARSON EDUCATION,INC. 37

You might also like