NUMBER THEORY Amin Witno

Size: px
Start display at page:

Download "NUMBER THEORY Amin Witno"

Transcription

1 WON Series in Discrete Mthemtics nd Modern Algebr Volume 2 NUMBER THEORY Amin Witno Prefce Written t Phildelphi University, Jordn for Mth 313, these notes 1 were used first time in the Fll 2005 semester. They hve since been revised 2 nd shll be revised gin s often s the uthor teches the course. Outline notes re more like revision. No student is expected to fully benefit from these notes unless they hve regulrly ttended the lectures. 1 Divisibility The nturl numbers 1, 2, 3,... together with their negtives nd zero mke up the set of integers. Number Theory is the study of integers. Every number represented throughout these notes will be understood n integer unless otherwise stted. Definition. The number d divides m, or m is divisible by d, if the opertion m d yields n integer. This reltion my be written d m, or d m if it is not true. When d m, the number d is lso clled divisor of m, nd m multiple of d. For exmple 3 18 nd We my lso stte tht even numbers re multiples of Proposition (Properties of divisibility) 1. The number 1 divides ll integers. 2. d 0 nd d d for ny integer d If d m nd m n then d n. 4. If d m nd d n then d (m + bn) for ny integers nd b. Proof. The first two sttements follow immeditely from the definition of divisibility. For (3) simply observe tht if m/d nd n/m re integers then so is n/d = n/m m/d. Similrly for (4), the number (m + bn)/d = (m/d) + b(n/d) is n integer when d m nd d n. Definition. For every rel number x, the nottion x denotes the gretest integer x. For exmple 3.14 = 3 nd 2 = 2. Now with n > 0, define the residue of m mod n by m % n = m m/n n. Here the symbol (%) is red mod. For exmple 18 % 5 = 3 1 Copyrighted under Cretive Commons License c Amin Witno 2 Lst Revision: www. w i t n o. com

2 WON 2 Number Theory 2 nd 18 % 3 = 0. Note tht m % n is relly the reminder upon dividing m by n nd it lies in the rnge 0 m % n n 1. In prticulr m % n = 0 if nd only if n m. Exercise. Find these residues % % % % Proposition One in every n consecutive integers is divisible by n. Proof. Let m be the first integer nd let k = m % n. If k = 0 then n m. Otherwise 1 k n 1 nd our consecutive integers cn be written m = m/n n + k, m/n n + (k + 1), m/n n + (k + 2),..., m/n n + (k + n 1) with k + n 1 n. Then one of these numbers is m/n n + n, multiple of n. Definition. The gretest common divisor of two integers m nd n is the lrgest integer which divides both. This number is denoted by gcd(m, n). For exmple gcd(18, 24) = 6 becuse 6 is the lrgest integer with the property 6 18 nd Exercise. Find gcd(36, 48), gcd(24, 0), gcd(1, 99), gcd(100, 123). 1.3 The Eucliden Algorithm gcd(m, n) = gcd(n, m % n) Proof. It suffices to show tht the two pirs {m, n} nd {n, m % n} hve identicl sets of common divisors. This is chieved entirely using Proposition upon observing tht, from its definition, m % n is liner combintion of m nd n, nd so is m of n nd m % n. Exercise. Use Eucliden Algorithm to compute gcd(m, n). 1. m = 144, n = m = 503, n = m = 725, n = m = 12345, n = Theorem gcd(m, n) = m + bn for some integers nd b. Proof. Note tht pplying the Eucliden Algorithm successively will lwys terminte with zero s the lst residue: gcd(m, n) = gcd(n, m % n) = gcd(m % n, n % (m % n)) = = gcd(d, 0) in which cse gcd(m, n) = d. Since ech integer in the pir is liner combintion of the previous pir of integers, we my by finite number of steps express d s liner combintion of m nd n. Remrk. The lgorithm involved in ctully finding the integers nd b is clled the Extended Eucliden Algorithm, the detils of which will be discussed in Project 1 given t the end of this chpter. 1.5 Corollry Let L be the set of ll integrl liner combintions of m nd n. Then

3 WON 2 Number Theory 3 1. L is equl to the set of ll multiples of gcd(m, n). 2. gcd(m, n) is the lest positive element of L. 3. gcd(m, n) = 1 if nd only if 1 L. 4. gcd(m, n) = 1 if nd only if L is the set of ll integers. Proof. All multiples of gcd(m, n) belong to L by Theorem 1.4. Conversely gcd(m, n) divides every element of L ccording to Proposition This proves the first sttement, from which follow the remining three. 1.6 Proposition (Properties of gretest common divisors) 1. If d m nd d n then d gcd(m, n). 2. If d gcd(m, n) then gcd(m/d, n/d) = gcd(m, n)/d. 3. If d mn nd gcd(d, m) = 1 then d n. Euclid s Lemm 4. If c m nd d m with gcd(c, d) = 1 then cd m. 5. If gcd(m, n) = 1 nd gcd(m, n) = 1 then gcd(mm, n) = 1. Proof. (1) This is corollry of Theorem 1.4 nd Proposition (2) By Corollry 1.5.2, gcd(m/d, n/d) is the lest positive liner combintion of m/d nd n/d, which is 1/d times the lest positive liner combintion of m nd n, tht is gcd(m, n)/d. (3) By Theorem 1.4 if gcd(d, m) = 1 then 1 = d + bm for some integers nd b. Multiplying this lst eqution by n/d yields n/d = n + b(mn/d), which is n integer if d mn. (4) Agin gcd(c, d) = 1 implies 1 = c + bd. This time multiply through by m/(cd) to get m/(cd) = (m/d) + b(m/c), which is n integer if c m nd d m. (5) Write 1 = m + bn nd 1 = m + b n nd multiply the two equtions together: 1 = mm + (b m + bm + bb n)n This displys 1 s liner combintion of mm nd n nd hence gcd(mm, n) = 1 by Corollry Liner Eqution Theorem The liner eqution mx+ny = c hs solution if nd only if d = gcd(m, n) c, in which cse ll its solutions re given by ( x 0 k n, y ) d 0 + k m d for ny prticulr solution (x 0, y 0 ) nd for ny integer k. Proof. The first prt of the theorem is resttement of Corollry Now suppose we hve prticulr solution (x 0, y 0 ) nd consider first the cse d = 1. All solutions of the liner eqution must lie on the line pssing through (x 0, y 0 ) with slope equl m/n. Another point on this line will be given by (x 0 t, y 0 + tm/n) for ny rel number t. If the coordintes re to be integers then by Euclid s Lemm we must hve t = kn for some integer k. Thus the generl solution (x 0 kn, y 0 + km). For the cse d > 1 we replce our eqution by (m/d)x + (n/d)y = c/d without ltering its solution set. But then Proposition implies tht gcd(m/d, n/d) = 1 nd therefore the generl solution is (x 0 kn/d, y 0 + km/d). Exercise. Find ll the solutions, if ny, of these equtions. 1. 5x + 8y = x + 25y = 3

4 WON 2 Number Theory x + 18y = x + 65y = Corollry gcd(m, n) = 1 if nd only if the eqution mx + ny = 1 hs solution. Proof. This follows since gcd(m, n) 1 if nd only if gcd(m, n) = 1. Problem Set 1 1. Does 3 divide ? Wht is % 3? 2. The time is now 11 o clock in the morning. Wht time will it be fter 100 hours? 3. Find ll integers n in the rnge 1 n 12 such tht gcd(n, 12) = Compute gcd(12345, 54321). 5. Find solution of 34x + 55y = Find ll the solutions of 25x + 65y = I mde two clls tody vi MobileCom, one cll to nother MobileCom line for 6 pisters per minute nd nother cll to FstLink number for 16 pisters per minute. The totl chrge ws 90 pisters. For how long did I tlk in ech cll? 8. Investigte true or flse. () If d m then d m. (b) If m n nd n m then m = n. (c) If c m nd d n then cd mn. (d) If d mn then either d m or d n. (e) If dn mn then d m. 9. Investigte true or flse. () gcd(m, n) > 0 (b) gcd(m, n) = gcd(m n, n) (c) gcd(m, mn) = m (d) gcd(m, m + 1) = 1 (e) gcd(m, m + 2) = Prove tht if k > 0 then gcd(km, kn) = k gcd(m, n). 11. Prove tht n 2 + n is even. 12. Prove tht n is not divisible by Prove tht n 2 1 is multiple of 8 when n is odd. 14. Prove 6 (n 3 n). 15. Prove 24 (n 3 n) if n is odd. 16. Prove 30 (n 5 n). Project 1 Extended Eucliden Algorithm The gol is to express the gretest common divisor of two integers s their liner combintion, tht is to write gcd(m, n) = m + bn for some integers nd b. We hve seen how the Eucliden Algorithm is used to evlute gcd(m, n). For exmple we find tht gcd(216, 78) = 6 s the lst non-zero reminder in the following recursive steps. 216 = 2(78) = 1(60) = 3(18) = 3(6) + 0

5 WON 2 Number Theory 5 Now rewrite these equtions in order to express ech reminder s liner combintion of m = 216 nd n = = 1(216) 2(78) 18 = 1(78) 1(60) = 1(78) 1{1(216) 2(78)} = 1(216) + 3(78) 6 = 1(60) 3(18) = 1{1(216) 2(78)} 3{ 1(216) + 3(78)} = 4(216) 11(78) We shll next simplify the ppernce of the bove lgorithm by not writing the m nd n in ech row. For convenience we dd two extr rows t the top, corresponding to the equtions 216 = 1(216) + 0(78) nd 78 = 0(216) + 1(78), in this order Recll tht the lst row gives the desired result gcd(216, 78) = 6 = 4(216) 11(78). If we lbel the first column, from the top down r 1, r 2, r 3,... then these numbers stisfy the recurrence reltion given by r n = r n /r n+1 r n+1 + r n+2, which mens tht row (n + 2) is obtined by subtrcting r n /r n+1 times row (n + 1) from row n. Exercise. Continue with Exercise 1.3 to find nd b such tht gcd(m, n) = m + bn. Assignment. Repet this exercise with m = nd n equls the number obtined from the lst six digits of your Phildelphi University Number. This is your personl 6-digit PUN, to be remembered nd used gin in subsequent projects. 2 Prime Numbers Definition. A prime number is n integer p > 1 with no positive divisors except 1 nd p itself. An integer n > 1 which is not prime number is clled composite. For exmple 13 nd 17 re primes, but 21 is composite becuse 21 = 3 7. Throughout these notes we shll designte p to lwys denote prime number. Exercise. Find ll prime numbers up to Proposition (Properties of primes) 1. Every integer greter thn 1 hs prime divisor. 2. n is composite if nd only if it hs prime divisor n. 3. gcd(p, n) = p if p n, otherwise gcd(p, n) = If p mn then either p m or p n. 5. If p n 1 n 2 n k then p divides one of n 1, n 2,..., n k.

