Lecture 4 4. Boolean functions – advanced

Slides:



Advertisements
Similar presentations
Boolean Algebra and Logic Gates
Advertisements

Logical Systems Synthesis.
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
Contemporary Logic Design Two-Level Logic © R.H. Katz Transparency No. 3-1 Chapter #2: Two-Level Combinational Logic Section 2.1, Logic Functions.
Propositional Calculus Math Foundations of Computer Science.
Chapter 2: Boolean Algebra and Logic Functions
Lecture 3: Incompletely Specified Functions and K Maps CSE 140: Components and Design Techniques for Digital Systems Fall 2014 CK Cheng Dept. of Computer.
Boolean Algebra Computer Organization 1 © McQuain Boolean Algebra A Boolean algebra is a set B of values together with: -two binary operations,
Systems Architecture I1 Propositional Calculus Objective: To provide students with the concepts and techniques from propositional calculus so that they.
1 COMBINATIONAL LOGIC One or more digital signal inputs One or more digital signal outputs Outputs are only functions of current input values (ideal) plus.
BOOLEAN ALGEBRA Saras M. Srivastava PGT (Computer Science)
Switching functions The postulates and sets of Boolean logic are presented in generic terms without the elements of K being specified In EE we need to.
ECE 331 – Digital System Design
1 Simplification of Boolean Functions:  An implementation of a Boolean Function requires the use of logic gates.  A smaller number of gates, with each.
 Seattle Pacific University EE Logic System DesignSOP-POS-1 The Connection: Truth Tables to Functions abcF abcF
Department of Computer Engineering
Dr. Eng. Farag Elnagahy Office Phone: King ABDUL AZIZ University Faculty Of Computing and Information Technology CPCS 222.
Charles Kime & Thomas Kaminski © 2008 Pearson Education, Inc. Circuit Optimization Logic and Computer Design Fundamentals.
Gate-Level Minimization
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
1 Minterm and Maxterm Expressions Definition: a minterm of n variables is a product of the variables in which each appears exactly once in true or complemented.
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 Lect # 2 Boolean Algebra and Logic Gates Boolean algebra defines rules for manipulating symbolic binary logic expressions. –a symbolic binary logic expression.
Module 5.  In Module 3, you have learned the concept of Boolean Algebra which consists of binary variables and binary operator.  A binary variable x,
Topic 4 – Switching Circuits. Serial vs. Parallel Transmission Circuit elements can be connected in either a serial or parallel manner. Serial implies.
BOOLEAN ALGEBRA AND LOGIC SIMPLIFICATION
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC
CSE 140: Components and Design Techniques for Digital Systems Lecture 3: Incompletely Specified Functions and K Maps CK Cheng Dept. of Computer Science.
Logic Simplification-Using K-Maps
Digital Logic (Karnaugh Map). Karnaugh Maps Karnaugh maps (K-maps) are graphical representations of boolean functions. One map cell corresponds to a row.
1 3- De-Morgan’s Theorems 1.The complement of a product of variables is equal to the sum of the complements of the variables. 2. The complement of a sum.
Boolean Functions 1 ECE 667 ECE 667 Synthesis and Verification of Digital Circuits Boolean Functions Basics Maciej Ciesielski Univ.
ECE DIGITAL LOGIC LECTURE 8: BOOLEAN FUNCTIONS Assistant Prof. Fareena Saqib Florida Institute of Technology Spring 2016, 02/11/2016.
Standard & Canonical Forms COE 202 Digital Logic Design Dr. Aiman El-Maleh College of Computer Sciences and Engineering King Fahd University of Petroleum.
BOOLEAN ALGEBRA LOGIC GATES. Introduction British mathematician George Boole( ) was successful in finding the link between logic and mathematics.
ECE 301 – Digital Electronics Minimizing Boolean Expressions using K-maps, The Minimal Cover, and Incompletely Specified Boolean Functions (Lecture #6)
School of Computer and Communication Engineering, UniMAP DKT 122/3 - DIGITAL SYSTEM I Chapter 4A:Boolean Algebra and Logic Simplification) Mohd ridzuan.
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC. De Morgan’s Theorem De Morgan’s Theorem.
DE MORGAN’S THEOREM. De Morgan’s Theorem De Morgan’s Theorem.
Boolean Algebra & Logic Gates
CHAPTER 3 Simplification of Boolean Functions
Lecture 3: Incompletely Specified Functions and K Maps
De Morgan’s Theorem,.
Lecture 4 Nand, Nor Gates, CS147 Circuit Minimization and
Chapter 2: Boolean Algebra and Logic Functions
DeMorgan’s Theorem DeMorgan’s 2nd Theorem
ECE 2110: Introduction to Digital Systems
ECE 20B, Winter 2003 Introduction to Electrical Engineering, II LECTURE NOTES #2 Instructor: Andrew B. Kahng (lecture)
CS 105 Digital Logic Design
ECE 3110: Introduction to Digital Systems
CHAPTER 3 SETS AND BOOLEAN ALGEBRA
ECE 331 – Digital System Design
CSE 311 Foundations of Computing I
Lecture 3: Incompletely Specified Functions and K Maps
Boolean Algebra.
BASIC & COMBINATIONAL LOGIC CIRCUIT
CHAPTER 5 KARNAUGH MAPS 5.1 Minimum Forms of Switching Functions
CSE 370 – Winter Combinational Logic - 1
Combinatorial Logic Circuit
January 19 W’05 Yutao He 4532B Boelter Hall CSM51A/EEM16-Sec.1 W’05
MINTERMS and MAXTERMS Week 3
Chapter 2 Introduction to Logic Circuits
Lecture 5 Logistics Last lecture Today’s lecture
3-Variable K-map AB/C AB/C A’B’ A’B AB AB’
Analysis of Logic Circuits Example 1
Combinational Logic Circuit
Lecture 3: Incompletely Specified Functions and K Maps
Circuit Simplification and
Presentation transcript:

