Chapter 2 Digital Design and Computer Architecture, 2 nd Edition Chapter 2 David Money Harris and Sarah L. Harris.

Slides:



Advertisements
Similar presentations
Switching circuits Composed of switching elements called “gates” that implement logical blocks or switching expressions Positive logic convention (active.
Advertisements

Logical Systems Synthesis.
1 CK Cheng CSE Dept. UC San Diego CS 140, Lecture 2 Combinational Logic.
Boolean Algebra and Reduction Techniques
K-Maps, Timing Sequential Circuits: Latches & Flip-Flops Lecture 4 Digital Design and Computer Architecture Harris & Harris Morgan Kaufmann / Elsevier,
ECE 3110: Introduction to Digital Systems Simplifying Sum of Products using Karnaugh Maps.
Combinational Logic Circuits Is the logic circuit where the output always depends on the inputs irrespective of the previous state with out the feed back.
Boolean Algebra and Combinational Logic
ECE C03 Lecture 21 Lecture 2 Two Level Minimization Hai Zhou ECE 303 Advanced Digital Design Spring 2002.
ECE 301 – Digital Electronics Minterm and Maxterm Expansions and Incompletely Specified Functions (Lecture #6) The slides included herein were taken from.
ECE 331 – Digital System Design
1 CK Cheng CSE Dept. UC San Diego CS 140, Lecture 2 Combinational Logic.

1 Copyright © 2013 Elsevier Inc. All rights reserved. Chapter 2 Combinational Logic Design.
EET 1131 Unit 5 Boolean Algebra and Reduction Techniques
بهينه سازي با نقشة کارنو Karnaugh Map. 2  Method of graphically representing the truth table that helps visualize adjacencies 2-variable K-map 3-variable.
Overview Part 2 – Circuit Optimization 2-4 Two-Level Optimization
Boolean Algebra and Logic Simplification. Boolean Addition & Multiplication Boolean Addition performed by OR gate Sum Term describes Boolean Addition.
1 Fundamentals of Computer Science Propositional Logic (Boolean Algebra)
Logic Design A Review. Binary numbers Binary numbers to decimal  Binary 2 decimal  Decimal 2 binary.
Boolean Algebra and Digital Circuits
1 Simplification of Boolean Functions:  An implementation of a Boolean Function requires the use of logic gates.  A smaller number of gates, with each.
Department of Computer Engineering
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC. K-Map (1)  Karnaugh Mapping is used to minimize the number of logic gates that are required in a digital circuit.
1 Digital Logic Design Week 5 Simplifying logic expressions.
1 COMP541 Combinational Logic - 3 Montek Singh Jan 21, 2010.
1 © 2015 B. Wilkinson Modification date: January 1, 2015 Designing combinational circuits Logic circuits whose outputs are dependent upon the values placed.
Combinational Logic 1.
1 COMP541 Combinational Logic - 4 Montek Singh Jan 30, 2012.
ECE 2110: Introduction to Digital Systems PoS minimization Don’t care conditions.
UM EECS 270 Spring 2011 – Taken from Dr.Karem Sakallah Logic Synthesis: From Specs to Circuits Implementation Styles –Random –Regular Optimization Criteria.
Combinational Logic Part 2: Karnaugh maps (quick).
07 KM Page 1 ECEn/CS 224 Karnaugh Maps. 07 KM Page 2 ECEn/CS 224 What are Karnaugh Maps? A simpler way to handle most (but not all) jobs of manipulating.
CHAPTER 3: PRINCIPLES OF COMBINATIONAL LOGIC
Unit 1 Minimization Techniques and Logic Gates. Introduction to Digital Systems Analog devices and systems process time-varying signals that can take.
ENG241 Digital Design Week #2 Combinational Logic Circuits.
Lecture 3. Combinational Logic 1 Prof. Taeweon Suh Computer Science Education Korea University 2010 R&E Computer System Education & Research.
LOGIC CIRCUITLOGIC CIRCUIT. Goal To understand how digital a computer can work, at the lowest level. To understand what is possible and the limitations.
1 COMP541 Combinational Logic - 3 Montek Singh Jan 23, 2012.
Boolean Algebra and Reduction Techniques
1 EENG 2710 Chapter 2 Algebraic Methods For The Analysis and Synthesis of Logic circuits.
Fundamentals of digital electronics Prepared by - Anuradha Tandon Assistant Professor, Instrumentation & Control Engineering Branch, IT, NU.
ECE 3110: Introduction to Digital Systems Chapter #4 Review.
Lecture 3. Combinational Logic 2 Prof. Taeweon Suh Computer Science Education Korea University 2010 R&E Computer System Education & Research.
Boolean Expressions Lecture 3 Digital Design and Computer Architecture Harris & Harris Morgan Kaufmann / Elsevier, 2007.
COMP541 Combinational Logic - 4
BOOLEAN ALGEBRA AND LOGIC SIMPLIFICATION
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC
THE K-MAP.
1 COMP541 Combinational Logic - 3 Montek Singh Jan 21, 2015.
C.S.Choy39 TERMINOLOGY Minterm –product term containing all input variables of a function in either true or complementary form Maxterm – sum term containing.
Digital Logic (Karnaugh Map). Karnaugh Maps Karnaugh maps (K-maps) are graphical representations of boolean functions. One map cell corresponds to a row.
ECE DIGITAL LOGIC LECTURE 8: BOOLEAN FUNCTIONS Assistant Prof. Fareena Saqib Florida Institute of Technology Spring 2016, 02/11/2016.
BOOLEAN ALGEBRA LOGIC GATES. Introduction British mathematician George Boole( ) was successful in finding the link between logic and mathematics.
School of Computer and Communication Engineering, UniMAP DKT 122/3 - DIGITAL SYSTEM I Chapter 4A:Boolean Algebra and Logic Simplification) Mohd ridzuan.
Lecture 3. Combinational Logic #2 Prof. Taeweon Suh Computer Science & Engineering Korea University COSE221, COMP211 Logic Design.
©2010 Cengage Learning SLIDES FOR CHAPTER 8 COMBINATIONAL CIRCUIT DESIGN AND SIMULATION USING GATES Click the mouse to move to the next page. Use the ESC.
COMP541 Combinational Logic - 3
COSC3330 Computer Architecture Lecture 2. Combinational Logic
Chapter 2 Digital Design and Computer Architecture: ARM® Edition
ECE 2110: Introduction to Digital Systems
ECE 3110: Introduction to Digital Systems
COMP541 Combinational Logic - 3
COMP211 Computer Logic Design Lecture 3. Combinational Logic 2
BASIC & COMBINATIONAL LOGIC CIRCUIT
COMP541 Combinational Logic - 3
Chapter 2 Digital Design and Computer Architecture, 2nd Edition
Computer Architecture
Lecture 2: Combinational Logic Design
ECE 120 Midterm 2 HKN Review Session.
Presentation transcript:

Chapter 2 Digital Design and Computer Architecture, 2 nd Edition Chapter 2 David Money Harris and Sarah L. Harris

Chapter 2 Introduction Boolean Equations Boolean Algebra From Logic to Gates Multilevel Combinational Logic X’s and Z’s, Oh My Karnaugh Maps Combinational Building Blocks Timing Chapter 2 :: Topics

Chapter 2 A logic circuit is composed of: Inputs Outputs Functional specification Timing specification Introduction

Chapter 2 Nodes – Inputs: A, B, C – Outputs: Y, Z – Internal: n1 Circuit elements – E1, E2, E3 – Each a circuit Circuits

Chapter 2 Combinational Logic – Memoryless – Outputs determined by current values of inputs Sequential Logic – Has memory – Outputs determined by previous and current values of inputs Types of Logic Circuits

Chapter 2 Every element is combinational Every node is either an input or connects to exactly one output The circuit contains no cyclic paths Example: Rules of Combinational Composition

Chapter 2 Functional specification of outputs in terms of inputs Example: S = F(A, B, C in ) C out = F(A, B, C in ) Boolean Equations

Chapter 2 Complement: variable with a bar over it A, B, C Literal: variable or its complement A, A, B, B, C, C Implicant: product of literals ABC, AC, BC Minterm: product that includes all input variables ABC, ABC, ABC Maxterm: sum that includes all input variables (A+B+C), (A+B+C), (A+B+C) Some Definitions

Chapter 2 Y = F(A, B) = All equations can be written in SOP form Each row has a minterm A minterm is a product (AND) of literals Each minterm is TRUE for that row (and only that row) Form function by ORing minterms where the output is TRUE Thus, a sum (OR) of products (AND terms) Sum-of-Products (SOP) Form

Chapter 2 Y = F(A, B) = Sum-of-Products (SOP) Form All equations can be written in SOP form Each row has a minterm A minterm is a product (AND) of literals Each minterm is TRUE for that row (and only that row) Form function by ORing minterms where the output is TRUE Thus, a sum (OR) of products (AND terms)

Chapter 2 Y = F(A, B) = AB + AB = Σ(1, 3) Sum-of-Products (SOP) Form All equations can be written in SOP form Each row has a minterm A minterm is a product (AND) of literals Each minterm is TRUE for that row (and only that row) Form function by ORing minterms where the output is TRUE Thus, a sum (OR) of products (AND terms)

Chapter 2 Y = F(A, B) = (A + B)(A + B) = Π(0, 2) All Boolean equations can be written in POS form Each row has a maxterm A maxterm is a sum (OR) of literals Each maxterm is FALSE for that row (and only that row) Form function by ANDing the maxterms for which the output is FALSE Thus, a product (AND) of sums (OR terms) Product-of-Sums (POS) Form

Chapter 2 You are going to the cafeteria for lunch – You won’t eat lunch (E) – If it’s not open (O) or – If they only serve corndogs (C) Write a truth table for determining if you will eat lunch (E). Boolean Equations Example

Chapter 2 You are going to the cafeteria for lunch – You won’t eat lunch (E) – If it’s not open (O) or – If they only serve corndogs (C) Write a truth table for determining if you will eat lunch (E). Boolean Equations Example

Chapter 2 SOP & POS Form SOP – sum-of-products POS – product-of-sums

Chapter 2 SOP – sum-of-products POS – product-of-sums E = (O + C)(O + C)(O + C) = Π(0, 1, 3) E = OC = Σ(2) SOP & POS Form

Chapter 2 Axioms and theorems to simplify Boolean equations Like regular algebra, but simpler: variables have only two values (1 or 0) Duality in axioms and theorems: – ANDs and ORs, 0’s and 1’s interchanged Boolean Algebra

Chapter 2 Boolean Axioms

Chapter 2 B 1 = B B + 0 = B T1: Identity Theorem

Chapter 2 B 1 = B B + 0 = B T1: Identity Theorem

Chapter 2 B 0 = 0 B + 1 = 1 T2: Null Element Theorem

Chapter 2 B 0 = 0 B + 1 = 1 T2: Null Element Theorem

Chapter 2 B B = B B + B = B T3: Idempotency Theorem

Chapter 2 B B = B B + B = B T3: Idempotency Theorem

Chapter 2 B = B T4: Identity Theorem

Chapter 2 B = B T4: Identity Theorem

Chapter 2 B B = 0 B + B = 1 T5: Complement Theorem

Chapter 2 B B = 0 B + B = 1 T5: Complement Theorem

Chapter 2 Boolean Theorems Summary

Chapter 2 Boolean Theorems of Several Vars Note: T8’ differs from traditional algebra: OR (+) distributes over AND () ()

Chapter 2 Y = AB + AB Simplifying Boolean Equations Example 1:

Chapter 2 Y = AB + AB = B(A + A)T8 = B(1)T5’ = BT1 Simplifying Boolean Equations Example 1:

Chapter 2 Y = A(AB + ABC) Example 2: Simplifying Boolean Equations

Chapter 2 Y = A(AB + ABC) = A(AB(1 + C))T8 = A(AB(1))T2’ = A(AB)T1 = (AA)BT7 = ABT3 Example 2: Simplifying Boolean Equations

Chapter 2 Y = AB = A + B Y = A + B = A B DeMorgan’s Theorem

Chapter 2 Backward: – Body changes – Adds bubbles to inputs Forward: – Body changes – Adds bubble to output Bubble Pushing

Chapter 2 What is the Boolean expression for this circuit? Bubble Pushing

Chapter 2 What is the Boolean expression for this circuit? Y = AB + CD Bubble Pushing

Chapter 2 Begin at output, then work toward inputs Push bubbles on final output back Draw gates in a form so bubbles cancel Bubble Pushing Rules

Chapter 2 Bubble Pushing Example

Chapter 2 Bubble Pushing Example

Chapter 2 Bubble Pushing Example

Chapter 2 Bubble Pushing Example

Chapter 2 Two-level logic: ANDs followed by ORs Example: Y = ABC + ABC + ABC From Logic to Gates

Chapter 2 Inputs on the left (or top) Outputs on right (or bottom) Gates flow from left to right Straight wires are best Circuit Schematics Rules

Chapter 2 Wires always connect at a T junction A dot where wires cross indicates a connection between the wires Wires crossing without a dot make no connection Circuit Schematic Rules (cont.)

Chapter 2 Example: Priority Circuit Output asserted corresponding to most significant TRUE input Multiple-Output Circuits

Chapter 2 Example: Priority Circuit Output asserted corresponding to most significant TRUE input Multiple-Output Circuits

Chapter 2 Priority Circuit Hardware

Chapter 2 Don’t Cares

Chapter 2 Contention: circuit tries to drive output to 1 and 0 – Actual value somewhere in between – Could be 0, 1, or in forbidden zone – Might change with voltage, temperature, time, noise – Often causes excessive power dissipation Warnings: – Contention usually indicates a bug. – X is used for “don’t care” and contention - look at the context to tell them apart Contention: X

Chapter 2 Floating, high impedance, open, high Z Floating output might be 0, 1, or somewhere in between – A voltmeter won’t indicate whether a node is floating Tristate Buffer Floating: Z

Chapter 2 Floating nodes are used in tristate busses – Many different drivers – Exactly one is active at once Tristate Busses

Chapter 2 Boolean expressions can be minimized by combining terms K-maps minimize equations graphically PA + PA = P Karnaugh Maps (K-Maps)

Chapter 2 Circle 1’s in adjacent squares In Boolean expression, include only literals whose true and complement form are not in the circle Y = AB K-Map

Chapter 2 3-Input K-Map

Chapter 2 Y = AB + BC 3-Input K-Map

Chapter 2 Complement: variable with a bar over it A, B, C Literal: variable or its complement A, A, B, B, C, C Implicant: product of literals ABC, AC, BC Prime implicant: implicant corresponding to the largest circle in a K-map K-Map Definitions

Chapter 2 Every 1 must be circled at least once Each circle must span a power of 2 (i.e. 1, 2, 4) squares in each direction Each circle must be as large as possible A circle may wrap around the edges A “don't care” (X) is circled only if it helps minimize the equation K-Map Rules

Chapter 2 4-Input K-Map

Chapter 2 4-Input K-Map

Chapter 2 4-Input K-Map

Chapter 2 K-Maps with Don’t Cares

Chapter 2 K-Maps with Don’t Cares

Chapter 2 K-Maps with Don’t Cares

Chapter 2 Multiplexers Decoders Combinational Building Blocks

Chapter 2 Selects between one of N inputs to connect to output log 2 N-bit select input – control input Example: 2:1 Mux Multiplexer (Mux)

Chapter 2 2- Logic gates – Sum-of-products form Tristates –For an N-input mux, use N tristates –Turn on exactly one to select the appropriate input Multiplexer Implementations

Chapter 2 Using the mux as a lookup table Logic using Multiplexers

Chapter 2 Reducing the size of the mux Logic using Multiplexers

Chapter 2 N inputs, 2 N outputs One-hot outputs: only one output HIGH at once Decoders

Chapter 2 Decoder Implementation

Chapter 2 OR minterms Logic Using Decoders

Chapter 2 Delay between input change and output changing How to build fast circuits? Timing

Chapter 2 Propagation delay: t pd = max delay from input to output Contamination delay: t cd = min delay from input to output Propagation & Contamination Delay

Chapter 2 Delay is caused by –Capacitance and resistance in a circuit –Speed of light limitation Reasons why t pd and t cd may be different: –Different rising and falling delays –Multiple inputs and outputs, some of which are faster than others –Circuits slow down when hot and speed up when cold Propagation & Contamination Delay

Chapter 2 Critical (Long) Path: t pd = 2t pd_AND + t pd_OR Short Path: t cd = t cd_AND Critical (Long) & Short Paths

Chapter 2 When a single input change causes an output to change multiple times Glitches

Chapter 2 What happens when A = 0, C = 1, B falls? Glitch Example

Chapter 2 Glitch Example (cont.)

Chapter 2 Fixing the Glitch

Chapter 2 Glitches don’t cause problems because of synchronous design conventions (see Chapter 3) It’s important to recognize a glitch: in simulations or on oscilloscope Can’t get rid of all glitches – simultaneous transitions on multiple inputs can also cause glitches Why Understand Glitches?