Notes and Exercises on Boolean Algebra by uws18949

VIEWS: 59 PAGES: 4

									     Notes and Exercises on Boolean Algebra
                                Dr. Holmes
                              June 12, 2006


1     Boolean Expressions from Truth Tables
From the truth table for any operation on truth values we can read out an
expression for that operation using ∧, ∨, ¬.
   For example,

                                x   y       z
                                T   T       T   F
                                T   T       F   T
                                T   F       T   F
                                T   F       F   F
                                F   T       T   T
                                F   T       F   T
                                F   F       T   F
                                F   F       F   T
    can be expressed as


       (x ∧ y ∧ ¬z) ∨ (¬x ∧ y ∧ z) ∨ (¬x ∧ y ∧ ¬z) ∨ (¬x ∧ ¬y ∧ ¬z)

    This expression is a disjunction (or-sentence) of conjunctions (and-sentences)
each of which is a conjunction of letters and negations of letters representing
a row of the truth table.
    If there are no rows in the truth table which are true, the expression
x ∧ ¬x will represent it.
    It should be clear that this will work for truth tables for expressions with
any number of letters.

                                        1
   Exercise:
   Write out an expression in ∨, ∧, ¬ for the operation on three propositions
represented by this truth table:

                                x   y       z
                                T   T       T   T
                                T   T       F   F
                                T   F       T   T
                                T   F       F   T
                                F   T       T   F
                                F   T       F   T
                                F   F       T   T
                                F   F       F   F
    Exercise: Construct a truth table for the operation represented by (x →
y) ∧ (y → z) then derive an equivalent expression in ∨, ∧, ¬ from the truth
table.


2    Algebraic Notation
An expression in ∨, ∧, ¬ can be written in an algebraic style.
    Write x ∧ y as xy, x ∨ y as x + y, and ¬x as x. Negations of complicated
expressions like ¬(x + y) will not be written using overlines. Write T as 1
and F as 0 in algebraic notation.
    A selection of the algebra rules we saw in section 6 can be used to reduce
any expression to a form like the ones we derived from truth tables.
    An expression is said to be in disjunctive normal form just in case it is a
disjunction of conjunctions of single letters and negations of single letters.
    The expressions derived from truth tables have the additional character-
istic that every conjunction contains each letter or its negation just once.
    The following rules will help us to reduce expressions to disjunctive nor-
mal form:

Distributive laws: x(y + z) = xy + xz and (x + y)z = xz + yz. Use these
     to eliminate conjunctions involving disjunctions.

deMorgan’s laws: ¬(xy) = (x) + y; ¬(x + y) = xy



                                        2
    Applying these rules repeatedly will convert any expression into a dis-
junction of conjunctions of letters and their negations (or into a conjunction
of letters and their negations, or into a single letter or the negation of a single
letter).
    If any conjunction includes a letter x and also includes x, it can be written
xxy (where y may be a complicated expression) which will simplify to 0
(false).
    We have a rule xx = 0; now show 0y = 0 to finish the demonstration.
0y = yyy = yy (here the rule yy = y is used)= 0. Now 0 can be eliminated
as a term in a disjunction because we have a rule 0 + x = x already.
    Applying these rules can give one more possible expression as a final form
(which we accept as DNF): 0.
    Of course any repeated expression in a disjunction or conjunction can be
eliminated using idempotent laws xx = x + x = x.
    Example: convert (x ∨ y ∨ ¬z) ∧ ¬(x ∧ y) to DNF.
    In algebraic notation, this is (x + y + z)(¬(xy)) = (x + y + z)(x + y) =
xx + xy + yx + yy + zx + zy (here I used the distributive law repeatedly just
as in ordinary algebra, not writing every step) = 0 + xy + yx + 0 + zx + zy =
xy + yx + zx + zy.
    Exercise: Convert (x ∨ ¬y ∨ z) ∧ ¬(x ∧ y) to DNF.


3     Other Rules
We can turn a DNF expression into an expression like those derived from
truth tables by making sure that all the conjunctions contain the same letters.
To add a letter (say y) to a conjunction (represented by x) use the rule
x = xy + xy, justified by the proof x = x1 = x(y + y) = xy + xy.
   Exercise: Try converting the expressions from the previous example and
exercise into forms from which truth tables can be read.
   I give the proofs of the Absorption Laws from the class example, though
you will not be asked to use these.
   First Absorption Law: x + xy = x
   Proof: x = xy + xy = (xy + xy) + xy = xy + (xy + xy) = xy + x = x + xy
   Exercise: Justify each step in this proof (using algebraic rules from the
book or from this document).
   Second Absorption Law: x + xy = x + y



                                        3
   Proof: x + y = (xy + xy) + (xy + xy) = xy + xy) + xy (eliminate repeated
xy) = x + xy
   Exercise: Justify each step in this proof (using algebraic rules from the
book or from this document).




                                     4

								
To top