0% found this document useful (0 votes)
19 views25 pages

Numbers and Proofs

Chapter 4 of Math 161: Discrete Mathematics covers number theory and methods of proof, including direct proofs, indirect arguments, and the concept of parity. It discusses various mathematical claims and theorems, providing examples and exercises related to proofs by contradiction and unique factorization. The chapter emphasizes the importance of proving properties of integers and the existence of certain numbers through constructive and non-constructive methods.

Uploaded by

Besu Winner
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views25 pages

Numbers and Proofs

Chapter 4 of Math 161: Discrete Mathematics covers number theory and methods of proof, including direct proofs, indirect arguments, and the concept of parity. It discusses various mathematical claims and theorems, providing examples and exercises related to proofs by contradiction and unique factorization. The chapter emphasizes the importance of proving properties of integers and the existence of certain numbers through constructive and non-constructive methods.

Uploaded by

Besu Winner
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 25

Math 161: Discrete Mathematics

Chapter 4

S. T. Woldeamanuel
BITS College

S. T. Woldeamanuel (BITS College) Math 161 2023 1 / 25


Table of Contents

1 Number theory & Methods of Proof


Direct proofs and counter examples
Indirect Argument: -contradiction and contraposition

S. T. Woldeamanuel (BITS College) Math 161 2023 2 / 25


Table of Contents

1 Number theory & Methods of Proof


Direct proofs and counter examples
Indirect Argument: -contradiction and contraposition

S. T. Woldeamanuel (BITS College) Math 161 2023 3 / 25


Basic definitions:Parity

An integer n is called even if, and only if, there exists an integer k
such that n = 2k. An integer n is called odd if, and only if, it is not
even.
Remark
An integer n is called odd if, and only if, there exists an integer k
such that n = 2k + 1.
The property of an integer as being either odd or even is known as its
parity.

S. T. Woldeamanuel (BITS College) Math 161 2023 4 / 25


Arguing the positive: Universal Statements

Consider the statement: ’The sum of an odd and an even integer is


odd.’
Proof.
Let n be any odd integer and and m be an even integer. Then,

∃k ∈ Z, n = 2k + 1 (1)

∃l ∈ Z, m = 2l (2)
By (1) and (2), we have that n + m = 2k + 1 + 2l = 2(k + l) + 1.
Set k + l = r . r ∈ Z. So, n + m = 2r + 1, showing that n + m is
odd.

S. T. Woldeamanuel (BITS College) Math 161 2023 5 / 25


The above is an example of a direct proof.
You start with some given conditions, and then use appropriate
definitions, previously established facts, axioms etc, to arrive at the
conclusion.
Remark
Notice that in the proof we used n = 2k + 1 and m = 2l. This is
important.
If use n = 2k + 1 and m = 2k, that makes m and n conscutive,
which is not the intention of the original statement.

S. T. Woldeamanuel (BITS College) Math 161 2023 6 / 25


Statements of claims / theorems

Mathematical claims and theorems can be stated in various different


ways!
’The sum of an odd and an even integer is odd.’
’Any two integers of opposite parity sum to an odd number’
’Every pair of integers of opposite parity sums to an odd number’
∀n, m ∈ Z, n = 2k + 1, m = 2l ⇒ n + m = 2(k + l) + 1

S. T. Woldeamanuel (BITS College) Math 161 2023 7 / 25


Prove the following

1 The square of an odd integer is also odd.


2 If a is an integer, then a 2 + a is even.

S. T. Woldeamanuel (BITS College) Math 161 2023 8 / 25


Arguing the affirmative of existential statements

Two methods: Constructive and Non-Constructive


In ’constructive’ proofs we either explicitly show or construct an
element of the domain that answers our query.
In non-constructive proofs (very rare in this class) we prove that it is
a logical necessity for such an element to exist!
But we neither explicitly, nor implicitly, show or construct such an
element!

S. T. Woldeamanuel (BITS College) Math 161 2023 9 / 25


