Lecture (02) NAND and NOR Gates

Similar documents
CHAPTER 7 MULTI-LEVEL GATE CIRCUITS NAND AND NOR GATES

Lecture 5: NAND, NOR and XOR Gates, Simplification of Algebraic Expressions

MULTI-LEVEL GATE CIRCUITS NAND AND NOR GATES

EE40 Lec 15. Logic Synthesis and Sequential Logic Circuits

Logic Design. Chapter 2: Introduction to Logic Circuits

EEE130 Digital Electronics I Lecture #4

Boolean Algebra and Digital Logic 2009, University of Colombo School of Computing

UNIT 5 KARNAUGH MAPS Spring 2011

Digital Logic. Lecture 5 - Chapter 2. Outline. Other Logic Gates and their uses. Other Logic Operations. CS 2420 Husain Gholoom - lecturer Page 1

Systems I: Computer Organization and Architecture

II. COMBINATIONAL LOGIC DESIGN. - algebra defined on a set of 2 elements, {0, 1}, with binary operators multiply (AND), add (OR), and invert (NOT):

Unit 2 Session - 6 Combinational Logic Circuits

Lecture 6: Manipulation of Algebraic Functions, Boolean Algebra, Karnaugh Maps

L4: Karnaugh diagrams, two-, and multi-level minimization. Elena Dubrova KTH / ICT / ES

ENG2410 Digital Design Combinational Logic Circuits

Chap 2. Combinational Logic Circuits

Combinational Logic. By : Ali Mustafa

Lecture 22 Chapters 3 Logic Circuits Part 1

Boolean algebra. Examples of these individual laws of Boolean, rules and theorems for Boolean algebra are given in the following table.

MC9211 Computer Organization

ELCT201: DIGITAL LOGIC DESIGN

14:332:231 DIGITAL LOGIC DESIGN

Outline. EECS150 - Digital Design Lecture 4 - Boolean Algebra I (Representations of Combinational Logic Circuits) Combinational Logic (CL) Defined

Number System conversions

Lecture (08) Synchronous Sequential Logic

211: Computer Architecture Summer 2016

Chapter 2. Digital Logic Basics

Sample Test Paper - I

Logic Gate Level. Part 2

Week-I. Combinational Logic & Circuits

UNIVERSITI TENAGA NASIONAL. College of Information Technology

Unit 3 Session - 9 Data-Processing Circuits

EECS150 - Digital Design Lecture 19 - Combinational Logic Circuits : A Deep Dive

Gate-Level Minimization

Chapter 7 Combinational Logic Networks

EECS150 - Digital Design Lecture 4 - Boolean Algebra I (Representations of Combinational Logic Circuits)

Karnaugh Maps Objectives

Combinatorial Logic Design Principles

Unit 2 Boolean Algebra

Digital Logic Design. Combinational Logic

Textbook: Digital Design, 3 rd. Edition M. Morris Mano

Additional Gates COE 202. Digital Logic Design. Dr. Muhamed Mudawar King Fahd University of Petroleum and Minerals

Digital Circuit And Logic Design I. Lecture 4

Digital Logic Appendix A

Digital Logic Design ABC. Representing Logic Operations. Dr. Kenneth Wong. Determining output level from a diagram. Laws of Boolean Algebra

Boolean Algebra & Logic Gates. By : Ali Mustafa

Midterm Examination # 1 Wednesday, February 25, Duration of examination: 75 minutes

UNIT 4 MINTERM AND MAXTERM EXPANSIONS

COM111 Introduction to Computer Engineering (Fall ) NOTES 6 -- page 1 of 12

This form sometimes used in logic circuit, example:

Logic Simplification. Boolean Simplification Example. Applying Boolean Identities F = A B C + A B C + A BC + ABC. Karnaugh Maps 2/10/2009 COMP370 1

Chapter 3. Boolean Algebra. (continued)

Computer Organization I. Lecture 13: Design of Combinational Logic Circuits

Karnaugh Map & Boolean Expression Simplification

Logic Design I (17.341) Fall Lecture Outline

Chapter 7 Logic Circuits

Number System. Decimal to binary Binary to Decimal Binary to octal Binary to hexadecimal Hexadecimal to binary Octal to binary

