Lecture (04) Boolean Algebra and Logic Gates By: Dr. Ahmed ElShafee

Similar documents
Lecture (04) Boolean Algebra and Logic Gates

SYNERGY INSTITUTE OF ENGINEERING & TECHNOLOGY,DHENKANAL LECTURE NOTES ON DIGITAL ELECTRONICS CIRCUIT(SUBJECT CODE:PCEC4202)

Boolean Algebra and Logic Gates

Chapter 2. Boolean Algebra and Logic Gates

Chapter 2. Boolean Expressions:

Bawar Abid Abdalla. Assistant Lecturer Software Engineering Department Koya University

ENGIN 112 Intro to Electrical and Computer Engineering

Lecture (05) Boolean Algebra and Logic Gates

UNIT 2 BOOLEAN ALGEBRA

Experiment 4 Boolean Functions Implementation

Boolean algebra. June 17, Howard Huang 1

Lecture (03) Binary Codes Registers and Logic Gates

Bawar Abid Abdalla. Assistant Lecturer Software Engineering Department Koya University

Combinational Logic & Circuits

Binary logic. Dr.Abu-Arqoub

Lecture 3: Binary Subtraction, Switching Algebra, Gates, and Algebraic Expressions

Lecture (02) Operations on numbering systems

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

Boolean Algebra & Digital Logic

Introduction to Boolean Algebra

Logic Design: Part 2

Introduction to Boolean Algebra

Boolean Algebra A B A AND B = A*B A B A OR B = A+B


Boolean Algebra. BME208 Logic Circuits Yalçın İŞLER

4&5 Binary Operations and Relations. The Integers. (part I)

2.6 BOOLEAN FUNCTIONS

Chapter 2 Boolean algebra and Logic Gates

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

Circuit analysis summary

ELCT201: DIGITAL LOGIC DESIGN

IT 201 Digital System Design Module II Notes

ENGIN 112. Intro to Electrical and Computer Engineering

Variable, Complement, and Literal are terms used in Boolean Algebra.

[Ch 6] Set Theory. 1. Basic Concepts and Definitions. 400 lecture note #4. 1) Basics

Unit-IV Boolean Algebra

CGF Lecture 2 Numbers

Propositional Calculus. Math Foundations of Computer Science

6.1 Combinational Circuits. George Boole ( ) Claude Shannon ( )

Propositional Calculus: Boolean Algebra and Simplification. CS 270: Mathematical Foundations of Computer Science Jeremy Johnson

Introduction to Computer Architecture

Menu. Algebraic Simplification - Boolean Algebra EEL3701 EEL3701. MSOP, MPOS, Simplification

Combinational Logic Circuits

DIGITAL SYSTEM DESIGN

6. Combinational Circuits. Building Blocks. Digital Circuits. Wires. Q. What is a digital system? A. Digital: signals are 0 or 1.

Information Science 1

Combinational Devices and Boolean Algebra

Summary. Boolean Addition

Boolean Analysis of Logic Circuits

CDA 3200 Digital Systems. Instructor: Dr. Janusz Zalewski Developed by: Dr. Dahai Guo Spring 2012

Computer Science. Unit-4: Introduction to Boolean Algebra

ELCT201: DIGITAL LOGIC DESIGN

Objectives: 1- Bolean Algebra. Eng. Ayman Metwali

Definitions. 03 Logic networks Boolean algebra. Boolean set: B 0,

Designing Computer Systems Boolean Algebra

Chapter 3. Boolean Algebra and Digital Logic

CSCI2467: Systems Programming Concepts

2. BOOLEAN ALGEBRA 2.1 INTRODUCTION

Dr. Chuck Cartledge. 10 June 2015