Lecture 4 4. Boolean functions – advanced 4.1 The normal form and the canonical form 4.2 Fundamental product and sums 4.3 Disjunctive and conjunctive canonical forms 4.4 Logical operations of 2 variables 4.5 Functionally complete sets 4.6 Karnaugh map – another way of denotation 4.7 Karnaugh map of 5 and 6 variables 4.7 Don’t care terms

Boolean functions and logical operations Some fundamental terms, forms and definitions relating to Boolean functions and expressions will now be studied We shall also see how many other logical operations besides AND, OR and negation can be derived

4.1 The normal form D1: A Boolean variable in true form or in complemented form is called a literal. Thus a,b,c, Na,Nb,Nc (a’,b’,c’) and so on are literals. D2: The Boolean product of two or more literals is called a product term.

The normal form-2 D3: The Boolean sum of two or more literals is called a sum term. D4: When a Boolean function appears as a sum of several product terms, it is said to be expressed as a sum of products (SOP). The SOP form is also called the disjunctive normal form (DNF).

The normal form-3 D5: When a Boolean function appears as a product of several sum terms, it is said to be expressed as a product of sums (POS). The POS form is also called the conjunctive normal form (CNF).

The normal form-4 Example 1 f(a,b,c,d)=N.a+b.Nc+c.d is an expression in SOP form or DNF. Example 2 f(a,b,c,d)=(a+b).(b+c+d) is an expression in POS form or CNF.

The canonical form D6: When each of the terms of a Boolean functions expressed either in SOP or POS form has all the variables in it it is said to be expressed in canonical form. Here also by idempotence law of Boolean algebra, the canonical form cannot have the same term more than once.

The canonical form-2 The canonical SOP form is called the disjunctive canonical form (DCF) and the canonical POS form is called the conjunctive canonical form (CCF). Example: Express the following functions in canonical forms f1=a.Nb.c+b.Nc+a.c f2=(a+b).(b+Nc)

