GIAM HW
GIAM HW
Joseph Fields
1. Each of the quantities indexing the rows of the following table is in one
or more of the sets which index the columns. Place a check mark in a
table entry if the quantity is in the set.
N Z Q R C
17
π
22/7
−6
e0
1+i
√
3
i2
1
2 CHAPTER 1. INTRODUCTION AND NOTATION
(a) 5021.2121212121 . . .
(b) 0.2340000000 . . .
(c) 12.31331133311133331111 . . .
(d) π
(e) 2.987654321987654321987654321 . . .
4. The “see and say” sequence is produced by first writing a 1, then it-
erating the following procedure: look at the previous entry and say
how many entries there are of each integer and write down what you
just said. The first several terms of the “see and say” sequence are
1, 11, 21, 1112, 3112, 211213, 312213, 212223, . . .. Comment on the ra-
tionality (or irrationality) of the number whose decimal digits are ob-
tained by concatenating the “see and say” sequence.
0.1112111123112211213...
1.1. BASIC SETS 3
√ √
6. Find the first 20 decimal places of π, 3/7, 2, 2/5, 16/17, 3, 1/2 and
42/100. Classify each of these quantity’s decimal expansion as: termi-
nating, having a repeating pattern, or showing no discernible pattern.
4 CHAPTER 1. INTRODUCTION AND NOTATION
7. Consider the process of long division. Does this algorithm give any in-
sight as to why rational numbers have terminating or repeating decimal
expansions? Explain.
(b) (1 + i) + (1 − i)
(c) (1 + i) · (1 − i)
(a) 105
(b) 414
(c) 168
(d) 1612
(e) 9177
1 2 3 4 5 6 7 8 9 10
11 12 13 14 15 16 17 18 19 20
21 22 23 24 25 26 27 28 29 30
31 32 33 34 35 36 37 38 39 40
41 42 43 44 45 46 47 48 49 50
51 52 53 54 55 56 57 58 59 60
61 62 63 64 65 66 67 68 69 70
71 72 73 74 75 76 77 78 79 80
81 82 83 84 85 86 87 88 89 90
91 92 93 94 95 96 97 98 99 100
3. What would be the largest prime one would sieve with in order to find
all primes up to 400?
1.2. DEFINITIONS: PRIME NUMBERS 7
10. Another famous conjecture, also thought to be true – but as yet un-
proved, is Goldbach’s conjecture. Goldbach’s conjecture states that
every even number greater than 4 is the sum of two odd primes. There
is a function g(n), known as the Goldbach function, defined on the pos-
itive integers, that gives the number of different ways to write a given
number as the sum of two odd primes. For example g(10) = 2 since
10 = 5 + 5 = 7 + 3. Thus another version of Goldbach’s conjecture is
that g(n) is positive whenever n is an even number greater than 4.
Graph g(n) for 6 ≤ n ≤ 20.
1.3. MORE SCARY NOTATION 9
1. How many quantifiers (and what sorts) are in the following sentence?
“Everybody has some friend that thinks they know everything about
a sport.”
3. The sentence “For every pair of (distinct) real numbers there is another
real number between them.” is true. Why?
7. For conversion between the three bases used most often in Computer
Science we can take binary as the “standard” base and convert using a
table look-up. Each octal digit will correspond to a binary triple, and
each hexadecimal digit will correspond to a 4-tuple of binary numbers.
Complete the following tables. (As a check, the 4-tuple next to A in
the table for hexadecimal should be 1010 – which is nice since A is
really 10 so if you read that as “ten-ten” it is a good aid to memory.)
hexadecimal binary
0 0000
1 0001
2 0010
octal binary 3
0 000 4
1 001 5
2 6
3 7
4 8
5 9
6 A
7 B
C
D
E
F
1.4. DEFINITIONS OF ELEMENTARY NUMBER THEORY 13
8. Use the tables from the previous problem to make the following con-
versions.
11. Suppose that 340 pounds of sand must be placed into bags having a
50 pound capacity. Write an expression using either floor or ceiling
notation for the number of bags required.
jnk lnm
<
d d
for all integers n and d > 0. Support your claim.
1.4. DEFINITIONS OF ELEMENTARY NUMBER THEORY 15
14. Assuming the symbols n,d,q and r have meanings as in the quotient-
remainder theorem (see page 29 of GIAM). Write expressions for q and
r, in terms of n and d using floor and/or ceiling notation.
(a) 3 mod 5
(b) 37 mod 7
(d) 6 div 6
(e) 7 div 6
3
(a) 0
7
(b) 7
13
(c) 5
13
(d) 8
52
(e) 7
17. An ice cream shop sells the following flavors: chocolate, vanilla, straw-
berry, coffee, butter pecan, mint chocolate chip and raspberry. How
many different bowls of ice cream – with three scoops – can they make?
1.5. SOME ALGORITHMS 17
a b gcd(a, b) lcm(a, b)
110 273
105 42
168 189
18 CHAPTER 1. INTRODUCTION AND NOTATION
√ √
4. The proof that 2 is irrational can be generalized to show that p is
irrational for every prime number p. What statement would be equiva-
lent to the lemma about the parity of x and x2 in such a generalization?
1.6. RATIONAL AND IRRATIONAL NUMBERS 21
√
5. Write a proof that 3 is irrational.
22 CHAPTER 1. INTRODUCTION AND NOTATION
1.7 Relations
Exercises — 1.7
1. Consider the numbers from 1 to 10. Give the set of pairs of these
numbers that corresponds to the divisibility relation.
{(1, 1), (1, 2), (1, 3), (1, 4), (1, 5), (1, 6), (1, 7), (1, 8), (1, 9), (1, 10),
(2, 2), (2, 3), (2, 4), (2, 5), (2, 6), (2, 7), (2, 8), (2, 9), (2, 10),
(3, 3), (3, 4), (3, 5), (3, 6), (3, 7), (3, 8), (3, 9), (3, 10),
(4, 4), (4, 5), (4, 6), (4, 7), (4, 8), (4, 9), (4, 10),
(5, 5), (5, 6), (5, 7), (5, 8), (5, 9), (5, 10),
(6, 6), (6, 7), (6, 8), (6, 9), (6, 10),
(7, 7), (7, 8), (7, 9), (7, 10),
(8, 8), (8, 9), (8, 10),
(9, 9), (9, 10),
(10, 10)}
24 CHAPTER 1. INTRODUCTION AND NOTATION
7. There is a relation known as “has color” which goes from the set
to the set
C = {orange, red, green, yellow}.
1. Design a digital logic circuit (using and, or & not gates) that imple-
ments an exclusive or.
27
28 CHAPTER 2. LOGIC AND QUANTIFIERS
2. Consider the sentence “This is a sentence which does not refer to itself.”
which was given in the beginning of this chapter as an example. Is this
sentence a statement? If so, what is its truth value?
4. Complete truth tables for each of the sentences (A∧B)∨C and A∧(B ∨
C). Does it seem that these sentences have the same logical content?
30 CHAPTER 2. LOGIC AND QUANTIFIERS
5. There are two other logical connectives that are used somewhat less
commonly than ∨ and ∧. These are the Scheffer stroke and the Peirce
arrow – written | and ↓, respectively — they are also known as NAND
and NOR.
The truth tables for these connectives are:
A B A|B A B A↓B
T T ϕ T T ϕ
T ϕ T and T ϕ ϕ
ϕ T T ϕ T ϕ
ϕ ϕ T ϕ ϕ T
2.2 Implication
Exercises — 2.2
4. Determine a sentence using the and connector (∧) that gives the nega-
tion of A =⇒ B.
5. Rewrite the sentence “Fix the toilet or I won’t pay the rent!” as a
conditional.
34 CHAPTER 2. LOGIC AND QUANTIFIERS
6. Why is it that the sentence “If pigs can fly, I am the king of Mesopotamia.”
true?
(c) If you wish others to treat you in a certain way, you must treat
P∞
(e) If an ≤ bn , for all n and n=0 bn is a convergent series, then
P∞
n=0 an is a convergent series.
2.2. IMPLICATION 35
9. What are the converse and inverse of “If you watch my back, I’ll watch
your back.”?
∞
X Z ∞
f (n) < f (x).
n=1 0
11. On the Island of Knights and Knaves (see page 31) you encounter two
individuals named Locke and Demosthenes.
Locke says, “Demosthenes is a knave.”
Demosthenes says “Locke and I are knights.”
Who is a knight and who a knave?
2.3. LOGICAL EQUIVALENCES 37
(a) (A ∧ B) ∨ B ∼
= (A ∨ B) ∧ B
(b) A ∧ (B ∨ ¬A) ∼
= A∧B
(c) (A ∧ ¬B) ∨ (¬A ∧ ¬B) ∼
= (A ∨ ¬B) ∧ (¬A ∨ ¬B)
(d) The absorption laws.
2.3. LOGICAL EQUIVALENCES 39
(a) (A ∨ B) ⇐⇒ C
(b) (A ∨ B) =⇒ (A ∧ B)
40 CHAPTER 2. LOGIC AND QUANTIFIERS
(a) “One should not behave towards others in a way which is disagree-
able to oneself.” Mencius Vii.A.4 (Hinduism)
(b) “None of you [truly] believes until he wishes for his brother what
he wishes for himself.” Number 13 of Imam “Al-Nawawi’s Forty
Hadiths.” (Islam)
(c) “And as ye would that men should do to you, do ye also to them
likewise.” Luke 6:31, King James Version. (Christianity)
(d) “What is hateful to you, do not to your fellow man. This is the law:
all the rest is commentary.” Talmud, Shabbat 31a. (Judaism)
(e) “An it harm no one, do what thou wilt” (Wicca)
(f) “What you would avoid suffering yourself, seek not to impose on
others.” (the Greek philosopher Epictetus – first century A.D.)
(g) “Do not do unto others as you expect they should do unto you.
Their tastes may not be the same.” (the Irish playwright George
Bernard Shaw – 20th century A.D.)
42 CHAPTER 2. LOGIC AND QUANTIFIERS
7. You encounter two natives of the land of knights and knaves. Fill in
an explanation for each line of the proofs of their identities.
is a knight.
Thus Bonaparte is a knight and Wellington is a knave (as
claimed).
Q.E.D.
44 CHAPTER 2. LOGIC AND QUANTIFIERS
1. A ∨ (A ∧ B) ∼
= A ∧ (A ∨ B)
2. (A ∧ ¬B) ∨ A ∼
= A
3. A ∨ B ∼
= A ∨ (¬A ∧ B)
5. A ∼
= A ∧ ((A ∨ ¬B) ∨ (A ∨ B))
6. (A ∧ ¬B) ∧ (¬A ∨ B) ∼
= c
7. A ∼
= A ∧ (A ∨ (A ∧ (B ∨ C)))
8. ¬(A ∧ B) ∧ ¬(A ∧ C) ∼
= ¬A ∨ (¬B ∧ ¬C)
2.4. TWO-COLUMN PROOFS 45
46 CHAPTER 2. LOGIC AND QUANTIFIERS
5. Alvin, Betty, and Charlie enter a cafeteria which offers three different
entrees, turkey sandwich, veggie burger, and pizza; four different bev-
erages, soda, water, coffee, and milk; and two types of desserts, pie and
pudding. Alvin takes a turkey sandwich, a soda, and a pie. Betty takes
a veggie burger, a soda, and a pie. Charlie takes a pizza and a soda.
Based on this information, determine whether the following statements
are true or false.
Hopefully you will see that they are the same! Does this make
you want to modify one or both of your answers to 5a and 5b?
50 CHAPTER 2. LOGIC AND QUANTIFIERS
1. In the movie “Monty Python and the Holy Grail” we encounter a me-
dieval villager who (with a bit of prompting) makes the following ar-
gument.
(a) You are either with us, or you’re against us. And you don’t
appear to be with us. So, that means you’re against us!
(b) All those who had cars escaped the flooding. Sandra had a car –
therefore, Sandra escaped the flooding.
(c) When Johnny goes to the casino, he always gambles ’til he goes
broke. Today, Johnny has money, so Johnny hasn’t been to the
casino recently.
(b) If one eats oranges one will have high levels of vitamin C.
You do have high levels of vitamin C.
Therefore, you must eat oranges.
2.7. VALIDITY OF ARGUMENTS AND COMMON ERRORS 53
5. Read the following proof that the sum of two odd numbers is even.
Discuss the rules of inference used.
x + y = 2k + 1 + 2j + 1 = 2(k + j + 1).
61
62 CHAPTER 3. PROOF TECHNIQUES I
Even
∀n ∈ Z,
n is even ⇐⇒ ∃k ∈ Z, n = 2k
Odd
∀n ∈ Z,
n is odd ⇐⇒ ∃k ∈ Z, n = 2k + 1
Divisibility
∀n ∈ Z, ∀ d > 0 ∈ Z,
d|n ⇐⇒ ∃k ∈ Z, n = kd
Floor
∀x ∈ R,
y = ⌊x⌋ ⇐⇒ y ∈Z ∧ y ≤x<y+1
Ceiling
∀x ∈ R,
y = ⌈x⌉ ⇐⇒ y ∈Z ∧ y−1<x≤y
Quotient-remainder theorem, Div and Mod
∀n, d > 0 ∈ Z,
∃!q, r ∈ Z, n = qd + r ∧ 0 ≤ r < d
n div d = q
n mod d = r
Prime
∀p ∈ Z
p is prime ⇐⇒
(p > 1) ∧ (∀x, y ∈ Z+ , p = xy =⇒ x = 1 ∨ y = 1)
3.1. DIRECT PROOFS OF UNIVERSAL STATEMENTS 63
4. Prove that the sum of an odd number and an even number is odd.
3.1. DIRECT PROOFS OF UNIVERSAL STATEMENTS 65
5. Prove that if the sum of two integers is even, then so is their difference.
2 3
6. Prove that for every real number x, 3
<x< 4
=⇒ ⌊12x⌋ = 8.
66 CHAPTER 3. PROOF TECHNIQUES I
8. Prove that for all integers a and b, if a is odd and 6 | (a + b), then b is
odd.
3.1. DIRECT PROOFS OF UNIVERSAL STATEMENTS 67
evenness(n) = k ⇐⇒ 2k | n ∧ 2k+1 ∤ n
11. Suppose that a, b and c are integers such that a | b and b | c. Prove that
a | c.
ax + b
= 1.
cx + d
Show that x is rational. Where is the hypothesis a ̸= c used?
3.1. DIRECT PROOFS OF UNIVERSAL STATEMENTS 69
13. Show that if two positive integers a and b satisfy a | b and b | a then
they are equal.
70 CHAPTER 3. PROOF TECHNIQUES I
4. Prove that for all integers a, b, and c, if a|b and a|(b + c), then a|c.
72 CHAPTER 3. PROOF TECHNIQUES I
1
5. Show that if x is a positive real number, then x + x
≥ 2.
6. Prove that for all real numbers a, b, and c, if ac < 0, then the quadratic
equation ax2 + bx + c = 0 has two real solutions.
Hint: The quadratic equation ax2 + bx + c = 0 has two real solutions
if and only if b2 − 4ac > 0 and a ̸= 0.
3.2. MORE DIRECT PROOFS 73
n k n n−r
7. Show that k
· r
= r
· k−r
(for all integers r, k and n with
r ≤ k ≤ n).
74 CHAPTER 3. PROOF TECHNIQUES I
d
(f (x) · g(x))
dx
d d
= (f (x)) · g(x) + f (x) · (g(x))
dx dx
Fill in the rest of the proof.
3.3. CONTRADICTION AND CONTRAPOSITION 75
1. Prove that if the cube of an integer is odd, then that integer is odd.
2. Prove that whenever a prime p does not divide the square of an integer,
it also doesn’t divide the original integer. (p ∤ x2 =⇒ p ∤ x)
76 CHAPTER 3. PROOF TECHNIQUES I
9. Suppose you have 2 pairs of positive real numbers whose products are
1. That is, you have (a, b) and (c, d) in R2 satisfying ab = cd = 1.
Prove that a < c implies that b > d.
80 CHAPTER 3. PROOF TECHNIQUES I
3.4 Disproofs
Exercises — 3.4
1! = 1
2! − 1! = 1
3! − 2! + 1! = 5
4! − 3! + 2! − 1! = 19
et cetera
6. True or false: There are two irrational numbers whose sum is rational.
Prove your answer.
8. True or false: There are two irrational numbers whose product is ra-
tional. Prove your answer.
3.4. DISPROOFS 83
2. Prove that every prime number other than 2 and 3 has the form 6q + 1
or 6q + 5 for some integer q. (Hint: this problem involves thinking
about cases as well as contrapositives.)
3.5. BY CASES AND BY EXHAUSTION 85
5. Find the pebbling number of a graph whose nodes are the corners and
whose edges are the, uhmm, edges of a cube.
9. The trichotomy property of the real numbers simply states that every
real number is either positive or negative or zero. Trichotomy can be
used to prove many statements by looking at the three cases that it
guarantees. Develop a proof (by cases) that the square of any real
number is non-negative.
1. Show that there is a perfect square that is the sum of two perfect
squares.
2. Show that there is a perfect cube that is the sum of three perfect cubes.
3.6. EXISTENTIAL STATEMENTS 91
3. Show that the WOP doesn’t hold in the integers. (This is an existence
proof, you show that there is a subset of Z that doesn’t have a smallest
element.)
scissors
cuts
paper
smashes
covers
rock
94 CHAPTER 3. PROOF TECHNIQUES I
Chapter 4
Sets
No more turkey, but I’d like some more of the bread it ate. –Hank Ketcham
1. What is the power set of ∅? Hint: if you got the last exercise in the
chapter you’d know that this power set has 20 = 1 element.
95
96 CHAPTER 4. SETS
7. Find a logical open sentence such that {0, 1, 4, 9, . . .} is its truth set.
8. How many singleton sets are there in the power set of {a, b, c, d, e}?
“Doubleton” sets?
P({a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p})?
10. How many singleton sets are there in the power set of {1, 2, 3, . . . n}?
98 CHAPTER 4. SETS
4.2 Containment
Exercises — 4.2
6. Prove that the set of perfect fourth powers is contained in the set of
perfect squares.
100 CHAPTER 4. SETS
Intersection Union
version version
Commutative
A∩B =B∩A A∪B =B∪A
laws
Associative A ∩ (B ∩ C) A ∪ (B ∪ C)
laws = (A ∩ B) ∩ C = (A ∪ B) ∪ C
Distributive A ∩ (B ∪ C) = A ∪ (B ∩ C) =
laws (A ∩ B) ∪ (A ∩ C) (A ∪ B) ∩ (A ∪ C)
Double
A = A same
complement
Identity
A∩U =A A∪∅=A
laws
Absorption A ∩ (A ∪ B) = A A ∪ (A ∩ B) = A
4.3. SET OPERATIONS 101
1. Let A = {1, 2, {1, 2}, b} and let B = {a, b, {1, 2}}. Find the following:
(a) A ∩ B
(b) A ∪ B
(c) A \ B
(d) B \ A
(e) A△B
102 CHAPTER 4. SETS
(a) A ∩ ♡
(b) A ∪ ♡
(c) J ∩ (♠ ∪ ♡)
(d) K ∩ ♡
(e) A ∩ K
(f) A ∪ K
4.3. SET OPERATIONS 103
(a) A ∩ B = A ∪ B
(b) A ∪ B = A ∪ (A ∩ B)
(c) A△B = (A ∪ B) \ (A ∩ B)
(d) (A ∪ B) \ C = (A \ C) ∪ (B \ C)
4.3. SET OPERATIONS 105
In = [−n, 1/n).
Find the union and intersection of all the intervals in this infinite family.
[
In =
n∈N
\
In =
n∈N
106 CHAPTER 4. SETS
6. There is a set X such that, for all sets A, we have X△A = A. What
is X?
10. Prove the set-theoretic versions of DeMorgan’s laws using the technique
discussed in the previous problems.
110 CHAPTER 4. SETS
Thus x ∈ B.
Now, we will show that B ⊆ A.
Suppose that x ∈ B.
..
.
Thus x ∈ A.
Therefore A ⊆ B ∧ B ⊆ A so we conclude that A = B.
Q.E.D.
1. Let A = {1, 2, 4, 5}, B = {2, 3, 4, 6}, and C = {1, 2, 3, 4}. Place each
of the elements 1, . . . , 6 in the appropriate regions of a three-set Venn
diagram.
2. Prove or disprove:
(A ∩ C ⊆ B ∩ C) =⇒ A ⊆B
112 CHAPTER 4. SETS
3. Venn diagrams are usually made using simple closed curves with no
further restrictions. Try creating Venn diagrams for 3, 4 and 5 sets (in
general position) using rectangular simple closed curves.
4.4. VENN DIAGRAMS 113
Use rectilinear simple closed curves to create a Venn diagram for 5 sets.
114 CHAPTER 4. SETS
5. Argue as to why rectilinear curves will suffice to build any Venn dia-
gram.
8. The prototypes for the modus ponens and modus tollens argument
forms are the following:
All men are mortal. All men are mortal.
Socrates is a man. Zeus is not mortal.
and
Therefore Socrates is Therefore Zeus is not a
mortal. man.
Illustrate these arguments using Venn diagrams.
116 CHAPTER 4. SETS
(A ∩ B) ∪ (C ∩ D) ⊆ (A ∪ C) ∩ (B ∪ D).
10. Use Venn diagrams to show that the following set equivalence is false.
(A ∪ B) ∩ (C ∪ D) = (A ∪ C) ∩ (B ∪ D)
118 CHAPTER 4. SETS
2. One way out of Russell’s paradox is to declare that the collection of sets
that don’t contain themselves as elements is not a set itself. Explain
how this circumvents the paradox.
Chapter 5
Proof techniques II —
Induction
The sum of the first several numbers in this sequence can be expressed
as a polynomial.
n
X
4j + 1 = 2n2 + 3n + 1
j=0
119
120 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
Pn
n j=0 4j + 1 2n2 + 3n + 1
0 1 1
1 1+5=6 2 · 12 + 3 · 1 + 1 = 6
2 1+5+9=
3
4
2. What is wrong with the following inductive proof of “all horses are the
same color.”?
Theorem Let H be a set of n horses, all horses in H are the same
color.
Q.E.D.
5.1. THE PRINCIPLE OF MATHEMATICAL INDUCTION 121
3. For each of the following theorems, write the statement that must be
proved for the basis – then prove it, if you can!
(c) If n coins are flipped, the probability that all of them are “heads”
is 1/2n .
(d) Every 2n ×2n chessboard – with one square removed – can be tiled
perfectly1 by L-shaped trominoes. (A trominoe is like a domino
but made up of 3 little squares. There are two kinds, straight
1
Here, “perfectly tiled” means that every trominoe covers 3 squares of the chessboard
(nothing hangs over the edge) and that every square of the chessboard is covered by some
trominoe.
122 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
4. Suppose that the rules of the game for PMI were changed so that one
did the following:
Explain why this would not constitute a valid proof that Pn holds for
all natural numbers n. How could we change the basis in this outline
to obtain a valid proof?
∀z ∈ Z, Pz ,
1. Write an inductive proof of the formula for the sum of the first n cubes.
124 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
3. The sum of the first n natural numbers is sometimes called the n-th
triangular number Tn . Triangular numbers are so-named because one
can represent them with triangular shaped arrangements of dots.
1
1 − 4 = −3
1−4+9=6
1 − 4 + 9 − 16 = −10
et cetera
Pn i−1 2
Guess a general formula for i=1 (−1) i, and prove it using PMI.
5.2. FORMULAS FOR SUMS AND PRODUCTS 127
n
Y 1 1
1− =
i=2
i n
n
X
6. Prove (4j + 1) = 2n2 + 3n + 1 for all integers n ≥ 0.
j=0
128 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
n
X 1 n
7. Prove = for all natural numbers n.
i=1
(2i − 1)(2i + 1) 2n + 1
5.2. FORMULAS FOR SUMS AND PRODUCTS 129
Fn+2 = Fn + Fn+1
The first two Fibonacci numbers (actually the zeroth and the first) are
both 1.
Thus, the first several Fibonacci numbers are
n
X
(Fi )2 = Fn · Fn+1
i=0
130 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
1. ∀x ∈ N, 3 | x3 − x
2. ∀x ∈ N, 3 | x3 + 5x
5.3. OTHER PROOFS USING PMI 131
3. ∀x ∈ N, 11 | x11 + 10x
4. ∀n ∈ N, 3 | 4n − 1
132 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
5. ∀n ∈ N, 6 | (3n2 + 3n − 12)
7. ∀n ∈ N, 4 | (13n + 4n − 1)
8. ∀n ∈ N, 7 | 8n + 6
134 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
9. ∀n ∈ N, 6 | 2n3 − 2n − 12
12. ∀n ≥ 3 ∈ N, n3 + 3 > n2 + 3n + 1
136 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
13. ∀x ≥ 4 ∈ N, x2 2x ≤ 4x
5.4. THE STRONG FORM OF MATHEMATICAL INDUCTION 137
∀n ∈ N, n ≥ 12 =⇒ ∃x, y ∈ N, n = 3x + 7y.
138 CHAPTER 5. PROOF TECHNIQUES II — INDUCTION
2. Show that any integer postage of 12 or more can be made using only
4 and 5 stamps.
√
1+ 5
3. The polynomial equation x2 = x + 1 has two solutions, α = 2
and
√
1− 5
β= 2
. Show that the Fibonacci number Fn is less than or equal to
αn for all n ≥ 0.
Chapter 6
6.1 Relations
Exercises — 6.1
139
140 CHAPTER 6. RELATIONS AND FUNCTIONS
4. The “socks and shoes” rule is a very silly little mnemonic for remem-
bering how to invert a composition. If we think of undoing the process
of putting on our socks and shoes (that’s socks first, then shoes) we
have to first remove our shoes, then take off our socks.
The socks and shoes rule is valid for relations as well.
Prove that (S ◦ R)−1 = R−1 ◦ S−1 .
142 CHAPTER 6. RELATIONS AND FUNCTIONS
2. Consider the relation A defined by A = {(x, y) x has the same astrological sign as y}.
Is A symmetric or anti-symmetric? Explain.
3. Explain why both of the relations just described (in problems 1 and 2)
have the transitive property.
4. For each of the five properties, name a relation that has it and a relation
that doesn’t.
6.2. PROPERTIES OF RELATIONS 143
6. Prove that “|” is an ordering relation (you must verify that it is reflexive,
anti-symmetric and transitive).
144 CHAPTER 6. RELATIONS AND FUNCTIONS
w1 Aw2 ⇐⇒ w1 is an anagram of w2 .
4. The two diagrams below both show a famous graph known as the Pe-
tersen graph. The picture on the left is the usual representation which
emphasizes its five-fold symmetry. The picture on the right highlights
the fact that the Petersen graph also has a three-fold symmetry. Label
the right-hand diagram using the same letters (A through J) in order
to show that these two representations are truly isomorphic.
F
E B
J G
I H
D C
5. We will use the symbol Z∗ to refer to the set of all integers except 0.
Define a relation Q on the set of all pairs in Z × Z∗ (pairs of integers
where the second coordinate is non-zero) by (a, b)Q(c, d) ⇐⇒ ad =
bc. Show that Q is an equivalence relation.
6.3. EQUIVALENCE RELATIONS 147
6. The relation Q defined in the previous problem partitions the set of all
pairs of integers into an interesting set of equivalence classes. Explain
why
Q = (Z × Z∗ )/Q.
7. Reflect back on the proof in problem 5. Note that we were fairly careful
in assuring that the second coordinate in the ordered pairs is non-zero.
(This was the whole reason for introducing the Z∗ notation.) At what
point in the argument did you use this hypothesis?
148 CHAPTER 6. RELATIONS AND FUNCTIONS
Fox Alligator
Cow
Duck Robin
Goose
Grass Worms
1. An (non-maximal) an-
tichain a. Grass
6.5 Functions
Exercises — 6.5
1. For each of the following functions, give its domain, range and a possible
codomain.
(b) g(x) = ex
(c) h(x) = x2
x2 +1
(d) m(x) = x2 −1
2. Find a bijection from the set of odd squares, {1, 9, 25, 49, . . .}, to the
non-negative integers, Znoneg = {0, 1, 2, 3, . . .}. Prove that the function
you just determined is both injective and surjective. Find the inverse
function of the bijection above.
154 CHAPTER 6. RELATIONS AND FUNCTIONS
Z x
1
ln(x) = dt.
t=1 t
ln(ab ) = b ln(a)
Use the above information to show that there is neither an upper bound
nor a lower bound for the values of the natural logarithm. These facts
together with the information that ln is strictly increasing show that
Rng(ln) = R.
6.5. FUNCTIONS 155
0 1 2 3 4 5 6 7 8
1 0/1 1/1 2/1 3/1 4/1 5/1 6/1 7/1 8/1
2. The usual algebraic procedure for inverting T (x) = (x2 +x)/2 fails. Use
your knowledge of the geometry of functions and their inverses to find
a formula for the inverse. (Hint: it may be instructive to first invert
the simpler formula S(x) = x2 /2 — this will get you the right vertical
scaling factor.)
3. What is π2 (W (t))?
10
X 1
· [i is prime].
i=1
i
160 CHAPTER 6. RELATIONS AND FUNCTIONS
Chapter 7
7.1 Counting
1. Determine the number of entries in the following sequences.
161
162 CHAPTER 7. PROOF TECHNIQUES III — COMBINATORICS
2. How many “full houses” are there in Yahtzee? (A full house is a pair
together with a three-of-a-kind.)
n+k−1 n+k−1
4. Prove that the binomial coefficients and are
k n−1
equal.
164 CHAPTER 7. PROOF TECHNIQUES III — COMBINATORICS
6. How many “words” are there of length 4, with distinct letters from the
Cryptographer’s alphabet, in which the letters appear in increasing
order alphabetically? (“Acef” would be one such word, but “cafe”
would not.)
10. How many functions are there from a set of size n to a set of size m?
11. How many relations are there from a set of size n to a set of size m?
166 CHAPTER 7. PROOF TECHNIQUES III — COMBINATORICS
2. Complete the proof of the fact that “Every graph has an even number
of odd nodes.”
5. The five tetrominoes (familiar to players of the video game Tetris) are
relatives of dominoes made up of four small squares.
1. The statement that there are two non-bald New Yorkers with the same
number of hairs on their heads requires some careful estimates to justify
it. Please justify it.
2. A mathematician, who always rises earlier than her spouse, has de-
veloped a scheme – using the pigeonhole principle – to ensure that
she always has a matching pair of socks. She keeps only blue socks,
green socks and black socks in her sock drawer – 10 of each. So as
not to wake her husband she must select some number of socks from
her drawer in the early morning dark and take them with her to the
adjacent bathroom where she dresses. What number of socks does she
choose?
7.3. THE PIGEONHOLE PRINCIPLE 173
4. Given any set of 53 integers, show that there are two of them having
the property that either their sum or their difference is evenly divisible
by 103.
174 CHAPTER 7. PROOF TECHNIQUES III — COMBINATORICS
5. Prove that if 10 points are placed inside a square of side length 3, there
√
will be 2 points within 2 of one another.
3. Find (x2 + y 2 )6 .
7.4. THE ALGEBRA OF COMBINATIONS 177
1 1
1
2 1
1
2
2 1
3 1
3
1 3
6
3 3
3 1
combinatorially.
n
n
X n n−k k
∀n ∈ N, ∀x, y ∈ R, (x + y) = x y
k=0
k
Chapter 8
Cardinality
179
180 CHAPTER 8. CARDINALITY
(x − a)(d − c)
2. Prove that f (x) = c + provides a bijection from the
(b − a)
interval [a, b] to the interval [c, d].
182 CHAPTER 8. CARDINALITY
3. Prove that any two circles are equinumerous (as sets of points).
6. Verify that the final deduction in the proof of Cantor’s theorem, “(y ∈
S =⇒ y ∈
/ S) ∧ (y ∈
/ S =⇒ y ∈ S),” is truly a contradiction.
8.4. DOMINANCE 187
8.4 Dominance
Exercises — 8.4
a
4. We can inject Q into Z by sending ± to ±2a 3b . Use this and an-
b
other obvious injection to (in light of the C-B-S theorem) reaffirm the
equivalence of these sets.
Chapter 9
1. What value should we get if we sum all of the angles that appear around
one of the interior vertices in the finished diagram? Verify that all three
have the correct sum.
c c c
b⋆⋆ a⋆ b⋆ a⋆⋆
c⋆ c⋆
b ⋆ a⋆
c⋆⋆ b
a
a b
a b
189
190 CHAPTER 9. PROOF TECHNIQUES IV — MAGIC
1. Do the algebra (and show all your work!) to prove that invariant de-
fined in this section actually has the value 1 for the set of all the men
occupying the x-axis and the lower half-plane.
192 CHAPTER 9. PROOF TECHNIQUES IV — MAGIC
1. There is a scenario where the proof we have sketched for Monge’s circle
theorem doesn’t really work. Can you envision it? Hint: consider two
relatively large spheres and one that is quite small.