CHAPTER1: Digital Logic Circuits Combination Circuits

Fundamentals of Boolean Algebra

Boolean Algebra. Digital Logic Appendix A. Postulates, Identities in Boolean Algebra How can I manipulate expressions?

MODULAR CIRCUITS CHAPTER 7

CHAPTER III BOOLEAN ALGEBRA

Experiment 7: Magnitude comparators

CHAPTER 7. Exercises 17/ / /2 2 0

CHAPTER 3 BOOLEAN ALGEBRA

Boolean Algebra. Digital Logic Appendix A. Boolean Algebra Other operations. Boolean Algebra. Postulates, Identities in Boolean Algebra

Chapter 2 Combinational Logic Circuits

Lecture 2 Review on Digital Logic (Part 1)

ENGG 1203 Tutorial - 2 Recall Lab 2 - e.g. 4 input XOR. Parity checking (for interest) Recall : Simplification methods. Recall : Time Delay

CHAPTER III BOOLEAN ALGEBRA

2009 Spring CS211 Digital Systems & Lab CHAPTER 2: INTRODUCTION TO LOGIC CIRCUITS

1 Boolean Algebra Simplification

Computer Science 324 Computer Architecture Mount Holyoke College Fall Topic Notes: Digital Logic

EEA051 - Digital Logic 數位邏輯 吳俊興高雄大學資訊工程學系. September 2004

ELCT201: DIGITAL LOGIC DESIGN

Review for Test 1 : Ch1 5

Lecture 6: Gate Level Minimization Syed M. Mahmud, Ph.D ECE Department Wayne State University

COMPUTER ENGINEERING PROGRAM

Simplification of Boolean Functions. Dept. of CSE, IEM, Kolkata

ELC224C. Karnaugh Maps

ELEC Digital Logic Circuits Fall 2014 Sequential Circuits (Chapter 6) Finite State Machines (Ch. 7-10)

Chapter 2 Boolean Algebra and Logic Gates

Reduction of Logic Equations using Karnaugh Maps

Karnaugh Maps (K-Maps)

14:332:231 DIGITAL LOGIC DESIGN. Combinational Circuit Synthesis

Chapter 2: Switching Algebra and Logic Circuits

Why digital? Overview. Number Systems. Binary to Decimal conversion

DIGITAL CIRCUIT LOGIC BOOLEAN ALGEBRA

Boolean Algebra, Gates and Circuits

Gates and Logic: From switches to Transistors, Logic Gates and Logic Circuits

Working with Combinational Logic. Design example: 2x2-bit multiplier

Ch 2. Combinational Logic. II - Combinational Logic Contemporary Logic Design 1

CS 121 Digital Logic Design. Chapter 2. Teacher Assistant. Hanin Abdulrahman

University of Technology

Part 5: Digital Circuits

CHAPTER 5 KARNAUGH MAPS

Discrete Mathematics. CS204: Spring, Jong C. Park Computer Science Department KAIST

Lecture 7: Karnaugh Map, Don t Cares

Minimization techniques

Logic Gates and Boolean Algebra

Transcription:

Lecture (02) NAND and NOR Gates By: Dr. Ahmed ElShafee ١ Dr. Ahmed ElShafee, ACU : Spring 2018, CSE303 Logic design II NAND gates and NOR gates In this section we will define NAND and NOR gates. Logic designer frequently use NAND and NOR gates because they are faster and use fewer components than AND or OR gates. ٢

Toshiba announced NAND flash at the 1987 International Electron Devices Meeting. It has reduced erase and write times, and requires less chip area per cell, thus allowing greater storage density and lower cost per bit than NOR flash; it also has up to ten times the endurance of NOR flash. A USB memory ٣ NAND gates Figure (a) shows a three-input NAND gate. The small circle (or bubble ) at the gate output indicates inversion, so the NAND gate is equivalent to an AND gate followed by an inverter, as shown in Figure (b). The gate output is F = (ABC) = A + B + C ٤

