Problem 1. Prove that (p⟹q)∨(q⟹p) is a tautology using a truth table.
Solution
p
q
p⟹q
q⟹p
disjunction
T
T
T
T
T
T
F
F
T
T
F
T
T
F
T
F
F
T
T
T
All rows give TSo it is a tautology.
If you get this wrong, revise: Section 1.1 and Section 1.4.
Problem 2. Convert (¬p∨q)∧(r∨¬s) to DNF.
Solution
The formula is a conjunction of two clauses. Distribute ∧ over ∨:
(¬p∨q)∧(r∨¬s)=(¬p∧r)∨(¬p∧¬s)∨(q∧r)∨(q∧¬s).
This is in DNF (disjunction of four terms, each a conjunction of two literals).
If you get this wrong, revise: Section 1.6.
Problem 3. Negate: “For every real number xThere exists a real number y such that y>x.”
Solution
Original: ∀x∃y(y>x).
Negation: ∃x∀y(y≤x)I.e., “there exists a real number x such that every Real number y satisfies y≤x.”
If you get this wrong, revise: Section 1.2.
Problem 4. Prove that A⊆B if and only if A∩Bc=∅.
Solution
(⇒) Assume A⊆B. Let x∈A∩Bc. Then x∈A and x∈/B. But A⊆B implies x∈BContradiction. So A∩Bc=∅.
(⇐) Assume A∩Bc=∅. Let x∈A. If x∈/BThen x∈BcSo x∈A∩Bc=∅Contradiction. Hence x∈BProving A⊆B. ■
If you get this wrong, revise: Section 2.1.
Problem 5. Show that the relation R on "Z′ defined by aRb iff a−b is even Is an equivalence relation. How many equivalence classes are there?
Solution
Reflexive:a−a=0Which is even. ✓ Symmetric: If a−b is even, then b−a=−(a−b) is even. ✓ Transitive: If a−b and b−c are even, then a−c=(a−b)+(b−c) is even. ✓
The equivalence classes are [0] = \\{\mathrm{even\; integers{}\\} and [1] = \\{\mathrm{odd\; integers{}\\}. There are exactly 2 equivalence classes.
If you get this wrong, revise: Section 2.2.
Problem 6. Let f:′R′→′R′ be f(x)=2x+1 and g:′R′→′R′ Be g(x)=x2. Find g∘f and f∘g. Is g∘f injective?
Solution
(g∘f)(x)=g(f(x))=g(2x+1)=(2x+1)2=4x2+4x+1.
(f∘g)(x)=f(g(x))=f(x2)=2x2+1.
Note g∘f=f∘gSo composition is not commutative.
g∘f is not injective: (g∘f)(0)=1 and (g∘f)(−1)=4(−1)2+4(−1)+1=1 But 0=−1.
If you get this wrong, revise: Section 2.3.
Problem 7. Prove that the set of all infinite binary sequences is uncountable.
Solution
Suppose the set S of all infinite binary sequences is countable, so S=s1,s2,s3,… Where si=(si1,si2,si3,…) with each sij∈0,1.
Define t=(t1,t2,t3,…) by ti=1−sii (flip the i-th bit of the i-th Sequence). Then t∈S but t=si for every i (they differ in position i). This Contradicts S=s1,s2,…. Therefore S is uncountable. ■
If you get this wrong, revise: Section 2.4.
Problem 8. Prove: the product of any two odd integers is odd.
Solution
Let a=2m+1 and b=2n+1 be odd. Then ab=(2m+1)(2n+1)=4mn+2m+2n+1=2(2mn+m+n)+1 Which is odd. ■
If you get this wrong, revise: Section 3.1.
Problem 9. Prove: if 3n+2 is odd, then n is odd.
Solution
By contrapositive: assume n is even, so n=2k. Then 3n+2=6k+2=2(3k+1)Which is Even. ■
If you get this wrong, revise: Section 3.2.
Problem 10. Prove: 3 is irrational.
Solution
Suppose 3=p/q in lowest terms. Then 3q2=p2So 3∣p2Hence 3∣p. Write p=3r. Then 3q2=9r2So q2=3r2Giving 3∣q2 and 3∣q. But then gcd(p,q)≥3Contradicting lowest terms. ■
If you get this wrong, revise: Section 3.3.
Problem 11. Prove by induction: ∑i=0n2i=2n+1−1 for all n≥0.
Solution
Base case:n=0: 20=1=21−1. ✓
Inductive step: Assume ∑i=0k2i=2k+1−1. Then
∑i=0k+12i=(2k+1−1)+2k+1=2⋅2k+1−1=2k+2−1
■
If you get this wrong, revise: Section 3.4.
Problem 12. Prove by strong induction that every integer n≥2 is a product of primes.
Solution
Base case:n=2 is prime, hence a product of primes.
Inductive step: Assume every integer in 2,…,k is a product of primes (k≥2). If k+1 is prime, done. If k+1 is composite, then k+1=ab where 2≤a,b≤k. By the induction hypothesis, both a and b are products of primes, so k+1=ab is too. ■
If you get this wrong, revise: Section 3.4 (strong induction).
Problem 13. A committee of 5 is to be chosen from 12 people. How many ways if two specific People must either both serve or neither serves?
Solution
Case 1: Both serve. Choose the remaining 3 from the other 10: (310)=120. Case 2: Neither serves. Choose all 5 from the other 10: (510)=252.
Total: 120+252=372.
If you get this wrong, revise: Section 4.2.
Problem 14. How many integers from 1 to 500 are divisible by 3 or 7 but not by 5?
Solution
∣A3∣=166, ∣A7∣=71, ∣A3∩A7∣=23. Divisible by 3 or 7: 166+71−23=214.
∣A3∩A5∣=33, ∣A7∩A5∣=14, ∣A3∩A7∩A5∣=4. Divisible by 3 or 7 and 5: 33+14−4=43.
Divisible by 3 or 7 but not 5: 214−43=171.
If you get this wrong, revise: Section 4.3.
Problem 15. How many solutions does x1+x2+x3=15 have with xi≥1?
Solution
Substitute yi=xi−1≥0: y1+y2+y3=12 with yi≥0. By stars and bars: (3−112+3−1)=(214)=91.
If you get this wrong, revise: Section 4.4.
Problem 16. Prove that among any 13 people, at least 2 were born in the same month.
Solution
There are 12 months and 13 people. By the pigeonhole principle, at least one month contains at least ⌈13/12⌉=2 people.
If you get this wrong, revise: Section 4.5.
Problem 17. Verify that C3=5 using the Catalan recurrence and the closed form.
Solution
By recurrence:C3=C0C2+C1C1+C2C0=1⋅2+1⋅1+2⋅1=2+1+2=5.
By closed form:C3=41(36)=41⋅20=5. ✓
If you get this wrong, revise: Section 4.6.
Problem 18. Find the chromatic number of C5 (the 5-cycle) and justify.
Solution
C5 is an odd cycle. It cannot be 2-coloured (an odd cycle requires 3 colours: colour the first Vertex 1, alternate 2 and 1 around, and the last vertex (5th) is adjacent to both the 4th (colour 2) And the 1st (colour 1), so it needs colour 3).
Problem 19. In the bipartite graph with partitions X=1,2,3 and Y=a,b,c,d And edges 1—a,b; 2—b,c; 3—c,dVerify Hall’s condition and find a matching covering X.
If you get this wrong, revise: Section 6.2 and Section 6.3.
Common Pitfalls
Confusing ⇒ and ⇔.P⇒Q means “if P then Q” (sufficient condition). P⇔Q means “if and only if” (necessary and sufficient). Fix:P⇒Q is equivalent to ¬Q⇒¬P (contrapositive), not Q⇒P (converse).
Wrong induction base case. The base case must be the smallest value for which the statement is claimed to hold. Fix: If the claim starts at n=1, prove n=1; if at n=0, prove n=0.
Confusing combinations and permutations with repetition. Standard formulas assume distinct, non-repeated items. Fix: With repetition: nr (ordered) or (rn+r−1) (unordered).
Worked Examples
Example 1: Proof by induction
Problem. Prove that ∑k=1nk2=6n(n+1)(2n+1) for all n≥1.
Solution. Base (n=1): 1=1(2)(3)/6=1. ✓ Inductive step: assume true for n. Then ∑k=1n+1k2=6n(n+1)(2n+1)+(n+1)2=6(n+1)[n(2n+1)+6(n+1)]=6(n+1)(2n2+7n+6)=6(n+1)(n+2)(2n+3). ✓
■
Example 2: Graph theory
Problem. A connected planar graph has 6 vertices and 8 edges. How many faces does it have?
Solution. By Euler’s formula: V−E+F=2. 6−8+F=2⟹F=4.
■
Summary
Logic: propositions, truth tables, quantifiers; implication, contrapositive, converse.