Our first constructive proof
Claim: There exists a natural number that cannot be written as a
sum of three squares of natural numbers.
(Example you can write as a sum of three squares: 14 = 12 + 22 + 32 )
Try to find a number that cannot be written as such.
Proof.
The natural number 7 cannot be written as the sum of three squares.
This we can prove by case analysis:
Can’t use 3, since 32 = 9 > 7.
Can’t use 2 more than once, since 22 + 22 = 8 > 7
So, we may use 2, one or zero times. If we use 2 once, we have
7 = 22 + a 2 + b 2 ≤ 6 < 7 (a 2 + b 2 = 12 + 12 = 2.)
If we use 2 zero times, the maximum value is
12 + 12 + 12 = 3 < 7

S. T. Woldeamanuel (BITS College) Math 161 2023 10 / 25


Prove the following

1 There exists an integer n that can be written in two ways as a


sum of two prime numbers.
2 There is a perfect square that can be written as a sum of two
other perfect squares.
3 Suppose r , s ∈ Z. Then, (∃k ∈ Z)[22r + 18s = 2k]
4 There exists an integer n that can be written in two ways as a
sum of two cubed integers. (Hard). 1729: Ramanujan, Hardy,

S. T. Woldeamanuel (BITS College) Math 161 2023 11 / 25


Non-constructive proof

Theorem: There exists a pair of irrational numbers a and b such


that a b is a rational number.
Proof.
√ √ √ √2
Let a √= b = 2. 2 is irrational. Is a = 2 rational? Two cases:
b
√ 2 √
If 2√ is rational, then Taking a = b = 2, we are done.
√ 2 √
If 2 is irrational, then we√ will name it c. Then, observe that c 2
√ √ 2 √ √ 2
is rational, since c√2 = ( 2 ) 2 = 2 = √
2.
Since both c and 2 are irrationals, but c is rational, we are done.
2

Take it as a given (for now) that root of 2 is irrational.

S. T. Woldeamanuel (BITS College) Math 161 2023 12 / 25


Divisibility

Definition
Let n, d ∈ Z and d 6= 0 . Then, we say or denote any one of the
following: d divides n,
n is divided by d,
d|n,
d is a divisor (or factor) of n,
n is a multiple of d or
n ≡ 0( mod d) if, and only if, ∃k ∈ Z[n = dk].
We sometimes call k the quotient of the division of n by d.
If d does not divide n, we denote that by d - n

S. T. Woldeamanuel (BITS College) Math 161 2023 13 / 25


Answer Yes or No
1 3|6
2 6|3
3 10|10
4 5|0
5 ∀p, p prime, 2 - p
6 @n ∈ N, n odd such that n|0

S. T. Woldeamanuel (BITS College) Math 161 2023 14 / 25


Sum Rule

Prove that ∀a, b ∈ Z, [((a 6= 0) ∧ a|b ∧ a|c) ⇒ a|(b + c)]

Proof.
a|b ⇒ ∃r ∈ Z such that b = ra
a|c ⇒ ∃s ∈ Z such that c = sa
Hence, we have that b + c = ar + as = a(r + s).
So, a|(b + c).

S. T. Woldeamanuel (BITS College) Math 161 2023 15 / 25


Proof by contradiction

Sometimes, proving a fact directly is tough. In such cases, we can


attempt an indirect proof.
The most common type of indirect proof is proof by contradiction.
Briefly: We want to prove a fact a, so we assume ¬a and hope that
we reach a contradiction (a falsehood).

Example
Show that if a prime number p divides an integer a, it cannot
possibly divide a + 1.

S. T. Woldeamanuel (BITS College) Math 161 2023 16 / 25


Proof by contradiction

Proof.
Suppose on the contrary p|(a + 1).
Then, this means that ∃r ∈ Z such that a + 1 = rp.
We already know that p|a which means that ∃s ∈ Z such that
a = sp.
But then, a + 1 = rp gives ps = a = rp − 1 and that gives us p|1
which is a contradiction.
Therefore, p - (a + 1).

S. T. Woldeamanuel (BITS College) Math 161 2023 17 / 25