NOR gates Figure (a) shows a three-input NOR gate. The small circle at the gate output indicates inversion, so the NOR gate is equivalent to an OR gate followed by an inverter. The gate output is F = (A + B + C) = A B C ٥ Functionally Complete Set of Gates AND and NOT are a functionally complete set of gates because OR can also be realized using AND and NOT: ٦

Similarly, any function can be realized using only NAND gates (Similarly, any function can be realized using only NOR gates) ٧ NAND Gate Dr. Ahmed Realization ElShafee, ACU : Spring 2018, of CSE303 NOT, Logic AND, design II and OR Design of Two-Level NAND- Gate Circuits A two-level circuit composed of AND and OR gates is easily converted to a circuit composed of NAND gates or NORE gates using F = (F ) and then applying DeMorgan s laws: (X 1 + X 2 + + X n ) = X 1 X 2 X n (X 1 X 2 X n ) = X 1 + X 2 + + X n ٨

Design of Two-Level NAND- Gate Circuits The following example illustrates conversion of a minimum sum-of-products form to several other two-level forms: F = A + BC + B CD = [(A + BC + B CD) ] AND-OR = [A (BC ) (B CD) ] NAND-NAND = [A (B + C) (B + C + D )] OR-NAND = A + (B + C) + (B + C + D ) NOR-OR ٩ ١٠

Design of Two-Level NOR- Gate Circuits If we want a two-level circuit containing only NOR gates, we should start with the minimum product-of-sums form for F instead of the minimum sum-of-products. After obtaining the minimum product-of-sums from a Karnaugh map, F can be written in the following twolevel forms: F = (A + B + C)(A + B + C )(A + C + D) OR-AND = {[(A + B + C)(A + B + C )(A + C + D)] } = [(A + B + C) + (A + B + C ) + (A + C + D) ] NOR-NOR = (A B C + A BC + A CD ) AND-NOR = (A B C ) (A BC) (A CD ) NAND-AND ١١ ١٢

Consider, for example, the following NAND-NOR circuit: From this example, it is clear that the NAND-NOR form can realize only a product of literals and not a sum of products. NAND and NOR gates are readily available in IC form.so two commonly used Dr. Ahmed circuit ElShafee, is ACU NAND NAND : Spring 2018, CSE303 Logic or design NOR NOR. II ١٣ Design of Minimum Two-Level NAND-NAND Circuits AND OR to NAND NAND Transformation Procedure for designing a minimum two-level NAND- NAND circuit: 1. Find a minimum sum-of-products expression for F. 2. Draw the corresponding two-level AND-OR circuit. 3. Replace all gates with NAND gates leaving the gate interconnection unchanged. If the output gate has any single literals as inputs, complement these literals. ١٤

F = l 1 + l 2 + + P 1 + P 2 + F = (l 1 l 2 P 1 P 2 ) ١٥ Design of Minimum Two-Level NOR-NOR Circuit Procedure for designing a minimum two-level NOR- NOR circuit: 1. Find a minimum products-of-sum expression for F. 2. Draw the corresponding two-level OR-AND circuit. 3. Replace all gates with NOR gates leaving the gate interconnection unchanged. If the output gate has any single literals as inputs, complement these literals. ١٦

Design of Multi-Level NANDand NOR-Gate Circuits The following procedure may be used to design multi level NAND gate circuits: 1. Simplify the switching function to be realized. 2. Design a multi-level circuit of AND and OR gates. The output gate must be OR. AND gate outputs cannot be used as AND-gate inputs; OR-gate outputs cannot be used as OR-gate inputs. 3. Number the levels starting with the output gate as level 1. Replace all gates with NAND gates, leaving all interconnections between gates unchanged, leave the inputs to levels 2,4,6, unchanged. Invert any literals which appear as inputs to levels 1,3,5, ١٧ Multi Level Circuit Conversion to NAND Gates EX: F1= a [b +c(d+e )+f g ]+hi j+k Steps: 1.Realize the function with AND-OR 2.Replacing all gate with NAND 3.2,4,6, leave unchanged 1,3,5 invert literals ١٨

Alternative Gate Symbols Logic designers who design complex digital systems often find it convenient to use more than one representation for a given type of gate. For example, an inverter can be represented by ١٩ Equivalent gate symbols based on DeMorgan s Laws ٢٠

