Exam 1

KETTERING UNIVERSITY
Department of Science and Mathematics
CS-211 Spring 2004
Exam 1 NAME
100 Points
e,
This is a closed book exam.
Answer all questions in the spaces provided on these sheets.
Partial credit will be given, so show your work!
CS211-Exam1
2
1. [12pts] Provide counterexamples to disprove each of the following assertions:
)
t
Af
a) Au(BnC)=(AuB)nC
b) (Au BY = A' U Be.
c) (A \ BY = (B \ A) c , for all sets A, and B.
d) A (B u C) = (A\ B) U C, for all sets A, B, and C.
A
i-//c2 ,,
A '
N,
---
f).--3
1 :14
6
2. [10pts] Prove that if A U B = C and A n B = 0, then B = C\A.
(-F A' 6 A ,/fu 6 -: ( ) x
"
37
or)] ,t/ 6C_
4 <,-- 4
Xd
().-47•JA
44 /A
4,4
(._ , s
-c) (1
)( e-
,c
c,\
-
A
c_,\ if-
X
b
I
A'
0
3
CS211-Examl
vL si vi,(xe,s , A4- A) --7) ,q 5 v 6-4
3. [10pts] Prove the following proposition: If A C S, then S \ (S \ A) = A.
2d-i x
Al
)7(
4c
0\4
Gt c,J.
77,,,
c \A
sec
A
Std
od-, c1
cs
S
EA
S \CN•14-
s
4) -
4. [18pts] For any set S, define the function (p : p(S)
p(S) by (i.o(A) = S A.
a) For S = {1, 2, 3}, what is its power set, p(S)?
b) For S = {1, 2, 3}, what is (p({l, 2, 3}), (p(0), (p({ll), and yo({2,3})?
c) Prove that (p -1 = o, i.e. (p is its own inverse. (Hint: Problem 3 may be helpful in
this proof.)
4
CS211-Examl
5. [lOpts] The Pierce Arrow is the logical connective defined by the truth table:
r
U
U
p
ptq
0
0
0
1
1
1
1
0
0
0
0
1
e
-----6--
'
(
6
0
0
I
1
0
0
(The Pierce Arrow is more commonly referred to as the NOR connective, i.e., the NOT
OR.)
ogically equivalent to the
a) Derive a propositio using only the Pierce Arrow that
rect.
proposition –p and
b) Derive a prop io • using only the Pierce Ar ow that is logically equivalent to the
erivation is correct.
proposit . p A and prove t
P
0 0
0/ l
/./t
0
1 d
1
l
0
6
C3 O /
C)
CS211-Exam1
5
6. [lOpts] Give a formal proof, supplying explanations for each step, for the following assertion:
SA(p—*(qVr))A(q---). ․ )A(r-4 —113)
e TS
ve,
Vr
,
t
i6C \/—
I
) (‘
P
6
CS211 -Exam 1
7. [lOpts] Three students A, B and C are believed to have cheated on an examination.
When they are questioned by the teacher, they testify as follows:
A: "B copied and C is innocent."
B: "If A is quilty, then so is C."
C: "I am innocent."
Now, answer the following: (JUSTIFY your answer.)
a) Express each student's statement using simple propositions and logical connectives.
A.
6A
b) If A spoke the truth and B lied, who is innocent and who copied?
C
1/3 L4 : 1 1-y
A
V
(t.
c) If everyone is innocent, who told the truth and who lied?
A
c -Lu
1,4\
d) If C lied and B spoke the truth, who is quilty?
,-c
11 6,..L
3 LA, 1 ity
de_
7
CS211-Exam1
8. [20pts] Let f : 113, -f IR, be defined by
f(x)
a) Prove that
f
is 1-1.
b) Prove f is onto.
2( X 2 -
1)/(X - 1) x
x =
1
1