6 WON 2 Number Theory 6 Proof. (1) Suppose, by induction, the sttement is true up to n 1. Either n is prime, nd its own prime divisor, or else it hs divisor d stisfying 1 < d < n. It follows tht d hs prime divisor which is lso divisor of n by Proposition (2) For prime p there is clerly no prime divisor p. For composite n = b with, b > 1 either n or b n must hold. Whichever is true, by (1) or b hs prime divisor d, which stisfies d n nd d n. (3) The sttement is obvious since 1 nd p re the only divisors of p. (4) If p m then by (3) gcd(p, m) = 1 nd by Euclid s Lemm p n. (5) Repeted use of (4) estblishes this clim. 2.2 Theorem There re infinitely mny prime numbers. Proof. If there were only finitely mny prime numbers, let N be the product of them ll. Now by Proposition 2.1.1, one of these prime divisors of N must lso divide N + 1, thus it would lso divide 1 = (N + 1) N ccording to Proposition This is bsurd becuse ll primes re lrger thn The Fundmentl Theorem of Arithmetic Every integer greter thn 1 is product of prime numbers in unique wy up to reordering. Proof. We use induction to show tht such integer is product of primes. Suppose this clim is true up to n 1. By Proposition 2.1.1, n hs prime divisor, sy n = pn with n < n. It follows tht n is product of primes nd so is n. To prove uniqueness we proceed by contrdiction. Suppose we hve two different multisets of primes p s nd q s whose products both equl n. Equting these products nd cncelling out ll common terms will result in p 1 p 2 p j = q 1 q 2 q k where none of the p s equls ny of the q s. By Proposition 2.1.5, p 1 must divide one of the q s, sy q i, implying tht p 1 = q i, contrdiction. Exercise. Fctor the numbers 123, 400, 720, 7575 into primes. 2.4 Corollry Let m nd n be fctored into powers of distinct primes: m = p j i i n = p k i i, with j i, k i 0. Then gcd(m, n) = p e i i where e i = min{j i, k i }. Proof. By Theorem 2.3 divisor of m must be of the form d = p e i i with e i j i. Similrly if d n then e i k i nd so the gretest such d is the cse e i = min{j i, k i }. Exercise. Find gcd(m, n). 1. m = , n = m = , n = m = , n = m = , n = Conjectures (Unsolved problems concerning prime numbers) 1. There re infinitely mny primes in the sequence {n 2 + 1}. 2. Twin Primes. There re infinitely mny primes in the sequence {p + 2}. 3. Mersenne Primes. There re infinitely mny primes in the sequence {2 p 1}. 4. Fermt Primes. There re only finitely mny primes in the sequence {2 2n + 1}. 5. Goldbch s Conjecture. Every even number n > 2 is sum of two primes. nd

7 WON 2 Number Theory Dirichlet s Theorem on Primes in Arithmetic Progressions There re infinitely mny primes in the sequence {n + b} if nd only if gcd(, b) = 1. Proof for = 4 nd b = 3. First note tht prime p > 2 must hve the form 4n + 1 or 4n + 3. Second, the product of two numbers in the form 4n + 1 is gin of the sme form, hence number in the form 4n + 3 must hve prime divisor of the form 4n + 3. We clim tht there re infinitely mny primes in the sequence {4n + 3}. If it were not so, let N be the product of them ll. As noted, one of these prime divisors of N must be prime divisor of the number 4(N 1) + 3 hence it would lso divide 1 = 4N (4(N 1) + 3) nd this is contrdiction. 2.7 The Prime Number Theorem Let π(x) denote the number of primes up to x. For exmple π(13) = {2, 3, 5, 7, 11, 13} = 6 nd π(100) = 25. Then lim x π(x) x/ log x = 1 nd even more ccurtely, π(x) cn be estimted by x/(log x 1) for lrge vlues of x. No Proof. The proof is beyond the scope of elementry number theory. Exercise. Approximtely how mny prime numbers re there up to 10,000,000? Problem Set 2 1. Fctor the number into primes. 2. Find ll the positive divisors of 300 = How mny positive integers divide the number n = ? 4. Find ll pirs of twin primes up to Find ll primes in the form n up to Write the number 2006 s sum of two primes in five different wys. 7. Find five Mersenne primes. 8. Find five Fermt primes. 9. Estimte the number of primes up to one million. 10. Estimte the number of primes mong the ten-digit integers. 11. Investigte true or flse. () n 2 + n + 41 is prime for ll n 0. (b) n 2 81n is prime for ll n 1. (c) If p n 2 then p 2 n 2. (d) If p n 2 then p n. (e) If p n k then p n. 12. The lest common multiple of two integers is the smllest positive integer which is divisible by both. For exmple lcm(4, 6) = 12 becuse 12 is the smllest positive integer with the property 4 12 nd () Use prime fctoriztion to find formul for lcm(m, n). (b) Find reltion between gcd(m, n) nd lcm(m, n). (c) Illustrte your nswers using m = 600 nd n = Prove tht if d 2 m 2 then d m. 14. Prove gcd(m 2, n 2 ) = gcd(m, n) Find ll prime triplets, nmely p, p + 2, p + 4, ll of which re primes. 16. Prove tht there re infinitely mny primes in the sequence {6n + 5}.

8 WON 2 Number Theory 8 Project 2 Fermt Fctoriztion If n = x 2 y 2 then it fctors to n = (x + y)(x y). This fct is the simple ide behind the method of Fermt Fctoriztion. We seek fctor of n by clculting the numbers y 2 = x 2 n for ech integer x n until we find perfect squre. For exmple with n = 4277 we first clculte so we strt with x = = = = = 484 = 22 2 The result is 4277 = = ( )(69 22) = Fermt Fctoriztion lwys works when n is odd becuse if n = b with both, b odd then n = x 2 y 2 with x = ( + b)/2 nd y = ( b)/2. Moreover this shows tht we should terminte the process when x = (n + 1)/2, in which cse n = n 1 is prime. Exercise. Follow the bove exmple with the numbers 2117, 16781, 65593, nd Assignment. With the help of Fermt Fctoriztion try to fctor into primes your personl 6-digit PUN from Project 1. 3 Congruences Definition. Two integers nd b re congruent modulo n > 0 if n ( b), in which cse we write b (mod n). Equivlently we my define b (mod n) to men % n = b % n nd in prticulr % n (mod n). For exmple 13 4 (mod 3) nd for rbitrry even numbers nd b we hve b 0 (mod 2). 3.1 Proposition (Properties of congruences) 1. If b (mod n) nd c d (mod n) then + c b + d (mod n). 2. If b (mod n) nd c d (mod n) then c bd (mod n). 3. If b (mod n) then f() f(b) (mod n) for ny integrl polynomil f(x). 4. If b (mod m) nd b (mod n) with gcd(m, n) = 1 then b (mod mn). 5. If m mb (mod n) nd gcd(m, n) = 1 then b (mod n). Proof. First note tht b (mod n) holds if nd only if = b + jn for some integer j. Now if both = b + jn nd c = d + kn then the sum + c = b + d + (j + k)n nd the product c = bd + (bk + jd + jkn)n show why (1) nd (2) re true. For the remining clims, (3) is nturl generliztion of (1) nd (2), wheres (4) follows directly from Proposition 1.6.4, nd (5) from Euclid s Lemm. Definition. Congruence modulo n is n equivlence reltion over the integers with n congruence clsses, nmely the clsses of integers whose residues mod n re 0, 1, 2,..., up to n 1. A set of n numbers form complete residue system modulo n if ech comes from different congruence clss. For exmple complete residue system modulo 7 cn be {0, 1, 2, 3, 4, 5, 6}, {1, 2, 3, 4, 5, 6, 7}, or {0, 1, 2, 10, 11, 75, 1}, etc. Exercise. Find complete residue system modulo 7 with only even numbers.

9 WON 2 Number Theory Liner Congruence Theorem The congruence mx c (mod n) hs solution if nd only if d = gcd(m, n) c, in which cse it hs exctly d solutions modulo n given by x x 0 + kn/d (mod n) for k = 0, 1, 2,..., d 1 nd for ny prticulr solution x 0. Proof. The congruence is equivlent to the liner eqution mx = c + ny nd the theorem is relly corollry of the Liner Eqution Theorem. Exercise. Count how mny solutions ech congruence hs, then find them. 1. 8x 5 (mod 13) 2. 35x 7 (mod 49) 3. 27x 1 (mod 209) 4. 6x 9 (mod 1023) Definition. Two integers nd b re inverses of ech other modulo n if b 1 (mod n). For exmple 3 nd 5 re inverses modulo 7 since 3 5 = 15 1 (mod 7). Similrly the congruence (mod 12) implies tht 5 is its own inverse modulo Modulr Inverse Theorem The number hs n inverse modulo n if nd only if gcd(, n) = 1, in which cse its inverse, written b = 1, is unique modulo n. Proof. Simply let m = nd c = 1 in the Liner Congruence Theorem. Exercise. Find 1 modulo n if it exists. 1. = 2, n = 7 2. = 5, n = 8 3. = 35, n = = 27, n = Chinese Reminder Theorem If gcd(m, n) = 1 then the pir of congruences x c (mod m) nd x d (mod n) hve unique common solution modulo mn. Proof. All solutions of x c (mod m) re of the form c + mk, which is common solution if nd only if c + mk d (mod n), or mk d c (mod n). By the Liner Congruence Theorem there exists such n integer k since gcd(m, n) = 1 (d c). Now ny two solutions must stisfy x 1 c x 2 (mod m) nd x 1 d x 2 (mod n) so tht x 1 x 2 (mod mn) by Proposition 3.1.4, proving uniqueness. Exercise. Find common solution of x 5 (mod 8) nd x 7 (mod 11). Definition. The numbers m nd n re reltively prime if gcd(m, n) = 1. Three or more integers re pirwise reltively prime if they re reltively prime one to nother. An exmple is 8, 11, nd 15, where gcd(8, 11) = gcd(8, 15) = gcd(11, 15) = Chinese Reminder Theorem (Generl) Suppose n 1, n 2,..., n k re pirwise reltively prime. Then the system of congruences x c i (mod n i ) for i = 1, 2,..., k hs unique solution modulo N = n 1 n 2 n k. Explicitly the solution is given by x k i=1 where ech inverse is tken modulo n i. c i ( N n i ) ( N n i ) 1 (mod N)

10 WON 2 Number Theory 10 ( ) ( ) 1 Proof. To check tht the solution stisfies the system is trivil for c N N i n i n i c i (mod n i ) for ech i. To see tht this solution is unique is gin by the use of Proposition 3.1.4, together with Proposition Exercise. Find the smllest integer x > 0 stisfying the system of congruences. 1. x 5 (mod 8), x 7 (mod 11) 2. x 3 (mod 4), x 2 (mod 5), x 5 (mod 7) 3. x 1 (mod 9), x 2 (mod 10), x 3 (mod 11) 4. x 1 (mod 2), x 2 (mod 3), x 1 (mod 5), x 2 (mod 7) 3.6 Lemm If 2 1 (mod p) then ±1 (mod p). Proof. According to Proposition 2.1.4, if p divides 2 1 = (+1)( 1) then p (+1) or p ( 1), which is equivlent to the sttement of the lemm. 3.7 Wilson s Theorem If p is prime then (p 1)! 1 (mod p). Proof. The Modulr Inverse Theorem ssures tht ech of the numbers 1, 2,..., p 1 hs n inverse modulo p, nd by Lemm 3.6 none of them is self-inverse, except 1 nd p 1. Hence (p 1)! consists of the product of pirs of inverses modulo p, except 1 nd p 1, which do not get pired up. This gives the desired congruence. Exercise. Compute k! % 13 for k = 11, 12, 13, 14. Problem Set 3 1. Find complete residue system modulo 9 with only odd numbers. 2. Find complete residue system modulo 5 with only prime numbers. 3. Find ll the solutions of 12x 18 (mod 54). 4. Find the inverse of 7 modulo Which integers in the rnge 1 12 hve n inverse modulo 12? 6. Find the smllest integer x > 1 which stisfies ll three congruences x 1 (mod 7) nd x 1 (mod 11) nd x 1 (mod 13). 7. Find complete solution to the system x 2 (mod 5), x 1 (mod 8), x 7 (mod 9), nd x 3 (mod 11). 8. I hve less thn 3 dinrs left in my MobileCom prepid ccount. I could try to spend it ll by sending locl SMSs, for 3 pisters ech, but then 1 pister would be left. Or I could use it ll on interntionl SMSs, 7 pisters ech, then 3 pisters would be left. Or MMSs, 13 pisters ech, nd 2 pisters would be left. How much credits exctly do I hve? 9. Investigte true or flse. () If b (mod n) nd d n then b (mod d). (b) If b (mod n) then gcd(, n) = gcd(b, n). (c) If b (mod n) then m mb (mod mn). (d) If m mb (mod mn) then b (mod n). (e) If m mb (mod n) then b (mod n). 10. Prove 37 (35! 1). 11. Prove 37 (34! 18). 12. Prove tht if is odd then 2 1 (mod 8).

