MATH 433 February 20, 2015 Exam 1: Solutions

advertisement
MATH 433
February 20, 2015
Exam 1: Solutions
Problem 1 (20 pts.) Find the smallest positive integer a such that the equation
76x + 96y = a has an integer solution.
Solution: a = 4.
The sought number is the greatest common divisor of 76 and 96. Since 76 = 2 · 38 = 22 · 19
and 96 = 2 · 48 = 22 · 24 = 23 · 12 = 24 · 6 = 25 · 3, it follows that a = 22 = 4.
Alternatively, gcd(76, 96) can be found by the Euclidean algorithm:
96 = 1 · 76 + 20,
76 = 3 · 20 + 16,
20 = 1 · 16 + 4,
16 = 4 · 4.
Problem 2 (20 pts.) Let a = 600, b = 96. Find the prime factorisation for the
following numbers: a, b, and the least common multiple of a and b.
Solution: a = 23 · 3 · 52 , b = 25 · 3, lcm(a, b) = 25 · 3 · 52 .
a = 600 = 6 · 102 = 2 · 3 · (2 · 5)2 = 23 · 3 · 52 , b = 96 = 2 · 48 = 22 · 24 = 23 · 12 = 24 · 6 = 25 · 3.
The prime factorisation of the least common multiple of a and b is the smallest product of primes
that contains both the prime factorisation of a and the prime factorisation of b. This is 25 · 3 · 52 .
Problem 3 (20 pts.)
inverse of 13 modulo 47).
Find an integer x such that 13x ≡ 1 mod 47 (that is, an
Solution: x = −18 (as well as any x ≡ 29 mod 47).
To find the inverse of 13 modulo 47, we need to represent 1 as an integral linear combination
of 13 and 47. This can be done by the matrix method:
1 0 13
1 0 13
4 −1 5
→
→
0 1 47
−3 1 8
−3
1 8
→
4 −1 5
−7
2 3
→
11 −3 2
−7
2 3
→
11 −3 2
−18
5 1
.
From the second row of the last matrix we read off that −18 · 13 + 5 · 47 = 1. Therefore
−18 · 13 ≡ 1 mod 47, which means that −18 is an inverse of 13 modulo 47.
1
Problem 4 (20 pts.) Solve the system
y ≡ 3 mod 17,
y ≡ 5 mod 11.
Solution: y ≡ 71 mod 187.
The moduli 17 and 11 are coprime. We need to represent 1 as an integral linear combination
of these moduli. It is easy to see that 2 · 17 − 3 · 11 = 1. Then one of the solutions is y =
5 · 2 · 17 − 3 · 3 · 11 = 71. The solution set is the congruence class of 71 modulo 17 · 11 = 187.
Problem 5 (20 pts.) You receive a message that was encrypted using the RSA system with public key (65, 29), where 65 is the base and 29 is the exponent. The encrypted
message, in two blocks, is 3/2. Find the private key and decrypt the message.
Solution: the private key is (65, 5), the decrypted message is 48/32.
First we find φ(65). The prime factorisation of 65 is 5 · 13, hence φ(65) = φ(5)φ(13) =
(5 − 1)(13 − 1) = 48.
The private key is (65, β), where the exponent β is the inverse of 29 (the exponent from the
public key) modulo φ(65) = 48. To find β, we apply the Euclidean algorithm (in matrix form)
to 29 and 48:
1 0 29
2 −1 10
2 −1 10
5 −3 1
1 0 29
→
→
→
→
.
0 1 48
−1 1 19
−1
1 19
−3
2 9
−3
2 9
From the first row we read off that 5 · 29 − 3 · 48 = 1, which implies that 5 is the inverse of 29
modulo 48.
Now that we know the private key, the decrypted message is b1 /b2 , where b1 ≡ 35 mod 65,
b2 ≡ 25 mod 65, and 0 ≤ b1 , b2 < 65. We find that b1 = 48, b2 = 32.
Bonus Problem 6 (15 pts.) Is the number 433 prime? Explain how you know.
Solution: 433 is prime.
√
The smallest prime divisor of a composite positive integer N does not exceed N . To show
that 433 is prime,
in the range
√ it is enough to check that it is not divisible by prime numbers √
between 1 and 433. Note that 202 = 400 < 433 < 441 = 212 , hence 20 < 433 < 21.
Therefore the prime numbers to check are 2, 3, 5, 7, 11, 13, 17, and 19. Neither of them divides
433.
2
Download