The canonical form-3 Solutions: a)f1=a.Nb.c+b.Nc+a.c= =a.Nb.c+(a+Na).b.Nc+a.(b+Nb).c= =a.Nb.c+a. b.Nc +Na.b.Nc+a.b.c+a.Nb.c b)f2= (a+b)(b+Nc)= = (a+b+c.Nc)(a.Na+b+Nc)= = (a+b+c).(a+b+Nc).(a+b+Nc).(Na+b+Nc)= = (a+b+c).(a+b+Nc).(Na+b+Nc) f1 is expressed in DCF, f2 is expressed in CCF.

4.2 Fundamental products and sums A product term of n variables is called a minterm of n variables. Thus Na.Nb.Nc and a.Nb.Nc are minterms of three variables. Since each variable can appear in a minterm in one of the two forms, true and complemented, the number of all possible minterms of n variables is 2 powered by n. A minterm is also called fundamental product.

Fundamental products and sums-2 If a 0 is written for complemented variable and 1 for the uncomplemented variable, each minterm can be expressed as a binary number. Each minterm is then designated as mi, where the subscript i is the decimal value of the binary number. See following table for the three variable case:

Fundamental products and sums-3 Minterms(n=3) Corresponding binary number representations Corresponding symbolic Na.Nb.Nc Na.Nb.c Na.b.Nc Na.b.c a.Nb.Nc a.Nb.c a.b.Nc a.b.c 000 001 010 011 100 101 110 111 m0 m1 m2 m3 m4 m5 m6 m7

Fundamental products and sums-4 A sum term of n variables is called a maxterm of n variables. Thus Na+b+c+Nd and a+b+c+d are maxterms of four variables. Like minterms, the number of maxterms is also 2 powered by n for n variables. A maxterm is also called fundamental sum.It is customary to designate each maxterm by Mi, where i is the decimal equivalent of the binary number representation of a maxterm, as shown in the following table for the three variable case.

Fundamental products and sums-5 Maxterms(n=3) Corresponding binary number representations Corresponding symbolic a+b+c a+b+Nc a+Nb+c a+Nb+Nc Na+b+c Na+b+Nc Na+Nb+c Na+Nb+Nc 000 001 010 011 100 101 110 111 M0 M1 M2 M3 M4 M5 M6 M7

Fundamental products and sums-6 It should be noted, that in the maxterms we have written a 0 for a variable in the true form and 1 for a variable in the complemented form. This is the opposite of the procedure we followed in the case of minterms. It can easily be verified, that the complement of mi is Mi and vice versa, that is: N(mi)=Mi and N(Mi)=mi

Fundamental products and sums-7 From the definitions of minterm and maxterm it is evident, that the disjunctive canonical form of a Boolean function is a sum of minterms, and the conjunctive canonical form is a product of maxterms. Thus f1=Na.Nb.Nc+Na.Nb.c+a.b.c =m0+m1+m7 and f2=(a+b+c).(Na+Nb+c).(Na+Nb+Nc)=M0.M6.M7

Fundamental products and sums-8 This has led to another convenient way of writing the canonical form wherein the m’s (minterms) and M’s (maxterms) are not written at all. Thus f1=sum(0,1,7) and f2=pí(0,6,7)

Fundamental products and sums-9 Here the decimal numbers (which are subscripts of the m’s or M’s) identify the particular terms, sum indicates, that the terms are minterms and the function is a summation, and pí indicates, that the terms are maxterms and the function is a product.

4.3 Disjunctive and conjunctive canonical forms It has been mentioned earlier that the disjunctive canonical form is the same as the sum of minterms and the conjunctive canonical form is the same as the product of maxterms. It is interesting to note that if a function is expressed in the DCF, it can also be expressed in the CCF, and vice versa.

Disjunctive and conjunctive canonical forms-2 Theorem: A Boolean function expressed as a sum of minterms or as a product of maxterms can be converted into the other form as given by sum(mi)=pí(Mj) and pí(Mi)=sum(mj) Where the subsets i and j are two partitions of the entire set of 2 powered by n subscripts of either m’s or M’s.

