2.7 NAND and NOR logic networks

Slides:



Advertisements
Similar presentations
Boolean Algebra and Logic Gates
Advertisements

Switching circuits Composed of switching elements called “gates” that implement logical blocks or switching expressions Positive logic convention (active.
Lecture 6 More Logic Functions: NAND, NOR, XOR and XNOR
Introduction to Logic Circuits
Sahar Mosleh PageCalifornia State University San Marcos 1 Introductory Concepts This section of the course introduces the concept of digital circuits and.
Types of Logic Circuits
Chapter 2 Logic Circuits.
Boolean Algebra and Reduction Techniques
Boolean Algebra and Combinational Logic
Logic Gate Level Part 2. Constructing Boolean expression from truth table First method: write nonparenthesized OR of ANDs Each AND is a 1 in the result.
MULTI-LEVEL GATE NETWORKS
CS 151 Digital Systems Design Lecture 11 NAND and XOR Implementations.
CS 151 Digital Systems Design Lecture 6 More Boolean Algebra A B.
ENGIN112 L11: NAND and XOR Implementation September 26, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 11 NAND and XOR Implementations.
Computer organization at the logic level Some not so famous last words.
Copyright © Cengage Learning. All rights reserved. CHAPTER 2 THE LOGIC OF COMPOUND STATEMENTS THE LOGIC OF COMPOUND STATEMENTS.
Logic Functions and their Representation. Slide 2 Combinational Networks x1x1 x2x2 xnxn f.
1 EECC341 - Shaaban #1 Lec # 6 Winter Combinational Circuit Analysis Example Given this logic circuit we can : Find corresponding logic.
Chapter 5 Boolean Algebra and Reduction Techniques William Kleitz Digital Electronics with VHDL, Quartus® II Version Copyright ©2006 by Pearson Education,
©2010 Cengage Learning SLIDES FOR CHAPTER 7 MULTI-LEVEL GATE CIRCUITS NAND AND NOR GATES This chapter in the book includes: Objectives Study Guide 7.1Multi-Level.
Chapter 2: Boolean Algebra and Logic Functions
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Fundamentals with PLD Programming.
Unit 7 Multi-Level Gate Circuits / NAND and NOR Gates Ku-Yaw Chang Assistant Professor, Department of Computer Science and Information.
1 Why study Boolean Algebra? 4 It is highly desirable to find the simplest circuit implementation (logic) with the smallest number of gates or wires. We.
Chapter 2 Combinational Systems And / Or / Not. TRIAD PRINCIPLE: Combinational is about And / Or / Not combinations As well as equivalent functions. It.
BOOLEAN ALGEBRA Saras M. Srivastava PGT (Computer Science)
Boolean Algebra and Digital Circuits
 Seattle Pacific University EE Logic System DesignSOP-POS-1 The Connection: Truth Tables to Functions abcF abcF
Company LOGO DKT 122/3 DIGITAL SYSTEM 1 WEEK #7 COMBINATIONAL LOGIC ANALYSIS.
CS/EE 3700 : Fundamentals of Digital System Design Chris J. Myers Lecture 2: Intro. to Logic Circuits Chapter 2.
EE2420 – Digital Logic Summer II 2013 Hassan Salamy Ingram School of Engineering Texas State University Set 4: Other Gates.
Dr. Eng. Farag Elnagahy Office Phone: King ABDUL AZIZ University Faculty Of Computing and Information Technology CPCS 222.
Course contents Chapter 1 - section 1.6 Chapter 2 - all sections Chapter – 4.7, and 4.12 Chapter , Chapter 6 - all sections.
Instructor: Alexander Stoytchev CprE 281: Digital Logic.
Unit 7 Multi-Level Gate Circuits Nand and Nor Gates Fundamentals of Logic Design Roth and Kinny.
Chapter 5 Boolean Algebra and Reduction Techniques 1.
NAND-NAND and NOR-NOR Circuits and Even and Odd Logic Functions
CHAPTER 7 MULTI-LEVEL GATE CIRCUITS / NAND AND NOR GATES
LOGIC GATES & BOOLEAN ALGEBRA
Venn Diagram – the visual aid in verifying theorems and properties 1 E.
ECE 3110: Introduction to Digital Systems
Implementation of SOP/POS Expressions
Lecture 09 NAND and XOR Implementations. Overview °Developing NAND circuits °Two-level implementations Convert from AND/OR to NAND (again!) °Multi-level.
1 BOOLEAN ALGEBRA Basic mathematics for the study of logic design is Boolean Algebra Basic laws of Boolean Algebra will be implemented as switching devices.
ENGIN112 L6: More Boolean Algebra September 15, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 6 More Boolean Algebra A B.
Floyd, Digital Fundamentals, 10 th ed Digital Fundamentals Tenth Edition Floyd Chapter 5 © 2008 Pearson Education.
NAND-NAND and NOR-NOR Circuits and Even and Odd Logic Functions ECE 301 – Digital Electronics.
Boolean Algebra and Reduction Techniques
1 EENG 2710 Chapter 2 Algebraic Methods For The Analysis and Synthesis of Logic circuits.
1 Lect # 2 Boolean Algebra and Logic Gates Boolean algebra defines rules for manipulating symbolic binary logic expressions. –a symbolic binary logic expression.
ECE 3110: Introduction to Digital Systems Chapter #4 Review.
Topic 4 – Switching Circuits. Serial vs. Parallel Transmission Circuit elements can be connected in either a serial or parallel manner. Serial implies.
1/16/ CSEE, UQ Lecture 3 Hardware Description Methods, Review of Switching Algebra.
ECE 171 Digital Circuits Chapter 6 Logic Circuits Herbert G. Mayer, PSU Status 1/16/2016 Copied with Permission from prof. Mark PSU ECE.
Figure 2.1. A binary switch. x1=x0= (a) Two states of a switch S x (b) Symbol for a switch.
BOOLEAN ALGEBRA LOGIC GATES. Introduction British mathematician George Boole( ) was successful in finding the link between logic and mathematics.
Lecture 5 More Boolean Algebra A B. Overview °Expressing Boolean functions °Relationships between algebraic equations, symbols, and truth tables °Simplification.
Chapter 5 Boolean Algebra and Reduction Techniques 1.
Boolean or, Switching Algebra. Switching Algebra The two-valued Boolean algebra is also called “Switching algebra” by engineers and computer scientists.
Instructor: Alexander Stoytchev CprE 281: Digital Logic.
MULTI-LEVEL GATE CIRCUITS / NAND AND NOR GATES
CHAPTER 7 MULTI-LEVEL GATE CIRCUITS / NAND AND NOR GATES
CS 105 Digital Logic Design
EI205 Lecture 5 Dianguang Ma Fall 2008.
Boolean Algebra and Combinational Logic
ECE 331 – Digital System Design
Universal gates.
Chapter 2 Introduction to Logic Circuits
Gates Type AND denoted by X.Y OR denoted by X + Y NOR denoted by X + Y
Introductory Concepts
Presentation transcript:

2.7 NAND and NOR logic networks Introduce the use of NAND and NOR gates in the synthesis of logic circuits Attractive due to their simpler electronic circuits implementation than AND and OR functions Q: Can be used directly in the synthesis of logic circuits? And how?

Graphical symbols for NAND and NOR gates (Figure 2.20) A bubble at the output side of the gate symbols represents the complemented output signal.

DeMorgan’s theorem in terms of logic gates x x 1 x 1 1 x x 2 x 2 2 (a) 𝑥 1 𝑥 2 = 𝑥 1 + 𝑥 2 A NAND gate is equivalent to the OR gate with inversions at its inputs. A NAND of variables x1 and x2 is equivalent to first inverting each of the variables and then ORing them. The NOR of variables x1 and x2 is equivalent to first complementing each of the variables and then ANDing them. x 1 x x 1 1 x x 2 x 2 2 (b) 𝑥 1 + 𝑥 2 = 𝑥 1 𝑥 2 A NOR gate is equivalent to the AND gate with inversions at its inputs

Figure 2.22. Using NAND gates to implement a sum-of-products. x 1 2 3 4 5 1 Double inversion has no effect on the network behavior. 2 Transform a AND-OR networks into a network of NAND gates Replace each connection between AND and OR gate by inversions of signals. Replace OR gate with inverted inputs by a NAND gate. Replace each connection between the AND and an OR gate by a connection that includes two inversions of signals The OR gate with inversions at its inputs is equivalent to a NAND gate. Can implement any AND-OR network as a NAND-NAND network having the same topology. Same topology! Figure 2.22. Using NAND gates to implement a sum-of-products.

Figure 2.23. Using NOR gates to implement a product-of sums. x 1 2 3 4 5 Can implement any OR-AND network as a NOR-NOR network having the same topology with the similar transformation procedure. Figure 2.23. Using NOR gates to implement a product-of sums.

Example 2.6 Let us implement the function using NOR gates only Combining property 14b. (x + y) (x + 𝑦 ) = x Let us implement the function using NOR gates only 𝑓 𝑥 1 , 𝑥 2 , 𝑥 3 = 𝑚(2, 3, 4 ,6, 7) = 𝑀(0,1,5) The POS expression 𝑓=(x1 + x2 + x3) (x1+x2+ 𝑥 3 )( 𝑥 1 +x2+ 𝑥 3 ) // apply combining property 14b to // M0 and M1; M1 and M5 = 𝑥 1 + 𝑥 2 ( 𝒙 𝟐 + 𝒙 𝟑 ) x1 x2 x3 F 1

Figure 2.24 NOR-gate realization of the function in Example 2.4. (a) POS implementation in Example 2.4 x3 is inverted by a NOR gate that has its inputs tired together. x1 x2 f 𝒙 𝟑 = 𝒙 𝟑 + 𝒙 𝟑 x3 (b) NOR implementation Figure 2.24 NOR-gate realization of the function in Example 2.4.

Example 2.7 Let us implement the function using NAND gates only Distributive property 12a. x (y + z) = xy + xz Let us implement the function using NAND gates only 𝑓 𝑥 1 , 𝑥 2 , 𝑥 3 = 𝑚(2, 3, 4 ,6, 7) The SOP expression 𝑓= 𝑥 1 𝑥2 𝑥 3 + 𝑥 1 𝑥2𝑥3+𝑥1 𝑥 2 𝑥 3 +𝑥1𝑥 2 𝑥 3 + 𝑥 1 𝑥2𝑥3 // merge m2, m3, m6, and m7 using P12a; // merge m4 and m6 = 𝑥2( 𝑥 1 𝑥3+ 𝑥 1 𝑥 3 +𝑥1 𝑥 3 +𝑥1𝑥3)+𝒙𝟏(𝒙𝟐+ 𝒙 𝟐 ) 𝒙 𝟑 = x2 + 𝒙𝟏 𝒙 𝟑 x1 x2 x3 F 1 All 4 combinations = 1

Figure 2.25. NAND-gate realization of the function in Example 2.3. x2= x2+x2 x2 x2 f x3 f x1 x1 x3 𝒙 𝟑 = 𝒙 𝟑 ∙𝒙 𝟑 (a) SOP implementation x2 f x1 x3 (b) NAND implementation Figure 2.25. NAND-gate realization of the function in Example 2.3.

2.8 Design Examples Basic issues that a designer is always confronted with Necessary to specify the desired behavior of the circuit. The circuit has to be synthesized and implemented.

Three-way light control Let x1, x2, and x3 be the input variables that denote the state of each switch. Assume that the light is off if all switches are open Closing any one of the switches will turn the light on. Closing a second switch will have to turn off the light, that is to say, light will be off if two (or no) switches are closed. Turn the light on by closing the third switch if two switches are closed. Figure 2.26. Truth table for a three-way light control.

Canonical SOP and POS SOP expression for the specified function 𝑓=𝑚1+𝑚2+𝑚4+𝑚7 = 𝑥 1 𝑥 2 𝑥 3 + 𝑥 1 𝑥 2 𝑥 3 + 𝑥 1 𝑥 2 𝑥 3 + 𝑥 1 𝑥 2 𝑥 3 POS expression for the specified function 𝑓=𝑀0𝑀3𝑀5𝑀6 =(𝑥1+𝑥2+𝑥3) (𝑥1+ 𝑥 2 + 𝑥 3 ) ( 𝑥 1 +𝑥2+ 𝑥 3 ) ( 𝑥 1 + 𝑥 2 +𝑥3)

f1 f2 f3 f4 (a) Sum-of-products realization x1 x2 x3 (a) Sum-of-products realization f1 x1 x2 x3 f1 f2 f3 f4 f 1 x3 x2 x1 f2 f3 f f4 (a) Product-of-sums realization

Multiplexer Distributive property 12a. x (y + z) = xy + xz A circuit that generates an output that exactly reflects the state of one of a number of data inputs, based on the value of one or more selection control inputs. s x1 x2 f (s, x1, x2) f(s, x1, x2) = 𝒔 𝒙𝟏 𝒙𝟐 + 𝒔 𝒙𝟏𝒙𝟐+𝒔 𝒙𝟏 𝒙𝟐+𝒔𝒙𝟏𝒙𝟐 //12a = 𝒔 𝒙𝟏 𝒙𝟐 +𝒙𝟐 +𝒔 𝒙𝟏 +𝒙𝟏 𝒙𝟐 = 𝒔 𝒙𝟏∙𝟏+𝒔∙𝟏∙𝒙𝟐 = 𝒔 𝒙𝟏+𝒔𝒙𝟐 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

Implementation of a 2-to-1 multiplexer = 𝒔 𝒙𝟏+𝒔𝒙𝟐 x 1 s x1 x2 f (s, x1, x2) f s 1 x 2 1 1 s f (s, x1, x2) (b) Circuit 1 1 1 x1 1 1 x2 1 1 1 s 1 1 (d) More compact truth-table representation x 1 1 1 1 1 f x 1 (a) Truth table 2 (c) Graphical symbol

More about complex multiplexer A 4-to-1 multiplexer has four data inputs and one output Two selection control inputs are needed A 8-to-1 multiplexer needs eight data inputs and three selection control inputs Same circuit structure can be used to implement multiplexer using NAND gates. More discussions on multiplexer are in Chapter 3 and 6.

2.12 Examples of Solved problems

Example 2.8 Determine if the following equation is valid 𝑥 1 𝑥 3 +𝑥2𝑥3+𝑥1 𝑥 2 = 𝑥 1 𝑥2+𝑥1𝑥3+ 𝑥 2 𝑥 3 Solution: Derive a canonical SOP form for each expression (an algebraic approach) LHS = 𝑥 1 (𝑥2+ 𝑥 2 ) 𝑥 3 +(𝑥1+ 𝑥 1 )𝑥2𝑥3+𝑥1 𝑥 2 (𝑥3+ 𝑥 3 ) = 𝑥 1 𝑥2 𝑥 3 + 𝑥 1 𝑥 2 𝑥 3 +𝑥1𝑥2𝑥3+ 𝑥 1 𝑥2𝑥3+𝑥1 𝑥 2 𝑥3+𝑥1 𝑥 2 𝑥 3 ( 2 0 7 3 5 4 ) = 𝑚(2,0,7,3,5,4) = 𝑚(0,2,3,4,5,7) RHS = 𝑥 1 𝑥2(𝑥3+ 𝑥 3 )+𝑥1(𝑥2+ 𝑥 2 )𝑥3+(𝑥1+ 𝑥 1 ) 𝑥 2 𝑥 3 = 𝑥 1 𝑥2𝑥3+ 𝑥 1 𝑥2 𝑥 3 +𝑥1𝑥2𝑥3+𝑥1 𝑥 2 𝑥3+𝑥1 𝑥 2 𝑥 3 + 𝑥 1 𝑥 2 𝑥 3 = 𝑚(3,2,7,5,4,0) = 𝑚(0,2,3,4,5,7)

Example 2.9 Combining property 14b. (x + y) (x + 𝑦 ) = x Determine the minimum-cost POS expression for the function f(x1,x2,x3,x4) = 𝑚(0,2,4,5,6,7,8,10,12,14,15) Solution: To find a POS expression we should start with the definition in terms of maxiterms, which is f = 𝑀(1,3,9,11,13) f = M1∙𝑀3∙𝑀9∙𝑀11∙𝑀13 = (x1+x2+x3+ 𝒙 𝟒 ) (x1+x2+ 𝒙 𝟑 + 𝒙 𝟒 ) ( 𝒙 𝟏 +x2+x3+ 𝒙 𝟒 ) ( 𝒙 𝟏 +x2+ 𝒙 𝟑 + 𝒙 𝟒 ) ( 𝒙 𝟏 + 𝒙 𝟐 +x3+ 𝒙 𝟒 ) M1∙𝑀3 = x1 + x2 + 𝒙 𝟒 // combining property 14b M9∙𝑀11= 𝒙 𝟏 + x2 + 𝒙 𝟒 M9∙𝑀13= 𝒙 𝟏 + x3 + 𝒙 𝟒 f = (x1+x2+ 𝒙 𝟒 ) ( 𝒙 𝟏 +x2+ 𝒙 𝟒 ) ( 𝑥 1 +x3+ 𝑥 4 ) = (x2+ 𝒙 𝟒 ) ( 𝑥 1 +x3+ 𝑥 4 )

Example 2.12 Derive the simplest SOP expression for the function Absorption 13a. x+xy = x Combining 14a. xy+x 𝑦 = x Derive the simplest SOP expression for the function 𝑓=𝑥2 𝑥3 𝑥4+𝑥1𝑥3𝑥4+𝑥1 𝑥2 𝑥4 Solution: f = 𝑥2 𝑥3 𝑥4+𝑥1𝑥3𝑥4+𝒙𝟐𝒙𝟒𝒙𝟏+ 𝑥1 𝑥2 𝑥4 //consensus = 𝑥2 𝑥3 𝑥4+𝑥1𝑥3𝑥4+𝒙𝟏𝒙𝟐𝒙𝟒+ 𝒙𝟏 𝒙𝟐 𝒙𝟒// combining = 𝑥2 𝑥3 𝑥4+𝑥1𝑥3𝑥4+𝒙𝟏𝒙𝟒 = 𝑥2 𝑥3 𝑥4+𝒙𝟏𝒙𝟑𝒙𝟒+𝒙𝟏𝒙𝟒 // absorption = 𝑥2 𝑥3 𝑥4+𝒙𝟏𝒙𝟒 Consensus 17a. xy + 𝑥 𝑧+𝑦𝑧 = xy+ 𝑥 𝑧

Problem 2.31 1 1 1 1 x 1 1 1 1 1 1 1 x 2 1 x 3 1 f Time Figure P2.3. A timing diagram representing a logic function. Synthesize the function in the simplest SOP form

Problem 2.31 The simplest SOP expression is 1 1 1 1 1 1 1 1 1 1 x 2 1 x 3 1 f x1 x2 x3 f 1 Time The simplest SOP expression is 𝑓= 𝑥 1 𝑥 2 𝑥 3 + 𝑥 1 x2x3+x1 𝑥 2 x3+x1x2 𝑥 3