0% found this document useful (0 votes)
74 views171 pages

Number Theory 1

Uploaded by

Rio Takashi
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)
74 views171 pages

Number Theory 1

Uploaded by

Rio Takashi
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/ 171

Holy Cross College of Calinan

Datu Abeng St. Calinan, Davao City

Number Theory

Mr. Raffy S. Centeno


College Instructor
Outline

1. Divisibility
The Division Algorithm
Divisibility
Greatest Common Divisor
Euclidean Algorithm
Least Common Multiples
Bezout’s Identity
Linear Diophantine Equations
Application of Linear Diophantine Equations
Outline

2. Prime Numbers
The Fundamental Theorem of Arithmetic

3. Congruences
Basic Properties of Congruence
Special Divisibility Tests
Linear Congruences
Chinese Remainder Theorem
Outline
4. Congruences with a Prime-power Modulus
The Arithmetic of Zp
Pseudoprimes and Carmichael Numbers
Solving Congruences mod (pe )
5. Euler’s Function
Units
Euler’s Function
Applications of Euler’s Function
6. Bibliography
Chapter I
Divisibility
The Division Algorithm
Theorem 1.1
The Division Algorithm
Given a, b ∈ Z with b > 0, ∃ unique q, r ∈ Z satisfying

a = qb + r 0≤r<b

The integers q and r are called, respectively, the quotient and re-
mainder in the division of a by b.
Example 1.1
Identify the values of q and r if

a = 9 and b = 2
Example 1.1
Identify the values of q and r if

a = 9 and b = 2

Answer

q = 4 and r = 1
Example 1.2
Identify the values of q and r if

a = 1, 397 and b = 37
Example 1.2
Identify the values of q and r if

a = 1, 397 and b = 37

Answer

q = 37 and r = 28
Example 1.3
Identify the values of q and r if

a = x3 − 12x2 + 38x − 17 and b = x − 7

where x ∈ Z
Example 1.3
Identify the values of q and r if

a = x3 − 12x2 + 38x − 17 and b = x − 7

where x ∈ Z

Answer

q = x2 − 5x + 3 and r = 4
Example 1.4
Identify the values of q and r if

a = 2x4 − 21x2 + 9x − 1 and b = x2 + x − 3

where x ∈ Z
Example 1.4
Identify the values of q and r if

a = 2x4 − 21x2 + 9x − 1 and b = x2 + x − 3

where x ∈ Z

Answer

q = 2x2 − 2x − 13 and r = 16x − 40


Example 1.5
Identify the values of q and r if

a = 21, 897, 845 and b = 1, 625


Example 1.5
Identify the values of q and r if

a = 21, 897, 845 and b = 1, 625

Answer

q = 13, 475 and r = 970


Divisibility
Definition
An integer b is said to be divisible by a ∈ Z and a 6= 0, in symbols
a|b, if ∃ c ∈ Z such that

b = ac

We write a 6 | b to indicate that b is not divisible by a.


Theorem 1.2
The following statements hold ∀ a, b, c ∈ Z:

I a|0, 1|a, a|a


I a|1 if and only if a = ±1
I if a|b and c|d, then ac|bd
I if a|b and b|c, then a|c
I a|b and b|a if and only if a = ±b
I If a|b and b 6= 0, then |a| ≤ |b|
I If a|b and a|c, then a|(bx + cy) for arbitrary x, y ∈ Z
Greatest Common Divisor
Definition
Suppose a, b ∈ Z, with at least one of the different from zero. The
greatest common divisor of a and b, denoted by gcd(a, b), is d ∈
Z+ satisfying

I d|a and d|b


I if c|a and c|b, then c ≤ d.
Example 1.6
Identify the GCD of the following numbers

36 and 42
Example 1.6
Identify the GCD of the following numbers

36 and 42

Answer

gcd(36, 42) = 6
Example 1.7
Identify the GCD of the following numbers

−12 and 30
Example 1.7
Identify the GCD of the following numbers

−12 and 30

Answer

gcd(−12, 30) = 6
Example 1.8
Identify the GCD of the following numbers

−5 and 5
Example 1.8
Identify the GCD of the following numbers

−5 and 5

Answer

gcd(−5, 5) = 5
Example 1.9
Identify the GCD of the following numbers

8 and 17
Example 1.9
Identify the GCD of the following numbers

8 and 17

Answer

gcd(8, 17) = 1
Example 1.10
Identify the GCD of the following numbers