NAND Gate Circuit Conversion: From NAND NAND to OR AND ٢١ Conversion to NOR Gates ٢٢

If AND and OR gates don t alternate? EX: AND OR Circuit to NAND Gates ٢٣ Design of Two-Level, Multiple- Output Circuits Solution of digital design problems often requires the realization of several functions of the same variables. Although each function could be realized separately, the use of some gates in common between two or more functions sometimes leads to a more economical realization. ٢٤

Example Design a circuit with four inputs and three outputs which realizes the functions F 1 (A, B, C, D) = Ʃ m(11, 12, 13, 14, 15) F 2 (A, B, C, D) = Ʃ m(3, 7, 11, 12, 13, 15) F 3 (A, B, C, D) = Ʃ m(3, 7, 12, 13, 14, 15) ٢٥ F 1 (A, B, C, D) = Ʃ m(11, 12, 13, 14, 15) F 2 (A, B, C, D) = Ʃ m(3, 7, 11, 12, 13, 15) F 3 (A, B, C, D) = Ʃ m(3, 7, 12, 13, 14, 15) ٢٦

Realization of Equations (The cost is 9 gates and 21 inputs ) Realization of functions separately (9 Gates) ٢٧ Multiple Output Realization of Equations: A reduced circuit 1. AB in common 2. CD in common Realization of functions with shared gates (lower overall cost) (7 Gates) ٢٨

Another example of sharing gates among multiple outputs to reduce cost.(from K- map) 1 f = Ʃ m(2, 3, 5, 7, 8, 9, 10, 11, 13, 15) f 2 = Ʃ m(2, 3, 5, 6, 7, 10, 11, 14, 15) f 3 = Ʃ m(6, 7, 8, 9, 13, 14, 15) ٢٩ Minimal Solution f 1 = a bd + abd + ab c + b c 2 f = c + a bd 3 f = bc + ab c + abd 12 gates 28 gate inputs ٣٠ After reduced 8 gates 22 gate inputs

In this example, the best solution is obtained by not combining the circled 1 with adjacent 1 s. ٣١ The solution with the maximum number of common terms is not necessarily the best solution, as illustrated by this example. ٣٢

The procedure for design of single-output, multi-level NAND- and NOR-gate circuits also applies to multiple-output circuits Multi Level Circuit Conversion to NOR Gates ٣٣ Example Find a circuit of AND and OR gates to realize f (a, b, c, d) = Ʃ m(1, 5, 6, 10, 13, 14) Consider solutions with two levels of gates and three levels of gates. Try to minimize the number of gates and the total number of gate inputs. Assume that all variables and their complements are available as inputs. First, simplify f by using a Karnaugh map. ٣٤

f (a, b, c, d) = Ʃ m(1, 5, 6, 10, 13, 14) ٣٥ This leads directly to a two-level AND-OR gate circuit. ٣٦

Factoring yields f = c d(a + b) + cd (a + b) ٣٧ Both of these solutions have an OR gate at the output. A solution with an AND gate at the output might have fewer gates or gate inputs. A two-level OR-AND circuit corresponds to a product-of-sums expression for the function. This can be obtained from the 0 s on the Karnaugh map as follows: f = c d + ab c + cd + a b c (1) f = (c + d)(a + b + c)(c + d )(a + b + c ) (2) Equation (2) leads directly to a two-level OR-AND circuit. ٣٨

(c + d)(a + b + c)(c + d )(a + b + c ) ٣٩ (c + d)(a + b + c)(c + d )(a + b + c ) To get a three-level circuit with an AND gate output, we partially multiply out Equation (7-4) using (X + Y)(X + Z) = X + Y Z: f = [c + d(a + b)][c + d (a + b)] (2 ) Equation (1) would require four levels of gates to realize; however, if we multiply out d (a + b) and d(a + b), we get f = (c + a d + bd)(c + ad + bd ) ( ) which leads directly to a three-level AND-OR-AND circuit. ٤٠

f = (c + a d + bd)(c + ad + bd ) ٤١ Thanks,.. ٤٢ Dr. Ahmed ElShafee, ACU : Spring 2018, CSE303 Logic design II