Professional Documents
Culture Documents
SEMESTER 1 2022/2023
DIVISIBILITY THEORY
• The division algorithm is one of the first concepts relative to the operation of division.
For any integers a & b, where bZ+, there exist unique integers q, r such that
a = bq + r 0rb.
Where.
a – dividend ; b – divisor
q – quotient ; r – remainder (in the division of a by b)
2
THE DIVISION ALGORITHM (Cont.)
Example.
Therefore, q = –9 ; r = 1
Corollary 1
3
THE DIVISION ALGORITHM (Cont.)
Consider b is negative.
Then,
|b|>0.
By Theorem 1,
unique integers q’ & r such that,
a = | b |q’ + r 0r|b|
Note that,
| b | = - b , take q = - q’ in order to get a = bq + r , 0 r | b | .
4
THE DIVISION ALGORITHM (Cont.)
Example
i. If a = 1 ,
then the division algorithm can be expressed as 1 = 0(-6) + 1 .
ii. If a = -2 ,
then the division algorithm can be expressed as – 2 = 1(-6) + 4 .
iii. If a = 61
then the division algorithm can be expressed as 61= (– 10)(-6) + 1 .
iii. If a = – 59
then the division algorithm can be expressed as – 59 = (10)(-6) + 1 .
5
THE DIVISION ALGORITHM (Cont.)
Application of Division Algorithm
If b = 2,
Then the possible remainder are : r = 0 and r = 1. (by D.A) Note: ( DA ) a = bq + r
If a2 ;
a2 = (2q)2 = 4q2 = 4k for some kZ
Or;
a2 = (2q + 1)2 = 4q2 + 4q + 1 = 4(q2 + q) + 1 = 4m + 1 for some mZ
6
THE DIVISION ALGORITHM (Cont.)
Application of Division Algorithm
Example. Example.
62 = 36 = 4(9) + 0
(cont. )
7
DIVISION ALGORITHM (Cont.)
Application of Division Algorithm
In the division algorithm, any integers can be represented as one of four form:
• 4q
• 4q + 1 Odd
• 4q + 2
• 4q + 3 Odd
If (4q + 1)2 ;
(4q + 1)2 = 16q2 + 8q + 1 = 8(2q2 + q) + 1= 8k + 1 for some k= (2q2 + q) Z
Or;
(4q + 3)2 = 16q2 + 24q + 9 = 8(2q2 + 3q + 1) + 1= 8m + 1 for some m= (2q2 + 3q + 1) Z
8
THE DIVISION ALGORITHM (Cont.)
Application of Division Algorithm
Example.
9
GREATEST INTEGER FUNCTION
Note:
Definition 1.
The greatest integer
function is very useful in
The greatest integer function for a real number x, denote by x
applications involving
the largest integer less than or equal to x, satisfying
data storage
x − 1 x x and data transmission.
Notes:
• x = x if and only if x is an integer.
• If x is any real numbers, then x can be written as x = x + t where 0 t 1.
10
GREATEST INTEGER FUNCTION (Cont.)
Example.
9
i. 2 =
4.5
= 4
−9
ii. 2 =
−4.5
= −5
iv. −6 = −6
11
GREATEST INTEGER FUNCTION (Cont.)
Proposition 1
i. x + n = x + n
− x if − x =x
ii. − x =
− x − 1 if − x x
x x
iii. =
n n if n 1
12
GREATEST INTEGER FUNCTION (Cont.)
Facts:
Greatest integer function can be used to give explicit formulas for the
quotient and remainder in the division algorithm:
a a
q= r = a−b
b b
Example.
Given a = 22, b = 3, by using the greatest integer function give explicit formulas for
the division algorithm.
13
GREATEST INTEGER FUNCTION (Cont.)
Solution.
Given a = 22 , b = 3.
22
q = = 7.33 = 7
3
22
r = 22 − 3 = 22 − 3 7.33 = 22 − 3 ( 7 ) = 1
3
Exercise: Given a = 46, b = 3, by using the greatest integer function give explicit formulas for the division
algorithm.
14
DIVISORS AND MULTIPLES
Divisibility
Definition 2
15
DIVISORS AND MULTIPLES
Divisibility
Example
Solution:
16
DIVISORS AND MULTIPLES (Cont.)
Divisibility
Theorem 2
17
DIVISORS AND MULTIPLES (Cont.)
Divisibility
Example.
Proof.
By Definition 2 (Divisibility)
By Definition 2 (Divisibility)
18
DIVISORS AND MULTIPLES (Cont.)
Divisibility
Solution:
19
DIVISORS AND MULTIPLES (Cont.)
Divisibility
1. To show 1S
For n = 1,
8 | (52(1) + 7)
= 8 | 32 Since 32 = 8(4) (from def. of divisible)
Then, 1S .
Let kS.
Then, 8 | (52k + 7)
[To show 8 | (52(k+1) + 7) ]
20
DIVISORS AND MULTIPLES (Cont.)
Divisibility
8 | (52(k+1) + 7)
= 8 | (52k . 52 + 7)
= 8 | (52k . 52 + 7) + 7. 52 – 7 . 52
= 8 | 52 (52k + 7) + ( 7 – 7 . 52 )
21
DIVISORS AND MULTIPLES (Cont.)
Divisibility
Exercise (divisibility)
22
DIVISORS AND MULTIPLES (Cont.)
Common Divisors
Notes:
23
DIVISORS AND MULTIPLES (Cont.)
Common Divisors
Example.
Solution:
24
DIVISORS AND MULTIPLES (Cont.)
Common Divisors
Exercise.
iv. 42 and 14
25
DIVISORS AND MULTIPLES (Cont.)
Greatest Common Divisors
i. d | a and d | b
ii. If c | a and c | b then c d
Note:
If c | a and c | b then c | d
26
DIVISORS AND MULTIPLES (Cont.)
Greatest Common Divisors
Example.
i. – 12 and 30
ii. – 8 and – 36
Solution.
27
DIVISORS AND MULTIPLES (Cont.)
Greatest Common Divisors
Solution.
Exercise.
Answer:
Determine the greatest common divisor of the following:
i. Gcd(45, 60) = 15
i. 45 and 60
ii. Gcd(– 9, 15) = 3
ii. – 9 and 15
iii. Gcd(36, 54) = 18
iii. 36 and 54
28
DIVISORS AND MULTIPLES (Cont.)
Greatest Common Divisors
Theorem 3.
Example.
29
DIVISORS AND MULTIPLES (Cont.)
Relatively Prime
Two integers a and b, not both zero, are said to be relatively prime
if gcd (a, b) = 1.
Example.
30
DIVISORS AND MULTIPLES (Cont.)
Relatively Prime
Theorem 4.
Let a, b Z, not both zero. Then a and b are relatively prime if and only if
there exist integers x and y such that 1 = ax + by.
Proof. (next )
31
DIVISORS AND MULTIPLES (Cont.)
Relatively Prime
Proof.
() Let a and b are relatively prime. (To show 1 = ax + by)
Then, gcd(a,b) = 1.
By Theorem 3, exist integers x, y such that
1 = ax + by .
32
DIVISORS AND MULTIPLES (Cont.)
Relatively Prime
Example. Example.
Let a = – 8 , b = – 36 Let a = 4 , b = 6
33
DIVISORS AND MULTIPLES (Cont.)
Relatively Prime
Note.
Corollary 3.
34
DIVISORS AND MULTIPLES (Cont.)
Relatively Prime
Proof. (Corollary 3)
35
DIVISORS AND MULTIPLES (Cont.)
Greatest Common Divisors
Note.
36
DIVISORS AND MULTIPLES (Cont.)
Euclid’s Lemma
Proof.
Since a | bc,
we have, bc = ak. ------ (2)
So, (Cont. )
37
DIVISORS AND MULTIPLES (Cont.)
Euclid’s Lemma
Proof. (cont.)
c = cax + cby
= cax + (ak)y
= a (cx + ky )
Therefore, a | c .
38
DIVISORS AND MULTIPLES (Cont.)
Euclid’s Lemma
Example.
Let a = 3, b = 4 & c = 3.
3 | 4(3) , with gcd(3, 4) = 1
Then, by Euclid’s Lemma, clearly 3 | 3.
Note.
39
DIVISORS AND MULTIPLES (Cont.)
Euclid’s Lemma
Theorem 6.
i. d | a and d | b
ii. Whenever c | a and c | b then c | d .
40
DIVISORS AND MULTIPLES (Cont.)
Euclid’s Lemma
41
DIVISORS AND MULTIPLES (Cont.)
Euclid’s Lemma
This implies c d,
Consequently d is the greatest common divisor of a and
b.
42
DIVISORS AND MULTIPLES (Cont.)
Common Multiple
Note:
43
DIVISORS AND MULTIPLES (Cont.)
Common Multiple
Example
44
DIVISORS AND MULTIPLES (Cont.)
Least Common Multiple
i. a | m and b | m
ii. If a | c and b | c with c > 0, then m c .
Example.
The positive common multiples of –12 and 30 are:
60, 120, 180, ......
Hence,
lcm(-12, 30) = 60.
45
DIVISORS AND MULTIPLES (Cont.)
Least Common Multiple
Example.
46
DIVISORS AND MULTIPLES (Cont.)
Least Common Multiple
Note.
47
DIVISORS AND MULTIPLES (Cont.)
Least Common Multiple
Example (ii).
Given two positive integers 3054 and 12378 where gcd(3054, 12378) = 6.
Determine the lcm(3054, 12378).
Solution.
48
THE EUCLIDEAN ALGORITHM
Cont.
49
THE EUCLIDEAN ALGORITHM
gcd (a, b) = gcd (b, r1) = ... = gcd (rn-1, rn) = gcd (rn, 0)
50
THE EUCLIDEAN ALGORITHM
Example.
Solution.
Cont.
51
THE EUCLIDEAN ALGORITHM
Solution. (Cont.)
2 = 14 – 12 (1)
= 14 – [68 – 14 (4)] 1
= – 68 + 14(5)
52
THE EUCLIDEAN ALGORITHM
Example.
Determine the GCD of 42823 and 6409 and write your GCD
= d in terms of (ax + by).
Solution.
53
THE EUCLIDEAN ALGORITHM
Solution. (Cont.)
54
THE EUCLIDEAN ALGORITHM
Exercise.
Answer:
Using the Euclidean algorithm, calculate the greatest
common divisor of the following numbers and find integers i. gcd(2689,4001) = 1.
x, y such that d = (ax + by). 1 = = – 1117 . 4001 + 1662 . 2689
x = -1117 and y = 1662
i. 2689 and 4001
ii. 864 and 468 ii. gcd(864, 468) = 36.
iii. 1819 and 3587 36 = = 6 . 864 – 11 . 468.
x = 6 and y = -11
55
LINEAR DIOPHANTINE EQUATION
• Diophantine equations are named after the Greek mathematician Diophantus, c. 250, of Alexandria.
• The great work of Diophantus rests in his Arithmetica, which may be described as the earliest treatise in
Algebra.
• The term Diophantine equation usually refers to any equation in one or more unknowns that is to be
solved in the integers.
• A solution of this equation is a pair of integers: x = x0, y = y0 that satisfy the equation.
• A linear Diophantine equation can have either a unique solution, many solutions or no solution.
56
LINEAR DIOPHANTINE EQUATION
Example.
57
LINEAR DIOPHANTINE EQUATION
The following theorem gives us the solutions for the linear Diophantine equations.
Theorem 7
58
LINEAR DIOPHANTINE EQUATION
Suppose d | c.
Then,
Then c = dt for tZ (by definition 2) (Cont. )
59
LINEAR DIOPHANTINE EQUATION
(2nd part.)
60
LINEAR DIOPHANTINE EQUATION
(2nd part.) (cont.)
61
LINEAR DIOPHANTINE EQUATION
(2nd part.) (cont.)
62
LINEAR DIOPHANTINE EQUATION
(2nd part.) (cont.)
63
LINEAR DIOPHANTINE EQUATION
Example.
Solution.
64
LINEAR DIOPHANTINE EQUATION
Solution. (Cont.)
65
LINEAR DIOPHANTINE EQUATION
Solution. (Cont.)
Next to find the positive solutions, i.e., for x > 0 and y > 0 :
66
LINEAR DIOPHANTINE EQUATION
Example.
Solution.
67
LINEAR DIOPHANTINE EQUATION
Solution. (Cont.)
68
LINEAR DIOPHANTINE EQUATION
Solution. (Cont.)
Next to find the positive solutions, i.e., for x > 0 and y > 0 :
−4250 − 43 t 0 Hence, t = -99. Therefore the Diophantine equation
500 + 5t > 0
36 has a unique solution x = 5, y =7 corresponding to the
t > -100 t −98 value t = -99.
43
69
LINEAR DIOPHANTINE EQUATION
Exercise.
2. Find all the solutions (x, y) to the following Diophantine equation 11x + 13y = 369 for
which x and y are both positive.
70