Solutions for Problems in Mathematical Structures for Computer Science, 7th Edition – Gersting
Solutions for Problems in Mathematical Structures for Computer Science, 7th Edition – Gersting
com
sm WhatsApp: https://wa.me/message/2H3BV2L5TTSUF1 Telegram: https://t.me/solutionmanual
Contents
EXERCISES 6.4.............................................................................................................270
The sample tests (and their solutions), two per chapter, are also included in the Student
Solutions Manual.
A website for Mathematical Structures for Computer Science, Seventh Edition, may be
found at www.whfreeman.com/gersting. It functions as an online study guide, offering for
each chapter a chapter overview, section overviews, and sample problems with audio
commentaries outlining the step-by-step solution process. The sample problems (not
contained in the text) are representative of many of the end-of-section Techniques.
Each sample problem on the Web first states the problem. Then succeeding pages develop
the solution, much as the student would be expected to write it. As the student navigates
the pages, the solution unfolds step-by-step. A compressed audio file is also part of each
Web page after the initial problem statement. The audio file contains a first-person stream-
of-consciousness thought process about that step of the solution—why it occurred to the
narrator to try this, why it looked promising, what knowledge was being called upon to
suggest that this should come next, etc. The point is, students see perfect and complete
worked-out proofs in the textbook, and often see them performed by the instructor. Yet
when a student goes home and tries to produce such a solution alone, he or she is unsure
where to start or how to think about the problem or how to discern any pattern to enable a
guess as to what to do next. Consequently, the student gives up in frustration. The
purpose of the audio narration is to share the “secret picture” that mathematicians use to
solve problems.
PowerPoint slides accompanying each section of the text are also available on the website.
2
CHAPTER 1: Formal Logic
Chapter 1 is an introduction to formal logic and some of its implications for computer
science. Formal logic is nothing more than a systematization of much of what we do daily
when we communicate in natural language and when we draw conclusions using informal
reasoning. It is certainly the basis for scientific thinking and reasoning.
Because of its formalization, many students seem to find logic a difficult topic.
You can point out to the students, however, that this very formality actually relieves them
of the burden of undirected creative thinking! There are certain patterns and rules that
must be followed in constructing formal proofs, which serve to channel and limit the
possible steps to be taken at any time. Students face similar constraints in following the
rules of syntax of a programming language; in fact, they are so much more constrained in
formal logic that their task is even simpler than in programming. Pointing this out to the
students (who have usually experienced some success in programming tasks by this time)
can serve as a morale-builder. Or you can also note the similarities to standard high school
geometry, but you are on less firm ground here because some students hated their high
school geometry class! At any rate, they need some reassurance that symbolism itself is
not all that formidable and, by its constraining nature, is actually helpful. I usually point
out that one of the purposes of symbolism is to strip away meaning in order to concentrate
on form alone, and thus help ensure that we are “pure in heart” in our thinking processes.
Students find this a bemusing idea, but they generally see the point.
Of course, natural language statements must first be translated into symbolic form,
and it is this part of the chapter that is most fun to teach. It points up how sloppy we tend
to be in our natural language statements. (See “John loves only Mary,” “John only loves
Mary,” and “Only John loves Mary” in Section 1.3.) One would think that students for
whom English is a second language would have more difficulties than native English
speakers with this type of translation exercise, but that doesn’t seem to be the case—they
all have to work at this, but they also enjoy it. Students often come back later and tell me
that after this course, they never take words and sentences at face value again!
Propositional logic is covered in Sections 1.1 and 1.2, while predicate logic is
discussed in Sections 1.3 and 1.4. Sections 1.5 and 1.6 give some direct applications of
formal systems to computer science; Section 1.5 is a brief introduction to logic
programming, and Section 1.6 introduces proof of correctness.
The discrete structures course is too often seen as a collection of disjointed topics,
so it behooves us as instructors to emphasize the connecting threads whenever possible.
The notations of formal logic will be used throughout the book to clarify definitions.
Logical reasoning, although not always formal, is the basis for much of the rest of the work
in this course and will also stand the students in good stead in many other computer
science courses.
3
EXERCISES 1.1
l. (a), (c), (d), (e), (f). Note that (d), (e), and (f) each have a truth value, even
though we may not know at the moment whether that value is true or false. (b) and (g)
are not statements because of the unknown variables of “he” and “x”, respectively.
2. “8 is even,” and “6 is even” are true statements, while “8 is odd,”and “6 is odd” are
false statements. The results follow from the truth tables for conjunction, disjunction,
and implication.
a. T b. F c. F d. F e. T f. F g. T h. T
3. a. T b. T c. T d. F
7. a. A ∨ B
b. A' ∧ B' (You don’t have A, and you don’t have B.)
8. a. A→B
b. B→A
c. A→B
d. A↔B
9. a. 1 and 3 b. 2 c. 4
10. a. 2 b. 1 c. 3
11. a. The original statement is an implication that excellent service follows from good
food. The negation of this statement says that excellent service does not follow
from good food, so you can have good food and not have excellect service. The
negation would be
The food is good, but the service is poor.
There are many alternatives to the use of the word “but,” such as “and” or “also,”
but it seems that a sort of negative flavor would be appropriate, so other
alternatives to “but” could be “although” or “however.”
b. The original statement is a disjunction, so for its negation, think De Morgan's laws.
The food is poor and so is the service.
4
c. Either the food is poor or the service is poor, but the price is low.
d. Either the food is good or the service is excellent.
e. The price is high, but either the food is poor or the service is poor.
14. a. (A ∨ B) → C
b. C ∧ A' ∧ B'
c. (A → B) ∧ (B' → C)
d. B→A
e. A→B
15. a. A∧B
b. A ∧ (B ∨ C)
c. B → (A ∧ C)
d. A → (B' ∨ C')
e. A ∧ [C' → (B' ∨ C)]
16. a. B∧D
b. A∧D
c. D → (B ∨ C)
d. B’ ∧ A
e. D→C
5
18. a. If the hero is American, then the villain is not French.
b. The hero is American, the heroine is British, and the movie is not good.
c. If the hero is American, then either the heroine is British or the villain is French.
d. If the villain is French or the heroine is British, then the hero is not American.
e. The villain is French if and only if the hero is American or the heroine is British.
f. If the movie is bad, then it is not true that the villain is French or the heroine is
British.
g. If the heroine is British then the movie is good, and if the villain is French, then the
hero is not American.
b. A B C A ∧ B (A ∧ B) ∨ C B ∨ C A ∧ (B ∨ C) (A ∧ B) ∨ C → A ∧ (B ∨ C)
T T T T T T T T
T T F T T T T T
T F T F T T T T
T F F F F F F T
F T T F T T F F
F T F F F T F T
F F T F T T F F
F F F F F F F T
6
d. A B A' A ∧ B A ∧ B → A'
T T F T F
T F F F T
F T T F T
F F T F T
e. A B C A → B A ∨ C B ∨ C (A ∨ C) → (B ∨ C) (A → B) → [(A ∨ C) → (B ∨ C)]
T T T T T T T T
T T F T T T T T
T F T F T T T T
T F F F T F F T
F T T T T T T T
F T F T F T T T
F F T T T T T T
F F F T F F T T
Tautology
24. a. A B B → A A → (B →A)
T T T T
T F T T
F T F T
F F T T
Tautology
7
e. A B C A' C' B ∨ C' A' → (B ∨ C')
T T T F F T T
T T F F T T T
T F T F F F T
T F F F T T T
F T T T F T T
F T F T T T T
F F T T F F F
F F F T T T T
2a. A B C A ∨ B (A ∨ B) ∨ C B ∨ C A ∨ (B ∨ C) (A ∨ B) ∨ C ↔ A ∨ (B ∨ C)
T T T T T T T T
T T F T T T T T
T F T T T T T T
T F F T T F T T
F T T T T T T T
F T F T T T T T
F F T F T T T T
F F F F F F F T
2b. A B C A ∧ B (A ∧ B) ∧ C B ∧ C A ∧ (B ∧ C) (A ∧ B) ∧ C ↔ A ∧ (B ∧ C)
T T T T T T T T
T T F T F F F T
T F T F F F F T
T F F F F F F T
F T T F F T F T
F T F F F F F T
F F T F F F F T
F F F F F F F T
3a. A ∨ (B ∧ C) ↔
A B C B ∧ C A ∨ (B ∧ C) A ∨ B A ∨ C (A ∨ B) ∧ (A ∨ C) (A ∨ B) ∧ (A ∨ C)
T T T T T T T T T
T T F F T T T T T
T F T F T T T T T
T F F F T T T T T
F T T T T T T T T
F T F F F T F F T
F F T F F F T F T
F F F F F F F F T
8
3b. A ∧ (B ∨ C) ↔
A B C B ∨ C A ∧ (B ∨ C) A ∧ B A ∧ C (A ∧ B) ∨ (A ∧ C) (A ∧ B) ∨ (A ∧ C)
T T T T T T T T T
T T F T T T F T T
T F T T T F T T T
T F F F F F F F T
F T T T F F F F T
F T F T F F F F T
F F T T F F F F T
F F F F F F F F T
g. A A A∨ A A∨ A↔A
T T T T
F F F T
9
c. A ∨ (B ∧ A') ⇔ (A ∨ B) ∧ (A ∨ A') by 3a
⇔ (A ∨ B) ∧ 1 by 5a
⇔ A ∨ B by 4b
32. “oil paintings” AND (Van Gogh OR REMBRANDT) AND NOT Vermeer
37. The conditional expression has the form (A ∨ B)' ∨ (A' ∧ B).
(A ∨ B)' ∨ (A' ∧ B) ⇔ (A' ∧ B') ∨ (A' ∧ B) (De Morgan's Laws)
⇔ A' ∧ (B' ∨ B) (tautology 3b)
⇔ A' ∧ (B ∨ B') (tautology 1a)
⇔ A' ∧ 1 (tautology 5a)
⇔ A' (tautology 4b)
10
Therefore, the statement form can be written as
if not(Value1 < Value2) then
statement1
else
statement2
end if
38. By De Morgan's laws, not (A and B) is equivalent to not A or not B, so statement 1 will
be executed when, for example, A is false, B is true, and C is true. You need the
condition “not A and not B and C.”
41. a. Assign
B' ∧ (A → B) true
A' false
From the second assignment, A is true. From the first assignment, B' is true (so B
is false), and A → B is true. If A → B is true and A is true, then B is true. B is thus
both true and false, and [B' ∧ (A → B)] → A' is a tautology.
b. Assign
(A → B) ∧ A true
B false
From the first assignment, A is true and A → B is true. If A → B is true and A is
true, then B is true. B is thus both true and false, and [(A → B) ∧ A] → B is a
tautology.
c. Assign
(A ∨ B) ∧ A' true
B false
From the first assignment, A' is true (and A is false), and A ∨ B is true. If A ∨ B
is true and A is false, then B is true. B is thus both true and false, and
(A ∨ B) ∧ A' → B is a tautology.
42. a. Assign
(A ∧ B) ∧ B' true
A false
From the first assignment, A ∧ B is true. If A ∧ B is true, then A is true. A is thus
both true and false, and (A ∧ B) ∧ B' → A is a tautology.
11
b. Assign
(A ∧ B') true
(A → B)' false
From the first assignment, A is true and B' is true, so B is false. From the second
assignment, A → B is true and, because A is true, then B must be true. B is thus
both true and false, and (A ∧ B') → (A → B)' is a tautology.
c. Assign
(A ∧ B)' ∨ B' true
A' ∨ B' false
From the second assignment, A' and B' are both false, so A is true and B is true.
From the first assignment, because B' is false, (A ∧ B)' must be true. A ∧ B is
therefore false, so A is false and B is false. B is thus both true and false, and (A ∧
B)' ∨ B' → A' ∨ B' is a tautology.
5
43. 22 = 232
45. A B A⊕B
T T F
T F T
F T T
F F F
This makes sense because A ↔ B is true when A and B have the same truth values, so
(A ↔ B)' is true when A and B have different truth values. But this is exactly when
A ⊕ B is true.
47. a. A B A∨B A' B' A' ∧ B' (A' ∧ B')' A ∨ B ↔ (A' ∧ B')'
T T T F F F T T
T F T F T F T T
F T T T F F T T
F F F T T T F T
12
b. A B B' A ∧ B' (A ∧ B') ' A → B A → B ↔ (A ∧ B')'
T T F F T T T
T F T T F F T
F T F F T T T
F F T F T T T
A → B is equivalent to A' ∨ B
A B A → B A' A' ∨ B A → B ↔ A' ∨ B
T T T F T T
T F F F F T
F T T T T T
F F T T T T
A ∨ B is equivalent to A' → B
A B A ∨ B A' A' → B A ∨ B ↔ A' →B
T T T F T T
T F T F T T
F T T T T T
F F F T F T
50. (A ∧ B)' has the value F when A and B both have the value T. However, any statement
using only → and ∨ will have the value T when A and B are both T.
13
52. A ∧ B is equivalent to (A ↓ A) ↓ (B ↓ B)
A B A ∧ B A ↓ A B ↓ B (A ↓ A) ↓ (B ↓ B) A ∧ B ↔ (A ↓ A) ↓ (B ↓ B)
T T T F F T T
T F F F T F T
F T F T F F T
F F F T T F T
A' is equivalent to A ↓ A
A A' A ↓ A A' ↔ A ↓ A
T F F T
F T T T
53. a. For A ∧ B to be true, we would want to know that both parts are true; if one part
has an unknown truth value, then it is unknown whether this is the case. In order
for A ∨ B to be true, we would want at least one part to be true; if one part is false
and the other part has an unknown truth value, then it is unknown whether this is
the case. Finally, if the truth value of A is unknown, then the truth value of A' is
also unknown.
b. (F)' ∧ N = T ∧ N = N
c. N ∧ F = F
d. (N)' ∨ (F)' = N ∨ T = T
54. a. If A has a truth value of x, 0 ≤ x ≤ 1, then A' is the “opposite condition” and will
have the truth value that represents everything A is not, namely 1 – x. For A ∧ B,
both conditions must hold, which means the lower of the two truth values is all that
can be achieved. For A ∨ B, either condition can hold, so the higher of the two
truth values can be achieved.
b. 1 – 0.12 = 0.88
c. min(0.12, 0.84) = 0.12
d. max(0.12, 1 – 0.84) = max(0.12, 0.16) = 0.16
55. Draw a “tree” similar to Figure 1.1 but where each level has three outcomes. The
number of outcomes at level n is 3n.
58. The ages are 13, 14, 15, 16, 17. By fact 2, Pollie and Mellie are one year apart, so by
facts 3 and 4, they do not sleep in the yellow room or the while room; therefore, one of
them sleeps in the green room. By fact 5, the person who sleeps in the green room is at
least age 15 because there are at least two younger siblings. By fact 3, the ages in the
yellow room could be
a. 13 and 15
b. 14 and 16
14
c. 15 and 17
and by fact 4, the ages in the white room can be
e. 13 and 16
f. 14 and 17
Option b conflicts with both e and f, so option b is ruled out. Option c conflicts with f,
but not with e. Options c and e say that the ages in the yellow and white rooms are 13,
15, 16, 17, leaving age 14 to sleep in the green room, but this contradicts the fact that
the age in the green room is at least 15. The only options left are a and f. This would
use up ages 13, 14, 15, and 17, leaving age 16 to sleep in the green room. If Rollie is
older than Ollie but less than 16 (the green room age), then they must fit option a, so
Ollie is 13, Rollie is 15, and they sleep in the yellow room. The girls are ages 14 and
17, and because Pollie is exactly one year older than Mellie, Mellie must be in the
green room (age 16), with Pollie age 17, leaving Nellie as age 14.
The solution is
Ollie, 13, yellow room
Nellie, 14, white room
Rollie, 15, yellow room
Mellie, 16, green room
Pollie, 17, white room
59. This could include everyone because members are welcome and nonmembers are
welcome. Or it could include no one because no one is both a member and a
nonmember.
60. If the defendant is a liar, then he makes false statements. Therefore, the statement he
made, “I am a liar,” is false, which means he is not a liar. But if the defendant is not a
liar, then he makes true statements, so he could not say “I am a liar,” The jury can
come to no conclusion based on this statement.
61. If Percival is a liar, then his statement is false. Therefore, it is false that there is at
least one liar, and both Percival and Llewellyn must be truth-tellers. But this is
impossible because we assumed Percival is a liar. Therefore, Percival is a truth-teller,
and his statement is true. Because he said, “At least one of us is a liar,” Llewellyn
must be a liar. Therefore, Percival is a truth-teller and Llewellyn is a liar.
62. Merlyn's statement is of the form A → B, where A stands for “I am a truth-teller” and
B stands for “Meredith is a truth-teller.” If Merlyn is a liar, then statement A is false;
therefore, statement A → B is true, but Merlyn, as a liar, would not have said a true
statement. Therefore, Merlyn must be a truth-teller. Then the statement he makes,
A → B, must be true, and statement A is true as well. Therefore, statement B must be
true, and Meredith is a truth-teller. So both Merlyn and Meredith are truth-tellers.
63. Rothwold's statement is of the form A ∨ B, where A stands for “I am a liar” and B
stands for “Grymlin is a truth-teller.” If Rothwold is a liar, then his statement A ∨ B is
false, and the statement (A ∨ B)' must be true. By De Morgan's laws, A' and B' must
both be true. But A' is the statement that Rothwold is a truth-teller, which is not true.
Therefore, Rothwold must be a truth-teller, and his statement A ∨ B is true. Statement
15
A, however, is false because it says that Rothwold is a liar. So statement B must be
true, and Grymlin is a truth-teller. Both are truth-tellers.
64. Gwendolyn's statement is of the form A ∧ B, where A stands for “I am a liar” and B
stands for “Merrilaine is not a liar.” If Gwendolyn is a truth-teller, then both A and B
must be true, but A is false. Therefore, Gwendolyn is a liar, and her statement A ∧ B is
false. But A is true, so B must be false. If it is false that Merrilaine is not a liar, then
Merrilaine is a liar. Both are liars.
EXERCISES 1.2
1. (M → F) ∧ F'→ M' – mt
2. (B → A) ∧ B → A – mp
3. S ∧ L→ L – sim
4. (S → R) ∧ (R → B) → (S → B) – hs
5. The hypotheses have the form (C → P) ∧ P'. By mt, the conclusion is C'; the car was
not involved in the hit-and-run.
6. The hypotheses have the form (W ∨ L) ∧ (W → F). No useful conclusion can be made.
Note that W ∨ L is a very weak hypothesis and does not mean that you have W, so you
cannot conclude F. You can do the following:
1. W ∨ L hyp
2. L ∨ W hyp
3. (L')' ∨ W 2, dn
4. L' → W 3, imp
5. W → F hyp
6. L' → F hs
But this conclusion is equivalent to L ∨ F, which is also very weak—you do not have
either L or F.
7. The hypotheses have the form (B → P) ∧ P. Only P, you will be paid tomorrow, can
be concluded, using simplification. (B cannot be concluded.)
8. The hypotheses have the form G ∧ T ∧ (G → R). By mp, the conclusion is R, we need
to rake the leaves.
17
21. [A → (B → C)] → [B → (A → C)] 25. (P ∨ Q) ∧ P' → Q
1. A → (B → C) hyp 1. P ∨ Q hyp
2. B hyp 2. P' hyp
3. A hyp (deduction 3. (P')' ∨ Q 1, dn
method again) 4. P' → Q 3, imp
4. B → C 1, 3, mp 5. Q 2, 4, mp
5. C 2, 4, mp
26. (P → Q) → (Q' → P')
22. (A ∧ B) → (A → B')' 1. P → Q hyp
1. A ∧ B hyp 2. Q' hyp
2. (A')' ∧ (B')' 1, dn 3. P' 1, 2, mt
3. (A' ∨ B')' 2, De Morgan
4. (A → B')' 3, imp 27. (Q' → P') → (P → Q)
1. Q' → P' hyp
23. (A → C) ∧ (C → B') ∧ B → A' 2. P hyp
3. (P')' 2, dn
1. A → C hyp
4. (Q')' 1, 3, mt
2. C → B' hyp
5. Q 4, dn
3. B hyp
4. (B')' 3, dn 28. P → P ∧ P
5. C' 2, 4, mt 1. P hyp
6. A' 1, 5, mt 2. P hyp (writing it
or again)
1. A → C hyp 3. P ∧ P 1, 2, con
2. C → B' hyp
3. B hyp 29. P ∨ P → P
4. A → B' 1, 2, hs 1. P' → P' ∧ P' Exercise 28
5. (B')' 3, dn 2. P' → (P ∨ P)' 1, De Morgan
6. A' 4, 5, mt 3. [P' → (P ∨ P)'] → [(P ∨ P) → P]
Exercise 27
24. [A → (B ∨ C)] ∧ C' → (A → B) 4. P ∨ P → P 2, 3, mp
1. A → (B ∨ C) hyp
2. C' hyp 30. [(P ∧ Q) → R] → [P → (Q → R)]
3. A hyp 1. (P ∧ Q) → R hyp
4. B ∨ C 1, 3, mp 2. P hyp
5. C ∨ B 4, comm. 3. Q hyp (deduction
6. (C')' ∨ B 5, dn method again)
7. C' → B 6, imp 4. P ∧ Q con
8. B 2, 7, mp 5. R 1, 4, mp
18
31. P ∧ P' → Q
1. P hyp
2. P' hyp
3. P ∨ Q 1, add
4. Q ∨ P 3, comm
5. (Q')' ∨ P 4, dn
6. Q' → P 5, imp
7. (Q')' 2, 6, mt
8. Q 7, dn
32. P ∧ (Q ∨ R) → (P ∧ Q) ∨ (P ∧ R)
Rewriting the conclusion, the argument is
P ∧ (Q ∨ R) → ((P ∧ Q)')' ∨ (P ∧ R) by dn
or
P ∧ (Q ∨ R) → [(P ∧ Q)'→ (P ∧ R)] by imp
1. P hyp
2. Q ∨ R hyp
3. (P ∧ Q)' hyp
4. P' ∨ Q' 3, De Morgan
5. Q' ∨ P' 4, comm
6. Q → P' 5, imp
7. (P')' 1, dn
8. Q' 6, 7, mt
9. R ∨ Q 2, comm
10. (R')' ∨ Q 9, dn
11. R' → Q 10, imp
12. (R')' 8, 11, mt
13. R 12, dn
14. P ∧ R 1, 13, con
33. P ∨ (Q ∧ R) → (P ∨ Q) ∧ (P ∨ R)
Prove
P ∨ (Q ∧ R) → (P ∨ Q)
Rewriting the conclusion, the argument is
P ∨ (Q ∧ R) → ((P')' ∨ Q) by dn
or
P ∨ (Q ∧ R) → (P'→ Q) by imp
1. P ∨ (Q ∧ R) hyp
2. P' hyp
3. (P')' ∨ (Q ∧ R) 1, dn
4. P' → (Q ∧ R) 3, imp
5. Q∧R 2, 4, mp
6. Q 5, sim
19
34. A' → (A → B) 37. (A' → B) ∧ (B → C)
1. A' hyp ∧ (C → D) → (A' → D)
2. A hyp 1. A' → B hyp
3. B 1, 2, inc 2. B → C hyp
3. C → D hyp
35. (P→ Q) ∧ (P' → Q) → Q 4. A' → C 1, 2, hs
1. P→ Q hyp 5. A' → D 3, 4, hs
2. P' → Q hyp
3. Q' → P' 1, cont 38. (A ∨ B) ∧ (A → C) ∧ (B → C) → C
4. Q' → Q 2, 3, hs 1. A ∨ B hyp
5. (Q')' ∨ Q imp 2. A → C hyp
6. Q ∨ Q 5, dn 3. B → C hyp
7. Q 6, self 4. (A')' ∨ B 1, dn
5. A' → B 4, imp
36. (A' → B') ∧ (A → C) → (B → C) 6. A' → C 3, 5, hs
1. A' → B' hyp 7. (A → C) ∧ (A' → C) 2, 5, con
2. A → C hyp 8. C Exercise 33
3. B hyp
4. B → A 1, cont
5. C 2, 4, hs
21
46. The argument is [(C ∧ W') ∧ ((R ∨ S') → W)] → (C ∧ S).
A proof sequence is
1. C ∧ W' hyp
2. (R ∨ S') → W hyp
3. W' 1, sim
4. W' → (R ∨ S')' 2, cont
5. (R ∨ S')' 3, 4, mp
6. R' ∧ (S')' 5, De Morgan
7. R' ∧ S 6, dn
8. S 7, sim
9. C 1, sim
10. C ∧ S 8, 9, con
or
1. C ∧ W' hyp
2. (R ∨ S') → W hyp
3. C 1, sim
4. W' 1, sim
5. (R ∨ S')' 4, 2, mt
6. R' ∧ (S')' 5, De Morgan
7. (S')' 6, sim
8. S 7, dn
9. C ∧ S 3, 8, conj
49. The argument is [(R ∧ (F' ∨ N)) ∧ N' ∧ (A' → F)] → (A ∧ R).
A proof sequence is
1. R ∧ (F' ∨ N) hyp
2. N' hyp
3. A' → F hyp
4. R 1, sim
22
5. F' ∨ N 1, sim
6. N ∨ F' 5, comm
7. F' 2, 6, ds
8. F' → (A')' 3, cont
9. (A')' 7, 8, mp
10. A 9, dn
11. A ∧ R 4, 10, con
23
6. (B ∧ L)' 4, 5, mt
7. B' ∨ L' 6, De Morgan
8. B → L' 7, imp
9. L 3, sim
10. (L')' 9, dn
11. B' 8, 10, mt
EXERCISES 1.3
3. a. T (pick y = 0)
b. T (pick y = 0)
c. T (pick y = –x)
d. F (No one y works for all x's.)
e. F (may have x = y)
f. T (pick y = –x)
g. T (pick x = 2, y = 4)
h. F (may have x = 0)
25
d. Every state is north of some state that starts with the letter M. - False (Florida)
e. Massachusetts is north of some state. - True
f. There is a state (Maine) that starts with the letter M and is north of Massachusetts. -
True
10. a. There is no variable as part of the existential quantifier, and no closing parentheses
at the end.
b. There is no logical connective between Q(y) and P(y).
c. Because of the two quantifiers in the front, it's likely that this should have been
written as (∀x)(∀y)[Q(x) → P(y)].
26
d. (∃x)[D(x) ∧ S(x) ∧ R(x)]
e. There are several ways to write the wff for this sentence. If you think of “no” as a
negation adjective for “day,” then this statement says that “sunny and rainy implies
not a day”: (∀x)[(S(x) ∧ R(x)) → (D(x))']. Using contraposition, this is equivalent to
(∀x)[ D(x) → (S(x) ∧ R(x))'] (“if it's a day, then it can't be both sunny and rainy”)
which, using DeMorgan's law is equivalent to (∀x)[ D(x) → (S(x))' ∨ (R(x))'] (“every
day is not sunny or not rainy”). Using implication, this is also equivalent to
(∀x)[ (D(x))' ∨ (S(x))' ∨ (R(x))'] and again by De Morgan's law, this is equivalent to
(∀x)[ D(x) ∧ S(x) ∧R(x)]'. Of all these choices, the most natural one is probably
(∀x)[ D(x) → (S(x) ∧ R(x))'], but they are all correct.
f. (∀x)[D(x) ∧ S(x) → D(x) ∧ R(x)]
g. (∀x)[D(x) → (S(x))']
h. S(M) → (∀x)(D(x) → S(x))
i. R(M) ∧ R(T)
j. This sentence is an overall implication: (∃x)(D(x) ∧ R(x)) → (∀x)(D(x) → S(x)).
27
17. a. “There is a person and for every time, that person is fooled at that time”:
(∃x)[P(x) ∧ (∀y)(T(y) → F(x, y))].
b. “For every person there is a time at which that person is fooled”:
(∀x)[P(x) → (∃y)(T(y) ∧ F(x, y))].
c. “It is false that for every person and every time that person is fooled at that time”:
[(∀x)(∀y)(P(x) ∧ T(y) → F(x, y))]' or [(∀x)(P(x) → (∀y)(T(y) → F(x, y)))]'.
“There is some person and some time such that that person is not fooled at that
time”: (∃x)( ∃y)(P(x) ∧ T(y) ∧ (F(x, y)').
28
b. (∃x)[P(x) ∧ (∀y)(S(x, y) → F(y))] or (∃x)(∀y)[P(x) ∧ (S(x, y) → F(y))]
c. (∀x)(∀y)([P(y) ∧ S(x, y)] → C(x))
d. (∀x)[F(x) → (∃y)(C(y) ∧ S(x, y))] or (∀x)(∃y)[F(x) → (C(y) ∧ S(x, y))]
or, if there is some one Corvette, (∃x)[C(x) ∧ (∀y)(F(y) → S(y, x))]
e. (∃x)(P(x) ∧ (∀y)[C(y) → (S(x, y))']) or (∃x)(∀y)(P(x) ∧ [C(y) → (S(x, y))'])
f. (∃x)(∃y)(C(x) ∧ F(y) ∧ S(x, y)) → (∀x)(∀y)(C(x) ∧ F(y) → S(x, y))
27. a. 2 b. 3 c. 3 d. 1
28. a. 3 b. 1 c. 3 d. 3
32. a. For every child, there is some clown the child does not fear.
b. Every child fears something besides a clown.
c. Some clown fears some child.
33. a. Both sides are true exactly when A(x, y) holds for all x, y pairs.
b. Both sides are true exactly when some x, y pair satisfies the property A(x, y).
c. If there is a single x that is in relation P to all y, then for every y an x exists (this
same x) that is in relation P to y.
d. If a has property A, then something in the domain has property A.
e. If any member of the domain that has property A also has property B, then if all
members of the domain have property A, all have property B.
35. a. Valid: Saying there is an x in the domain with property A is the same as
saying it is false that everything in the domain fails to have property A.
b. Not valid: domain is the integers, P(x) is “x is even,” Q(x) is “x is prime.” Because
there are prime integers, (∃x)Q(x) and therefore (∀x)P(x) v (∃x)Q(x) is true. But it
is false that every integer is even or prime, so the implication is false.
36. a. Valid: If property A is true for all objects in the domain then it is false that there is
some object in the domain for which A is not true.
b. Not valid: domain is the odd integers, P(x) is “x is even,” Q(x) is “x is odd.” Then
30
(∀x)[P(x) → Q(x)] is true because P(x) is always false (there are no even integers
in the domain). (∃x)[P(x) ∨ Q(x)] is true; pick x = 3, for example. Therefore the
antecedent of the implication is true. But the consequent, (∃x)[P(x) ∧ Q(x)], is
false because no (odd) integer is both even and odd.
c. Valid: suppose that for every member of the domain, either P(x) or Q(x) is true. If
there is some member of the domain for which Q is true, then (∃y)Q(y) is true.
Otherwise, all members of the domain have property P and (∀x)P(x) is true. In
either case, (∀x)P(x) ∨ (∃y)Q(y) is true.
37. If something in the domain has either property P or property Q, then something has
property P or something has property Q, and vice versa.
EXERCISES 1.4
1. The conclusion is that pansies are plants. The hypotheses have the form
(∀x)(F(x) → P(x)) ∧ F(p). By universal instantiation, F(p) → P(p), then by modus
ponens, P(p).
2. No conclusion is possible. Just because pansies are plants, this does not [from what we
know here] make them flowers.
3. The conclusion is that pansies are red. The hypotheses have the form
(∀x)[F(x) → (R(x) ∨ P(x))] ∧ F(p) ∧ [P(p)]'. By universal instantiation,
F(p) → (R(p) ∨ P(p)), then by modus ponens, R(p) ∨ P(p), and finally by disjunctive
syllogism, R(p).
4. The conclusion is that some flowers are small. The hypotheses have the form
(∃x)(F(x) ∧ P(x)) ∧ (∀x)(F(x) ∧ P(x) → S(x)). By existential and universal
instantiation (in that order), F(a) ∧ P(a) and F(a) ∧ P(a) → S(a), so by modus ponens,
S(a). Combining F(a) and S(a) and using existential generalization results in
(∃x)(F(x) ∧ S(x)).
5. No conclusion is possible. Just because pansies are flowers, it does not make them
either red or purple. The hypotheses have the form (∃x)(F(x) ∧ R(x)), (∃x)(F(x) ∧ P(x)),
F(p). But existential instantiation does not allow us to use p in removing the existential
quantifiers, so we can say nothing further about pansies.
31