Lecture 3 Dr Richard Reilly Dept. of Electronic & Electrical Engineering Room 53, Engineering uilding oolean lgebra and Multi- oolean algebra George oole, little formal education yet was a brilliant scholar. Made lasting contribution to mathematics in the areas of differential and difference equations as well as algebra. He published in 854 his work n Investigation of the Laws of Thought, on which are founded the Mathematical Theories of Logic an Probability. oole s stated intention was a mathematical analysis of logic. oolean lgebra and Multi- oolean algebra like any other deductive mathematical system, may be defined with a set of elements, a set of operators, and a number of unproved axioms or postulates, i.e. it is a mathematical analysis of logic Why do we use oolean lgebra? We use oolean algebra due to its ability for mathematical analysis of logic to study digital systems. oolean lgebra and Multi- In oolean algebra a proposition is either true or false (no inbetween state possible), these proposition are denoted by letters (usually at start of the alphabet) e.g.. The grass is green TRUE. 3 is an even number FLSE We can combine these propositions to get oolean Functions denoted by letters (from the end of the alphabet). e.g. Z = ND FLSE oolean lgebra and Multi- There are several advantages for having a mathematical method for description of the internal workings of a computer more convenient to calculate using expressions that represent switching circuits then it is to use schematic or even logical expressions just as an ordinary algebraic expression may be simplified by means of basic theorems, the expression describing a given switching circuit network may be reduced or simplified. oolean lgebra and Multi- enabling the designer to simplify the circuitry used achieving economy of construction and reliability of operation oolean algebra also provides an economical and straightforward way of describing the circuitry used in computers. Title goes here
Fundamental oncepts of oolean lgebra When a variable is used in an algebraic formula, it is generally assumed that the variable may take on any numerical value. assume x,y and z range 2x 5y = z through the entire field of real numbers However a variable in oolean equations has a unique characteristic. it may assume only one of two possible states these states can be represented by the symbols and. i.e. T or F Fundamental oncepts of oolean lgebra This concept becomes clearer once the + symbol is defined. Since each of the two variables, x and y can take on only the value of or we define the + symbol by listing all possible combinations for x and y and x+y Fundamental oncepts of oolean lgebra The input/output combinations are as follows : += += += += This is the LOGIL DDITION table This is logical addition. The symbol + does not have the normal meaning it is a logical addition of logical OR symbol. Fundamental oncepts of oolean lgebra nother important operation in oolean lgebra is logical multiplication or logical ND operation. This rules of this operation can be given by simply listing all the values that might occur.=.=.=.= This is the LOGIL MULTIPLITION table Fundamental oncepts of oolean lgebra oth + and. obey a mathematical rule called the associative law. i.e. ( x + y) + z = x + ( y + z) we can write without ambiguity. No matter what order the operation is performed Fundamental oncepts of oolean lgebra It is necessary to know both the terms : logical addition and OR operations for the symbol + and logical multiplication and ND operation for the. symbol. E : The two operations cannot be mixed without ambiguity in the absence of further rules i.e.. + = (. ) +. ( + ) Since all these terms are actually used in computer architecture manuals, technical journals trade magazines. Title goes here 2
oolean Operations : ND,OR and The + and. operations are physically realised by two types of electronic circuits called OR gates and ND gates. treat them simply as block boxes. Gate is simply an electronic circuit that operates on one or more input signals to produce an output signal. oolean Operations : ND,OR and oolean algebra uses the operation called complementation and the symbol of this is means take the complement of ( + ) means take the complement of + The complement operation can be defined quite simply as oolean Operations : ND,OR and s we have seen the complementation operation is physically realised by a gate or circuit called an inverter. omplement of oolean Operations : ND,OR and Examples of oolean Functions Z = + Y = + D + OR ND Logical Sum, True if either OR true Logical Product, True if both ND true To study a logical expression, it is very useful to construct a table of values for the variables. then evaluate the expression for each possible combination of variables. oolean Operations : ND,OR and oolean Operations : ND,OR and e.g. + Title goes here 3
oolean Operations : ND,OR and oolean Operations : ND,OR and Finally ORing or Logical ddition + Rules of oolean lgebra We represent FLSE with and TRUE with. If we have a large number of propositions and a complicated oolean function we may be able to simplify it using the concept of tautology (redundancy). e.g. Z = + Z = + Z = always TRUE always TRUE always FLSE We can use the complete set of rules of oolean lgebra to simplify expressions.. 2. 3. 4. 5. 6. 7. 8. 9. =. ommutative Laws + = + =. ( ) ( ) + + = + + = + + 2. ssociative Laws ( ) = ( ) = 3. 4. ( + ) = + Distributive Law 5. 6. 7. + = + = + = + = = = = = + = ( + ) = + = + 8. + + = + 9. De Morgan s Laws ( + ) = 2 ( ) = + ( + Rules of oolean lgebra 2. ( ) = + ) ( + + + + + + + = + + = ( ( + ) ) = + ( + ) = + + ( + ) + = = + We can extend De Morgan s Laws to... = + + +... + + +... =... Example of the pplication of the Rules Z = + + Rule 4 Rule 4 = + ( + ) + = + + + = + ( + ) + ( + ) Rule 5 truth table for each expression will verify that both are equivalent Title goes here 4
Specific Design Problem Specific Design Problem logical network has two inputs, and and output. put this into a truth table. The relationship between the inputs and outputs is as follows : When and are s is to be When is and is is to be When is and is is to be When and are s is to be Specific Design Problem Specific Design Problem Now add a new column for the product terms : will contain each of the input variables for each row, with the letter complemented when input value for the variable is and not complemented when the input value is. Product Terms When the product term is equal to product term is removed and used as a sum-of - products expansion in this case st, 2 nd and 4 th rows are selected. = + + Specific Design Problem Specific Design Problem simplify Rule 4 ( ) = + + heck using the Truth-Table : + Rule 8 = + Rule : + = = = + Implementation : Title goes here 5
Interconnecting Gates OR gates, ND gates etc. can be interconnected to form gating or logic networks. These are also called combinational networks. The oolean lgebra expression corresponding to a given gating network can be derived by systematically progressing from input to output of the gates. Interconnecting Gates We can analyse the operation of these gating networks by using the oolean lgebra expressions. e.g. in trouble-shooting a computer can determine which gates have failed by examining the inputs to the gating network and the outputs Thus we can see whether the oolean expression are properly performed. Sum of Products and Product of Sums ertain types of oolean algebra expressions lead to gating networks that are more desirable from most implementation viewpoints. an define two types of oolean expression: Sum of Products and Product of Sums Sum Term sum term is a single variable or logical sum of several variables. The variables may or may not be complemented e.g. + + is a sum term Product Term product term is a single variable or logical product of several variables. The variables may or may not be complemented e.g. is a product term UT + term. is neither a product term nor a sum Sum of Products and Product of Sums We can now define two very important types of expressions : Sum of Product Expressions is a product term or several product terms logically added. e.g. + Product of Sums Expressions Sum of Products and Product of Sums What is that main advantage? The main reason as we saw earlier, is that we convert them in a straightforward way to simple gating networks Þ Their purest form is represented by two- networks i.e. networks whose longest path from input to output is two gates. is a sum term or several sum terms logically multiplied. e.g. + + ( ) ( ) Title goes here 6
Derivation of Product of Sums Expression Derivation of Product of Sums Expression We have seen earlier the sequence of steps for deriving a SOP expression for a given circuit. e.g. nother method, a dual of the first, forms the required expression as a POS. Method:. onstruct a table of the input and output values 2. onstruct an additional column of sum terms if the input term for a given variable is variable will be complemented but if the input term for a given variable is variable not complemented 3. The desired expression is the product of the sum terms from the rows in which the output is. Derivation of Product of Sums Expression Derivation of Product of Sums Expression Sum Terms POS expression is formed only from 2 nd and 3 rd rows (as output is ) + + + + = ( + )( + ) = + = + + + + NND and NOR Implementations ND s and OR s and s have been used up to this point. Why not continue Why bother with NND s or NOR s use DeMorgan s Rules : NND and NOR Implementations = + The main reason is that the Silicon rea on an I is very valuable. Thus we must make optimised use of it. NND can be made to yield ND and OR gates an ND gate can be formed from 2 NND gates and 2-input OR can be formed from 3 NND gates + + + + Thus a set of NND s can thus be used to make any combinational network by substituting the above for ND and OR blocks Title goes here 7
NND and NOR Implementations Thus the combination of this substituting ability of NND s, make the design of the I have all the same type of gates. Thus manufacture is made simpler. Same applies for NOR s. + ombinational Logic We have already seen the basic digital logic gates :, ND, OR, NND and NOR. One we have not yet seen is the Exclusive OR. Exclusive OR gate Symbol Function Truth-Table Denote thus defined : = + ombinational Logic We can implement an exclusive-or gate directly as follows : + n alternative form of the Exclusive OR-Gate is ( ) + = = + = + ( + ) = This implementation requires 4 NND gates. Such a single gate type solution is elegant and cost effective. Title goes here 8