Discrete Structure Revision Questions v1
Discrete Structure Revision Questions v1
1 – Propositional logic / 10
2 – Predicate logic / 24
3 – Inference rules / 20
4 – Proof Methods / 20
Discrete Structure - Review Exercises and Answers
Part A — 5 points
Show that the compound proposition below is a contradiction:
(p ∨ q) ∧ (¬p ∨ q) ∧ (p ∨ ¬q) ∧ (¬p ∨ ¬q)
p q p ∨ q ¬p ∨ q p ∨ ¬q ¬p ∨ resu
¬q lt
T T T T T F F
T F T F T T F
F T T T F T F
F F F T T T F
Via
equivalences (p ∨ q) ∧ (¬p ∨ q) ∧ (p ∨ ¬q) ∧ (¬p ∨ ¬q)
: ≡ ((p ∧ ¬p) ∨ q) ∧ ((p ∧ ¬p) ∨ ¬q)
≡ (F ∨ q) ∧ (F ∨ ¬q)
≡ q ∧ ¬q
≡ F
2
Discrete Structure - Review Exercises and Answers
Part B — 5 points
(p ∧ q) ∨ (¬q ∧ p) ∨ (r ∧ p) ∨ (q ∧ r)
≡ (p ∧ (q ∨ ¬q)) ∨ (r ∧ p) ∨ (q ∧ r)
≡ (p ∧ T ) ∨ (r ∧ p) ∨ (q ∧ r)
≡ p ∨ (r ∧ p) ∨ (q ∧ r)
The above solution is acceptable, but for bonus marks, can be simplified
further to:
p ∨ (r ∧ p) ∨ (q ∧ r)
≡ (p ∧ T ) ∨ (p ∧ r) ∨ (q ∧ r)
≡ (p ∧ (r ∨ T )) ∨ (q ∧ r)
≡ (p ∧ T ) ∨ (q ∧ r)
≡ p ∨ (q ∧ r)
Note that the drawing of the circuit is not included here but was expected in
your solution.
3
Discrete Structure - Review Exercises and Answers
Part A — 12 points
Circle true or false
1. ∀x∃y(x2 = y), where the domain is the set of real numbers. [true] [false]
2. ∃x∀y((y /= 0) → (xy = 1), where the domain is the set of real [true] [false]
numbers.
3. The following are logically equivalent: ¬(p ∧ ¬q) and (p → q) [true] [false]
4. The following are logically equivalent: ∀x¬Q(x) and ¬∃x¬Q(x) [true] [false]
5. ∃xP (x) ∧ ∀x¬Q(x) logically implies ∃x(P (x) ∨ Q(x)) [true] [false]
6. Consider the domain of discourse to be the set {1, 2, 3}, and
Q(x, y) =“y ≥ x”, [true] [false]
and R(y) =“y is odd”. Then ∀y((∀xQ(x, y)) → R(y)) is true.
4
Discrete Structure - Review Exercises and Answers
Part B — 12 points
1. B(a) → ¬L(a)
2. D(a) → ¬M (a)
3. ¬L(a) → D(a)
5
Discrete Structure - Review Exercises and Answers
1. l → a
2. ¬l → ¬m
3. ¬m → f
4. ¬l → f
Formal argument:
1. ¬l → ¬m hypothesis
2. ¬m → f hypothesis
3. ¬l → f hypothetical syllogism of 1, 2
6
Discrete Structure - Review Exercises and Answers
Step Justification
1. ∀x(P (x) → Q(x)) hypothesis
2. P (a) → Q(a) universal instantiation for arbitrary a
3. ∀x(Q(x) → R(x)) hypothesis
4. Q(a) → R(a) universal instantiation for arbitrary a
5. P (a) → R(a) hypothetical syllogism for 2, 4
6. ∀x(P (x) → R(x)) universal generalization
7
Discrete Structure - Review Exercises and Answers
For this question you will need the definitions of odd and even, seen in class.
DEFINITION: An integer n is even if there exists an integer k
such that n = 2k. An integer n is odd if there exists an integer
k such that n = 2k + 1.
8
Part B — 10 points
Prove the following:
For any integer number n, if n2 + 5 is odd then n is even, using:
B1 (5 points) a proof by contraposition.
B2 (5 points) a proof by contradiction.
Answer
B1. Contrposition: p q q p
p: n2 + 5 is odd
q: n is even
Assume n is odd, and show n2 + 5 is even.
Let n be an odd number. Thus, n = 2k + 1 for some integer k. Then:
n2 + 5 = (2k + 1)2 + 5
= 4k2 + 4k + 1 + 5
= 4k2 + 4k + 6
= 2(2k2 + 2k + 3)
Thus, n2 + 5 is an even.
B2.
Contradiction: p q a contradiction
p: n2 + 5 is odd
q: n is even
Assume n2 + 5 is odd and n is odd and reach a contradiction.
*******