CS 281 Solutions to Test II



July 23, 1999



1. Find the powerset of each of the following sets: [9]



(a) {1}



{$\emptyset$ , {1} }



(b) {$\emptyset$ , {$\emptyset$ }}



{ $\emptyset$, {$\emptyset$}, { {$\emptyset$ } }, {$\emptyset$ , {$\emptyset$ }} }



(c) $\emptyset$



{ $\emptyset$ }



2. Find the following Cartesian products: [9]



(a) { $ \emptyset , \{ \emptyset \} \} \times \{ \emptyset \}$



{ $<\emptyset, \emptyset>, <\{ \emptyset \}, \emptyset>$ }



(b) { $ \emptyset \} \times \{ 1,2 \} \times \{ 3,4 \} $



{ $<\emptyset, 1, 3>, <\emptyset, 1, 4>, <\emptyset, 2, 3>, <\emptyset, 2, 4>$ }



(c) $\emptyset \times \{ \{ \emptyset \}, \emptyset \}$



$\emptyset$



3. Indicate which of the following are true and which are false. [15]



(a) $\emptyset \in \{ x \}$ False
(b) $\{x \} \subseteq \{\{x \}\}$ False
(c) $\{ x \} \in \{\{x \}\}$ True
(d) { $x\} \in \{ x\}$ False
(e) $\emptyset \subseteq \{ x \}$ True



4. Find the smallest four elements of the set S defined recursively as follows: [8]



Basis Clause: $ 1 \in S$
Inductive Clause: If $x \in S$, then $3x + 1 \in S$.
Extremal clause: Nothing is in S unless it is obtained from the above two clauses.



1, 4, 13, 40



5. Recursively define each of the following sets:



(a) The set of non-negative integers that produce remainder 1 when divided by 5. [10]



Let F be the set to be defined.
Basis Clause: $1 \in F$
Inductive Clause: If $x \in F$, then $x + 5 \in F$.
Extremal Clause: Nothing is in F unless it is obtained by the Basis and Inductive Clauses.



(b) { $3^{n} - 1 \mid n$ is a natural number.} [12]



Let T be the set to be defined.
Basis Clause: $0 \in T$
Inductive Clause: If $x \in T$, then $3x + 2 \in T$.
Extremal Clause: Nothing is in T unless it is obtained by the Basis and Inductive Clauses.



6. Prove the following statements on sets A and B.



(a) $A \cap B \subseteq A \cup B$ [10]



Since $A \subseteq A \cup B$ and $B \subseteq A \cup B$, by applying formula # 7 on properties of set operations ( If $A \subseteq B$ and $C \subseteq D $, then $A \cap C \subseteq B \cap D$ ), $A \cap B \subseteq ( A \cup B ) \cap ( A \cup B )$. But $ ( A \cup B ) \cap ( A \cup B )
= A \cup B$. Hence $A \cap B \subseteq A \cup B$.



(b) If $(A - B) = \emptyset$, then $A \subseteq B$. [13]



Since $(A - B) = \emptyset$, for an arbitrary x, $ \neg x \in A - B$. Hence $\neg x \in A$or $x \in B$. From this, if $x \in A$, then by disjunctive syllogism $x \in B$. Hence for an arbitrary x if $x \in A$, then $x \in B$. Hence $A \subseteq B$.

7. Which rules of inference are used to establish the conclusion of the following argument ? [14]



Premises:
"All lions are fierce."
"Some lions do climb trees."



Conclusion:
"There are fierce creatures that climb trees."



Give your answer using L(x), C(x) and F(x) to denote "x is a lion", "x climbs trees" and "x is fierce", respectively, and assuming the universe is the set of all creatures. Using these symbols, the statements given above can be expressed as follows:



$\forall x [L(x) \rightarrow F(x) ]$
$\exists x [L(x) \wedge \neg C(x) ]$
---------------------
$\exists x [F(x) \wedge \neg C(x) ]$



Answer:



(1) $\forall x [L(x) \rightarrow F(x) ]$ : premise
(2) $\exists x [L(x) \wedge \neg C(x) ]$ : premise
(3) $L(c) \wedge \neg C(c)$ for some creature c : Existential Instantiation on (2)
(4) L(c) : Simplification on (3)
(5) $\neg C(c)$ : Simplification on (3)
(6) $[L(c) \rightarrow F(c) ]$ : Universal Instantiation on (1)
(7) F(c) : Modus Ponens on ((4) and (6)
(8) $F(c) \wedge \neg C(c)$ : Conjunction on (5) and (7)
(9) $\exists x [F(x) \wedge \neg C(x) ]$ : Existential Generalization on (8)



------------------------------------------------




You may use the following table.



Logical Equivalences and Implications -- Omitted.



Additional Inference Rule: Conjunction



P
Q
------------------
P $\wedge$ Q



 

S. Toida
1999-07-27