Chapter 2 Combinational Logic Circuits

Similar documents
Chapter 2 Combinational

Chapter 2 Combinational Logic Circuits

Literal Cost F = BD + A B C + A C D F = BD + A B C + A BD + AB C F = (A + B)(A + D)(B + C + D )( B + C + D) L = 10

Boolean Function Simplification

MUX using Tri-State Buffers. Chapter 2 - Part 2 1

Combinational Logic Circuits Part III -Theoretical Foundations

Chapter 2 Part 5 Combinational Logic Circuits

Gate Level Minimization Map Method

Simplification of Boolean Functions

A B AB CD Objectives:

IT 201 Digital System Design Module II Notes

Gate-Level Minimization

4 KARNAUGH MAP MINIMIZATION

Combinational Logic Circuits

Gate-Level Minimization

Chapter 3. Gate-Level Minimization. Outlines

Gate-Level Minimization. BME208 Logic Circuits Yalçın İŞLER

Experiment 4 Boolean Functions Implementation

Karnaugh Map (K-Map) Karnaugh Map. Karnaugh Map Examples. Ch. 2.4 Ch. 2.5 Simplification using K-map

ELCT201: DIGITAL LOGIC DESIGN

CMPE223/CMSE222 Digital Logic

Outcomes. Unit 9. Logic Function Synthesis KARNAUGH MAPS. Implementing Combinational Functions with Karnaugh Maps

DKT 122/3 DIGITAL SYSTEM 1

Review: Standard forms of expressions

ECE380 Digital Logic

Chapter 2. Boolean Expressions:

Simplification of Boolean Functions

Digital Logic Lecture 7 Gate Level Minimization

S1 Teknik Telekomunikasi Fakultas Teknik Elektro FEH2H3 2016/2017


ELCT201: DIGITAL LOGIC DESIGN

UNIT II. Circuit minimization

Chapter 6. Logic Design Optimization Chapter 6

Bawar Abid Abdalla. Assistant Lecturer Software Engineering Department Koya University

Unit-IV Boolean Algebra

Assignment (3-6) Boolean Algebra and Logic Simplification - General Questions

CHAPTER-2 STRUCTURE OF BOOLEAN FUNCTION USING GATES, K-Map and Quine-McCluskey

LSN 4 Boolean Algebra & Logic Simplification. ECT 224 Digital Computer Fundamentals. Department of Engineering Technology

2.6 BOOLEAN FUNCTIONS

Standard Forms of Expression. Minterms and Maxterms

Chapter 3 Simplification of Boolean functions

MODULE 5 - COMBINATIONAL LOGIC

Module -7. Karnaugh Maps

Gate Level Minimization

2008 The McGraw-Hill Companies, Inc. All rights reserved.

DIGITAL CIRCUIT LOGIC UNIT 5: KARNAUGH MAPS (K-MAPS)

Experiment 3: Logic Simplification

Points Addressed in this Lecture. Standard form of Boolean Expressions. Lecture 4: Logic Simplication & Karnaugh Map

Gate-Level Minimization

A graphical method of simplifying logic

Combinational Logic Circuits

1. Mark the correct statement(s)

Contents. Chapter 3 Combinational Circuits Page 1 of 34

ENGINEERS ACADEMY. 7. Given Boolean theorem. (a) A B A C B C A B A C. (b) AB AC BC AB BC. (c) AB AC BC A B A C B C.

數位系統 Digital Systems 朝陽科技大學資工系. Speaker: Fuw-Yi Yang 楊伏夷. 伏夷非征番, 道德經察政章 (Chapter 58) 伏者潛藏也道紀章 (Chapter 14) 道無形象, 視之不可見者曰夷

CSCI 220: Computer Architecture I Instructor: Pranava K. Jha. Simplification of Boolean Functions using a Karnaugh Map

2.1 Binary Logic and Gates

To write Boolean functions in their standard Min and Max terms format. To simplify Boolean expressions using Karnaugh Map.

Specifying logic functions

X Y Z F=X+Y+Z

Slide Set 5. for ENEL 353 Fall Steve Norman, PhD, PEng. Electrical & Computer Engineering Schulich School of Engineering University of Calgary

University of Technology

CprE 281: Digital Logic

Date Performed: Marks Obtained: /10. Group Members (ID):. Experiment # 04. Boolean Expression Simplification and Implementation

LOGIC CIRCUITS. Kirti P_Didital Design 1

Switching Circuits & Logic Design

Code No: R Set No. 1

Summary. Boolean Addition

CS8803: Advanced Digital Design for Embedded Hardware