Disjunctive and conjunctive canonical forms-3 From this theorem it can be concluded, that any Boolean function can be expressed in both the disjunctive and conjunctive canonical form. Example1: Express the following function in the other type of canonical form: f1=Na.b.c+a.Nb.Nc+a.b.c

Disjunctive and conjunctive canonical forms-4 Solution f1=f1(a,b,c)=m3+m4+m7=sum(mi) Subset i=(3,4,7) Entire set of subscripts: 2 powered by n (n=3) is 8 (0,1,2,3,4,5,6,7) Subset j=(0,1,2,5,6) f1=pí(Mj)=pí(M0,M1,M2,M5,M6)= =M0.M1.M2.M5.M6= (a+b+c).(a+b+Nc).(a+Nb+c).(Na+b+Nc).(Na+Nb+c)

Disjunctive and conjunctive canonical forms-5 Example2: Express the function y from the Example 1 from exercises in the both canonical forms: y=f(S1,S2,S3) y=sum (mi)=(i:(3,5,6))=NS1.S2.S3+ S1.NS2.S3+ S1.S2.NS3…….DCF (DSF) y=pí(Mj)=(j:(0,1,2,4,7))=(S1+S2+S3). .(S1+S2+NS3).(S1+NS2+S3).(NS1+S2+S3). .(NS1+NS2+NS3)…..CCF (CSF)

4.4 Logical operations of 2 variables So far we have discussed mainly two logical operations, AND and OR of two variables and NOT(negation, inversion) of one variable. But there are altogether 16 various functions of two variables. 2 powered by 2 powered by 2=2 powered by 4=16 Generally the number of various functions of n binary variables is equal 2 powered by 2 powered by n

Logical operations of 2 variables -2 00 1 01 10 11

Logical operations of 2 variables -3 f1…allways FALSE f16…allways TRUE f2….AND f15……NAND f8…..OR f9…..NOR f7….EXOR (nonequivalence) f10…equivalence

Logical operations- of 2 variables-4 00 1 01 10 11 negation

Logical operations of 2 variables -5 f4…assertion (repetition) of a f13…negation of a f6…. assertion (repetition) of b f11…negation of b f3,f5,f12,f14 inclusion (does not have direct technical meaning)

4.5 Functionally complete sets Definition: A set of operations is called a functionally complete set, if and only if any Boolean function can be expressed by operations belonging to the set only. In fact, to prove any other set of operations to be functionally complete, it should be shown that its members can express the three operations of AND, OR, and NOT.

Functionally complete sets-2 For example, the sets of operations {AND, OR,NOT} {AND, NOT} {NAND} {OR,NOT} {NOR} {XOR, AND} are functionally complete sets.

Functionally complete sets-3 It can be seen that the NAND and NOR operations alone form a functionally complete set. It is therefore possible to implement any switching function using only one type of gate, either NAND or NOR. Hence these two operations are also known as universal operations, and the gates are used much more extensively than other gates in the synthesis of combinational logic circuits.

Functionally complete sets-4 How to implement switching function NOT (negation) using only NAND gate a a Na Na & & 1 a N(a . 1)=N(a)=Na N(a . a)=N(a)=Na

Functionally complete sets-5 How to implement switching function NOT (negation) using only NOR gate a a Na Na >=1 >=1 a N(a + 0)=N(a)=Na N(a + a)=N(a)=Na

Functionally complete sets-6 How to implement switching function AND using only NAND gate a N(a.b) N(a.b) a.b & & b N(a.b)

Functionally complete sets-7 How to implement switching function OR using only NOR gate a N(a+b) N(a+b) a+b >=1 >=1 b N(a+b)

Functionally complete sets-8 How to implement switching function OR using only NAND gate a N(Na.Nb)= N(Na)+N(Nb)= a+b Na & a & b Nb & b

Functionally complete sets-8 How to implement switching function AND using only NOR gate a N(Na+Nb)= N(Na).N(Nb)= a.b Na >=1 a >=1 b Nb >=1 b