Combinational Circuits Digital Logic (Materials taken primarily from:

Software Engineering 2DA4. Slides 2: Introduction to Logic Circuits

1. Mark the correct statement(s)

2.1 Binary Logic and Gates

Gate Level Minimization Map Method

Propositional Calculus. CS 270: Mathematical Foundations of Computer Science Jeremy Johnson

Standard Forms of Expression. Minterms and Maxterms

LECTURE 4. Logic Design

Algebra 1 Review. Properties of Real Numbers. Algebraic Expressions

QUESTION BANK FOR TEST

Boolean Algebra. P1. The OR operation is closed for all x, y B x + y B

Boolean Logic CS.352.F12

Read this before starting!

6.1 Combinational Circuits. George Boole ( ) Claude Shannon ( )

BOOLEAN ALGEBRA AND CIRCUITS

Lecture 5. Chapter 2: Sections 4-7

Review. EECS Components and Design Techniques for Digital Systems. Lec 05 Boolean Logic 9/4-04. Seq. Circuit Behavior. Outline.

(Refer Slide Time 6:48)

Chap-2 Boolean Algebra

DSAS Laboratory no 4. Laboratory 4. Logic forms

Software and Hardware

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

Experiment 3: Logic Simplification

01 Introduction to Digital Logic. ENGR 3410 Computer Architecture Mark L. Chang Fall 2008

8.3 Common Loop Patterns

EE292: Fundamentals of ECE

SWITCHING THEORY AND LOGIC CIRCUITS

Combinational Circuits

NAND. Grade (10) Instructor. Logic Design 1 / 13

Henry Lin, Department of Electrical and Computer Engineering, California State University, Bakersfield Lecture 7 (Digital Logic) July 24 th, 2012

Read this before starting!

SE311: Design of Digital Systems

Computer Architecture

Module -7. Karnaugh Maps

Why Don t Computers Use Base 10? Lecture 2 Bits and Bytes. Binary Representations. Byte-Oriented Memory Organization. Base 10 Number Representation

Lecture 10: Combinational Circuits

Outline. What Digit? => Number System. Decimal (base 10) Significant Digits. Lect 03 Number System, Gates, Boolean Algebra. CS221: Digital Design

Read this before starting!

EEE130 Digital Electronics I Lecture #4_1

X Y Z F=X+Y+Z

Read this before starting!

Transcription:

Lecture (4) Boolean Algebra and Logic Gates By: Dr. Ahmed ElShafee Boolean algebra properties basic assumptions and properties: Closure law A set S is closed with respect to a binary operator, for every pair of elements of S, the binary operator specifies a rule for obtaining a unique element of S. ١ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٢ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Commutative law. A binary operator * on a set S is said to be commutative whenever Associative law. A binary operator * on a set S is said to be associative whenever ٣ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٤ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Identity element. A set S is said to have an identity element with respect to a binary operation * on S if there exists an element e S with the property that ٥ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Example: The element is an identity element with respect to the binary operator + on the set of integers I = {, 3, 2,,,, 2, 3, }, since x + = + x = x for any x I Example: The element is an identity element with respect to the binary operator. on the set of integers I = {, 3, 2,,,, 2, 3, }, since x. =. x = x for any x I Inverse. A set S having the identity element e with respect to a binary operator * is said to have an inverse whenever, for every x S, there exists an element y S such that Example: In the set of integers, I, and the operator +, with e =, the inverse of an element a is ( a), since a + ( a) =. ٧ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٨ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Distributive law If * and. are two binary operators on a set S, * is said to be distributive over. Whenever ٩ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ١٠ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Summery The binary operator + defines addition (OR). The additive identity is. The additive inverse defines subtraction. The binary operator. defines multiplication (AND). The multiplicative identity is. For a, the multiplicative inverse of a = /a defines division (i.e., a. /a = ). The only distributive law applicable is that of. over +: a. (b + c) = (a. b) + (a.. c) ١١ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ١٢ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Ordinary and Boolean Algebra George Boole developed an algebraic system now called Boolean algebra. Claude E. Shannon introduced a two valued Boolean algebra called switching algebra that represented the properties of bistable electrical switching circuits.. (a) The structure is closed with respect to the operator +. (b) The structure is closed with respect to the operator.. 2. (a) The element is an identity element with respect to +; that is, x + = + x = x. (b) The element is an identity element with respect to. ; that is, x. =. x = x. 3. (a) The structure is commutative with respect to +; that is, x + y = y + x. (b) The structure is commutative with respect to. ; that is, x. y = y. x. ١٣ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ١٤ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design 4. (a) The operator. is distributive over +; that is, x. (y + z) = (x. y) + (x. z). (b) The operator + is distributive over. ; that is, x + (y. z) = (x + y). (x + z). 5. For every element x B, there exists an element x B (called the complement of x) such that (a) x + x = and (b) x. x =, 6. There exist at least two elements x, y B such that x y. Comparing Boolean algebra with arithmetic and ordinary algebra: The distributive law of + over. (i.e., x + (y. z) = (x + y). (x + z) ) is valid for Boolean algebra, but not for ordinary algebra. Boolean algebra does not have additive or multiplicative inverses; therefore, there are no subtraction or division operations. defines an operator called the complement that is not available in ordinary algebra. ١٥ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Two Valued Boolean Algebra Ordinary algebra deals with the real numbers, which constitute an infinite set of elements. Boolean algebra deals with the as yet undefined set of elements, B, but in the two valued Boolean algebra defined next (and of interest in our subsequent use of that algebra), B is defined as a set with only two elements, and. defined on a set of two elements, B = {, }, with rules for the two binary operators + and. Truth table rules are exactly the same as the AND, OR, and NOT operations ١٧ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ١٨ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design the structure is closed with respect to the two operators, each operation is either or and, B. From the tables, we see that (a) + = + = + = ; (b). =. =. =. This establishes the two identity elements, for + and for., The commutative laws are obvious from the symmetry of the binary operator table (A+B = B+A) & (A.B = B.A) The distributive law x. (y + z) = (x. y) + (x. z) can be shown to hold from the operator tables The distributive law of + over. can be shown to hold by means of a truth table ١٩ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٢٠ Truth table Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Postulates and Basic theorem of Boolean algebra the complement table (a) x + x =, since + = + = and + = + =. Postulates and Theorems of Boolean Algebra (b) x. x =, since. =. = and. =. =. ٢١ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٢٢ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Duality principle postulates were listed in pairs and designated by part (a) and part (b). One part may be obtained from the other if the binary operators and the identity elements are interchanged we simply interchange OR and AND operators and replace s by s and s by s. Theorem 5.a Truth table ٢٣ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٢٤ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Truth table Operator Precedence () parentheses, (2) NOT, (3) AND, and (4) OR. expressions inside parentheses must be evaluated before all other operations. The next operation that holds precedence is the complement, and then follows the AND and, finally, the OR. example: demorgan s ٢٥ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٢٦ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Boolean functions Boolean function described by an algebraic expression consists of binary variables A Boolean function can be represented in a truth table. The number of rows in the truth table is 2 n, where n is the number of variables in the function. The interconnection of gates will dictate the logic expression. Logic diagram ٢٧ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٢٨ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

x y z Y' y z x F it is sometimes possible to obtain a simpler expression for the same function and thus reduce the number of gates in the circuit and the number of inputs to the gate. ٢٩ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٣٠ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Logic diagram Logic diagram ٣١ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٣٢ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Algebraic Manipulation x y z X Y Xy X z X z f2 When a Boolean expression is implemented with logic gates, each term requires a gate and each variable within the term designates an input to the gate. We define a literal to be a single variable within a term, in complemented or un complemented form. By reducing the number of terms, the number of literals, or both in a Boolean expression, it is often possible to obtain a simpler circuit Truth table ٣٣ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٣٤ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Example ٣٥ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٣٦ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Complement of a Function The complement of a function may be derived algebraically through DeMorgan s theorems DeMorgan s theorems can be extended to three or more variables. ٣٧ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٣٨ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Example 2 ٣٩ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٤٠ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design

Example 3 ٤١ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design ٤٢ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design Thanks,.. See you next week (ISA), ٤٣ Dr. Ahmed ElShafee, ACU : Spring 26, Logic Design