−8 and −36
Example 1.10
Identify the GCD of the following numbers

−8 and −36

Answer

gcd(−8, −36) = 4
Euclidean Algorithm
Definition
Euclidean Algorithm is a way to find the greatest common divisor
of a, b ∈ Z+ .

Process:
Input: Two positive integers, a and b
Output: gcd(a, b)
Algorithm:
I If a < b, exchange a and b

I Divide a by b and get the remainder, r. If r = 0, report


gcd(a, b) = b
I Replace a and b with b and r, respectively. Return to the previ-

ous step.
Example 1.11
Using the Euclidean Algorithm, identify the GCD of the following
numbers

36 and 42
Example 1.11
Using the Euclidean Algorithm, identify the GCD of the following
numbers

36 and 42

Answer

gcd(36, 42) = 6
Example 1.12
Using the Euclidean Algorithm, identify the GCD of the following
numbers

143 and 227


Example 1.12
Using the Euclidean Algorithm, identify the GCD of the following
numbers

143 and 227

Answer

gcd(143, 227) = 1
Example 1.13
Using the Euclidean Algorithm, identify the GCD of the following
numbers

306 and 657


Example 1.13
Using the Euclidean Algorithm, identify the GCD of the following
numbers

306 and 657

Answer

gcd(306, 657) = 9
Example 1.14
Using the Euclidean Algorithm, identify the GCD of the following
numbers

272 and 1479


Example 1.14
Using the Euclidean Algorithm, identify the GCD of the following
numbers

272 and 1479

Answer

gcd(272, 1479) = 17
Example 1.15
Using the Euclidean Algorithm, identify the GCD of the following
numbers

12, 378 and 3054


Example 1.15
Using the Euclidean Algorithm, identify the GCD of the following
numbers

12, 378 and 3054

Answer

gcd(12378, 3054) = 6
Least Common Multiples
Definition
The least common multiple of a, b ∈ Z\{0}, denoted by lcm(a, b),
is m ∈ Z+ satisfying
I a|m and b|m; and

I if a|c and b|c, with c > 0, then m ≤ c.


Theorem 1.3
∀ a, b ∈ Z+
ab
lcm(a, b) =
gcd(a, b)
Example 1.16
Identify the LCM of the following numbers

56 and 75
Example 1.16
Identify the LCM of the following numbers

56 and 75

Answer

lcm(56, 75) = 4200


Example 1.17
Identify the LCM of the following numbers

24 and 138
Example 1.17
Identify the LCM of the following numbers

24 and 138

Answer

lcm(24, 138) = 552


Example 1.18
Identify the LCM of the following numbers

119 and 272


Example 1.18
Identify the LCM of the following numbers

119 and 272

Answer

lcm(119, 272) = 1904


Example 1.19
Identify the LCM of the following numbers

1769 and 2378


Example 1.19
Identify the LCM of the following numbers

1769 and 2378

Answer

lcm(1769, 2378) = 4206682


Example 1.20
Identify the LCM of the following numbers

58745 and 2755


Example 1.20
Identify the LCM of the following numbers

58745 and 2755

Answer

lcm(58745, 2755) = 32368495


Bezout’s Identity
Theorem 1.4
Bezout’s Identity
Given a, b ∈ Z\{0}, ∃ x, y ∈ Z such that

gcd(a, b) = ax + by
Definition
The Extended Euclidean Algorithm is an algorithm that computes
x, y ∈ Z such that

gcd(a, b) = ax + by

given a, b ∈ Z. NOTE: We can apply Elementary Matrix Operations


to solve for the linear combination.
Example 1.21
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(56, 72) = 56x + 72y


Example 1.21
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(56, 72) = 56x + 72y

Answer

x=4 ; y = −3
Example 1.22
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(24, 138) = 24x + 138y


Example 1.22
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(24, 138) = 24x + 138y

Answer

x=6 ; y = −1
Example 1.23
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(119, 272) = 119x + 272y


Example 1.23
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(119, 272) = 119x + 272y

Answer

x=7 ; y = −3
Example 1.24
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(1769, 2378) = 1769x + 2378y


Example 1.24
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(1769, 2378) = 1769x + 2378y

Answer

x = 39 ; y = −29
Example 1.25
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(58745, 2755) = 58745x + 2755y


Example 1.25
Use the Euclidean Algorithm to obtain x, y ∈ Z satisfying

gcd(58745, 2755) = 58745x + 2755y

Answer

