You are on page 1of 4

Section 1.6 Boolean algebra provides a framework for reasoning logically about statements.

In Boolean algebra, variables represent the values TRUE and FALSE (So, the variables in a Boolean expression can take on only 2 values.) Operations we perform on the values TRUE and FALSE include: , , , , . Boolean Algebra can be thought of as arithmetic of the values TRUE and FALSE. (1) Symbol: Truth table: x T T F F y T F T F x y T F F F English Equivalent: or English Equivalent: and

(2) Symbol: Truth table: x T T F F y T F T F x y T T T F

(3) Symbol: Truth table: x T F x F T

English Equivalent: not

(4) Symbol: Truth table: x T T F F y T F T F xy T F T T

English Equivalent: x y means if x, then y

(5) Symbol: Truth table: x T T F F y T F T F xy T F F T

English Equivalent: x y means x if and only if y

NOTE: Most mathematical theorems can be written as if-then statements. For example, we could re-write the statement: A positive integer that ends in 4 is divisible by 2. Written as an if-then statement: If a positive integer ends in 4, then it is divisible by 2. This if-then statement is a true statement. No matter which positive integer we choose that ends in 4, it is divisible by 2. However, consider the converse: If a positive integer is divisible by 2, then it ends in 4. Is the converse true? No. Consider the number 12. The number 12 is divisible by 2, but it does not end in 4. Thus, this if-then statement is false. However, in a case where the converse of a true if-then statement is true, we have a (true) if and only if statement. Consider: A number is prime if and only if it is divisible only by 1 and itself. We can think of this as two if-then statements (both of which are true): If a number is prime, then it is divisible only by 1 and itself. If a number is divisible only by 1 and itself, then it is prime. (Here we can also have a conversation about vacuous truth i.e. If you hold a guinea pig by the tail, then its eyes will pop out. This is vacuously true, since guinea pigs have no tails. It may also help here, if there is confusion, to talk about the logical equivalence of x y and x y.) Question: Does the order of operations matter? Yes. Example: Do the following calculations on the values: (a) (TRUE) TRUE = TRUE (b) (TRUE TRUE) = FALSE

The only dierence between (a) and (b) above is the placement of the parentheses. Order DOES matter. Proof of logical equivalence using truth tables: To show that two Boolean expressions are logically equivalent: Make truth tables including all possible values of the variables. If the Boolean expressions (the nal columns of each truth table) have the same values, then the the expressions are logically equivalent. Example: Prove x y is logically equivalent to y x (this is called the contrapositive).

Make truth tables for each expression: x y xy T T T T F F F T T F F T x y x y y x T T F F T T F F T F F T T F T F F T T T Thus, since the nal columns are the same for each expression, the expressions evaluate to the same truth values for all of the possible values of the variables. Therefore, x y is logically equivalent to y x. The following summarizes the basic properties of operations , , and : (Theorem 6.2 in book): (a) x y = y x and x y = y x. (Commutative properties) (b) (x y) z = x (y z) and (x y) z = x (y z). (Associative properties) (c) x TRUE = x and x FALSE = x. (Identity elements. *Recall that x takes on the values TRUE and FALSE). (d) (x) = x (e) x x = x and x x = x. (f) x (y z) = (x y) (x z) and x (y z) = (x y) (x z). (Distributive properties) (g) x (x) = FALSE and x (x) = TRUE. (h) (x y) = (x) (y) and (x y) = (x) (y). (DeMorgans Laws) Example (2) Prove the distributive property: x (y z) = (x y) (x z). x T T T T F F F F x T T T T F F F F y T T F F T T F F y T T F F T T F F z T F T F T F T F z T F T F T F T F y z T T T F T T T F x y T T F F F F F F x (y z) T T T F F F F F x z (x y) (x z) T T F T T T F F F F F F F F F F

Again, the nal columns match. So, the two expressions have the same values for each of the possible values of x, y, and z. Thus, the expressions are logically equivalent.

Example (3) Prove that x y is logically equivalent to (x y) ((x) (y)) (Use truth tables) Question: How would you disprove a logical equivalence? Find values (TRUE or FALSE) for x and y that result in dierent values for the expressions. Example: Show that x y is not logically equivalent to y x. Proof: Suppose x is FALSE and y is TRUE. Then, x y is TRUE, but y x is FALSE. Since we have two dierent values for the expressions, the rst expression is not equivalent to the second. Note: This shows that an if-then statement is not equivalent to its converse. A tautology is a Boolean expression that evaluates to TRUE for all possible values of its variables. Prove that the following is a tautology: (x y) (x y). (Show that the nal column in the truth table has all TRUE.)

You might also like