4.6 Karnaugh map – another way of denotation cd ab 00 01 11 10 0000 1 0001 3 0011 2 0010 4 0100 5 0101 7 0111 6 0110 12 1100 13 1101 15 1111 14 1110 8 1000 9 1001 1011 1010

Karnaugh map – another way of denotation-2 cd ab 0000 1 0001 3 0011 2 0010 4 0100 5 0101 7 0111 6 0110 12 1100 13 1101 15 1111 14 1110 8 1000 9 1001 11 1011 10 1010

Karnaugh map – another way of denotation -3 ab cd 00 01 11 10 0000 4 0100 12 1100 8 1000 1 0001 5 0101 13 1101 9 1001 3 0011 7 0111 15 1111 1011 2 0010 6 0110 14 1110 1010

Karnaugh map – another way of denotation -3 ab cd 0000 4 0100 12 1100 8 1000 1 0001 5 0101 13 1101 9 1001 3 0011 7 0111 15 1111 11 1011 2 0010 6 0110 14 1110 10 1010

Karnaugh map – another way of denotation -4 What is important: Index is a binary value of the same expression, e.g. „abcd“ Property of neighbourhood

4.7 Karnaugh map of 5 and 6 variables The five-variable map is drawn as two separate four variable maps. Each of the two four variable maps is a map for the four variables e.g. x2,x3,x4,x5. They differ in the value of the first variable, x1. In one of the maps x1=0, in the other x1=1. Decimal values of the index can be computed following the same procedure as in other maps. Similarly, the six-variable map consists of four four-variable maps.

Five-varibles Karnaugh map-2 Example – values of indexes, 1st map for x1=0 x2x3 x4x5 00 01 11 10 00000 4 00100 12 01100 8 01000 1 00001 5 00101 13 01101 9 01001 3 00011 7 00111 15 01111 01011 2 00010 6 00110 14 01110 01010

Five-varibles Karnaugh map-2 Example – values of indexes, 2nd map for x1=1 x2x3 x4x5 00 01 11 10 16 10000 20 10100 28 11100 24 11000 17 10001 21 10101 29 11101 25 11001 19 10011 23 10111 31 11111 27 11011 18 10010 22 10110 30 11110 26 11010

4.8 Don’t care terms Karnaugh map is a representation of a switching function expressed in the form of a truth table or as a sum of minterms. In all the maps that we discussed so far, in each cell we plotted either a 1(shown on the map) or a 0 (shown or not shown but meant by implication) This means, that for such functions the output of the circuit is clearly specified to be either 1 or 0. Such functions are called completely specified functions.

Don’t care terms-2 There may be many practical cases, however, where the output of a circuit cannot be precisely specified. Very often this happens due to the simple fact that all input combinations may not occur in a practical situation For example, if the input variables of a function f(a,b) represent the values of limit switches for level in a container, we know that in practical case there is not possible to have high level and simultanously don’t have the low level too.

Don’t care terms-3 The exact value of the function for this input combination cannot be specified. Such functions are known as incompletely specified functions The input combinations for which the function is not specified are shown by plotting a x on the corresponding cell of the map. It is obvious that while minimizing, the value of x can be assumed to be either 1 or 0.

Don’t care terms-4 Since the circuit or software designer does not care for the exact value of these cells and chooses either 1 or 0 to suit the objective of obtaining the minimum solution, these terms are known as don’t –care terms. The minterms for which the function has the value x are also known as don’t –care minterms.

Don’t care terms-example -5 Z cd ab 00 01 11 10 x 1

Don’t care terms-example -6 Z cd ab 00 01 11 10 x 1

Don’t care terms-example -6 Z cd ab 00 01 11 10 x 1

Don’t care terms-example -7 Without using of „x“ fields the minimized function will be: Z= Na.b.Nc+Na.b.d+Na.Nc.d+b.Nc.d Using of „x“ fields as shown we get minimized function : Z=Na.Nc+ b.d

Literature Nripendra N. Biswas: Logic Design Theory,Prentice Hall International,1993,ISBN 0-13-010695-X