Download Sample Final - University of Nebraska–Lincoln

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Eisenstein's criterion wikipedia , lookup

History of algebra wikipedia , lookup

Fundamental theorem of algebra wikipedia , lookup

System of polynomial equations wikipedia , lookup

Equation wikipedia , lookup

System of linear equations wikipedia , lookup

Transcript
End of Course Problems for Number Theory and Cryptography
Summer 2006
1. Prove: If d|(a + b) and d|a, then d|b.
2. Prove or disprove: If a and b are odd integers, then a2 + b2 is not a perfect square.
3. Find five different ways a collection of 100 coins - pennies, dimes, and quarters – can
be worth exactly $4.99.
4. Prove or disprove: If a2 ≡ b2 (mod m), then a ≡ b (mod m) or a ≡ −b (mod m).
5. The International Standard Book Number (ISBN) is used to identify books. A correctly
coded 10-digit ISBN a1a2a3a4a5a6a7a8a9a10 has the property that 10a1+9a2+
8a3+7a4+6a5+5a6+4a7+3a8+2a9+a10 is divisible by 11. All transposition errors (errors
where two adjacent digits are swapped) are detected by the ISBN encoding. Show that
if the digits a8 and a9 are swapped, that the error will be detected.
6. Consider the linear congruence equation ax ≡ b (mod 36).
(a) Construct a linear congruence equation modulo 36 with no solutions.
(b) Construct a linear congruence equation modulo 36 with exactly 1 solution.
(c) Construct a linear congruence equation modulo 36 with more than one
solution.
7. Solve, if possible, the congruence equations:
(a) 9x ≡ 7 (mod 11)
(b) 15x ≡ 27 (mod 20)
(c) 573x ≡ 1 (mod 256)
(d) 573x ≡ 27 (mod 256)
8. Compute the last two digits of 7171.
9. You examined perfect numbers in your homework. A perfect number is a number
equal to the sum of its divisors (other than itself). For example, 6 is a perfect number
since 6 = 1+2+3. We could say that a number is product perfect if the product of all its
divisors (other than itself) is equal to the original number. For example, 6 and 15 are
product perfect since 6 = 1 · 2 · 3 and 15 = 1 · 3 · 5. The number 12 is not product
perfect since 1 · 2 · 3 · 4 · 6 = 144  12.
(a) List all the product perfect numbers between 2 and 50.
(b) Based on your data in part (a), find a precise characterization of all product
perfect numbers. Your characterization should begin with ”A number is
product perfect if and only if . . . ”.
Copyright 2007. Number Theory and Cryptology for Middle Level Teachers. Developed by the Math in the Middle
Institute Partnership, University of Nebraska, Lincoln.
1
(c) Prove this characterization.
10. Collecting data:
(a) As we did in class (see sections 6 and 7), build a table tabulating ak (mod 12) for a =
0, 1, . . . , 11 and for enough k starting at k = 1 until a repeating pattern is established.
(b) Explain how the data in the table demonstrates Euler’s Theorem.
(c) Note that 0  (12)  1. Does this violate Euler’s Theorem?
(d) From your table, which numbers are multiplicative inverses of themselves?
(e) What is 943,345,192,345 (mod 12)?
11. Consider the RSA encryption method with p = 11 and q = 17 as the two primes. Also let A =
0,B = 1, . . . , Z = 25, space = 26 as we did in class.
(a) Find n and  (n).
(b) Let e = 71 and find d.
(c) Verify that de ≡ 1 (mod  (n)).
(d) A secret message m has been encoded using me (mod n) with the values of n and e
given above. The encoded message is GABCDACQDAEPEF. Decode this message
by breaking it up into blocks of size 2. Convert each block to a base 10 number. For
ex., DU = 3 · 27 + 20 = 74. Decrypt these base ten numbers using sd (mod n), where
s is the encoded number; your results will be a number between 0 and 26. You may
use the web-based computer program found at http://www.nebrwesleyan.edu
/people/kpfabe/FastExp.html to perform the fast exponentiation. Translate this number
to a letter using the substitution given above to decode the message. The message is a
familiar English phrase.
Copyright 2007. Number Theory and Cryptology for Middle Level Teachers. Developed by the Math in the Middle
Institute Partnership, University of Nebraska, Lincoln.
2
Solutions: End of Course Problems for Number Theory and Cryptography
1. Prove: If d|(a + b) and d|a, then d|b.
Since d|(a + b) and d|a, dj = a + b and dk = a, for some integers j, k.
Thus b = d(j − k). Hence d|b.
2. Prove or disprove: If a and b are odd integers, then a2 + b2 is not a perfect square.
If a and b are odd, then there are integers j and k such that a = 2j+1 and b = 2k+1.
Then
a2 + b2 = 4j2 + 4j + 4k2 + 4k + 2, which is an even number. If a perfect square
d = c2 is even, then it must be divisible by 4, since c would be divisible by 2. However
4j2 + 4j + 4k2 + 4k + 2 ≡ 2 (mod 4), and so a2 + b2 is not a perfect square.
3. Find five different ways a collection of 100 coins - pennies, dimes, and quarters – can be worth
exactly $4.99.
Let x be the number of quarters and y be the number of dimes. Then there are 100 − x − y
pennies. Thus
499 = 100 − x − y + 25x + 10y which simplifies to 133 = 8x + 3y, and so y =
133  8 x
3
Test values of x starting at 0, 1, . . . to find the first value for which y is an integer.
We see that x = 2 works, and the corresponding y is y = 39. Thus our solutions to
133 = 8x +3y are x = 2 +3t, y = 39−8t. Nonnegative values of x and y occur when
t = 0, 1, 2, 3, 4. Thus, the combination of coins that are worth $4.99 are
• 2 quarters, 39 dimes and 59 pennies
• 5 quarters, 31 dimes and 64 pennies
• 8 quarters, 23 dimes and 69 pennies
• 11 quarters, 15 dimes and 74 pennies
• 14 quarters, 7 dimes and 79 pennies
4. Prove or disprove: If a2 ≡ b2 (mod m), then a ≡ b (mod m) or a ≡ −b (mod m).
To disprove, let a = 7, b = 5 and m = 24. 49 ≡ 25 (mod 24) but 7 ≡  5 (mod 24).
5. The International Standard Book Number (ISBN) is used to identify books. A correctly coded
10-digit ISBN a1a2a3a4a5a6a7a8a9a10 has the property that 10a1+9a2+8a3+7a4+6a5+5a6+4a7+
3a8+2a9+a10 is divisible by 11. All transposition errors (errors where two adjacent digits are
swapped) are detected by the ISBN encoding. Show that if the digits a8 and a9 are swapped,
that the error will be detected.
For the error to go undetected, 10a1+9a2+8a3+7a4+6a5+5a6+4a7+3a8+2a9+a10would be
divisible by 11. Since 10a1+9a2+8a3+7a4+6a5+5a6+4a7+3a8+2a9+a10 is divisible by 11,
then for the error to go undetected, the difference of these two would also be divisible by 11.
We’ll look at that difference now: 10a1+9a2+8a3+7a4+6a5+5a6+4a7+3a8+2a9+a10−
Copyright 2007. Number Theory and Cryptology for Middle Level Teachers. Developed by the Math in the Middle
Institute Partnership, University of Nebraska, Lincoln.
3
(10a1+9a2+8a3+7a4+6a5+5a6+4a7+3a9+2a8+a10) =3a8 + 2a9 − (3a9 + 2a8) = a8 − a9. There
is no way hat a8 − a9 can be divisible by 11 if a8 and a9 can be the numbers 0, 1, . . . , 9.
6. Consider the linear congruence equation ax ≡ b (mod 36).
(a) Construct a linear congruence equation modulo 36 with no solutions.
(b) Construct a linear congruence equation modulo 36 with exactly 1 solution.
(c) Construct a linear congruence equation modulo 36 with more than one solution.
No solution: 2x ≡ 1 (mod 36)
One solution: 17x ≡ 1 (mod 36)
More than one solution: 2x ≡ 4 (mod 36)
7. Solve, if possible, the congruence equations:
(a) 9x ≡ 7 (mod 11)
The solution is x = 2
(b) 15x ≡ 27 (mod 20)
We note that (15, 20) = 5 and 5 does not divide 27, so there are no solutions.
(c) 573x ≡ 1 (mod 256)
Here we use the Extended Euclidean Algorithm.
573 = 2 · 256 + 61
256 = 4 · 61 + 12
61 = 5 · 12 + 1
Reversing the steps of the Euclidean Algorithm above,
1 = 61 − 5 · 12
= 61 − 5(256 − 4 · 61)
= 21 · 61 − 5 · 256
= 21 · (573 − 2 · 256) − 5 · 256
= 21 · 573 − 47 · 256
So 21 · 573 ≡ 1 (mod 256), thus, 21 is the solution. It is the only least residue solution
since (573, 256) = 1.
(d) 573x ≡ 27 (mod 256)
Using the previous part, we see that 21 · 27 = 567 is a solution. Its least residue is 55.
8. Compute the last two digits of 7171. I.e. we want to compute 7171 (mod 100)
712 ≡ 5041 ≡ 41 (mod 100)
713 ≡ 41 · 71 ≡ 11 (mod 100)
716 ≡ 112 ≡ 21 (mod 100)
7112 ≡ 212 ≡ 41 (mod 100)
7124 ≡ 412 ≡ 81 (mod 100)
7148 ≡ 812 ≡ 61 (mod 100)
7171 = 71487112716713712 ≡ 61 · 41 · 21 · 11 · 41 ≡ 71 (mod 100)
9. You examined perfect numbers in your homework. A perfect number is a number equal to the
sum of its divisors (other than itself). For example, 6 is a perfect number since 6 = 1+2+3. We
could say that a number is product perfect if the product of all its divisors (other than itself) is
equal to the original number. For example, 6 and 15 are product perfect since 6 = 1 · 2 · 3
Copyright 2007. Number Theory and Cryptology for Middle Level Teachers. Developed by the Math in the Middle
Institute Partnership, University of Nebraska, Lincoln.
4
and 15 = 1 · 3 · 5. The number 12 is not product perfect since 1 · 2 · 3 · 4 · 6 = 144  12.
(a) List all the product perfect numbers between 2 and 50.
They are 6, 8, 10, 14, 15, 21, 22, 26, 27, 33, 34, 35, 38, 39, 46.
(b) Based on your data in part (a), find a precise characterization of all product perfect
numbers. Your characterization should begin with ”A number is product perfect if
and only if . . . ”.
A number is product perfect if and only if it is the product of two distinct prime or is
the cube of a prime.
(c) Prove this characterization.
(sketch) Product perfect numbers will have four distinct factors, and these are of the
form listed above.
10. Collecting data:
a
0
1
2
3
4
5
6
7
8
9
10
11
(a) As we did in class (see sections 6 and 7), build a table tabulating ak (mod 12)
for a = 0, 1, . . . , 11 and for enough k starting at k = 1 until a repeating pattern
is established.
a2
a3
a4
0
0
0
1
1
1
4
8
4
9
3
9
4
4
4
1
5
1
0
0
0
1
7
1
4
8
4
9
9
9
4
4
4
1
11
1
(b) Explain how the data in the table demonstrates Euler’s Theorem.
First,  (12) = 4. The numbers that are relatively prime to 12 are 1, 5, 7 and 11. For
these values of a, the table shows that a4 (mod 12) = 1, which is what Euler’s
Theorem guarantees.
(c) Note that 0  (12) 6= 1. Does this violate Euler’s Theorem?
No it doesn’t since (0, 12) = 12, ie. 0 and 12 are not relatively prime.
(d) From your table, which numbers are multiplicative inverses of themselves?
1, 5, 7 and 11.
(e) What is 943,345,192,345 (mod 12)?
9
Copyright 2007. Number Theory and Cryptology for Middle Level Teachers. Developed by the Math in the Middle
Institute Partnership, University of Nebraska, Lincoln.
5
11. Consider the RSA encryption method with p = 11 and q = 17 as the two primes. Also let A =
0,B = 1, . . . , Z = 25, space = 26 as we did in class.
(a) Find n and  (n).
n = 187 and  (n) = 160.
(b) Let e = 71 and find d.
Using the Extended Euclidean Algorithm,
160 = 2 · 71 + 18
71 = 3 · 18 + 17
18 = 1 · 17 + 1
So
1 = 18 − 1 · 17
= 18 − 1(71 − 3 · 18)
= 4 · 18 − 71
= 4(160 − 2 · 71) − 71
= 4 · 160 − 9 71
Thus d = −9 + 160 = 151.
(c) Verify that de ≡ 1 (mod  (n)).
de = 151 · 71 = 10721 = 67 · 160 + 1 ≡ 1 (mod 160).
(d) A secret message m has been encoded using me (mod n) with the values of n and e
given above. The encoded message is GABCDACQDAEPEF. Decode this message
by breaking it up into blocks of size 2. Convert each block to a base 10 number. For
ex., DU = 3 · 27 + 20 = 74. Decrypt these base ten numbers using sd (mod n), where
s is the encoded number; your results will be a number between 0 and 26. You may
use the web-based computer program to perform the fast exponentiation. Translate
this number to a letter using the substitution given above to decode the message. The
message is a familiar English phrase.
GA = 6 · 27 + 0 = 162
BC = 1 · 27 + 2 = 29
DA = 3 · 27 + 0 = 81
CQ = 2 · 27 + 16 = 70
DA = 3 · 27 + 0 = 81
EP = 4 · 27 + 15 = 123
EF = 4 · 27 + 5 = 113
Decode using sd (mod n) to get the respective numbers 19, 7, 4, 26, 4, 13 and 3,
which translates into ”THE END”.
Copyright 2007. Number Theory and Cryptology for Middle Level Teachers. Developed by the Math in the Middle
Institute Partnership, University of Nebraska, Lincoln.
6