x = −65 ; y = 1386
Linear Diophantine Equations
Definition
A Diophantine equation is an equation in which only integer solu-
tions are allowed.

Theorem 1.5
The Linear Diophantine Equation ax + by = c has a solution if
and only if d|c, where d = gcd(a, b) If x0 and y0 is any particular
solution of this equation, then all other solutions are given by
bt at
x = x0 + and y = y0 −
d d
such that t ∈ Z
Example 1.26
Determine all the solutions in the integers of the following Diophan-
tine Equations:

172x + 20y = 1000


Example 1.26
Determine all the solutions in the integers of the following Diophan-
tine Equations:

172x + 20y = 1000

Answer

x = 500 + 5t and y = −4250 − 43t


Example 1.27
Determine all the solutions in the integers of the following Diophan-
tine Equations:

221x + 91y = 117


Example 1.27
Determine all the solutions in the integers of the following Diophan-
tine Equations:

221x + 91y = 117

Answer

x = −18 + 7t and y = 45 − 17t


Example 1.28
Determine all the solutions in the non-negative integers of the fol-
lowing Diophantine Equations:

30x + 17y = 300


Example 1.28
Determine all the solutions in the non-negative integers of the fol-
lowing Diophantine Equations:

30x + 17y = 300

Answer

x = 2390 and y=0


Example 1.29
Determine all the solutions in the positive integers of the following
Diophantine Equations:

54x + 21y = 906


Example 1.29
Determine all the solutions in the positive integers of the following
Diophantine Equations:

54x + 21y = 906

Answer

x = 604 + 7t and y = −1510 − 18t


−86.29 < t < −82.89 such that t ∈ Z
Example 1.30
Determine all the solutions in the positive integers of the following
Diophantine Equations:

123x + 360y = 99
Example 1.30
Determine all the solutions in the positive integers of the following
Diophantine Equations:

123x + 360y = 99

Answer

No solution such that x, y ∈ Z+


Application of Linear Diophantine
Equations
Example 1.31
A customer bought a dozen pieces of fruit, apples and oranges, for
$ 1.32. If an apple costs 3 cents more than an orange and more
apples than oranges were purchased, how many pieces of each kind
were bought?
Example 1.31
A customer bought a dozen pieces of fruit, apples and oranges, for
$ 1.32. If an apple costs 3 cents more than an orange and more
apples than oranges were purchased, how many pieces of each kind
were bought?

Answer

1 dozen of apples or 8 apples and 4 oranges.


Example 1.32
How many ways are there to make $2.00 from only nickels and quar-
ters?
Example 1.32
How many ways are there to make $2.00 from only nickels and quar-
ters?

Answer

There are 9 ways.


Example 1.33
Travis is purchasing beverages for an upcoming party. He has $68
to spend. He can purchase packs of cans for $12, or smaller packs
of bottles for $8.00. How many ways are there for him to purchase
beverages if he spends all of his money?
Example 1.33
Travis is purchasing beverages for an upcoming party. He has $68
to spend. He can purchase packs of cans for $12, or smaller packs
of bottles for $8.00. How many ways are there for him to purchase
beverages if he spends all of his money?

Answer

Therefore, if Travis spends all his money, there are 3 ways he could
purchase beverages for the party.
Example 1.34
Clara wants to buy pizza and cola to her family. She has 400 php.
If we know that each pizza 57 php and each bottle of cola cost 22
php, how many pizzas and bottles of cola she can buy?
Example 1.34
Clara wants to buy pizza and cola to her family. She has 400 php.
If we know that each pizza 57 php and each bottle of cola cost 22
php, how many pizzas and bottles of cola she can buy?

Answer

She can buy 2 pizza and 13 bottles of cola.


Chapter II
Prime Numbers
The Fundamental Theorem of Arithmetic
Definition
An integer p > 1 is called a prime number, or simple a prime, if its
only positive divisors are 1 and p. An integer greater than 1 which
is not a prime is termed composite.
Theorem 2.1
If p is a prime and p | ab, then

p | a or p | b

Corollary 1
If p is a prime and p | a1 · a2 · ... · an , then

p | ak

for some k, where 1 ≤ k ≤ n.


Corollary 2
If p, q1 , q2 , ..., qn are all primes and p | q1 · q2 · ... · qn , then

p = qk

for some k, where 1 ≤ k ≤ n.


Theorem 2.2
Fundamental Theorem of Arithmetic

Every positive integer n > 1 can be expressed as a product of primes;