B.Tech II Year I Semester (R13) Regular Examinations December 2014 DIGITAL LOGIC DESIGN

Boolean Analysis of Logic Circuits

Lecture 5. Chapter 2: Sections 4-7

Chapter 3. Boolean Algebra and Digital Logic

UNIT-4 BOOLEAN LOGIC. NOT Operator Operates on single variable. It gives the complement value of variable.

Combinational Logic & Circuits

Presented By :- Alok Kumar Lecturer in ECE C.R.Polytechnic, Rohtak

SEE1223: Digital Electronics

Code No: 07A3EC03 Set No. 1

Philadelphia University Faculty of Information Technology Department of Computer Science. Computer Logic Design. By Dareen Hamoudeh.

Gate-Level Minimization. section instructor: Ufuk Çelikcan

BOOLEAN ALGEBRA. Logic circuit: 1. From logic circuit to Boolean expression. Derive the Boolean expression for the following circuits.

ADAPTIVE MAP FOR SIMPLIFYING BOOLEAN EXPRESSIONS

Chapter 2 Boolean algebra and Logic Gates

Chapter 2: Combinational Systems

Digital Logic Design. Outline

Combinational Circuits Digital Logic (Materials taken primarily from:

ENGIN 112 Intro to Electrical and Computer Engineering

Code No: R Set No. 1

QUESTION BANK FOR TEST

Digital Design. Chapter 4. Principles Of. Simplification of Boolean Functions

Code No: R Set No. 1

Computer Organization

Announcements. Chapter 2 - Part 1 1

Switching Theory And Logic Design UNIT-II GATE LEVEL MINIMIZATION

Boolean algebra. June 17, Howard Huang 1

Lecture 4: Implementation AND, OR, NOT Gates and Complement

SIDDHARTH GROUP OF INSTITUTIONS :: PUTTUR Siddharth Nagar, Narayanavanam Road QUESTION BANK (DESCRIPTIVE)

Department of Electrical and Computer Engineering University of Wisconsin - Madison. ECE/CS 352 Digital System Fundamentals.

3.4 QUINE MCCLUSKEY METHOD 73. f(a, B, C, D, E)¼AC ĒþB CD þ BCDþĀBD.

Ch. 5 : Boolean Algebra &

Transcription:

Logic and Computer Design Fundamentals Chapter 2 Combinational Logic Circuits Part 2 Circuit Optimization

Overview Part Gate Circuits and Boolean Equations Binary Logic and Gates Boolean Algebra Standard Forms Part 2 Circuit Optimization Two-Level Optimization Map Manipulation Part 3 Additional Gates and Circuits Other Gate Types Exclusive-OR Operator and Gates High-Impedance Outputs Chapter 2 - P 2 IT32 2

Circuit Optimization Goal: To obtain the simplest implementation for a given function Introduce a graphical technique using Karnaugh maps (K-maps, for short) Chapter 2 - P 2 IT32 3

Karnaugh Maps (K-map) A K-map is a collection of squares Each square represents a minterm The collection of squares is a graphical representation of a Boolean function Adjacent squares differ in the value of one variable Alternative algebraic expressions for the same function are derived by recognizing patterns of squares The K-map can be viewed as A reorganized version of the truth table Chapter 2 - P 2 IT32 4

Use of K-Maps Provide a means for: Finding optimum or near optimum SOP and POS standard forms, and two-level AND/OR and OR/AND circuit implementations Chapter 2 - P 2 IT32 5

Two Variable K-Maps A 2-variable Karnaugh Map: Note that:. m0 and m are adjacent and differ in the value of the y variable. 2. m0 and m2 differ in the x variable. 3. m and m3 differ in the x variable. 4. m2 and m3 differ in the value of the variable y. y = 0 y = x = 0 x = x y x y x y x y Chapter 2 - P 2 IT32 6

Two Variable K-Maps Every 2 adjacent cells differ in the value of variable only. Chapter 2 - P 2 IT32 7

K-Map and Truth Tables The K-Map is just a different form of the truth table. Example Two variable function: F each of a, b, c, d can be either 0 or Function Table Input Values (x,y) Function Value F(x,y) 0 0 a 0 b 0 c d Minterm m 0 m m 2 m 3 K-Map y = 0 y = x = 0 a b x = c d Chapter 2 - P 2 IT32 8

K-Map Function Representation Example: F(x,y) = x F = x y = 0 y = x = 0 0 0 x = For function F(x,y), the two adjacent cells containing s can be combined using the Minimization Theorem: F ( x, y ) = x y + x y = x Chapter 2 - P 2 IT32 9

K-Map Function Representation Example: G(x,y) = x + y G = x+y y = 0 y = x = 0 0 x = For G(x,y), two pairs of adjacent cells containing s can be combined using the Minimization Theorem: ( x y + x y ) + ( xy + x y ) = x y G ( x, y ) = + Duplicate x y Chapter 2 - P 2 IT32 0

Three Variable Maps A three-variable K-map: yz=00 yz=0 yz= yz=0 x=0 m 0 m m 3 m 2 x= m 4 m 5 m 7 m 6 Where each minterm corresponds to the product terms: Note that if the binary value for an index differs in one bit position, the minterms are adjacent on the K-Map Chapter 2 - P 2 IT32

Alternative Map Labeling Map use largely involves: Entering values into the map, and Reading off product terms from the map. Alternate labeling are useful: x x z y 0 3 2 4 z y 5 7 6 z x y z x Chapter 2 - P 2 IT32 2 0 z y 0 3 2 4 00 0 0 5 7 6

Example Functions By convention, we represent the minterms of F by a "" in the map and leave the minterms of F blank Example: F(x, y, F =? Example: G =? z) = Learn the locations of the 8 indices based on the variable order shown (x, most significant and z, least significant) on the map boundaries m G(a, b,c) = (2,3,4,5) m (3,4,6,7) Chapter 2 - P 2 IT32 3 x a y 0 3 2 4 5 7 6 z b 0 3 2 4 5 7 6 c

Example Functions Chapter 2 - P 2 IT32 4

Combining Squares By combining squares, we reduce number of literals in a product term On a 3-variable K-Map: # of adjacent squares represents A minterm with three variables 2 A product term with two variables 4 A product term with one variable 8 The function of all ones (no variables) = Chapter 2 - P 2 IT32 5

Combining Squares Groupings to select product-terms must be:. Rectangular in shape 2. In powers of twos (, 2, 4, 8, etc.) 3. Always select largest possible groupings of minterms (i.e. prime implicants) 4. Eliminate redundant groupings Chapter 2 - P 2 IT32 6

Simplest SOP Expressions To find the simplest possible sum of products (SOP) expression from a K-map, you need to obtain: minimum number of literals per product term; and minimum number of product terms This is achieved in K-map using bigger groupings of minterms (prime implicants) where possible; and no redundant groupings (look for essential prime implicants) Implicant: a product term that could be used to cover minterms of the function. Chapter 2 - P 2 IT32 7

Example: Combining Squares Example: Let F = m(2,3,6,7) Applying the Minimization Theorem three times: F ( x, y, z ) = x y z + x y z + x y z + = yz + y z = y x y z Thus the four terms that form a 2 2 square correspond to the term "y". x y 0 3 2 4 5 7 6 z Chapter 2 - P 2 IT32 8

Three-Variable Maps Reduced literal product terms for SOP standard forms correspond to rectangles on K-maps containing cell counts that are powers of 2. Rectangles of 2 cells represent 2 adjacent minterms; of 4 cells represent 4 minterms that form a pairwise adjacent ring. Rectangles can contain non-adjacent cells as illustrated by the pairwise adjacent ring above. Chapter 2 - P 2 IT32 9

Chapter 2 - P 2 IT32 20

Three-Variable Maps Example Shapes of 2-cell Rectangles: y 0 3 2 x 4 5 7 6 Read off the product terms for the rectangles shown z Chapter 2 - P 2 IT32 2

Three-Variable Maps Example Shapes of 4-cell Rectangles: y 0 3 2 x 4 5 7 6 Read off the product terms for the rectangles shown z Chapter 2 - P 2 IT32 22

Three Variable Maps K-Maps can be used to simplify Boolean functions by systematic methods. Terms are selected to cover the s in the map. Example: Simplify F(x, y, z) = m(,2,3,5,7) z y x y x F(x,y,z)= xy+z z Chapter 2 - P 2 IT32 23

Four-Variable Maps Chapter 2 - P 2 IT32 24

Four Variable Terms Four variable maps can have rectangles corresponding to: A single = 4 variables, (i.e. Minterm) Two s = 3 variables, Four s = 2 variables Eight s = variable, Sixteen s = zero variables (i.e. Constant "") Chapter 2 - P 2 IT32 25

Four-Variable Maps Example Shapes of Rectangles: Y 0 3 2 5 6 4 7 W 2 3 5 4 8 9 0 X Z Chapter 2 - P 2 IT32 26

Four-Variable Maps Example Shapes of Rectangles: Y 0 3 2 W 5 6 4 7 2 3 5 4 8 9 0 X Z Chapter 2 - P 2 IT32 27

K-maps Possible valid groupings of a 4-variable K-map include: Chapter 2 - P 2 IT32 28

K-maps Groups of minterms must be () rectangular, and (2) have size in powers of 2 s. Otherwise they are invalid groups. For examples: Chapter 2 - P 2 IT32 29

Systematic Simplification A Prime Implicant is a product term obtained by combining the maximum possible number of adjacent squares in the map into a rectangle with the number of squares a power of 2. A prime implicant is called an Essential Prime Implicant if it is the only prime implicant that covers (includes) one or more minterms. Prime Implicants and Essential Prime Implicants can be determined by inspection of a K-Map. A set of prime implicants "covers all minterms" if, for each minterm of the function, at least one prime implicant in that set includes the minterm. Chapter 2 - P 2 IT32 30

Example of Prime Implicants Find ALL Prime Implicants CD C B D ESSENTIAL Prime Implicants C B D BD A A B B BD A B Chapter 2 - P 2 D AD B C Minterms covered by single prime implicant IT32 3 D

Prime Implicant Practice Find all prime implicants for: F(A, B,C, D) = m (0,2,3,8,9,0,,2,3,4,5) Prime implicants are: Chapter 2 - P 2 IT32 32

Another Example Find all prime implicants for: G(A, B,C,D) = Hint: There are seven prime implicants! m (0,2,3,4,7,2,3,4,5) Prime Implicants are : AB, B C' D', A' C' D', A' B' D', A' B' C, A' C D, B C D Chapter 2 - P 2 IT32 33

Five Variable or More K-Maps For five variable problems, we use two adjacent K-maps. It becomes harder to visualize adjacent minterms for selecting PIs. You can extend the problem to six variables by using four K-Maps. V = 0 V = Y Y X X W W Z Z Chapter 2 - P 2 IT32 34

Optimization Algorithm. Find all prime implicants. 2. Include all essential prime implicants in the solution (optimum function F). 3. Select a minimum cost set of non-essential prime implicants to cover all minterms not yet covered: Obtaining a good simplified solution: Use the Selection Rule Chapter 2 - P 2 IT32 35

Prime Implicant Selection Rule Minimize the overlap among prime implicants as much as possible. In particular, in the final solution, make sure that each prime implicant selected includes at least one minterm not included in any other prime implicant selected. Chapter 2 - P 2 IT32 36

Selection Rule Example Simplify F(A, B, C, D) given on the K-map. Selected Essential C C A B A B D F=? In SOP and POS Minterms covered by essential prime implicants D Chapter 2 - P 2 IT32 37

Don't Cares in K-Maps Sometimes a function table or map contains : Input values for the minterm will never occur, or Output value for the minterm is not used In these cases, the output value is defined as a don't care ( an x entry). By doing that the cost of the logic circuit of that function may be lowered. Chapter 2 - P 2 IT32 38

Don't Cares in K-Maps Example : A logic function having the binary codes for the BCD digits as its inputs. Only the codes for 0 through 9 are used. The six codes, 00 through never occur, so the output values for these codes are x to represent don t cares. Chapter 2 - P 2 IT32 39

Don't Cares in K-Maps Ultimately, each x entry may take on either a 0 or value in resulting solutions. For example, an x may take on value 0 in an SOP solution and value in a POS solution (If not covered), or vice-versa (If covered). Any minterm with value x need not be covered by a prime implicant. Chapter 2 - P 2 IT32 40

Example: BCD 5 or More w The map below gives a function F(w,x,y,z) which is defined as "5 or more" over BCD inputs. With the don't cares used for the 6 non-bcd combinations: y F (w,x,y,z) = w + x z + x y This 0 0 0 0 is much simpler than F2 where the 0 3 2 don't cares were treated as "0s. 0 4 5 7 6 X X 2 3 5 4 8 9 0 z X X X X x F 2 (w, x, y, z) = w x z + w x y + w x y For this particular function, cost for the POS solution for F(w,x,y,z) is not changed by using the don't cares. Chapter 2 - P 2 IT32 4

Selection Rule Example with Don't Cares Simplify F(A, B, C, D) given on the K-map. C Selected Essential C x x A x x x x B x A x x x B D Minterms covered by essential prime implicants D Chapter 2 - P 2 IT32 42

Product of Sums Example Find the optimum POS solution: F(A, B,C,D) = m (3,9,,2,3,4,5) + d (,4,6) Hint: Use F it to get the result. and complement Chapter 2 - P 2 IT32 43