S 701 oolean lgebra Mahna hmadi Oct. 14 2004 McMaster Universit References J. Eldon whitesitt oolean lgebra and its pplications Ralph P. Grimaldi Discrete and ombinational Mathematics Kenneth H.Rosen Discrete Mathematics and its pplications 1
2 oolean algebra Let be a nonempt set that contains two special elements 0 and 1 and on which we define closed binar operations. and a unar operation 01. is called a oolean algebra if the following aioms are satisfied for all Identit laws 1 0 Inverse laws 0 1 ommutative laws Distributive laws... ssociative laws....
From the aioms above we can derive the following theorems Idempotent Laws bsorption Laws Dominance Laws Demorgan s Laws Law of the Double omplement. 1 1.0 0.. The principle of Dualit n algebraic equalit derived from the aioms of oolean algebra remains true when the operators. and are interchanged and the identit elements 0 and 1 are interchanged. This propert is called the dualit principle. For eample: 11. 0 0 Dual ecause of the dualit principle for an given theorem we get it's dual for free. 3
4 n application of oolean algebra onsider an set X and let X P stands for the collection of all possible subsets of the set X. The power set of the set X. φ X X P ontains two special elements φ corresponding to 0 in oolean algebra and X orresponding to 1 in oolean algebra and closed binar operations and a unar operation is an instance of oolean algebra since the following aioms are satisfied for all X P. Identit laws X φ Inverse laws φ X ommutative laws Distributive laws ssociative laws
Logic Gates In 1938 laude Shannon showed how the basic rules of logic first given b Geoge ool in 1854 in his The Laws of Thought could be used to design circuits. oolean algebra is used to design and simplif circuits of electronic devices. Each input and output can be thought as a member of the set { 01}. The basic elements of circuits are called gates. Each tpe of gate implements a oolean operation. Inverter OR ND Inverter produces the complement of an input oolean variable as its output OR which produces the oolean sum of two or more oolean variables ND which produces the oolean products of two or more oolean variables 5
Each circuit can be designed using the rules of oolean algebra For eample: 1 circuit for Majorit Voting: 2 The Half dder: arr 6
Minimiation of ircuits oolean algebra finds its most practical use in the simplification of logic circuits. To do this: Translate a logic circuit's function into smbolic oolean form ppl certain algebraic rules to the resulting equation to reduce the number of terms and/or arithmetic operations The simplified equivalent function with fewer components will: 1 Increase efficienc and reliabilit 2 Decrease cost of manufacture. There are several was to reduce the number of terms in a oolean epression representing a circuit such as: 1 Rules of oolean algebra 2 Karnaugh Maps 3 The Quine-Mcluske Method 7
1 Rules of oolean algebra bsorption Laws 1 Identit Law 1 Distributive Law of. Over 1 Dominance Law and ommutative Law of Identit Law 8
2 Karnaugh Maps Karnaugh map is a graphical method to reduce the number of terms which was introduced b Maurice Karnaugh in 1953. This method is usuall applied onl when the function involves si or fewer variable. Karnaugh map uses the sum-of-products d.n.f epansion of a circuit to find a set of logic gates that implement circuits and to find terms to combine. Terms in a sum-of products epansion that differ in just one variable can be combined so that in one term this variable occurs and in the other term the complement of this variable occurs. 1 is placed in the square representing a minterm if this minterm is present in the epansion. The goal is to identif the largest blocks of 1s in the map and to cover all the 1s using the fewest blocks needed using the largest blocks first. 9
Suppose a oolean function in four variables is: w w w w w w w Karnaugh map in four variables is a square that is divided into 16 squares that means there are 16 possible minters in the sum-of-products epansion of a oolean function in the four variables w w w w w The minimal epansion is: w 10
3 The Quine-Mcluske Method It was developed in the 1950s b W.V.Quine and E.J.Mcluske. The Quine-Mcluske Method is procedure for simplifing sum of products epansions that can be mechanied. It can be used for oolean function in an number of variables. The Quine-Mcluske method consists of two parts. 1 Finds those terms that are candidates for inclusion in a minimal epansion as a oolean sum of oolean products 2 Determines which of these terms to actuall use Represent the minterms in the epansion b bit strings. The first bit will be 1 if occurs and 0 if occurs. The second and third bit as the same represent for and. Minterms that can be combined are those that differ in eactl one literal. Hence two terms that can be combined differ b eactl one in the number of 1s in the bit strings that represent them. product in two literals is represented using a dash to denote the variable that doesn t occur. 11
Find a minimal epansion equivalent to: Step1 Step2 Term it String Term String Term String 1 111 2 101 3 011 4 001 5 000 12 1-1 13-11 24-01 34 0-1 45 00-1234 --1 X X X X X X The minimal epansion is: 12