this representation is unique, apart from the order in which the factors
occurs.
Corollary 1
Any positive integer n > 1 can be written uniquely in a canonical
form

n = pk11 · pk22 · ... · pkr r

where, for i = 1, 2, ..., r, each k1 is a positive integer and each pi is


a prime, with p1 < p2 < ... < pr .
Definition
A composite number a will always possess a prime divisor p satisfying

p≤ a
Example 2.1
Express the given number in its canonical form

360
Example 2.1
Express the given number in its canonical form

360

Answer

23 · 32 · 5
Example 2.2
Express the given number in its canonical form

4725
Example 2.2
Express the given number in its canonical form

4725

Answer

33 · 52 · 7
Example 2.3
Express the given number in its canonical form

17460
Example 2.3
Express the given number in its canonical form

17460

Answer

23 · 32 · 5 · 72
Example 2.4
Express the given number in its canonical form

2093
Example 2.4
Express the given number in its canonical form

2093

Answer

7 · 13 · 23
Example 2.5
Express the given number in its canonical form

3528
Example 2.5
Express the given number in its canonical form

3528

Answer

23 · 32 · 72
Chapter III
Congruences
What day of the week will it be 100 days from now?
Basic Properties of Congruence
Definition
Let n be a fixed positive integer. Two integers a and b are said to
be congruent modulo n, symbolized by

a ≡ b (mod n)

if n divides the difference a − b; that is provided that a − b = kn for


some k ∈ Z
Theorem 3.1
For arbitrary a, b ∈ Z

a ≡ b (mod n)

if and only if a and b leave the same nonnegative remainder when


divided by n.
Example 3.1

29 ≡ 8 (mod 7)
Example 3.1

29 ≡ 8 (mod 7)

Example 3.2

60 ≡ 0 (mod 15)
Example 3.3

15 ≡ 3 (mod 4)
Example 3.3

15 ≡ 3 (mod 4)

Example 3.4

10 ≡ 15 (mod 5)
Example 3.5
Consider n = 3, that is Z3 :

[0] = {..., −6, −3, 0, 3, 6, ...}


[1] = {..., −5, −2, 1, 4, 7, ...}
[2] = {..., −4, −1, 2, 5, 8, ...}
Theorem 3.2
Let n > 0 be fixed and a, b, c, d be arbitrary integers. Then the
following properties hold:
I a ≡ a (mod n)

I If a ≡ b (mod n), then b ≡ a (mod n)

I If a ≡ b (mod n) and b ≡ c (mod n), then a ≡ c (mod n)

I If a ≡ b (mod n) and c ≡ d (mod n), then a + c ≡ b + d

(mod n) and ac ≡ bd (mod n)


I If a ≡ b (mod n), then a + c ≡ b + c (mod n) and ac ≡ bc

(mod n)
I If a ≡ b (mod n), then ak ≡ bk (mod n) for any k ∈ Z+
Example 3.6
Show that

41 divides 220 − 1
Example 3.7
Show that

89 divides 244 − 1
Example 3.8
Show that

97 divides 248 − 1
Example 3.9
If divided by 12, what is the remainder of

1! + 2! + 3! + ... + 99! + 100!


Example 3.9
If divided by 12, what is the remainder of

1! + 2! + 3! + ... + 99! + 100!

Answer

The remainder is 9.
Example 3.10
If divided by 7, what is the remainder of

250
Example 3.10
If divided by 7, what is the remainder of

250

Answer

The remainder is 4.
Example 3.11
If divided by 7, what is the remainder of

4165
Example 3.11
If divided by 7, what is the remainder of

4165

Answer

The remainder is 6.
Example 3.12
Find the value of k such that k ∈ Z and 0 ≤ k ≤ 11 if

k ≡ 37453 (mod 12)


Example 3.12
Find the value of k such that k ∈ Z and 0 ≤ k ≤ 11 if

k ≡ 37453 (mod 12)

Answer

k=1
Example 3.13
Find the value of k such that k ∈ Z and 0 ≤ k ≤ 6 if

250 ≡ k (mod 7)
Example 3.13
Find the value of k such that k ∈ Z and 0 ≤ k ≤ 6 if

250 ≡ k (mod 7)

Answer

k=4
Example 3.14
Find the value of k such that k ∈ Z and 0 ≤ k ≤ 11 if

39453 ≡ k (mod 1)2


Example 3.14
Find the value of k such that k ∈ Z and 0 ≤ k ≤ 11 if