The well ordering Axiom
Every non-empty subset of the set of natural numbers has a smallest
or least element.
Using this property show that:
Any composite integer n > 1 is divisible by a prime number.

S. T. Woldeamanuel (BITS College) Math 161 2023 18 / 25


Proof.
Suppose n is composite.
Let F = {m : m > 1 and m|n}. Then since n|n and n > 1, n ∈ F .
So, F 6= ∅.
Hence, by the WOA, ∃p ∈ F such that p > 1 and p|n, which is the
least element.
Claim that p is prime. Suppose not! Then ∃q, r such that
1 < q < p; 1 < r < p such that p = qr .
but then, q|p and p|n, which implies q|n. Contradiction to the fact
that p is the least element.
Therefore, p is prime.

S. T. Woldeamanuel (BITS College) Math 161 2023 19 / 25



If n is composite then there is a prime p such that p ≤ n and p|n

Proof.
Suppose n is composite. Then r , s such that 1 < r < n, 1 < s < n
and n = rs.√ √
Claim s ≤ n or r ≤ n. √ √
Suppose not! Then s > n and r > n, which leads to the
contradiction n > n.√
So WLOG, let s ≤ n. Now if s is prime we are done.
Otherwise, by the previous result s has one prime
√ divisor, say p.
But, then p|s and hence p|n. Not that p ≤ n.

Note: use the contrapositive of the fact to check primality

S. T. Woldeamanuel (BITS College) Math 161 2023 20 / 25


Example
There are infinite primes.

Proof.
Assume that the primes are finite. Then, we can list them in
ascending order: p1 , p2 , · · · , pn .
Consider the number N = p1 p2 · · · pn + 1. Clearly, N is bigger than
any pi . We have two cases:
N is prime. Contradiction, since N is bigger than any prime. N is
composite. This means that N has at least one factor q > 1.
Let’s take the smallest factor of N, and call it qmin . Then, this
number is prime (why?)
Since qmin is prime, it divides p1 p2 · · · pn . By the previous example,
this means that it cannot possibly divide N = p1 p2 · · · pn + 1.
Contradiction, since we assumed that qmin is a factor of N.
Therefore, the primes are not finite.
S. T. Woldeamanuel (BITS College) Math 161 2023 21 / 25
Proofs by contrapositive

Applicable to all kinds of statements of type: ∀x ∈ A, P(x) ⇒ Q(x).


You use it when proving the implication is harder than proving its
contrapositive: ∀x ∈ A, ¬Q(x) ⇒ ¬P(x).

Example
Show that for any n, if n2 is even then n is even

Proof.
Prove the contrapositive.

S. T. Woldeamanuel (BITS College) Math 161 2023 22 / 25


Indirect Argument Two classical theorems


Prove that 2 is irrational
Proof.

Let’s assume BY WAY OF CONTRADICTION that 2 is rational.
√ a
So 2 = , a, b ∈ Z, b 6= 0 and GCD(a, b) = 1.
b
So, a 2 = 2b 2 . which gives us 2|a. Hence there exists k ∈ Z, such
that a = 2k.
But then a 2 = 4k 2 = 2b 2 which gives us 2|b 2 . From this we get 2|b.
So both a and b are both even, and have common factor of 2.
Contradiction.

Exercise: Proof that 5 is irrational.

S. T. Woldeamanuel (BITS College) Math 161 2023 23 / 25


Unique Factorization Theorem

Example
91 = 71 × 131
There is no other way to factor 91 into a product of primes.
18 = 21 × 32
Once again, no other way to factor 18 into a product of primes.
7 = 71
Since 7 is prime, there is trivially no other way to factor it into primes.
1000 = 23 × 53
1027: prime or not?
1049= (1049 is prime)

S. T. Woldeamanuel (BITS College) Math 161 2023 24 / 25


(UFT) Every number n ∈ N, n ≥ 2 can be uniquely factored into a
product of prime numbers p1 , p2 , · · · pk like so:
n = p1e1 p2e2 · · · pkek , ei ≥ 1

S. T. Woldeamanuel (BITS College) Math 161 2023 25 / 25

You might also like