11 WON 2 Number Theory Prove tht if p 1 (mod 3) then p 1 (mod 6). 14. Prove tht if 2 b 2 (mod p) then either b (mod p) or b (mod p). 15. Prove tht if b (mod m) nd b (mod n) then b (mod lcm(m, n)). 16. Prove tht the converse of Wilson s Theorem is lso true. Project 3 Divisibility Tests A number n is divisible by 9 if nd only if the sum of its digits is divisible by 9. For exmple multiple of 9 is the number = where the digit sum is = 27, gin multiple of 9. To see why this is true, let n = n (10 n ) + n 1 (10 n 1 ) (10 2 ) + 1 (10) + 0 with 0 i 9 for ech term. This simply gives the deciml representtion of n with digits, from right to left, 0, 1, 2,..., n. Since 10 1 (mod 9), Proposition turns the eqution to the congruence n n + n (mod 9). Similrly 3k-digit number n is divisible by 7, 11, or 13 if nd ony if the lternting sum of the k consecutive 3-digit substrings of n is divisible by 7, 11, or 13, respectively. To illustrte this let n = , where the two leding zeros hve been dded to mke the number of digits multiple of 3. We hve = 546 = , mening tht n is divisible by 7 nd 13 but not by 11. Exercise. Prove this using the fct tht (mod 7, 11, 13) nd lso prove tht n is divisible by 11 if nd only if the lternting sum of its digits is divisible by 11. Exercise. Given n integer n, remove the right-most digit, sy u, nd denote wht remins by t. Then n is divisible by 17 if nd only if t 5u is, nd by 19 if nd only if t + 2u is. Verify these fcts using severl exmples nd try to prove them. Assignment. Mke summry of Divisibility Tests to determine when number n is divisible by d = 2, 3,..., 19 nd illustrte ech test using your full 9-digit PUN s n. In the end try to fctor n into primes. 4 Modulr Exponentition 4.1 Successive Squring Algorithm An efficient method for computing k % n for lrge integer k is to first express k s the sum of powers of 2, then compute 2 % n, 4 % n, 8 % n,... up to the highest exponent in those summnds. Exercise. Use the lgorithm to compute these residues % % % % Lemm If gcd(, n) = 1 then {r 1, r 2,..., r n } is complete residue system modulo n if nd only if {r 1, r 2,..., r n } is lso complete residue system modulo n.

12 WON 2 Number Theory 12 Proof. By Proposition 3.1.4, r j r k (mod n) implies r j r k (mod n) if gcd(, n) = 1, in which cse {r 1, r 2,..., r n } represents distinct congruence clsses modulo n if nd only if {r 1, r 2,..., r n } lso represents distinct congruence clsses modulo n. Exercise. Illustrte this lemm with = 4 nd n = Fermt s Little Theorem If p then p 1 1 (mod p). Proof. By Lemm 4.2 the numbers 0,, 2,..., (p 1) form complete residue system modulo p, hence their residues mod p re 0, 1, 2,..., p 1, not necessrily in this order. Leving out 0, we obtin the following congruence by multiplying those numbers. 2 3 (p 1) (p 1) (mod p) Wilson s Theorem then reduces this to p 1 1 (mod p) nd the desired result. Exercise. Use the theorem to compute these residues % % % % 239 Definition. The Euler phi-function φ(n) is the number of positive integers up to n which re reltively prime to n. For exmple φ(10) = 4 nd φ(11) = 10. Exercise. Evlute φ(12), φ(13), φ(14), φ(15). Definition. A reduced residue system modulo n is subset of complete residue system modulo n consisting of the φ(n) numbers reltively prime to n. For exmple {1, 2, 4, 5, 7, 8} is reduced residue system modulo 9. Exercise. Find reduced residue system modulo 10, 11, 12, Lemm If gcd(, n) = 1 then {r 1, r 2,..., r φ(n) } is reduced residue system modulo n if nd only if {r 1, r 2,..., r φ(n) } is lso reduced residue system modulo n. Proof. As in the proof of Lemm 4.2, either both sets represent distinct congruence clsses or neither does. To finish the proof we need to show tht gcd(r i, n) = 1 if nd only if gcd(r i, n) = 1, but this follows from Proposition since gcd(, n) = 1. Exercise. Illustrte this lemm with = 4 nd n = Euler s Theorem If gcd(, n) = 1 then φ(n) 1 (mod n). Proof. If gcd(, n) = 1 then by Lemm 4.4 we my choose pir of reduced residue systems modulo n in the form {r 1, r 2,..., r φ(n) } nd {r 1, r 2,..., r φ(n) }. Multiplying ll the elements in ech set yields the congruence φ(n) r 1 r 2 r φ(n) r 1 r 2 r φ(n) (mod n) Since ech element r i in the set is reltively prime to n, Proposition completes the proof by cncelling the common terms off both sides of the congruence.

13 WON 2 Number Theory 13 Exercise. Compute 7 26 % 10 using Euler s Theorem. Remrk. As computtionl corollry, when gcd(, n) = 1, the computtion of k % n cn be reduced by first replcing by % n nd k by k % φ(n). Euler s Theorem is not true, however, when gcd(, n) 1. Nevertheless for smll n we cn find similr reduction once we observe the periodicity of the sequence % n, 2 % n, 3 % n,... Exercise. Compute the following residues % % % % Theorem If gcd(m, n) = 1 then φ(mn) = φ(m)φ(n). Proof. Let M, N, nd MN be reduced residue systems modulo m, n, nd mn, respectively. To complete the proof we shll provide one-to-one correspondence between M N nd MN, thereby showing tht φ(mn) = MN = M N = φ(m)φ(n). For ech MN we hve gcd(, mn) = 1, thus gcd(, m) = 1 nd gcd(, n) = 1. Since M nd N re reduced residue systems, there exists unique pir (c, d) M N such tht c (mod m) nd d (mod n). Conversely given pir of congruences x c (mod m) nd x d (mod n) with (c, d) M N, by Chinese Reminder Theorem nd Proposition 1.6.5, x = is the unique element in MN which solves the system. This estblishes the one-to-one correspondence between the two sets. 4.7 Proposition (Evlution of Euler phi-function) 1. φ(p) = p 1 2. φ(p k ) = p k p k 1 3. If n = p k i i then φ(n) = p k i 1 i (p i 1) = n ( 1 1 p i ). Proof. The clim (1) is trivil. In (2) φ(p k ) is the number of integers from 1 to p k which re reltively prime to p k. Since p is the only prime divisor of p k, this number is p k minus the number of multiples of p, which re p, 2p, 3p,..., (p k 1 )p. Thus φ(p k ) = p k p k 1. And finlly (3) follows directly from (2) nd Theorem 4.6. Exercise. Evlute φ(61), φ(62), φ(63), φ(64). 4.8 A Generliztion of Euler s Theorem Let nd n be rbitrry positive integers. Set n 0 = n nd d 0 = gcd(, n) then for i 1 we define n i nd d i recursively by n i = n i 1 /d i 1 nd d i = gcd(, n i ). If k is the smllest integer for which d k = 1 then φ(n k)+k k (mod n) in which Euler s Theorem coincides with the cse k = 0. Proof. We clim tht the following sttements re ll equivlent, so tht we re done since the very lst one is true by Euler s Theorem. φ(n k)+k k (mod n) φ(n k)+k /d 0 k /d 0 (mod n 1 )

14 WON 2 Number Theory 14 φ(n k)+k 1 k 1 (mod n 1 ) φ(n k)+k 1 /d 1 k 1 /d 1 (mod n 2 ) φ(n k)+k 2 k 2 (mod n 2 ). φ(n k)+1 /d k 1 /d k 1 (mod n k ) φ(n k) 1 (mod n k ) To justify the equivlence, in ech lternting step down the list we divide through the congruence including the modulus n i by d i to obtin the next modulus n i+1. Immeditely following this we divide the congruence, without the modulus, by /d i. This is llowed by Proposition s d i = gcd(, n i ) implies gcd(/d i, n i+1 ) = 1 by Proposition Exercise. Apply this theorem to compute % Modulr Root Extrction If both gcd(, n) = 1 nd gcd(e, φ(n)) = 1 then the congruence x e (mod n) hs unique root x d (mod n) where d e 1 (mod φ(n)). Proof. We my write de = 1 + hφ(n) for some integer h. Now rise to the power d both sides of the congruence x e (mod n) to obtin d x de = x 1+hφ(n) = x(x φ(n) ) h x (mod n) using Euler s Theorem. Exercise. Solve for x. 1. x 7 12 (mod 13) 2. x 13 5 (mod 32) 3. x (mod 899) 4. x (mod 2005) Problem Set 4 1. Find reduced residue system modulo Find reduced residue system modulo 15 with only odd numbers. 3. Evlute φ(250313). 4. Find ll positive integers n stisfying φ(n) = Compute % Compute % Wht will be the right-most digit if we compute ? 8. Find the two right-most digits upon computing Solve the congruence x 39 5 (mod 121). 10. Investigte true or flse. () (mod 6601) hence the number 6601 must be prime. (b) (mod 1763) hence 1763 cnnot be prime number. (c) If b (mod n) then k b k (mod n). (d) If j k (mod n) then j k (mod n). 11. Prove tht Fermt s Little Theorem is equivlent to the following sttement: p (mod p) for ny integer.

15 WON 2 Number Theory Prove tht if k 1 (mod n) for some k > 0 then gcd(, n) = Another property of φ(n) is tht φ(d) = n where the sum is tken over ll the positive integers d which divide n. Verify this property for n = 24 nd n = Prove tht φ(2n) = 2φ(n) if n is even nd φ(2n) = φ(n) if n is odd. 15. Prove tht if d n then φ(d) φ(n). 16. Prove tht φ(n) is even for ll n > 2. Project 4 The RSA Cryptosystem Sensitive messges, when trnsfered over the internet, need to be encrypted, tht is chnged into secret code in such wy tht only the intended receiver who hs the secret key is ble to decrypt it. It is common tht lphbeticl chrcters re converted to their numericl ASCII equivlents before they re encrypted, hence the coded messge will look like integer strings. The RSA Algorithm is n encryptiondecryption process which is widely employed tody. Ali hs number n = pq where p nd q re very lrge distinct primes, over hundred digits ech. She computes φ(n) = φ(pq) = (p 1)(q 1) nd picks number e reltively prime to φ(n) nd nother number d e 1 (mod φ(n)), found vi the Eucliden Algorithm. She gives to Bob the pir (n, e) nd keeps the rest secret. Then whenever Bob wnts to send messge (integer) m < n to Ali, he encrypts it to s = m e % n. Upon receiving s, Ali uses Theorem 4.9 to retrieve the messge by computing m = s d % n. Now if bd guy intercepts the secret messge s, together with e nd n, he will yet hve to find the fctors p nd q in order to compute φ(n). Woe to him, fctoring lrge integer the size of pq will tke lifetime on the best computers of tody. Assignment. Suppose it is known tht e = 3989 nd n = Using your 6-digit PUN s m, find the encrypted messge s. Then try to brek this code, perhps using Fermt Fctoriztion, nd verify tht you do indeed get m bck. Exercise. Suppose the encrypted messge s is not reltively prime to n. Even though this is highly improbble since n hs only two prime divisors, show tht by Theorem 4.8, the decryption lgorithm will nyhow return the correct messge m. 5 Primitive Roots Definition. Suppose nd n re reltively prime. The order of modulo n is the smllest positive integer k such tht k 1 (mod n). We denote this quntity by n or simply when there is no mbiguity. For exmple 2 7 = 3 becuse k = 3 is the smllest positive solution of the congruence 2 k 1 (mod 7). We reiterte tht n implicitly ssumes tht gcd(, n) = 1, hence we hve n φ(n) by Euler s Theorem. Exercise. Find 3 7, 3 10, 5 12, Proposition (Properties of orders) 1. If b (mod n) then n = b n. 2. k 1 (mod n) if nd only if n k. In prticulr n φ(n). 3. j k (mod n) if nd only if j k (mod n ).

