01. Logic
01. Logic
01. Logic
Worksheet 1 :
Mathematical logic and mathematical reasoning
Exercise 1.
1. Give two statements P and Q such that
(a) P =⇒ Q is true and Q =⇒ P is true.
(b) P =⇒ Q is true and Q =⇒ P is false.
(c) P =⇒ Q is false and Q =⇒ P true.
2. Is it possible to find two statements P and Q such that P =⇒ Q is false and Q =⇒ P is false ?
Exercise 2.
Let P , Q and R be three statements.
1. Show the following compound statements are logically equivalent by using two different methods.
Exercise 3.
Give the logical relationships between the following statements
Exercise 4.
1. Let f : R → R be a map. Using the syntax of the predicates write the following sentences and then
give their negation.
1
(k) f is periodic. (o) f is not constant.
(l) f is strictly increasing.
(m) f possesses a maximum. (p) f never has the same values at two different
(n) f does not vanish on R. points.
2. Using the syntax of the predicates write the following sentences and then give their negation.
(a) The square of any real number is positive or zero.
(b) Any positive integer is the sum of three squares.
(c) For any real number, we can find a real number such that their product is greater than 1.
(d) Any nonempty part of N admits a smallest element.
Exercise 5.
Say if the following statements are true or false and write their negation.
Exercise 6.
1. Prove that
n
n(n + 1)(2n + 1) n
1 √
k2 =
P P
(a) . (d) √ < 2 n.
k=1
6 k=1 k
n
n2 (n + 1)2 (e) ∀n ∈ N, 2n−1 ≤ n! ≤ nn .
k3 =
P
(b) .
k=1
4 n−1
(f ) ∀n ∈ N, an − bn = (a − b) ak bn−1−k , where
P
n
P 1 n k=0
(c) = . a, b ∈ C.
k=1
k(k + 1) n+1
2
(c) Every positive integer can be written as a product of prime factors, and this product is unique
up to reordering of the factors.
Exercise 7. n
X 1
For any integer n ≥ 2, let Hn := . Hn is called the n-th harmonic number. The goal of this exercise
k=1
k
is to show that Hn isn’t an integer for n ≥ 2.
1. Show that for any positive integer m, there exist a positive integer a and nonnegative integer b such
1 a
that H2m = Hm + .
2 2b + 1
2. Using induction, show that for any integer n ≥ 2, Hn is a quotient of an odd integer and an even
integer.
3. Deduce that Hn is not an integer for n ≥ 2.
Exercise 8.
1. Using the proof by contrapositive, show that the following statements are true.
(a) For n ∈ N, if 3n2 + n + 2 is odd then n is odd.
(b) If a2 is not an integer multiple of 16, then a/2 is not an even integer.
(c) For two positive integers a and n, if an − 1 is a prime number, then a = 2 and n is a prime
number.
x y
(d) ∀x ∈ R, ∀y ∈ R, if xy ̸= 1 and x ̸= y, then 2 ̸= 2 .
x +x+1 y +y+1
2. Using the proof by contradiction, show that the following statements are true.
√
(a) ∀n ∈ N, n2 + 1 ∈ / N.
(b) If a, b ∈ Z, then a2 − 4b − 2 ̸= 0.
(c) If a, b, c ∈ Z such that a2 + b2 = c2 , then a or b is even.
√
(d) p ∈ / Q, for any prime number p.
√ √
(e) 2 + 3 ∈ / Q.
ln 2
(f ) ∈/ Q.
ln 3
(g) cos 1◦ ∈ / Q.
(h) Let p1 , p2 , . . . , pr be prime numbers. The integer N = p1 p2 . . . pr + 1 is not divisible by any of the
integers pi .
Exercise 9.
Find two irrational numbers a, b such that ab is a rational number.
Exercise 10.
1. Find all maps f : N0 −→ N0 that satisfy, f (n + m) = f (n) + f (m) for all nonnegative integers n
and m.
2. Find all maps g : N0 −→ N0 that satisfy, g(n + m) = g(n) × g(m) for all nonnegative integers n
and m.
3. Find all functions h : R −→ R that satisfy, for all x, y ∈ R, h(y − h(x)) = 2 − x − y.