Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

1.

a) a = 1980, b=2040 ans: gcd = 60, s = -1, t = 1


q r1 r2 r s1 s2 s t1 t2 t
0 1980 2040 1980 1 0 1 0 1 0
1 2040 1980 60 0 1 -1 1 0 1
33 1980 60 0 1 -1 34 0 1 -33
60 0 -1 34 1 -33
b) a=720 b = 1080 ans: gcd =360 , s =-1 , t =1
q r1 r2 r s1 s2 s t1 t2 t
0 720 1080 720 1 0 1 0 1 0
1 1080 720 360 0 1 -1 1 0 1
2 720 360 0 1 -1 3 0 1 -2
360 0 -1 3 1 -2
C a=187, b=27 ans: gcd =1, s = 13, t =-90
q r1 r2 r s1 s2 s t1 t2 t
6 187 27 25 1 0 1 0 1 -6
1 27 25 2 0 1 -1 1 -6 7
12 25 2 1 1 -1 13 -6 7 -90
2 2 1 0 -1 13 -27 7 -90 187
1 0 13 -27 -90 187
D a=99, b=210 ans: gcd= 3, s = 17, t = -8
q r1 r2 r s1 s2 s t1 t2 t
0 99 210 99 1 0 1 0 1 0
2 210 99 12 0 1 -2 1 0 1
8 99 12 3 1 -2 17 0 1 -8
4 12 3 0 -2 17 -72 1 -8 33
3 0 17 -72 -8 33
2.
a) -8≡2≡12≡22≡32≡42
b) -110≡11≡132≡253≡374≡495
c) -71≡3≡77≡151≡225≡299
d) -11≡5≡21≡37≡53≡69
3.
(a) additive inverse [(a+b)≡0 (mod n)]: (0,0),(1,11),(2,10),(3,9),(4,8),(5,7),(6,6)
Multiplicative inverse [(a*b)≡1 (mod n)]: first checking whether the element in Z_12
and 12 are coprime. Z*_12 = {1,5,7,11}
Because the set is few, we directly check whether elements in set are coprime.
We get multiplicative inverse = {(1,1), (5,5),(7,7),(11,11)}
(b) additive inverse [(a+b)≡0 (mod n)]:
(0,0),(1,22),(2,21),(3,20),(4,19),(5,18),(6,17),(7,16),(8,15),(9,14),(10,13),(11,12)
Multiplicative inverse [(a*b)≡1 (mod n)]: Because 23 is prime, elements excluding 0
in set have multiplicative inverse.
First we check small number X≡1 (mod 23).
24≡1 (mod 23) 24 = (2,12), (3,8), (4,6)
47≡1 (mod 23) => 47 is prime
70≡1 (mod 23) = (5,14), (7,10)
Trivial case: (1,1)
Special case: (22+1)*(22-1) = 22*22-1 = 23*21, so [22*22 ≡ 1 (mod 23)](22,22)
The remaining numbers : 9,11,13,15,16,17,18,19,20,21
We know lemma: gcd(n,b)=1, inverse of b is t (by extend Euclidean algorithm)
q r1 r2 r s1 s2 s t1 t2 t
2 23 9 5 1 0 1 0 1 -2
1 9 5 4 0 1 -1 1 -2 3
1 5 4 1 1 -1 2 -2 3 -5
4 4 1 0 -5
1 0 -5
Because we just know t, we can finish at 3rd row. Inverse = -5+23=18
q r1 r2 r s1 s2 s t1 t2 t
2 23 11 1 1 0 1 0 1 -2
11 11 1 0 0 1 -2
1 0 -2
Inverse = -2+23 = 21
q r1 r2 r s1 s2 s t1 t2 t
1 23 13 10 1 0 1 0 1 -1
1 13 10 3 0 1 -1 1 -1 2
3 10 3 1 1 -1 4 -1 2 -7
3 3 1 0
1 0
Inverse : -7+23 = 16
q r1 r2 r s1 s2 s t1 t2 t
1 23 15 8 1 0 1 0 1 -1
1 15 8 7 0 1 -1 1 -1 2
1 8 7 1 1 -1 2 -1 2 -3
7 7 1 0
1 0
Inverse : -3+23 = 20
The remaining pair (17,19) => 17*19-23*14=1,case is true
Multiplicative inverse [(a*b)≡1 (mod n)]: (1,1),(2,12),(3,8),(4,6),(5,14),(7,10),(9,18),
(11,21),(13,16),(15,20),(17,19),(22,22)
4.a)
q r1 r2 r s1 s2 s t1 t2 t
8 143 17 7 1 0 1 0 1 -8
2 17 7 3 0 1 -2 1 -8 17
2 7 3 1 1 -2 -3 -8 17 -42
3 3 1 0
1 0
multiplicative inverse: -42+143=101
b)
q r1 r2 r s1 s2 s t1 t2 t
3 221 69 14 1 0 1 0 1 -3
4 69 14 13 0 1 -4 1 -3 13
1 14 13 1 1 -4 -3 13 -16
13 13 1 0
1 0
multiplicative inverse: -16+221=205
c)
q r1 r2 r s1 s2 s t1 t2 t
5 433 73 68 1 0 1 0 1 -5
1 73 68 5 0 1 -1 1 -5 6
13 68 5 3 1 -1 14 -5 6 -83
1 5 3 2 -1 14 -15 6 -83 89
1 3 2 1 14 -15 29 -83 89 -172
2 2 1 0
1 0
multiplicative inverse: 433-172 = 261
d)
q r1 r2 r s1 s2 s t1 t2 t
2 31 11 9 1 0 1 0 1 -2
1 11 9 2 0 1 -1 1 -2 3
4 9 2 1 1 -1 5 -2 3 -14
2 2 1 0
1 0
multiplicative inverse: -14+31 = 17
5.
(a) 10x≡2 (mod 14)
gcd(10,14) = 2 , 2|2 so there are 2 solutions for the equation
10x≡2 (mod 14) => 5x≡1 (mod 7)
x≡(1 * 5^-1) (mod 7), and 3 is the multiplicative inverse of 5 [(3*5)≡1 mod 7]
=> x0=3 , x1 = 3 + (14/2) = 10
(b)
5x+7≡9 (mod 32) => 5x≡2 (mod 32)
Gcd(5,32) = 1 , 1|2 so there are only one solution for the equation
x≡(2 * 5^-1) (mod 32), and 13 is the multiplicative inverse of 5 [(13*5)≡1 mod 32]
 x =(2 * 13) ≡26 (mod 32)

You might also like