16 WON 2 Number Theory k = if nd only if gcd(k, ) = If gcd(, b ) = 1 then b = b. Proof. (1) It is cler tht the definition of order extends to congruence clsses. (2) Let j = k/ n so tht we my write k = j n + k % n. Then k = ( n ) j k % n k % n (mod n) nd with the fct k % n < n, the congruence k 1 (mod n) holds if nd only if k % n = 0, equivlently n k. (3) The congruence j k (mod n) is equivlent to j k 1 (mod n) nd the result follows from (2). (4) Observe tht the following congruence jk = ( j ) k = ( k ) j 1 (mod n) is true if we let j =, in which cse k by (2). It is lso true with j = k nd similrly k k. If gcd(k, ) = 1 then by Euclid s Lemm k nd so k =. Conversely if gcd(k, ) = d > 1, since the congruence holds for j = /d, we hve k /d <. (5) Suppose gcd(, b ) = 1. Agin we hve the following congruence. b b = b b (b b ) b = (b) b b 1 (mod n) Hence by (2) b b nd in turn, by Euclid s Lemm b. Now by symmetry b b nd so b b by Proposition It is cler, however, tht b b so it follows tht b = b. Definition. An integer g is clled primitive root modulo n if g n = φ(n). For exmple 3 is primitive root modulo 7 becuse 3 7 = 6 = φ(7). Exercise. Find ll the primitive roots modulo 6, 7, 8, 9, if ny. 5.2 Proposition (Properties of primitive roots) 1. g is primitive root modulo n if nd only if {g, g 2, g 3,..., g φ(n) } is reduced residue system modulo n. 2. g is primitive root modulo n if nd only if the congruence g x c (mod n) hs solution for every integer c reltively prime to n. 3. If g is primitive root modulo n then so is g k if nd only if gcd(k, φ(n)) = If ny exists, there re exctly φ(φ(n)) primitive roots modulo n. Proof. Let G = {g, g 2, g 3,..., g φ(n) }. (1) If g is primitive root then clerly ech element in G is reltively prime to n. We show now tht they represent distinct congruence clsses, for if g j g k (mod n) then by Proposition 5.1.3, φ(n) (j k). But this reltion is not possible since j k < φ(n) unless j = k. It follows tht G is reduced residue system modulo n. Conversely if g is not primitive root then g k 1 (mod n) with k < φ(n) nd G is not reduced residue system for then g k+1 g (mod n) where both g k+1, g G. (2) Equivlent to (1), G is reduced residue system modulo n if nd only if it represents ll congruence clsses of c with gcd(c, n) = 1.

17 WON 2 Number Theory 17 (3) This sttement is specil cse of Proposition (4) Exctly φ(φ(n)) elements g k G stisfy gcd(k, φ(n)) = 1 nd by (3) these nd only these re primitive roots modulo n. 5.3 Theorem The number of solutions of f(x) 0 (mod p) is t most the degree of f. Proof. For liner congruence, x + b 0 (mod p) hs unique solution ccording to the Liner Congruence Theorem since gcd(, p) = 1 nd so the theorem is true. By wy of induction, ssume the clim is true for polynomils of degree up to n 1. Let f(x) be polynomil with leding term x n nd with p. If f(x) hs less thn n roots then there is nothing to prove, else let r 1, r 2,..., r n be distinct roots of f(x) modulo p nd let g(x) = f(x) (x r 1 )(x r 2 ) (x r n ) Note tht the degree of g(x) is less thn n, nd yet it hs the sme n roots of f(x). By induction hypothesis this is impossible unless g(x) is the zero polynomil (mod p), so f(x) (x r 1 )(x r 2 ) (x r n ) (mod p) nd by Proposition f(x) 0 (mod p) if nd only if x r i (mod p) for one of these roots. Thus f(x) hs only these n roots modulo p. 5.4 Corollry If d (p 1) then the congruence x d 1 (mod p) hs exctly d solutions. Proof. Suppose dk = p 1 so tht we hve the following polynomil identity. x p 1 1 = (x d 1)((x d ) k 1 + (x d ) k x d + 1) By Fermt s Little Theorem the left-hnd side hs exctly p 1 roots modulo p. Since p is prime, these roots must come from those of the two polynomils on the right, which by Theorem 5.3 hve t most d nd d(k 1) = p 1 d roots, respectively. The only wy this cn hppen is if their roots re exctly d nd p 1 d. 5.5 Theorem There re exctly φ(p 1) primitive roots modulo every prime p. Proof. In view of Proposition 5.2.4, it suffices to show tht there is t lest one primitive root modulo p. Let p 1 = q e i i where the q s re distinct primes nd e i 1. By Corollry 5.4 there re exctly q e 1 1 integer solutions of x qe (mod p), ll of which hve orders power of q 1 ccording to Proposition Similrly, however, q e of these integers stisfy the congruence x qe (mod p) hence their orders re no more thn q e It follows tht there exist q e 1 1 q e integers of order q e 1 1. By symmetry we hve n integer of order q e i i for ech of the distinct prime fctors of p 1. And the product of these integers, by Proposition 5.1.5, is of order p 1, tht is primitive root. Exercise. How mny re primitive roots modulo 5? 7? 11? 89? 5.6 Primitive Root Theorem Primitive roots exist only modulo 1, 2, 4, p k, or 2p k for ny prime p > 2 nd k > 0. No Proof. The proof is set side s n independent ssignment.

18 WON 2 Number Theory 18 Exercise. Is there primitive root modulo 4? 8? 25? 50? 100? How mny? 5.7 Artin s Conjecture The number 2 is primitive root for infinitely mny primes. 5.8 Discrete Logrithm Problem The congruence x b (mod p) with p b cn be solved by writing nd b s powers of primitive root g modulo p. Exercise. Solve these mod-13 congruences using g = 2 with the help of the given tble x 10 (mod 13) 2. 5 x 9 (mod 13) x 3 (mod 13) x 11 (mod 13) k k % Exercise. Use this tble, in similr wy, to solve gin Exercises nd Problem Set 5 1. Find the order of 4 modulo Is 5 primitive root modulo 29? 3. Find ll the primitive roots modulo Suppose = 6. Find k for k = 2, 3, 4, 5, One of the primitive roots modulo 11 is 2. Find the rest. 6. Is there primitive root modulo ? 7. How mny primitive roots re there modulo 1250? 8. Find three primes modulo which 2 is not primitive root. 9. Solve the congruence 10 6 x 12 (mod 13). 10. Investigte true or flse. () =. (b) If n = b n then b (mod n). (c) If j k (mod n) then j k (mod n). (d) k 1 (mod n) is not possible if gcd(, n) Prove tht if n = n 1 then n must be prime. 12. Prove tht modulr inverses hve equl orders. 13. Prove tht if g is primitive root modulo p > 2 then g (p 1)/2 1 (mod p). 14. Prove tht 4 is not primitive root modulo ny prime. 15. Prove tht the product of two primitive roots modulo p > 2 is not primitive root. 16. Prove tht if p 1 (mod 4) then g is primitive root modulo p if nd only if g is too. Project 5 Secret Key Exchnge For cryptologicl purposes, Ali nd Bob need to estblish common secret key. However, the only vilble mens of communiction between them is the telephone, which they know is being tpped by the enemy. They resort to the Diffie-Hellmn Key Exchnge protocol s follows.

19 WON 2 Number Theory 19 Ali chooses lrge prime p, primitive root g, nd positive integer m < p. She gives to Bob, over the non-secure telephone line, the numbers p, g, nd g m % p but keeps m secret. In turn Bob selects secret number n nd gives to Ali g n % p. They gree tht their common secret key is g mn % p, which, employing Successive Squring Algorithm, Ali obtins from (g n ) m % p nd Bob, independently, from (g m ) n % p. If the enemy gthers this informtion (but not m nd n for they re not trnsmitted cross) they will hve to solve the congruence g x (mod p) where = g m % p or similrly = g n % p in order to cpture the secret key. But the fct is, there is no efficient lgorithm known to solve this Discrete Logrithm Problem, nd for lrge p the problem is computtionlly infesible. Assignment. Illustrte the bove ide with p = 313, g = 10, m = 97, nd n is the residue mod p of your PUN. After tht pretend you knew neither m nor n nd try to find nother wy to retrieve the secret key g mn % p. Exercise. Will this ide work if g is not primitive root modulo p? Think bout it. 6 Qudrtic Residues Definition. A number which is reltively prime to n is qudrtic residue modulo n if the congruence x 2 (mod n) hs solution. If it hs no solution then is clled qudrtic non-residue modulo n. For exmple 19 is qudrtic residue modulo 5 since (mod 5) wheres 7 is non-residue becuse x 2 7 (mod 5) hs no solution. Exercise. Find ll the qudrtic residues nd non-residues modulo 5. Definition. Let p be n odd prime. We define the so-clled Legendre symbol s follows. ( ) 1 if is qudrtic residue modulo p = 1 if is qudrtic non-residue modulo p p 0 if p For exmple we hve shown tht ( ) ( ) 19 5 = 1 nd 7 5 = 1. Henceforth the number p in the Legendre symbol ( ) p is understood n odd prime, tht is prime lrger thn Proposition (Properties of the Legendre symbol) 1. ( ) ( ) p = b p if b (mod p) 2. ( ) ( ) ( b p = b p p) 3. ( ) p (p 1)/2 (mod p) Euler s Criterion Proof. It is cler tht the definition of qudrtic residue extends to congruence clsses, thus (1). Next we fix primitive root g modulo p nd clim tht g k is qudrtic residue if nd only if k is even. Sufficiency is cler since g k = (g k/2 ) 2 when k is even. For necessity observe tht g j g k (mod p) implies 2 (p 1) (j k) by Proposition nd so j nd k must be of the sme prity. In prticulr if g k is congruent to squre modulo p then k must be even. By Proposition we my ssume = g j nd b = g k. Now b = g j+k is qudrtic residue if nd only if j + k is even, tht is both j nd k even or both odd. This is concisely expressed in (2).