39453 ≡ k (mod 1)2

Answer

k=3
Example 3.15

What day of the week will it be 1000 days from now?


Special Divisibility Tests
Definition
Given an integer b > 1, any positive integer N can be written
uniquely in terms of powers of b as

N = am bm + am−1 bm−1 + ... + a2 b2 + a1 b + a0

where the coefficients ak can take on the b different values 0, 1, 2, ...,


b−1
Example 3.15
The number 1256 can be expressed as

1256 = 1 · 103 + 2 · 102 + 5 · 10 + 6

where b = 10 using the definition stated on the previous slide.


Example 3.16
Prove the following statement

Any number with 2, 4, 6, 8, or 9


as the units digits is divisible by 2.
Example 3.17
Prove the following statement

Any number whose sum of digits is divisible by 3


is also divisible by 3.
Example 3.18
Prove the following statement

Any number whose digits in the tens and units places


taken in that order are divisible by 4
is itself also divisible by 4.
Linear Congruences
Theorem 3.3
The linear congruence

ax ≡ b (mod n)

has a solution if and only if d|b, where d = gcd(a, n). If d|b, then it
has d mutually incongruent solutions modulo n.
Example 3.19
Solve for the general solution of the linear congruence

18x ≡ 30 (mod 42)


Example 3.19
Solve for the general solution of the linear congruence

18x ≡ 30 (mod 42)

Answer

x = −10 + 7t
Example 3.20
Solve for the general solution of the linear congruence

9x ≡ 21 (mod 30)
Example 3.20
Solve for the general solution of the linear congruence

9x ≡ 21 (mod 30)

Answer

x = −21 + 10t
Example 3.21
Solve for the general solution of the linear congruence

10x ≡ 3 (mod 12)


Example 3.21
Solve for the general solution of the linear congruence

10x ≡ 3 (mod 12)

Answer

No solution.
Example 3.22
Solve for the general solution of the linear congruence

7x ≡ 3 (mod 12)
Example 3.22
Solve for the general solution of the linear congruence

7x ≡ 3 (mod 12)

Answer

x = −15 + 12t
Example 3.23
Solve for the general solution of the linear congruence

10x ≡ 6 (mod 14)


Example 3.23
Solve for the general solution of the linear congruence

10x ≡ 6 (mod 14)

Answer

x = 9 + 7t
Extension of Theorem 3.3
If x0 is any solution of ax ≡ b (mod n), then d = gcd(a, n) incon-
gruent solutions are given by the sequence
n 2n (d − 1)n
{ad } = x0 , x0 + , x0 + , ... , x0 +
d d d
which can be written as

x ≡ ad (mod n)

which represents the d equivalance classes of the solution to the linear


congruence.
Corollary
If gcd(a, n) = 1, then the linear congruence

ax ≡ b (mod n)

has a unique solution modulo n.


Example 3.24
Identify the incongruent solution(s) modulo n of

7x ≡ 3 (mod 12)

Express your answer as a positive number.


Example 3.24
Identify the incongruent solution(s) modulo n of

7x ≡ 3 (mod 12)

Express your answer as a positive number.

Answer

x ≡ 9 (mod 12)
Example 3.25
Identify the incongruent solution(s) modulo n of

9x ≡ 21 (mod 30)

Express your answer as a positive number.


Example 3.25
Identify the incongruent solution(s) modulo n of

9x ≡ 21 (mod 30)

Express your answer as a positive number.

Answer

x ≡ 9 (mod 30), x ≡ 19 (mod 30), x ≡ 29 (mod 30)


Example 3.26
Identify the incongruent solution(s) modulo n of the following
I 25x ≡ 15 (mod 29) I 36x ≡ 8 (mod 102)
I 5x ≡ 2 (mod 26) I 34x ≡ 60 (mod 98)
I 6x ≡ 15 (mod 21) I 140x ≡ 133 (mod 301)

Express your answers as a positive number.


Chinese Remainder Theorem
Chapter IV
Congruences with a Prime-power
Modulus
The Arithmetic of Zp
Pseudoprimes and Carmichael Numbers
Solving Congruences mod (pe)
Chapter V
Euler’s Function
Units
Euler’s Function
Applications of Euler’s Function
Bibliography

Jones, G Jones, J.M. (2005) Elementary Number Theory. Great


Britain: Springer-Verlag London Limited.
Burton, D. (2010) Elementary Number Theory - 7th Edition.
USA: McGraw-Hill Education

You might also like