Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Алгебра_1 / Gilbert - Modern algebra with applications.pdf
Скачиваний:
34
Добавлен:
23.02.2015
Размер:
2.55 Mб
Скачать

NUMBER OF ELEMENTS IN A SET

11

A

B

 

C

A ∆ (B C) = (A B) ∆ C

Figure 2.4.

A

B

 

C

A B

C

A ∩ (B C) = (A B) ∆ (A C)

Venn diagrams.

A

B

 

C

A (B C)

(A B) ∆ (A C)

Figure 2.5. Venn diagrams of unequal expressions.

Hence

A (B C) = {A (B C)} {A (B C)}

={A [(B C) (B C)]} {A [(B C) (B C)]}

=(A B C) (A B C) (A B C) (A B C)).

This expression is symmetric in A, B, and C, so (ii) gives

A (B C) = C (A B) = (A B) C.

We leave the proof of the other parts to the reader. Parts (i) and (vii) are illustrated in Figure 2.4.

Relation (vii) of Proposition 2.3 is a distributive law and states that is distributive over . It is natural to ask whether is distributive over .

Example 2.4. Is it true that A (B C) = (A B) (A C) for all A, B, C P (X)?

Solution. The Venn diagrams for each side of the equation are given in

Figure 2.5. If the shaded areas are not the same,

we will be able to find a

counter example. We see from the diagrams

that

the result will be false if

A is nonempty. If A = X and B = C = Ø,

then A (B C) = A, whereas

(A B) (A C) = Ø; thus union is not distributive over symmetric difference.

NUMBER OF ELEMENTS IN A SET

If a set X contains two or three elements, we have seen that P (X) contains 22 or 23 elements, respectively. This suggests the following general result on the number of subsets of a finite set.

12

2 BOOLEAN ALGEBRAS

Theorem 2.5. If X is a finite

set with n elements, then P (X) contains 2n

elements.

 

Proof. Each of the n elements of X is either in a given subset A or not in A. Hence, in choosing a subset of X, we have two choices for each element, and these choices are independent. Therefore, the number of choices is 2n, and this

is the number of subsets of X.

 

If n = 0, then X = Ø and P (X) = {Ø}, which contains one element.

Denote the number of elements of a set X by |X|. If A and B are finite disjoint sets (that is, A B = Ø), then

|A B| = |A| + |B|.

Proposition 2.6. For any two finite sets A and B,

|A B| = |A| + |B| − |A B|.

Proof. We can express A B as the disjoint union of A and B A; also, B can be expressed as the disjoint union of B A and A B as shown in Figure 2.6. Hence |A B| = |A| + |B A| and |B| = |B A| + |A B|. It fol-

lows that |A B| = |A| + |B| − |A B|.

 

Proposition 2.7. For any three finite sets A, B, and C,

 

|A B C| = |A| + |B| + |C| − |A B| − |A C|

 

− |B C| + |A B C|.

 

Proof. Write A B C as (A B) C. Then, by Proposition 2.6,

 

|A B C| = |A B| + |C| − |(A B) C|

 

= |A| + |B| − |A B| + |C| − |(A C) (B C)|

 

= |A| + |B| + |C| − |A B| − |A C| − |B C|

 

+ |(A C) (B C)|.

 

The result follows because (A C) (B C) = A B C.

 

A

B A

A B B A

Figure 2.6

BOOLEAN ALGEBRAS

 

13

C

 

B

520

110

60

20

200 10

120 W

Figure 2.7. Different classes of commuters.

Example 2.8. A survey of 1000 commuters reported that 850 sometimes used a car, 200 a bicycle, and 350 walked, whereas 130 used a car and a bicycle, 220 used a car and walked, 30 used a bicycle and walked, and 20 used all three. Are these figures consistent?

Solution. Let C, B, and W be the sets of commuters who sometimes used a car, a bicycle, and walked, respectively. Then

|C B W | = |C| + |B| + |W | − |C B| − |C W |

|B W | + |C B W |

=850 + 200 + 350 130 220 30 + 20

=1040.

Since this number is greater than 1000, the figures must be inconsistent. The

breakdown

of the reported figures into their various classes is illustrated in

Figure 2.7.

The sum of all these numbers is 1040.

 

Example 2.9. If 47% of the people in a community voted in a local election and 75% voted in a federal election, what is the least percentage that voted in both?

Solution. Let L and F be the sets of people who voted in the local and federal elections, respectively. If n is the total number of voters in the community, then |L| + |F | − |L F | = |L F | n. It follows that