20 WON 2 Number Theory 20 Finlly for the lst clim, ( ) p = 1 if nd only if = g j with j even. But then (g j ) (p 1)/2 = (g j/2 ) p 1 1 (mod p) by Fermt s Little Theorem. Conversely if j is odd, then j 1 is even nd similrly (g j ) (p 1)/2 = (g j 1 g) (p 1)/2 g (p 1)/2 (mod p). However g being primitive root implies tht this lst congruence reduces not to 1, but to 1 (mod p) by Lemm Corollry ( ) p 1 1 p = ( 1) 2 Proof. The two numbers re congruent modulo p by Euler s Criterion. However, since ech is ±1 nd p > 2, this reltion is possible only when both re equl. Exercise. Is qudrtic residue modulo p? Use different wys to nswer. 1. = 28, p = 5 2. = 48, p = 7 3. = 35, p = = 54, p = Guss Lemm If p then ( ) p = ( 1) n where n is the number of integers in the set {, 2, 3,..., p 1 } whose residues mod p re lrger thn p/2. 2 Proof. Let A denote the set in the bove sttement. Replce ech x > p/2 in the set {1, 2,..., p 1} by x p to obtin nother reduced residue system modulo p, cll it S = {±1, ±2,..., ± p 1 }. Hence n is the number of negtive integers in S which re 2 congruent modulo p to some elements in A. We clim tht for ech pir of elements in A, if j ±k (mod p) then j = k. This is true becuse p so tht the congruence cn be written j ±k (mod p) with j, ±k {1, 2,..., p 1 } S, nd S being reduced residue system forces j = k. This 2 implies tht, modulo p, the elements of A re reordering of the numbers 1, 2,..., p 1, 2 only tht n of them hve negtive sign: 2 3 p 1 2 ( 1) n p 1 2 (mod p) Cncel out the common terms since they re reltively prime to p nd we hve (p 1)/2 ( 1) n (mod p). Now pply Euler s Criterion to obtin the desired result. Exercise. Illustrte Guss Lemm with = 5 nd p = Eisenstein s Lemm If gcd(, 2p) = 1 then ( ) p = ( 1) m where m = (p 1)/2 k=1 k/p. Proof. Our gol is to show tht m is of the sme prity s the number n in Guss Lemm, thereby mking the two lemms equivlent. By definition k = k/p p + k % p where, s in the proof of Guss Lemm, the numbers k % p, for k = 1, 2,..., p 1 re congruent modulo p, perhps not in this 2 order, to 1, 2,..., p 1 but exctly n of them should hve negtive sign. Denote by 2 r s those which should hve been negtives nd the rest by s s so tht p 1 2 p 1 2 n k = k/p p + p r i + k=1 k=1 i=1 p 1 2 n j=1 s j

21 WON 2 Number Theory 21 On the other hnd we lso hve (p 1)/2 k=1 k = n i=1 r i + (p 1)/2 n j=1 s j nd subtrcting this from the lst eqution yields p 1 2 p 1 2 n n ( 1) k = k/p p + p 2 r i k=1 k=1 i=1 i=1 Since p 1 (mod 2), this in turn gives the congruence 0 (p 1)/2 k=1 k/p + n 0 (mod 2), tht is m n (mod 2) s sought. Exercise. Illustrte Eisenstein s Lemm with = 5 nd p = Corollry ( ) p 2 p = ( 1) Proof. In the previous proof, substitute = 2 in the lst displyed eqution to obtin (p 1)/2 k=1 k (p 1)/2 k=1 2k/p +n 0 (mod 2). But ech ( term ) ( 2k/p ) = 0 becuse 2k < p, wheres the left-hnd side of the congruence is 1 p 1 p = p 2 1 nd the result 8 then follows by Guss Lemm. 6.6 The Lw of Qudrtic Reciprocity If p nd q re distinct odd primes then ( ) ( ) p q = ( 1) ( p 1 2 )( q 1 2 ) q p In other words, ( ) ( ( ) ( ) p q = q p) if p or q 1 (mod 4) nd p q = q p if p q 3 (mod 4). Proof. Let P = {x 1 x p 1 q 1 } nd Q = {y 1 y }. Then P Q contins ( ) ( ) 2 2 p 1 q elements which cn be prtitioned into two subsets S 1 = {(x, y) P Q py < qx} nd S 2 = {(x, y) P Q py > qx} Note tht py = qx is not possible s p qx. For ech x P we hve (x, y) S 1 if nd only if 1 y qx/p, hence S 1 = (p 1)/2 x=1 qx/p nd similrly S 2 = Now rising 1 to the power P Q = S 1 + S 2 yields ( 1) ( p 1 2 )( q 1 2 ) (p 1)/2 = ( 1) qx/p x=1 ( 1) (q 1)/2 y=1 py/q (q 1)/2 py/q y=1 nd ccording to Eisenstein s Lemm, the right-hnd side of this is ( ( ) q p p) q. Exercise. Evlute the Legendre symbol ( ) p. 1. = 37, p = = 71, p = = 69, p = = 816, p = 239

22 WON 2 Number Theory 22 Definition. Let P = p 1 p 2 p k be the product of odd prime numbers, not necessrily distinct. Define the Jcobi symbol ( ) ( ) ( ) ( ) = P p 1 nd for convenience lso let ( ) ( ( ) ( ) ( ) ( ) 1 = 1. For exmple ) = In the cse k = 1, Jcobi symbol is relly Legendre symbol. Moreover if gcd(, P ) = 1 then the vlue of ( ) ( ) P is ±1, nd 0 otherwise. It is lso true tht if P = 1 then is qudrtic non-residue modulo P, but the converse is not necessrily true. Exercise. Is 14 qudrtic residue modulo 825? 6.7 Proposition (Properties of the Jcobi symbol) 1. ( ) ( ) P = b P if b (mod P ) 2. ( ) ( ) ( ) b P = b P P 3. ( ( ) ( ) P Q) = P Q Proof. The congruence b (mod P = p 1 p 2 p k ) implies b (mod p i ) for ech prime p i. Thus ( ) ( ) ( ) ( ) ( ) ( ) ( ) b b b = = = P p 1 p 2 p k p 2 p 1 p 2 p k p k ( ) b P by Proposition This proves (1). In very similr wy (2) follows from Proposition 6.1.2, nd (3) stright from the definition of Jcobi symbol. 6.8 The Generlized Lw of Qudrtic Reciprocity Suppose P, Q > 0 re odd. 1. ( 1 P 2. ( 2 P 3. ( P Q) ( Q P ) P 1 = ( 1) 2 ) P = ( 1) ) = ( 1) ( P 1 2 )( Q 1 2 ) No Proof. The proof is set side s n independent ssignment. Exercise. Evlute ( ) p with the help of Jcobi symbol. 1. = 21, p = = 35, p = = 69, p = = 816, p = Modulr Squre Root If is qudrtic residue modulo p 3 (mod 4) then the congruence x 2 (mod p) hs exctly two solutions given by x ± (p+1)/4 (mod p). Proof. Using Euler s Criterion, ( (p+1)/4 ) 2 = (p+1)/2 = (p 1)/2 ( ) p = (mod p). Hence x 2 (mod p) implies x ± (p+1)/4 (mod p) by Problem 3.14 nd these two solutions re distinct since p 2. Exercise. Find ll solutions.

23 WON 2 Number Theory x 2 2 (mod 23) 2. x 2 2x (mod 11) 3. x 2 10 (mod 21) 4. x 2 31 (mod 55) Problem Set 6 1. Find ll the qudrtic residues nd non-residues modulo Evlute the Legendre symbol ( ) 7 11 using () Euler s Criterion (b) Guss Lemm (c) Eisenstein s Lemm (d) Qudrtic Reciprocity Lw. 3. Does the congruence x (mod 557) hve solution? 4. Does the congruence x 2 6x 2 (mod 79) hve solution? 5. Does the congruence x 2 5x (mod 29) hve solution? 6. Evlute the Jcobi symbol ( ) Chrcterize the prime numbers modulo which 5 is qudrtic residue. 8. Find ll solutions of the congruence x 2 8 (mod 31). 9. Find ll solutions of the congruence 2x 2 + x (mod 31). 10. Find ll solutions of the congruence x 2 29 (mod 35). 11. Investigte true or flse. () ( ) = 1 thus 713 is qudrtic residue modulo (b) ( ) = 1 thus 442 is qudrtic non-residue modulo 751. (c) ( ) 2 15 = 1 thus 2 is qudrtic residue modulo 15. (d) ( ) 7 15 = 1 thus 7 is qudrtic non-residue modulo Suppose tht is reltively prime to n odd prime p. Prove tht the congruence x 2 (mod p) hs either exctly two solutions or none. 13. Prove tht 1 is qudrtic residue modulo p > 2 if nd only if p 1 (mod 4). 14. Prove tht 2 is qudrtic residue modulo p > 2 if nd only if p ±1 (mod 8). 15. Prove tht 2 is qudrtic residue modulo p > 2 if nd only if p 1, 3 (mod 8). 16. Prove tht 3 is qudrtic residue modulo p > 2 if nd only if p 1 (mod 6). Project 6 Electronic Coin Tossing In gme of coin tossing, two plyers hve fifty-fifty chnce of winning by betting on the outcome, either Hed or Til. How cn this gme be plyed electroniclly, over emil for instnce? Ali knows two lrge primes p q 3 (mod 4) nd sends the product n = pq to Bob. In turn Bob chooses n integer h < n nd sends = h 2 % n to Ali. Using 6.9 nd Chinese Reminder Theorem, Ali is ble to solve x 2 (mod n) nd finds four roots in the forms x ±h, ±t (mod n). Ali now guesses Bob s number, either h or t. If Ali sends h to Bob, Ali wins. If, however, she picks t then Bob wins nd he proves it by returning to her the fctors p, q, one of which equls gcd(h + t, n), hence cn be computed in no time using the Eucliden Algorithm. Exercise. Verify tht the congruence x 2 (mod pq) hs indeed four roots whose residues mod pq equl h, pq h, t, pq t. Also prove tht gcd(h + t, pq) = p or q. Assignment. Illustrte the bove discussion using h your 6-digit PUN nd n = , which supposedly you hve fctored into two primes bck in Project 4. First compute = h 2 % n then find the four roots of x 2 (mod n) nd finlly verify tht gcd(h+t, n) is one of the two prime fctors of n.

NUMBER THEORY AMIN WITNO

NUMBER THEORY AMIN WITNO NUMBER THEORY AMIN WITNO.. w w w. w i t n o. c o m Number Theory Outlines and Problem Sets Amin Witno Preface These notes are mere outlines for the course Math 313 given at Philadelphia

More information

MATH 118 PROBLEM SET 6

MATH 118 PROBLEM SET 6 MATH 118 PROBLEM SET 6 WASEEM LUTFI, GABRIEL MATSON, AND AMY PIRCHER Section 1 #16: Show tht if is qudrtic residue modulo m, nd b 1 (mod m, then b is lso qudrtic residue Then rove tht the roduct of the

More information

LECTURE 9: QUADRATIC RESIDUES AND THE LAW OF QUADRATIC RECIPROCITY

LECTURE 9: QUADRATIC RESIDUES AND THE LAW OF QUADRATIC RECIPROCITY LECTURE 9: QUADRATIC RESIDUES AND THE LAW OF QUADRATIC RECIPROCITY 1. Bsic roerties of qudrtic residues We now investigte residues with secil roerties of lgebric tye. Definition 1.1. (i) When (, m) 1 nd

More information

Primitive Roots. Chapter Orders and Primitive Roots

Primitive Roots. Chapter Orders and Primitive Roots Chapter 5 Primitive Roots The name primitive root applies to a number a whose powers can be used to represent a reduced residue system modulo n. Primitive roots are therefore generators in that sense,

More information

Example. Check that the Jacobian of the transformation to spherical coordinates is

Example. Check that the Jacobian of the transformation to spherical coordinates is lss, given on Feb 3, 2, for Mth 3, Winter 2 Recll tht the fctor which ppers in chnge of vrible formul when integrting is the Jcobin, which is the determinnt of mtrix of first order prtil derivtives. Exmple.

More information

Spiral Tilings with C-curves

Spiral Tilings with C-curves Spirl Tilings with -curves Using ombintorics to Augment Trdition hris K. Plmer 19 North Albny Avenue hicgo, Illinois, 0 chris@shdowfolds.com www.shdowfolds.com Abstrct Spirl tilings used by rtisns through

More information

Math Circles Finite Automata Question Sheet 3 (Solutions)

