Boolean Algebra and Digital Circuits

Slides:



Advertisements
Similar presentations
CS 151 Digital Systems Design Lecture 5 Boolean Algebra.
Advertisements

Prof. Sin-Min Lee Department of Computer Science
Chapter 2 Logic Circuits.
Boolean Algebra and Reduction Techniques
Boolean Algebra and Combinational Logic
ECE 331 – Digital System Design Boolean Algebra (Lecture #3) The slides included herein were taken from the materials accompanying Fundamentals of Logic.
ENGIN112 L8: Minimization with Karnaugh Maps September 19, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 8 Minimization with Karnaugh.
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN Lecture 6 Dr. Shi Dept. of Electrical and Computer Engineering.
Chapter 2 – Combinational Logic Circuits Part 1 – Gate Circuits and Boolean Equations Logic and Computer Design Fundamentals.
Relationship Between Basic Operation of Boolean and Basic Logic Gate The basic construction of a logical circuit is gates Gate is an electronic circuit.
CS 151 Digital Systems Design Lecture 6 More Boolean Algebra A B.
ENGIN112 L5: Boolean Algebra September 12, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 5 Boolean Algebra.
CS 151 Digital Systems Design Lecture 8 Minimization with Karnaugh Maps.
بهينه سازي با نقشة کارنو Karnaugh Map. 2  Method of graphically representing the truth table that helps visualize adjacencies 2-variable K-map 3-variable.
Chapter 2: Boolean Algebra and Logic Functions
Gate Circuits and Boolean Equations BIL- 223 Logic Circuit Design Ege University Department of Computer Engineering.
Boolean Algebra – I. Outline  Introduction  Digital circuits  Boolean Algebra  Two-Valued Boolean Algebra  Boolean Algebra Postulates  Precedence.
Overview of Chapter 3 °K-maps: an alternate approach to representing Boolean functions °K-map representation can be used to minimize Boolean functions.
Binary Logic and Gates Binary variables take on one of two values.
BOOLEAN ALGEBRA Saras M. Srivastava PGT (Computer Science)
1 Representation of Logic Circuits EE 208 – Logic Design Chapter 2 Sohaib Majzoub.
Department of Computer Engineering
Dr. Eng. Farag Elnagahy Office Phone: King ABDUL AZIZ University Faculty Of Computing and Information Technology CPCS 222.
Overview Part 1 – Gate Circuits and Boolean Equations
Chapter 4 Combinational Logic Design Principles. Overview Objectives -Define combinational logic circuit -Analysis of logic circuits (to describe what.
Chapter 2 Two- Level Combinational Logic. Chapter Overview Logic Functions and Switches Not, AND, OR, NAND, NOR, XOR, XNOR Gate Logic Laws and Theorems.
CHAPTER 3: PRINCIPLES OF COMBINATIONAL LOGIC
LOGIC GATES & BOOLEAN ALGEBRA
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.
Computer Systems 1 Fundamentals of Computing Simplifying Boolean Expressions.
LOGIC CIRCUITLOGIC CIRCUIT. Goal To understand how digital a computer can work, at the lowest level. To understand what is possible and the limitations.
Boolean Algebra and Reduction Techniques
Lecture 4 Boolean Algebra. Logical Statements °A proposition that may or may not be true: Today is Monday Today is Sunday It is raining °Compound Statements.
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.
Binary Logic and Gates Boolean Algebra Canonical and Standard Forms Chapter 2: Boolean Algebra and Logic Gates.
CS151 Introduction to Digital Design Chapter Map Simplification.
BOOLEAN ALGEBRA AND LOGIC SIMPLIFICATION
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN Lecture 4 Dr. Shi Dept. of Electrical and Computer Engineering.
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.
Lecture 5 More Boolean Algebra A B. Overview °Expressing Boolean functions °Relationships between algebraic equations, symbols, and truth tables °Simplification.
CSE 461. Binary Logic Binary logic consists of binary variables and logical operations. Variables are designated by letters such as A, B, C, x, y, z etc.
K-maps and Decoders Prof. Sin-Min Lee Department of Computer Science.
CHAPTER 2 Boolean algebra and Logic gates
CHAPTER 3 Simplification of Boolean Functions
De Morgan’s Theorem,.
Chapter 2: Boolean Algebra and Logic Functions
Unit 2 Boolean Algebra.
ECE 20B, Winter 2003 Introduction to Electrical Engineering, II LECTURE NOTES #2 Instructor: Andrew B. Kahng (lecture)
CS 105 Digital Logic Design
Gate Circuits and Boolean Equations
CHAPTER 2 Boolean Algebra
CHAPTER 2 Boolean Algebra This chapter in the book includes:
Boolean Algebra and Combinational Logic
SLIDES FOR CHAPTER 2 BOOLEAN ALGEBRA
TN 221: DIGITAL ELECTRONICS 1
Speaker: Fuw-Yi Yang 楊伏夷 伏夷非征番, 道德經 察政章(Chapter 58) 伏者潛藏也
Lecture 3: Boolean Algebra
CHAPTER 2 Boolean Algebra
Boolean Algebra.
Boolean Algebra.
Chapter 2 Boolean Algebra and Logic Gate
BASIC & COMBINATIONAL LOGIC CIRCUIT
CSE 370 – Winter Combinational Logic - 1
BOOLEAN ALGEBRA AND LOGIC SIMPLIFICATION Part (a)
COMS 361 Computer Organization
Circuit Simplification and
Presentation transcript:

Boolean Algebra and Digital Circuits Reading: Chapter 8 (138-162) from the text book

Defn of a Boolean Algebra A Boolean algebra consists of: a set B={0, 1}, 2 binary operations on B (denoted by + & ×), a unary operation on B (denoted by '), such that : 0 + 0 = 0 0 × 0 = 0 1 + 0 = 1 0 × 1 = 0 0 + 1 = 1 1 × 0 = 0 1 + 1 = 1 1 × 1 = 1 0’=1 and 1’=0.

Rules of a Boolean Algebra The following axioms (‘rules’) are satisfied for all elements x, y& z of B: (1) x + y = y + x (commutative axioms) x× y = y × x (2) x + (y + z) = (x + y) + z (associative axioms) x × (y × z) = (x × y) × z (3) x × (y + z) = (x × y) + (x × z) x + (y × z) = (x + y) × (x + z) (distributive axioms) (4) x + 0 = x x × 1 = x (identity axioms) (5) x + x' = 1 x × x' = 0 (inverse axioms)

Duality To form the dual of an expression, replace all + operators with × operators, all × operators with + operators, all 1’s with 0’s, and all 0’s with 1’s. The principle of duality says that if an expression is valid in Boolean algebra, the dual of that expression is also valid.

Duality Exercise: Form the dual of the expression a + (bc) = (a + b)(a + c) Solution: Following the replacement rules… a(b + c) = ab + ac Take care not to alter the location of the parentheses if they are present.

Laws of Boolean Algebra In addition to the laws given by the axioms of Boolean Algebra, we can show the following laws x'' = x (double complement) x + x = x x× x = x (idempotent ) (x + y)' = x' × y' (x × y)' = x' + y' (de Morgan’s laws) x + 1 = 1 x × 0 = 0 (annihilation) x + (x × y) = x x× (x + y) = x (absorption) 0' = 1 1' = 0 (complement)

Exercise (x' × y) + (x × y) Solution: (x' × y) + (x × y) Simplify the Boolean expression (x' × y) + (x × y) Solution: (x' × y) + (x × y) = (y × x') + (y × x) (commutative) = y × (x' + x) (distributive) = y × (x + x') (commutative) = y × 1 (inverse) = y (identity) Thus (x' × y) + (x × y) = y

Digital Circuits The circuitry in a digital computer operates with signals that can take only 2 values ‘on/off’ (i.e. 0/1). We’ll use the particular Boolean Algebra where B has just the 2 elts 0 & 1, and where Boolean addition corresponds to parallel switch contacts:

Boolean Addition

Boolean Multiplication Boolean multiplication corresponds to series switch contacts:

Boolean Notation This means that in effect we’ll be employing Boolean Algebra notation. The truth tables can be rewritten as

Notational Short-cuts We will employ short-cuts in notation: In ‘multiplication’ we’ll omit the symbol ×, & write xy for x × y (just as in ordinary algebra) (2) The associative law says that x + (y + z) = (x + y) + z So we’ll write this as simply x + y + z, because the brackets aren’t necessary.

Notational Short-cuts Similarly, write the product of 3 terms as xyz (3) In ordinary algebra, the expression x + y × z means x + (y × z), because of the convention that multiplication takes precedence over addition. e.g. x + yz means x + (y × z), and not (x + y) × z Similarly, ab + cd means (a × b) + (c × d)

Digital Circuits A digital circuit (or logic gate circuit) is an electronic device for carrying out digital computations (e.g. addition of 2 numbers) It accepts 1 or more inputs, each of which has 2 possible states (0 for ‘off’ & 1 for ‘on’) For each possible combination of inputs, one or more outputs are produced . Logic Circuit Inputs Outputs

Describing Circuit Functionality: Inverter Truth Table A Y 1 A Y Symbol Input Output Truth table completely specifies outputs for all input combinations. The above circuit is an inverter. An input of 0 is inverted to a 1. An input of 1 is inverted to a 0. credential: bring a computer die photo wafer : This can be an hidden slide. I just want to use this to do my own planning. I have rearranged Culler’s lecture slides slightly and add more slides. This covers everything he covers in his first lecture (and more) but may We will save the fun part, “ Levels of Organization,” at the end (so student can stay awake): I will show the internal stricture of the SS10/20. Notes to Patterson: You may want to edit the slides in your section or add extra slides to taylor your needs.

The AND Gate This is an AND gate. So, if the two inputs signals B Y This is an AND gate. So, if the two inputs signals are asserted (high (ON)) the output will also be asserted (ON). Otherwise, the output will be asserted (low (OFF)). Truth Table Input 1 input2 output A B Y 1

The OR Gate This is an OR gate. B Y This is an OR gate. So, if at least one of the two input signals is asserted (ON), then output will be asserted (ON). Otherwise, the output will be asserted (low (OFF)). Input 1 Input 2 Output A B Y 1

Consider Three-input Gate 3 Input OR Gate

Boolean Functions Boolean algebra deals with binary variables and logic operations. Function results in binary 0 or 1 x 1 y z F F = x(y+z’) z’ y+z’

Boolean Functions x 1 y 1 z 1 xy 1 yz 1 G 1 x y z G = xy +yz yz xy We will learn how to transform between expression and truth table.

Truth Table to Expression Converting a truth table to an expression Each row with output of 1 becomes a product term Sum product terms together to have the Boolean function. x 1 y 1 z 1 G 1 Any Boolean Expression can be represented in sum of products form! xyz + xyz’ + x’yz

Equivalent Representations of Circuits Number of 1’s in truth table output column equals AND terms for Sum-Of-Products (SOP) x y z 1 G G = xyz + xyz’ + x’yz credential: bring a computer die photo wafer : This can be an hidden slide. I just want to use this to do my own planning. I have rearranged Culler’s lecture slides slightly and add more slides. This covers everything he covers in his first lecture (and more) but may We will save the fun part, “ Levels of Organization,” at the end (so student can stay awake): I will show the internal stricture of the SS10/20. Notes to Patterson: You may want to edit the slides in your section or add extra slides to taylor your needs.

Reducing Boolean Expressions Is this the smallest possible implementation of this expression? No! Use Boolean Algebra rules to reduce complexity while preserving functionality. Step 1: Use idempotent law (a + a = a). So xyz + xyz’ + x’yz = xyz + xyz + xyz’ + x’yz G = xyz + xyz’ + x’yz

Reducing Boolean Expressions Step 2: Use distributive law a(b + c) = ab + ac. So xyz + xyz + xyz’ + x’yz = xy(z + z’) + yz(x + x’) Step 3: Use Inverse law (a + a’ = 1). So xy(z + z’) + yz(x + x’) = xy.1 + yz.1 Step 4: Use Identity law (a . 1 = a). So xy + yz = xy.1 + yz.1 = xyz + xyz’ + x’yz

Reduced Hardware Implementation Reduced equation requires less hardware! Same function implemented! x 1 y z G x x G credential: bring a computer die photo wafer : This can be an hidden slide. I just want to use this to do my own planning. I have rearranged Culler’s lecture slides slightly and add more slides. This covers everything he covers in his first lecture (and more) but may We will save the fun part, “ Levels of Organization,” at the end (so student can stay awake): I will show the internal stricture of the SS10/20. Notes to Patterson: You may want to edit the slides in your section or add extra slides to taylor your needs. x x x y z G = xyz + xyz’ + x’yz = xy + yz

Karnaugh maps Alternate way of representing Boolean function All rows of truth table represented with a square Each square represents a minterm x y F 0 0 1 0 1 1 1 0 0 1 1 0 1 y x x’y’ xy’ xy x’y 1 y x

Karnaugh maps Easy to convert between truth table, K-map, and SOP. Unoptimized form: number of 1’s in K-map equals number of minterms (products) in SOP. Optimized form: reduced number of minterms F(x,y) = x’y + x’y’ = x’

F=AB’C’ +AB C +ABC +ABC  + A’B’C + A’BC’ Karnaugh Maps A Karnaugh map is a graphical tool for assisting in the general simplification procedure. Two variable maps. A 1 B F=AB +A’B B 1 A 1 F=AB +AB +AB  1 1 1 A B C F Three variable maps. 1 1 A 1 00 01 BC 11 10 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 + F=AB’C’ +AB C +ABC +ABC  + A’B’C + A’BC’

Rules for K-Maps We can reduce functions by circling 1’s in the K-map. Each circle represents minterm reduction. Following circling, we can deduce minimized and-or form. F(x,y) = x’y + x’y’ = x’ 1 y x

Rules for K-Maps Rules to consider Every cell containing a 1 must be included at least once. The largest possible “power of 2 rectangle” must be enclosed.

F=AB’C’ +AB C +ABC +ABC  + A’B’C + A’BC’ Karnaugh Maps A Karnaugh map is a graphical tool for assisting in the general simplification procedure. Two variable maps. A 1 B F=AB +A’B A 1 B F=AB +AB +AB  F=A+B Three variable maps. A 1 00 01 BC 11 10 F=A+B C +BC  F=AB’C’ +AB C +ABC +ABC  + A’B’C + A’BC’

More Karnaugh Map Examples 1 1 b b 1 1 1 1 1 1 f = a g = b' ab ab c 00 01 11 10 c 00 01 11 10 1 1 1 1 1 1 1 1 1 1 cout = ab + bc + ac f = a 1. Circle the largest groups possible. 2. Group dimensions must be a power of 2. 3. Remember what circling means!