Professional Documents
Culture Documents
CLASS NOTES
UNIT-IV LINEAR DIOPHANTINE EQUATIONS AND CONGRUENCES
Linear Diophantine Equation
The linear Diophantine equations are the simplest class of Diophantine equations.
The general form of a linear Diophantine equation (LDE) is two variables x and y is
ax by c, where a, b, c areintegers.
Theorem
The linear Diophantine equation ax by c is solvable if and only if d | c, where d (a, b) . If
x0, y0 is a particular solution of the linear Diophantine equation, then all its solutions are given by
b a
x x0 t and y y0 t , t Z
d d
1. Determine whether the LDE 2 x 3 y 4 z 5 is solvable?
Solution:
The gcd (2,3, 4) 1
i.e., (2,3, 4) 1 and 1/ 5
The given LDE is Solvable.
2. Find the general solution of the LDE 15x 21y 39
Solution:
15 x 21y 39 a 15, b 21, c 39.
d (15, 21) and d / 39 d 3
So, the given LDE is solvable.
15 x 21 y 39
5 x 7 y 13 (1)
then (5, 7) d 1
d /13
a 5, b 7, d 1
b a
x x0 t and y y0 t , t Z
d d
1
7 5
x 3 t and y 4 t , t Z
1 1
x 3 7t and y 4 5t , t Z
3. Find the general solution of the LDE 6 x 8 y 12 z 10
Solution:
Given the LDE is 6 x 8 y 12 z 10 (1)
Here a1 6, a2 8, a3 12, c 10
d (a1 .a2 , a3 ) 2
Since 2 | 10, d | c
So, the given LDE is solvable.
Since 8 y 12 z is a linear combination of 8and 12, it must bea multiple of (8,12) 4
8 y 12 z 4u (2)
(1) 6 x 4u 10 (3)
First we solve the LDE (3) in two variables x and u
Here a 6, b 4, c 10
(a, b) (6, 4) 2
d (a, b) 2 and c 10
Since 2 | 10, d | c
So, the given LDE (3) is solvable.
b a
x x0 t and u u0 t, t Z
d d
4 6
x 1 t and u 1 t , t Z
2 2
x 1 2t and u 1 3t , t Z
Substituting for u in (2), we get
8 y 12 z 4(1 3t )
2
a b
Since d= 4 and 4 2.8 (1).12 is a linear combination of 8 and 12.
8, 12
Multiplying by (1 3t ), we get
4(1 3t ) 2(1 3t ).8 (1)(1 3t ).12
(2 6t ).8 (1 3t ).12
a solution of (2) is
y0 2 6t and z0 1 3t , t Z
So, the generalsolution of (2) is
b a
y y0 t' and z z0 t ', t ' Z
d d
12 8
y 2 6t t' and z 1 3t t ', t ' Z
4 4
y 2 6t 3t ' and z 1 3t 2t ', t ' Z
Thus the general solution of (1) is
x 1 2t , y 2 6t 3t ', z 1 3t 2t ', t ' Z
Congruence modulo m
If an integer m ( 0) divides the difference a b , we say that a is congruent to b modulo m.
(i.e) a b(mod m).
Solution:
4 x 5(mod 6)
Here a 4, b 5, m 6
(a, m) (4, 6) 2
2 / 5 (i.e) (a, m) / b
The congruence has no solution.
3
n even 2m
n2 n (2m)2 (2m)
4m2 2m
2(2m2 m)
n2 n is divisible by 2
n odd 2m 1
4m 2 6m 2
2(2m2 3m 1)
n2 n is divisible by 2
n2 n 0(mod 2)
6. Let a b (mod m) and c d (mod m), then prove that ac bd (mod m).
Solution:
Since a b (mod m) and c d (mod m),
a b lm and c d km for some inegers l and m.
Then ac bd (ac bc) (bc bd )
c ( a b ) b (c d )
clm bkm
(cl bk )m
So ac bd (mod m)
7. Let a b (mod m) and c d (mod m), then prove that a c b d (mod m).
Solution:
Since a b (mod m) and c d (mod m),
a b lm and c d km for some inegers l and m.
Then a c (b lm) (d km)
(b d ) (l k )m
b d (mod m)
8.If ac bc (mod m) and (c, m) 1, then prove that a b (mod m).
Solution:
4
Suppose ac bc (mod m), where (c, m) 1.
Then m | (ac bc) m | c(a b).
we know that : If a and b are relatively prime, and if a | bc, then a | c.
But (m, c) 1, m | (a b), (i.e) a b (mod m)
Complete residue system.
A set x1 , x2 ,...., xm is a complete residue system mod m if for integer y , there is one and only one x j
9. Solve x7 1 0(mod 7)
Solution:
The complete residuesystem (CRS ) is 0,1, 2,3, 4,5, 6
But 4 3 (mod 7)
5 2 (mod 7)
6 1 (mod 7)
The CRS is {0, 1, 2, 3}
The CRS does not satisfy the congruence x 2 1 0(mod 7)
The given congruence has no solution.
23 1 (mod 7)
253 23(17) 2
(23 )17 .22
117.4(mod 7)
4(mod 7)
5
11. Find the remainder when 1! 2! 3! .... 300! is divided by 13.
Solution:
For divisibility by 13, we consider mod 13.
For r 13, r ! will contain 13 as a facor.
r ! 0(mod13)
1! 2! 3! 4! ...... 12! ..... 300!
1! 2! 3! 4! ...... 12! 0 0 (mod13)
1! 2! 3! 4! ...... 12!(mod13)
1 2 6 24 120 .... 12!(mod13)
But 2 24 26 0(mod13)
5! 120 3(mod13)
6! 5!6 3.6 (mod13)
18(mod13)
5(mod13)
7! 6!7 5.7 (mod13)
35(mod13)
9 (mod13)
8! 7!8 9.8(mod13)
72(mod13)
7 (mod13)
9! 8!9 7.9(mod13)
63(mod13)
11(mod13)
10! 9!10 11.10(mod13)
110(mod13)
6 (mod13)
11! 10!11 6.11(mod13)
66(mod13)
1(mod13)
12! 11!12 1.12(mod13)
12(mod13)
1! 2! 3! 4! ...... 12! ..... 300! 1 6 0 3 5 9 7 11 6 1 12(mod13)
6
61(mod13) 9(mod13)
the remainder is9 when1! 2! 3! 4! ...... 12! ..... 300! is divided by13.
12. Find the remainder when 3181 is divided by 17 using modular exponentitation.
Solution:
32 9(mod17); 34 4(mod17); 38 1(mod17); 316 1(mod17)
332 1(mod17); 364 1(mod17);
3128 1(mod17)
3181 3128.332.316.34.31
1.1.1.13.3 (mod 17)
5(mod17)
Thus the desired remainder is 5.
32 2 (mod 7)
(32 )3 23 (mod 7) 1(mod 7)
36 1(mod 7)
331 (36 )5 .3
15.3 (mod 7)
3(mod 7)
Thus the remainder is 3.
n 1, (42 10) 1 25
25 is divisible by 25
7
statement is true for n 1.
Assume that the statement is true for n k
42 k 2 10(k 1) 1 is divisible by 25
Statement is true for n k 1
By principle of mathematical induction,
Statement is true for all n.
n n2 (n 2) (n 2) 1 (mod12)
n((n 2)(n2 1) 1 (mod12)
(n 1)n(n 1)(n 2) 1 (mod12)
1 (mod12)
Thus when (n2 n 41)2 is divided by12, the remainder is 1.
16. Compute the remainder when 3247 is divisible by 25.
Solution:
8
We have 32 9(mod 25)
34 92 81 6 (mod 25)
38 62 36 11 (mod 25)
9
3181 3128.332.316.34.31
1.1.1.13.3 (mod 17)
5(mod17)
Thus the desired remainder is 5.
23 1 (mod 7)
253 23(17) 2
(23 )17 .22
117.4(mod 7)
4(mod 7)
10
which is not possible p1 1
Hence p must be prime.
Linear Congruence
A congruence of the form ax b (mod m), where m is a positive integer and a,b are integers and
x is a variable, is called a linear congruence.
Chinese remainder theorem.
Let m1 , m2 ,...., mr denote r positive integers that are relatively prime in pairs and let a1 , a2 ,...., ar
be any r integers. Then the congruence x ai (mod mi ), i 1, 2,...., r have common solution.
be any r integers. Then the congruence x ai (mod mi ), i 1, 2,...., r have common solution.
Proof:
First we prove the existence of the solution
11
Since x1 a j (mod m j ) and x2 a j (mod m j ), j 1, 2,3,...., k
we have x1 x2 0(mod m j )
m j | x1 x2 for every j
Let n m1 m2 m3 3.4.5 60
n 3.4.5
and n1 20
m1 3
n 3.4.5
n2 15
m2 4
n 3.4.5
n3 12
m3 5
n1 y1 1(mod m1 )
n2 y2 1(mod m2 )
n3 y3 1(mod m3 )
12
We have n1 y1 1(mod m1 ),
20 y1 1(mod 3),
Since 20.2 40 1(mod 3), we see y1 2 is a solution
We have n2 y2 1(mod m2 ),
15 y2 1(mod 4),
Since 15.3 45 1(mod 4) , we see y2 3 is a solution
We have n3 y3 1(mod m3 ),
12 y3 1(mod 5),
Since 12.3 36 1(mod 5), we see y3 3 is a solution
m
, m1 (21, 4) 1
m1
m
, m2 (28,3) 1
m2
m
, m3 (12, 7) 1
m3
13
we knowthat
m
b j 1(mod m j )
mj
m
For m1 b1 1(mod m1 )
m1
(21)b1 1(mod 4) 4 / 21b1 1
21b1 1 4k , k is an integer
21b1 1 4k
1 4k
b1
21
put k 5, b1 1
m
For m2 b2 1(mod m2 )
m2
(28)b2 1(mod 3) 3 / 28b2 1
28b2 1 3k , k is an integer
28b 2 1 3k
1 3k
b2
28
put k 9, b2 1
m
For m3 b3 1(mod m3 )
m3
(12)b3 1(mod 7) 7 /12b3 1
12b3 1 7k2 , k2 is an integer
12b3 1 7k2
1 7 k2
b3
12
put k2 5, b3 3
14
m m m
a1b1 a2b2 a3b3 (mod m)
m1 m2 m3
(2111) (28 0 1) (12 5 3) (mod84)
(21 180) (mod84)
201(mod84)
22. Determine whether the system
x 3(mod10); x 8(mod15); x 5(mod84) has a solution and find themall if it exists.
Solution:
The first congruence x 3(mod10) is equivalent to the simultaneous congruences
x 3(mod 2) -------(1)
x 3(mod 5) --------(2)
The congruence x 8(mod15)is equivalent to,
x 8(mod 3) (3)
x 8(mod 5) (4)
The congruence x 5(mod84)is equivalent to,
x 5(mod 3) (5)
x 5(mod 4) (6)
x 5(mod 7) (7)
The congruence (1) &(6)
x 3(mod 2)
x 5(mod 4) reduces to x 1(mod 4) (8)
The congruence (3) &(5)
x 8(mod 3)
x 5(mod 3) reduces to x 2 (mod 3) (9)
The congruence (2) & (4)
x 3(mod 5)
x 8(mod 5) reduces to x 3(mod 5) (10)
From (7) x 2 (mod 7) (11)
we have solve thecongruence of (8),(9),(10) &(11)
15
Here a1 1, a2 2, a3 3, a4 5
m1 4, m2 3, m3 5, m4 7
m m1 . m2 . m3 . m4
4.3.5.7
420
m m m m
105, 140, 84, 60
m1 m2 m3 m4
we knowthat
m
b j 1(mod m j )
mj
m
For m1 b1 1(mod m1 )
m1
(105)b1 1(mod 4) 4 /105b1 1
105b1 1 4k1 , k1 is an integer
105b1 1 4k1
1 4k1
b1
105
put k1 26, b1 1
m
For m2 b2 1(mod m2 )
m2
(140)b2 1(mod 3) 3 /140b2 1
1 3k2
b2
140
put k2 93, b2 2
m
For m3 b3 1(mod m3 )
m3
(84)b3 1(mod 5) 5 / 84b3 1
16
84b3 1 5k3 , k3 is an integer
84b3 1 5k3
1 5k3
b3
84
m
For m4 b4 1(mod m4 )
m4
(60)b4 1(mod 7) 7 / 60b4 1
84b 4 1 7k4
1 7 k4
b4
84
put k4 17, b3 2
m m m m
a1b1 a2b2 a3b3 a4b4 (mod m)
m1 m2 m3 m4
(105 11) (140 2 2) (84 3 4) (60 5 2) (mod 420)
17
Theorem
The linear system of congruences ax by e( mod m) and cx dy f ( mod m) has a unique
solution if and only if (, m) 1, where ad bc(mod m) .
23. Verify that the linear system 2x+3y4(mod13) and 3x +4y 5 (mod 13) has a unique solution
modulo 13.
Solution:
We know that the system has a unique solution modulo m if and only if (, m) 1
23
ad bc 1 12(mod 13).
34
Since (12,13)=1
Therefore the system has a unique solution modulo 13.
24.Solve the linear system
5 x 6 y 10(mod13)
6 x 7 y 2(mod13).
Solution:
5 x 6 y 10 (mod13)
6 x 7 y 2 (mod13)
a 5, b 6, c 6, d 7, e 10, f 2.
m 13, ad bc
35 36
71(mod13) 7(mod13)
(, m) (13,1) 1.
Hence unique solution.
10 6
x0 1 (mod13) (1)
2 7
5 10
y0 1 (mod13) (2)
6 2
1 1(mod13)
7 1 1(mod13)
1 2(mod13)
18
(1)
19