Math Circles Finite Automata Question Sheet 3 (Solutions) Mth Circles Finite Automt Question Sheet 3 (Solutions) Nickols Rollick nrollick@uwterloo.c Novemer 2, 28 Note: These solutions my give you the nswers to ll the prolems, ut they usully won t tell you how

More information

Theme: Don t get mad. Learn mod.

Theme: Don t get mad. Learn mod. FERURY When 1 is divided by 5, the reminder is. nother wy to sy this is opyright 015 The Ntionl ouncil of Techers of Mthemtics, Inc. www.nctm.org. ll rights reserved. This mteril my not be copied or distributed

More information

First Round Solutions Grades 4, 5, and 6

First Round Solutions Grades 4, 5, and 6 First Round Solutions Grdes 4, 5, nd 1) There re four bsic rectngles not mde up of smller ones There re three more rectngles mde up of two smller ones ech, two rectngles mde up of three smller ones ech,

More information

CS 135: Computer Architecture I. Boolean Algebra. Basic Logic Gates

CS 135: Computer Architecture I. Boolean Algebra. Basic Logic Gates Bsic Logic Gtes : Computer Architecture I Boolen Algebr Instructor: Prof. Bhgi Nrhri Dept. of Computer Science Course URL: www.ses.gwu.edu/~bhgiweb/cs35/ Digitl Logic Circuits We sw how we cn build the

More information

Domination and Independence on Square Chessboard

Domination and Independence on Square Chessboard Engineering nd Technology Journl Vol. 5, Prt, No. 1, 017 A.A. Omrn Deprtment of Mthemtics, College of Eduction for Pure Science, University of bylon, bylon, Irq pure.hmed.omrn@uobby lon.edu.iq Domintion

More information

Lecture 20. Intro to line integrals. Dan Nichols MATH 233, Spring 2018 University of Massachusetts.

Lecture 20. Intro to line integrals. Dan Nichols MATH 233, Spring 2018 University of Massachusetts. Lecture 2 Intro to line integrls Dn Nichols nichols@mth.umss.edu MATH 233, Spring 218 University of Msschusetts April 12, 218 (2) onservtive vector fields We wnt to determine if F P (x, y), Q(x, y) is

More information

Introduction to Modular Arithmetic

Introduction to Modular Arithmetic 1 Integers modulo n 1.1 Preliminaries Introduction to Modular Arithmetic Definition 1.1.1 (Equivalence relation). Let R be a relation on the set A. Recall that a relation R is a subset of the cartesian

More information

Section 16.3 Double Integrals over General Regions

Section 16.3 Double Integrals over General Regions Section 6.3 Double Integrls over Generl egions Not ever region is rectngle In the lst two sections we considered the problem of integrting function of two vribles over rectngle. This sitution however is

More information

SOLUTIONS TO PROBLEM SET 5. Section 9.1

SOLUTIONS TO PROBLEM SET 5. Section 9.1 SOLUTIONS TO PROBLEM SET 5 Section 9.1 Exercise 2. Recall that for (a, m) = 1 we have ord m a divides φ(m). a) We have φ(11) = 10 thus ord 11 3 {1, 2, 5, 10}. We check 3 1 3 (mod 11), 3 2 9 (mod 11), 3

More information

CHAPTER 2. Modular Arithmetic

CHAPTER 2. Modular Arithmetic CHAPTER 2 Modular Arithmetic In studying the integers we have seen that is useful to write a = qb + r. Often we can solve problems by considering only the remainder, r. This throws away some of the information,

More information

Polar Coordinates. July 30, 2014