|L F | |L| + |F | − n =

47

+

75

1

n =

22

n.

100

100

100

Hence at least 22% voted in both elections.

 

 

 

 

 

 

BOOLEAN ALGEBRAS

We now give the definition of an abstract boolean algebra in terms of a set with two binary operations and one unary operation on it. We show that various algebraic structures, such as the algebra of sets, the logic of propositions, and

14

2 BOOLEAN ALGEBRAS

the algebra of switching circuits are all boolean algebras. It then follows that any general result derived from the axioms will hold in all our examples of boolean algebras.

It should be noted that this axiom system is only one of many equivalent ways of defining a boolean algebra. Another common way is to define a boolean algebra as a lattice satisfying certain properties (see the section “Posets and Lattices”).

A boolean algebra (K, , , ) is a set K together with two binary operationsand , and a unary operation on K satisfying the following axioms for all

A, B, C K:

(i) A (B C) = (A B) C.

(ii) A (B C) = (A B) C.

(iii) A B = B A.

(associative laws)

(iv) A B = B A.

(v) A (B C)

(commutative laws)

(vi) A (B C)

= (A B) (A C).

= (A B) (A C).

 

(distributive laws)

(vii)There is a zero element 0 in K such that A 0 = A.

(viii)There is a unit element 1 in K such that A 1 = A.

(ix) A A = 0.

(x) A A = 1.

We call the operations and , meet and join, respectively. The element A is called the complement of A.

The associative axioms (i) and (ii) are redundant in the system above because with a little effort they can be deduced from the other axioms. However, since associativity is such an important property, we keep these properties as axioms.

It follows from Proposition 2.1 that (P (X), , , ) is a boolean algebra with Ø as zero and X as unit. When X = Ø, this boolean algebra of subsets contains one element, and this is both the zero and unit. It can be proved (see Exercise 2.17) that if the zero and unit elements are the same, the boolean algebra must have only one element.

We can define a two-element boolean algebra ({0, 1}, , , ) by means of Table 2.3.

Proposition 2.10. If the binary operation on the set K has an identity e such that a e = e a = a for all a K, then this identity is unique.

TABLE 2.3. Two-Element Boolean Algebra

A

B

A B

A B

 

A

A

0

0

0

0

0

1

0

1

0

1

1

0

1

0

0

1

 

 

 

 

 

 

1

1

1

1

 

 

 

 

 

 

 

 

 

 

BOOLEAN ALGEBRAS

15

Proof. Suppose that e and e are both identities. Then an identity, and e e = e since e is an identity. Hence must be unique.

e = e e , since e is

e = e , so the identity

Corollary 2.11. The zero and unit elements in a boolean algebra are unique.

Proof. This follows directly from the proposition above, because the zero and unit elements are the identities for the join and meet operations, respectively.

Proposition 2.12. The complement of an element in a boolean algebra is unique; that is, for each A K there is only one element A K satisfying axioms (ix) and (x): A A = 0 and A A = 1.

Proof. Suppose that B and C are both complements of A, so that A B = 0, A B = 1, A C = 0, and A C = 1. Then

B= B 0 = B (A C) = (B A) (B C)

= (A B) (B C) = 1 (B C) = B C.

Similarly, C = C B and so B = B C = C B = C.

 

If we interchange and and interchange 0 and 1 in the system of axioms for a boolean algebra, we obtain the same system. Therefore, if any proposition is derivable from the axioms, so is the proposition obtained by interchangingand and interchanging 0 and 1. This is called the duality principle. For example, in the following proposition, there are four pairs of dual statements. If one member of each pair can be proved, the other will follow directly from the duality principle.

If (K, , , ) is a boolean algebra with 0 as zero and 1 as unit, then (K, , , ) is also a boolean algebra with 1 as zero and 0 as unit.

Proposition 2.13. If A, B, and C are elements of a boolean algebra (K, , , ), the following relations hold:

(i) A 0 = 0.

(ii) A 1 = 1.

(iii) A (A B) = A.

(iv) A (A B) = A.

(v) A A = A.

(absorption laws)

(vi) A A = A. (idempotent laws)

(vii) (A B) = A B .

(viii) (A B) = A B .

(ix) (A ) = A.

(De Morgan’s laws)

 

Proof. Note first that relations (ii), (iv), (vi), and (viii) are the duals of relations (i), (iii), (v), and (vii), so we prove the last four, and relation (ix). We use the axioms for a boolean algebra several times.