Polar Coordinates. July 30, 2014 Polr Coordintes July 3, 4 Sometimes it is more helpful to look t point in the xy-plne not in terms of how fr it is horizontlly nd verticlly (this would men looking t the Crtesin, or rectngulr, coordintes

More information

Number Theory. Konkreetne Matemaatika

Number Theory. Konkreetne Matemaatika ITT9131 Number Theory Konkreetne Matemaatika Chapter Four Divisibility Primes Prime examples Factorial Factors Relative primality `MOD': the Congruence Relation Independent Residues Additional Applications

More information

Energy Harvesting Two-Way Channels With Decoding and Processing Costs

Energy Harvesting Two-Way Channels With Decoding and Processing Costs IEEE TRANSACTIONS ON GREEN COMMUNICATIONS AND NETWORKING, VOL., NO., MARCH 07 3 Energy Hrvesting Two-Wy Chnnels With Decoding nd Processing Costs Ahmed Arf, Student Member, IEEE, Abdulrhmn Bknin, Student

More information

Unit 1: Chapter 4 Roots & Powers

Unit 1: Chapter 4 Roots & Powers Unit 1: Chpter 4 Roots & Powers Big Ides Any number tht cn be written s the frction mm, nn 0, where m nd n re integers, is nn rtionl. Eponents cn be used to represent roots nd reciprocls of rtionl numbers.

More information

PT. Primarity Tests Given an natural number n, we want to determine if n is a prime number.

PT. Primarity Tests Given an natural number n, we want to determine if n is a prime number. PT. Primarity Tests Given an natural number n, we want to determine if n is a prime number. (PT.1) If a number m of the form m = 2 n 1, where n N, is a Mersenne number. If a Mersenne number m is also a

More information

Foundations of Cryptography

Foundations of Cryptography Foundations of Cryptography Ville Junnila viljun@utu.fi Department of Mathematics and Statistics University of Turku 2015 Ville Junnila viljun@utu.fi Lecture 10 1 of 17 The order of a number (mod n) Definition

More information

9.4. ; 65. A family of curves has polar equations. ; 66. The astronomer Giovanni Cassini ( ) studied the family of curves with polar equations

9.4. ; 65. A family of curves has polar equations. ; 66. The astronomer Giovanni Cassini ( ) studied the family of curves with polar equations 54 CHAPTER 9 PARAMETRIC EQUATINS AND PLAR CRDINATES 49. r, 5. r sin 3, 5 54 Find the points on the given curve where the tngent line is horizontl or verticl. 5. r 3 cos 5. r e 53. r cos 54. r sin 55. Show

More information

Wilson s Theorem and Fermat s Theorem

Wilson s Theorem and Fermat s Theorem Wilson s Theorem and Fermat s Theorem 7-27-2006 Wilson s theorem says that p is prime if and only if (p 1)! = 1 (mod p). Fermat s theorem says that if p is prime and p a, then a p 1 = 1 (mod p). Wilson

More information

MAXIMUM FLOWS IN FUZZY NETWORKS WITH FUNNEL-SHAPED NODES

MAXIMUM FLOWS IN FUZZY NETWORKS WITH FUNNEL-SHAPED NODES MAXIMUM FLOWS IN FUZZY NETWORKS WITH FUNNEL-SHAPED NODES Romn V. Tyshchuk Informtion Systems Deprtment, AMI corportion, Donetsk, Ukrine E-mil: rt_science@hotmil.com 1 INTRODUCTION During the considertion

More information

Solutions for the Practice Final

Solutions for the Practice Final Solutions for the Practice Final 1. Ian and Nai play the game of todo, where at each stage one of them flips a coin and then rolls a die. The person who played gets as many points as the number rolled

More information

10.4 AREAS AND LENGTHS IN POLAR COORDINATES

10.4 AREAS AND LENGTHS IN POLAR COORDINATES 65 CHAPTER PARAMETRIC EQUATINS AND PLAR CRDINATES.4 AREAS AND LENGTHS IN PLAR CRDINATES In this section we develop the formul for the re of region whose oundry is given y polr eqution. We need to use the

More information

Section 17.2: Line Integrals. 1 Objectives. 2 Assignments. 3 Maple Commands. 1. Compute line integrals in IR 2 and IR Read Section 17.

Section 17.2: Line Integrals. 1 Objectives. 2 Assignments. 3 Maple Commands. 1. Compute line integrals in IR 2 and IR Read Section 17. Section 7.: Line Integrls Objectives. ompute line integrls in IR nd IR 3. Assignments. Red Section 7.. Problems:,5,9,,3,7,,4 3. hllenge: 6,3,37 4. Red Section 7.3 3 Mple ommnds Mple cn ctully evlute line

More information

Kirchhoff s Rules. Kirchhoff s Laws. Kirchhoff s Rules. Kirchhoff s Laws. Practice. Understanding SPH4UW. Kirchhoff s Voltage Rule (KVR):

Kirchhoff s Rules. Kirchhoff s Laws. Kirchhoff s Rules. Kirchhoff s Laws. Practice. Understanding SPH4UW. Kirchhoff s Voltage Rule (KVR): SPH4UW Kirchhoff s ules Kirchhoff s oltge ule (K): Sum of voltge drops round loop is zero. Kirchhoff s Lws Kirchhoff s Current ule (KC): Current going in equls current coming out. Kirchhoff s ules etween

More information

Discrete Math Class 4 ( )

Discrete Math Class 4 ( ) Discrete Math 37110 - Class 4 (2016-10-06) 41 Division vs congruences Instructor: László Babai Notes taken by Jacob Burroughs Revised by instructor DO 41 If m ab and gcd(a, m) = 1, then m b DO 42 If gcd(a,

More information

Fermat s little theorem. RSA.

Fermat s little theorem. RSA. .. Computing large numbers modulo n (a) In modulo arithmetic, you can always reduce a large number to its remainder a a rem n (mod n). (b) Addition, subtraction, and multiplication preserve congruence:

More information

Assignment 2. Due: Monday Oct. 15, :59pm

Assignment 2. Due: Monday Oct. 15, :59pm Introduction To Discrete Math Due: Monday Oct. 15, 2012. 11:59pm Assignment 2 Instructor: Mohamed Omar Math 6a For all problems on assignments, you are allowed to use the textbook, class notes, and other

More information

To be able to determine the quadratic character of an arbitrary number mod p (p an odd prime), we. The first (and most delicate) case concerns 2

To be able to determine the quadratic character of an arbitrary number mod p (p an odd prime), we. The first (and most delicate) case concerns 2 Quadratic Reciprocity To be able to determine the quadratic character of an arbitrary number mod p (p an odd prime), we need to be able to evaluate q for any prime q. The first (and most delicate) case

More information

Congruences for Stirling Numbers of the Second Kind Modulo 5

Congruences for Stirling Numbers of the Second Kind Modulo 5 Southest Asin Bulletin of Mthemtics (2013 37: 795 800 Southest Asin Bulletin of Mthemtics c SEAMS. 2013 Congruences for Stirling Numbers of the Second Kind Modulo 5 Jinrong Zho School of Economic Mthemtics,

More information

6. Find an inverse of a modulo m for each of these pairs of relatively prime integers using the method

6. Find an inverse of a modulo m for each of these pairs of relatively prime integers using the method Exercises Exercises 1. Show that 15 is an inverse of 7 modulo 26. 2. Show that 937 is an inverse of 13 modulo 2436. 3. By inspection (as discussed prior to Example 1), find an inverse of 4 modulo 9. 4.

More information

METHOD OF LOCATION USING SIGNALS OF UNKNOWN ORIGIN. Inventor: Brian L. Baskin

METHOD OF LOCATION USING SIGNALS OF UNKNOWN ORIGIN. Inventor: Brian L. Baskin METHOD OF LOCATION USING SIGNALS OF UNKNOWN ORIGIN Inventor: Brin L. Bskin 1 ABSTRACT The present invention encompsses method of loction comprising: using plurlity of signl trnsceivers to receive one or

More information

SOLVING TRIANGLES USING THE SINE AND COSINE RULES

SOLVING TRIANGLES USING THE SINE AND COSINE RULES Mthemtics Revision Guides - Solving Generl Tringles - Sine nd Cosine Rules Pge 1 of 17 M.K. HOME TUITION Mthemtics Revision Guides Level: GCSE Higher Tier SOLVING TRIANGLES USING THE SINE AND COSINE RULES

More information

Number Theory - Divisibility Number Theory - Congruences. Number Theory. June 23, Number Theory

Number Theory - Divisibility Number Theory - Congruences. Number Theory. June 23, Number Theory - Divisibility - Congruences June 23, 2014 Primes - Divisibility - Congruences Definition A positive integer p is prime if p 2 and its only positive factors are itself and 1. Otherwise, if p 2, then p

More information

L29&30 - RSA Cryptography

L29&30 - RSA Cryptography L29&30 - RSA Cryptography CSci/Math 2112 20&22 July 2015 1 / 13 Notation We write a mod n for the integer b such that 0 b < n and a b (mod n). 2 / 13 Calculating Large Powers Modulo n Example 1 What is

More information

(CATALYST GROUP) B"sic Electric"l Engineering

(CATALYST GROUP) Bsic Electricl Engineering (CATALYST GROUP) B"sic Electric"l Engineering 1. Kirchhoff s current l"w st"tes th"t (") net current flow "t the junction is positive (b) Hebr"ic sum of the currents meeting "t the junction is zero (c)

More information

Solutions to exercise 1 in ETS052 Computer Communication

Solutions to exercise 1 in ETS052 Computer Communication Solutions to exercise in TS52 Computer Communiction 23 Septemer, 23 If it occupies millisecond = 3 seconds, then second is occupied y 3 = 3 its = kps. kps If it occupies 2 microseconds = 2 6 seconds, then

More information

General Augmented Rook Boards & Product Formulas

General Augmented Rook Boards & Product Formulas Forml Power Series nd Algebric Combintorics Séries Formelles et Combintoire Algébriue Sn Diego, Cliforni 006 Generl Augmented Rook Bords & Product Formuls Brin K Miceli Abstrct There re number of so-clled

More information

p 1 MAX(a,b) + MIN(a,b) = a+b n m means that m is a an integer multiple of n. Greatest Common Divisor: We say that n divides m.

p 1 MAX(a,b) + MIN(a,b) = a+b n m means that m is a an integer multiple of n. Greatest Common Divisor: We say that n divides m. Great Theoretical Ideas In Computer Science Steven Rudich CS - Spring Lecture Feb, Carnegie Mellon University Modular Arithmetic and the RSA Cryptosystem p- p MAX(a,b) + MIN(a,b) = a+b n m means that m

More information

CHAPTER 2 LITERATURE STUDY

CHAPTER 2 LITERATURE STUDY CHAPTER LITERATURE STUDY. Introduction Multipliction involves two bsic opertions: the genertion of the prtil products nd their ccumultion. Therefore, there re two possible wys to speed up the multipliction:

More information

Mathematics Explorers Club Fall 2012 Number Theory and Cryptography

Mathematics Explorers Club Fall 2012 Number Theory and Cryptography Mathematics Explorers Club Fall 2012 Number Theory and Cryptography Chapter 0: Introduction Number Theory enjoys a very long history in short, number theory is a study of integers. Mathematicians over

More information

ECE 274 Digital Logic. Digital Design. Datapath Components Shifters, Comparators, Counters, Multipliers Digital Design

ECE 274 Digital Logic. Digital Design. Datapath Components Shifters, Comparators, Counters, Multipliers Digital Design ECE 27 Digitl Logic Shifters, Comprtors, Counters, Multipliers Digitl Design..7 Digitl Design Chpter : Slides to ccompny the textbook Digitl Design, First Edition, by Frnk Vhid, John Wiley nd Sons Publishers,

More information

UNIVERSITY OF MANITOBA DATE: December 7, FINAL EXAMINATION TITLE PAGE TIME: 3 hours EXAMINER: M. Davidson

UNIVERSITY OF MANITOBA DATE: December 7, FINAL EXAMINATION TITLE PAGE TIME: 3 hours EXAMINER: M. Davidson TITLE PAGE FAMILY NAME: (Print in ink) GIVEN NAME(S): (Print in ink) STUDENT NUMBER: SEAT NUMBER: SIGNATURE: (in ink) (I understand that cheating is a serious offense) INSTRUCTIONS TO STUDENTS: This is

More information

The Chinese Remainder Theorem

The Chinese Remainder Theorem The Chinese Remainder Theorem Theorem. Let n 1,..., n r be r positive integers relatively prime in pairs. (That is, gcd(n i, n j ) = 1 whenever 1 i < j r.) Let a 1,..., a r be any r integers. Then the

More information

Synchronous Machine Parameter Measurement

Synchronous Machine Parameter Measurement Synchronous Mchine Prmeter Mesurement 1 Synchronous Mchine Prmeter Mesurement Introduction Wound field synchronous mchines re mostly used for power genertion but lso re well suited for motor pplictions

More information

Student Book SERIES. Fractions. Name

Student Book SERIES. Fractions. Name D Student Book Nme Series D Contents Topic Introducing frctions (pp. ) modelling frctions frctions of collection compring nd ordering frctions frction ingo pply Dte completed / / / / / / / / Topic Types

More information

Module 9. DC Machines. Version 2 EE IIT, Kharagpur

Module 9. DC Machines. Version 2 EE IIT, Kharagpur Module 9 DC Mchines Version EE IIT, Khrgpur esson 40 osses, Efficiency nd Testing of D.C. Mchines Version EE IIT, Khrgpur Contents 40 osses, efficiency nd testing of D.C. mchines (esson-40) 4 40.1 Gols

More information

ON THE EQUATION a x x (mod b) Jam Germain

ON THE EQUATION a x x (mod b) Jam Germain ON THE EQUATION a (mod b) Jam Germain Abstract. Recently Jimenez and Yebra [3] constructed, for any given a and b, solutions to the title equation. Moreover they showed how these can be lifted to higher

More information

Collection of rules, techniques and theorems for solving polynomial congruences 11 April 2012 at 22:02

Collection of rules, techniques and theorems for solving polynomial congruences 11 April 2012 at 22:02 Collection of rules, techniques and theorems for solving polynomial congruences 11 April 2012 at 22:02 Public Polynomial congruences come up constantly, even when one is dealing with much deeper problems

More information

Discrete Mathematics & Mathematical Reasoning Multiplicative Inverses and Some Cryptography

Discrete Mathematics & Mathematical Reasoning Multiplicative Inverses and Some Cryptography Discrete Mathematics & Mathematical Reasoning Multiplicative Inverses and Some Cryptography Colin Stirling Informatics Some slides based on ones by Myrto Arapinis Colin Stirling (Informatics) Discrete

More information

Lecture 16. Double integrals. Dan Nichols MATH 233, Spring 2018 University of Massachusetts.

Lecture 16. Double integrals. Dan Nichols MATH 233, Spring 2018 University of Massachusetts. Leture 16 Double integrls Dn Nihols nihols@mth.umss.edu MATH 233, Spring 218 University of Msshusetts Mrh 27, 218 (2) iemnn sums for funtions of one vrible Let f(x) on [, b]. We n estimte the re under

More information

Public Key Encryption

Public Key Encryption Math 210 Jerry L. Kazdan Public Key Encryption The essence of this procedure is that as far as we currently know, it is difficult to factor a number that is the product of two primes each having many,

More information

Joanna Towler, Roading Engineer, Professional Services, NZTA National Office Dave Bates, Operations Manager, NZTA National Office

Joanna Towler, Roading Engineer, Professional Services, NZTA National Office Dave Bates, Operations Manager, NZTA National Office . TECHNICA MEMOANDM To Cc repred By Endorsed By NZTA Network Mngement Consultnts nd Contrctors NZTA egionl Opertions Mngers nd Are Mngers Dve Btes, Opertions Mnger, NZTA Ntionl Office Jonn Towler, oding

More information

Student Book SERIES. Patterns and Algebra. Name

Student Book SERIES. Patterns and Algebra. Name E Student Book 3 + 7 5 + 5 Nme Contents Series E Topic Ptterns nd functions (pp. ) identifying nd creting ptterns skip counting completing nd descriing ptterns predicting repeting ptterns predicting growing

More information

Number Theory/Cryptography (part 1 of CSC 282)

Number Theory/Cryptography (part 1 of CSC 282) Number Theory/Cryptography (part 1 of CSC 282) http://www.cs.rochester.edu/~stefanko/teaching/11cs282 1 Schedule The homework is due Sep 8 Graded homework will be available at noon Sep 9, noon. EXAM #1

More information

Vector Calculus. 1 Line Integrals

Vector Calculus. 1 Line Integrals Vector lculus 1 Line Integrls Mss problem. Find the mss M of very thin wire whose liner density function (the mss per unit length) is known. We model the wire by smooth curve between two points P nd Q

More information

Synchronous Generator Line Synchronization

Synchronous Generator Line Synchronization Synchronous Genertor Line Synchroniztion 1 Synchronous Genertor Line Synchroniztion Introduction One issue in power genertion is synchronous genertor strting. Typiclly, synchronous genertor is connected

More information

Make Your Math Super Powered

Make Your Math Super Powered Mke Your Mth Super Powered: Use Gmes, Chllenges, nd Puzzles Where s the fun? Lern Mth Workshop model by prticipting in one nd explore fun nocost/low-cost gmes nd puzzles tht you cn esily bring into your

More information

University of North Carolina-Charlotte Department of Electrical and Computer Engineering ECGR 4143/5195 Electrical Machinery Fall 2009

University of North Carolina-Charlotte Department of Electrical and Computer Engineering ECGR 4143/5195 Electrical Machinery Fall 2009 Problem 1: Using DC Mchine University o North Crolin-Chrlotte Deprtment o Electricl nd Computer Engineering ECGR 4143/5195 Electricl Mchinery Fll 2009 Problem Set 4 Due: Thursdy October 8 Suggested Reding:

More information

Exercise 1-1. The Sine Wave EXERCISE OBJECTIVE DISCUSSION OUTLINE. Relationship between a rotating phasor and a sine wave DISCUSSION

Exercise 1-1. The Sine Wave EXERCISE OBJECTIVE DISCUSSION OUTLINE. Relationship between a rotating phasor and a sine wave DISCUSSION Exercise 1-1 The Sine Wve EXERCISE OBJECTIVE When you hve completed this exercise, you will be fmilir with the notion of sine wve nd how it cn be expressed s phsor rotting round the center of circle. You

More information

Math 116 Calculus II

Math 116 Calculus II Mth 6 Clculus II Contents 7 Additionl topics in Integrtion 7. Integrtion by prts..................................... 7.4 Numericl Integrtion.................................... 7 7.5 Improper Integrl......................................

More information

Math 127: Equivalence Relations

Math 127: Equivalence Relations Math 127: Equivalence Relations Mary Radcliffe 1 Equivalence Relations Relations can take many forms in mathematics. In these notes, we focus especially on equivalence relations, but there are many other

More information

Solutions for the Practice Questions

Solutions for the Practice Questions Solutions for the Practice Questions Question 1. Find all solutions to the congruence 13x 12 (mod 35). Also, answer the following questions about the solutions to the above congruence. Are there solutions

More information

MAT Modular arithmetic and number theory. Modular arithmetic

MAT Modular arithmetic and number theory. Modular arithmetic Modular arithmetic 1 Modular arithmetic may seem like a new and strange concept at first The aim of these notes is to describe it in several different ways, in the hope that you will find at least one

More information

The Discussion of this exercise covers the following points:

The Discussion of this exercise covers the following points: Exercise 4 Bttery Chrging Methods EXERCISE OBJECTIVE When you hve completed this exercise, you will be fmilir with the different chrging methods nd chrge-control techniques commonly used when chrging Ni-MI

More information

Application Note. Differential Amplifier

Application Note. Differential Amplifier Appliction Note AN367 Differentil Amplifier Author: Dve n Ess Associted Project: Yes Associted Prt Fmily: CY8C9x66, CY8C7x43, CY8C4x3A PSoC Designer ersion: 4. SP3 Abstrct For mny sensing pplictions, desirble

More information

Math 319 Problem Set #7 Solution 18 April 2002

Math 319 Problem Set #7 Solution 18 April 2002 Math 319 Problem Set #7 Solution 18 April 2002 1. ( 2.4, problem 9) Show that if x 2 1 (mod m) and x / ±1 (mod m) then 1 < (x 1, m) < m and 1 < (x + 1, m) < m. Proof: From x 2 1 (mod m) we get m (x 2 1).

More information

Defining the Rational Numbers

Defining the Rational Numbers MATH10 College Mthemtis - Slide Set 2 1. Rtionl Numers 1. Define the rtionl numers. 2. Redue rtionl numers.. Convert etween mixed numers nd improper frtions. 4. Express rtionl numers s deimls.. Express

More information

Geometric quantities for polar curves

Geometric quantities for polar curves Roerto s Notes on Integrl Clculus Chpter 5: Bsic pplictions of integrtion Section 10 Geometric quntities for polr curves Wht you need to know lredy: How to use integrls to compute res nd lengths of regions

More information

Samantha s Strategies page 1 of 2

Samantha s Strategies page 1 of 2 Unit 1 Module 2 Session 3 Smnth s Strtegies pge 1 of 2 Smnth hs been working with vriety of multiplition strtegies. 1 Write n expression to desribe eh of the sttements Smnth mde. To solve 18 20, I find

More information

Example: Modulo 11: Since Z p is cyclic, there is a generator. Let g be a generator of Z p.

Example: Modulo 11: Since Z p is cyclic, there is a generator. Let g be a generator of Z p. Qudrtic Residues Defiitio: The umbers 0, 1,,, ( mod, re clled udrtic residues modulo Numbers which re ot udrtic residues modulo re clled udrtic o-residues modulo Exmle: Modulo 11: Itroductio to Number

More information

Solutions to Exam 1. Problem 1. a) State Fermat s Little Theorem and Euler s Theorem. b) Let m, n be relatively prime positive integers.

Solutions to Exam 1. Problem 1. a) State Fermat s Little Theorem and Euler s Theorem. b) Let m, n be relatively prime positive integers. Solutions to Exam 1 Problem 1. a) State Fermat s Little Theorem and Euler s Theorem. b) Let m, n be relatively rime ositive integers. Prove that m φ(n) + n φ(m) 1 (mod mn). c) Find the remainder of 1 008

More information

Algebra Practice. Dr. Barbara Sandall, Ed.D., and Travis Olson, M.S.

Algebra Practice. Dr. Barbara Sandall, Ed.D., and Travis Olson, M.S. By Dr. Brr Sndll, Ed.D., Dr. Melfried Olson, Ed.D., nd Trvis Olson, M.S. COPYRIGHT 2006 Mrk Twin Medi, Inc. ISBN 978-1-58037-754-6 Printing No. 404042-EB Mrk Twin Medi, Inc., Pulishers Distriuted y Crson-Dellos

More information

Exam 1 7 = = 49 2 ( ) = = 7 ( ) =

Exam 1 7 = = 49 2 ( ) = = 7 ( ) = Exam 1 Problem 1. a) Define gcd(a, b). Using Euclid s algorithm comute gcd(889, 168). Then find x, y Z such that gcd(889, 168) = x 889 + y 168 (check your answer!). b) Let a be an integer. Prove that gcd(3a

More information

The Math Learning Center PO Box 12929, Salem, Oregon Math Learning Center

The Math Learning Center PO Box 12929, Salem, Oregon Math Learning Center Resource Overview Quntile Mesure: Skill or Concept: 300Q Model the concept of ddition for sums to 10. (QT N 36) Model the concept of sutrction using numers less thn or equl to 10. (QT N 37) Write ddition

More information

University of British Columbia. Math 312, Midterm, 6th of June 2017

University of British Columbia. Math 312, Midterm, 6th of June 2017 University of British Columbia Math 312, Midterm, 6th of June 2017 Name (please be legible) Signature Student number Duration: 90 minutes INSTRUCTIONS This test has 7 problems for a total of 100 points.

More information

Understanding Basic Analog Ideal Op Amps

Understanding Basic Analog Ideal Op Amps Appliction Report SLAA068A - April 2000 Understnding Bsic Anlog Idel Op Amps Ron Mncini Mixed Signl Products ABSTRACT This ppliction report develops the equtions for the idel opertionl mplifier (op mp).

More information

b) Find all positive integers smaller than 200 which leave remainder 1, 3, 4 upon division by 3, 5, 7 respectively.

b) Find all positive integers smaller than 200 which leave remainder 1, 3, 4 upon division by 3, 5, 7 respectively. Solutions to Exam 1 Problem 1. a) State Fermat s Little Theorem and Euler s Theorem. b) Let m, n be relatively prime positive integers. Prove that m φ(n) + n φ(m) 1 (mod mn). Solution: a) Fermat s Little

More information

Practice Midterm 2 Solutions

Practice Midterm 2 Solutions Practice Midterm 2 Solutions May 30, 2013 (1) We want to show that for any odd integer a coprime to 7, a 3 is congruent to 1 or 1 mod 7. In fact, we don t need the assumption that a is odd. By Fermat s

More information

The Chinese Remainder Theorem

The Chinese Remainder Theorem The Chinese Remainder Theorem Theorem. Let m and n be two relatively prime positive integers. Let a and b be any two integers. Then the two congruences x a (mod m) x b (mod n) have common solutions. Any

More information

Polar coordinates 5C. 1 a. a 4. π = 0 (0) is a circle centre, 0. and radius. The area of the semicircle is π =. π a

Polar coordinates 5C. 1 a. a 4. π = 0 (0) is a circle centre, 0. and radius. The area of the semicircle is π =. π a Polr coordintes 5C r cos Are cos d (cos + ) sin + () + 8 cos cos r cos is circle centre, nd rdius. The re of the semicircle is. 8 Person Eduction Ltd 8. Copying permitted for purchsing institution only.

More information

Algorithmic Number Theory and Cryptography (CS 303)

Algorithmic Number Theory and Cryptography (CS 303) Algorithmic Number Theory and Cryptography (CS 303) Modular Arithmetic and the RSA Public Key Cryptosystem Jeremy R. Johnson 1 Introduction Objective: To understand what a public key cryptosystem is and

More information

Algorithms for Memory Hierarchies Lecture 14

Algorithms for Memory Hierarchies Lecture 14 Algorithms for emory Hierrchies Lecture 4 Lecturer: Nodri Sitchinv Scribe: ichel Hmnn Prllelism nd Cche Obliviousness The combintion of prllelism nd cche obliviousness is n ongoing topic of reserch, in

More information

Interference Cancellation Method without Feedback Amount for Three Users Interference Channel

Interference Cancellation Method without Feedback Amount for Three Users Interference Channel Open Access Librry Journl 07, Volume, e57 ISSN Online: -97 ISSN Print: -9705 Interference Cncelltion Method without Feedbc Amount for Three Users Interference Chnnel Xini Tin, otin Zhng, Wenie Ji School

More information

Synchronous Machine Parameter Measurement

Synchronous Machine Parameter Measurement Synchronous Mchine Prmeter Mesurement 1 Synchronous Mchine Prmeter Mesurement Introduction Wound field synchronous mchines re mostly used for power genertion but lso re well suited for motor pplictions

More information

& Y Connected resistors, Light emitting diode.

& Y Connected resistors, Light emitting diode. & Y Connected resistors, Light emitting diode. Experiment # 02 Ojectives: To get some hndson experience with the physicl instruments. To investigte the equivlent resistors, nd Y connected resistors, nd

More information

An interesting class of problems of a computational nature ask for the standard residue of a power of a number, e.g.,

An interesting class of problems of a computational nature ask for the standard residue of a power of a number, e.g., Binary exponentiation An interesting class of problems of a computational nature ask for the standard residue of a power of a number, e.g., What are the last two digits of the number 2 284? In the absence

More information

EE Controls Lab #2: Implementing State-Transition Logic on a PLC

EE Controls Lab #2: Implementing State-Transition Logic on a PLC Objective: EE 44 - Controls Lb #2: Implementing Stte-rnsition Logic on PLC ssuming tht speed is not of essence, PLC's cn be used to implement stte trnsition logic. he dvntge of using PLC over using hrdwre

More information

LECTURE 3: CONGRUENCES. 1. Basic properties of congruences We begin by introducing some definitions and elementary properties.

LECTURE 3: CONGRUENCES. 1. Basic properties of congruences We begin by introducing some definitions and elementary properties. LECTURE 3: CONGRUENCES 1. Basic properties of congruences We begin by introducing some definitions and elementary properties. Definition 1.1. Suppose that a, b Z and m N. We say that a is congruent to

More information

1 tray of toffee 1 bar of toffee. 10 In the decimal number, 0 7, the 7 refers to 7 tenths or

1 tray of toffee 1 bar of toffee. 10 In the decimal number, 0 7, the 7 refers to 7 tenths or Chpter 3 Deciml Numers Do you know wht DECIMAL is? In chpter, we delt with units, s, 0 s nd 00 s. When you tke single unit nd divide it into (or 0 or 00) its, wht we then hve re deciml frctions of whole

More information

Number Theory and Security in the Digital Age

Number Theory and Security in the Digital Age Number Theory and Security in the Digital Age Lola Thompson Ross Program July 21, 2010 Lola Thompson (Ross Program) Number Theory and Security in the Digital Age July 21, 2010 1 / 37 Introduction I have

More information

Data security (Cryptography) exercise book

Data security (Cryptography) exercise book University of Debrecen Faculty of Informatics Data security (Cryptography) exercise book 1 Contents 1 RSA 4 1.1 RSA in general.................................. 4 1.2 RSA background.................................

More information

EE 418: Network Security and Cryptography

EE 418: Network Security and Cryptography EE 418: Network Security and Cryptography Homework 3 Solutions Assigned: Wednesday, November 2, 2016, Due: Thursday, November 10, 2016 Instructor: Tamara Bonaci Department of Electrical Engineering University

More information

ABB STOTZ-KONTAKT. ABB i-bus EIB Current Module SM/S Intelligent Installation Systems. User Manual SM/S In = 16 A AC Un = 230 V AC

ABB STOTZ-KONTAKT. ABB i-bus EIB Current Module SM/S Intelligent Installation Systems. User Manual SM/S In = 16 A AC Un = 230 V AC User Mnul ntelligent nstlltion Systems A B 1 2 3 4 5 6 7 8 30 ma 30 ma n = AC Un = 230 V AC 30 ma 9 10 11 12 C ABB STOTZ-KONTAKT Appliction Softwre Current Vlue Threshold/1 Contents Pge 1 Device Chrcteristics...

More information

CMPSCI 250: Introduction to Computation. Lecture #14: The Chinese Remainder Theorem David Mix Barrington 4 October 2013

CMPSCI 250: Introduction to Computation. Lecture #14: The Chinese Remainder Theorem David Mix Barrington 4 October 2013 CMPSCI 250: Introduction to Computation Lecture #14: The Chinese Remainder Theorem David Mix Barrington 4 October 2013 The Chinese Remainder Theorem Infinitely Many Primes Reviewing Inverses and the Inverse

More information

Final exam. Question Points Score. Total: 150

Final exam. Question Points Score. Total: 150 MATH 11200/20 Final exam DECEMBER 9, 2016 ALAN CHANG Please present your solutions clearly and in an organized way Answer the questions in the space provided on the question sheets If you run out of room

More information