p e i 1 [p e i i ) = i=1



Similar documents
Modern Algebra Lecture Notes: Rings and fields set 4 (Revision 2)

calculating the result modulo 3, as follows: p(0) = = 1 0,

Quotient Rings and Field Extensions

PROBLEM SET 6: POLYNOMIALS

Chapter 4, Arithmetic in F [x] Polynomial arithmetic and the division algorithm.

Introduction to Finite Fields (cont.)

CHAPTER SIX IRREDUCIBILITY AND FACTORIZATION 1. BASIC DIVISIBILITY THEORY

it is easy to see that α = a

Math 319 Problem Set #3 Solution 21 February 2002

The Division Algorithm for Polynomials Handout Monday March 5, 2012

9. POLYNOMIALS. Example 1: The expression a(x) = x 3 4x 2 + 7x 11 is a polynomial in x. The coefficients of a(x) are the numbers 1, 4, 7, 11.

Winter Camp 2011 Polynomials Alexander Remorov. Polynomials. Alexander Remorov

a 1 x + a 0 =0. (3) ax 2 + bx + c =0. (4)

8 Divisibility and prime numbers

POLYNOMIAL RINGS AND UNIQUE FACTORIZATION DOMAINS

1 Homework 1. [p 0 q i+j p i 1 q j+1 ] + [p i q j ] + [p i+1 q j p i+j q 0 ]

CHAPTER 5. Number Theory. 1. Integers and Division. Discussion

minimal polyonomial Example

SOLVING POLYNOMIAL EQUATIONS

PUTNAM TRAINING POLYNOMIALS. Exercises 1. Find a polynomial with integral coefficients whose zeros include

2. Let H and K be subgroups of a group G. Show that H K G if and only if H K or K H.

Factorization in Polynomial Rings

CS 103X: Discrete Structures Homework Assignment 3 Solutions

ABSTRACT ALGEBRA: A STUDY GUIDE FOR BEGINNERS

On the generation of elliptic curves with 16 rational torsion points by Pythagorean triples

Factoring polynomials over finite fields

1 Lecture: Integration of rational functions by decomposition

U.C. Berkeley CS276: Cryptography Handout 0.1 Luca Trevisan January, Notes on Algebra

Factorization Algorithms for Polynomials over Finite Fields

Number Theory: A Mathemythical Approach. Student Resources. Printed Version

Factoring Polynomials

The finite field with 2 elements The simplest finite field is

Elementary Number Theory and Methods of Proof. CSE 215, Foundations of Computer Science Stony Brook University

(a) Write each of p and q as a polynomial in x with coefficients in Z[y, z]. deg(p) = 7 deg(q) = 9

An Introduction to the General Number Field Sieve

Math Abstract Algebra I Questions for Section 23: Factoring Polynomials over a Field

Lecture 6: Finite Fields (PART 3) PART 3: Polynomial Arithmetic. Theoretical Underpinnings of Modern Cryptography

Kevin James. MTHSC 412 Section 2.4 Prime Factors and Greatest Comm

Unique Factorization

15. Symmetric polynomials

Some facts about polynomials modulo m (Full proof of the Fingerprinting Theorem)

Lagrange Interpolation is a method of fitting an equation to a set of points that functions well when there are few points given.

H/wk 13, Solutions to selected problems

3 1. Note that all cubes solve it; therefore, there are no more

GCDs and Relatively Prime Numbers! CSCI 2824, Fall 2014!

Homework until Test #2

Discrete Mathematics: Homework 7 solution. Due:

Algebra 3: algorithms in algebra

FACTORING POLYNOMIALS IN THE RING OF FORMAL POWER SERIES OVER Z

Today s Topics. Primes & Greatest Common Divisors

JUST THE MATHS UNIT NUMBER 1.8. ALGEBRA 8 (Polynomials) A.J.Hobson

7. Some irreducible polynomials

Lectures on Number Theory. Lars-Åke Lindahl

Basics of Polynomial Theory

SYSTEMS OF PYTHAGOREAN TRIPLES. Acknowledgements. I would like to thank Professor Laura Schueller for advising and guiding me

8 Primes and Modular Arithmetic

HOMEWORK 5 SOLUTIONS. n!f n (1) lim. ln x n! + xn x. 1 = G n 1 (x). (2) k + 1 n. (n 1)!

a 11 x 1 + a 12 x a 1n x n = b 1 a 21 x 1 + a 22 x a 2n x n = b 2.

CONTINUED FRACTIONS AND PELL S EQUATION. Contents 1. Continued Fractions 1 2. Solution to Pell s Equation 9 References 12

MATH 289 PROBLEM SET 4: NUMBER THEORY

I. GROUPS: BASIC DEFINITIONS AND EXAMPLES

Continued Fractions and the Euclidean Algorithm

The Greatest Common Factor; Factoring by Grouping

The Method of Partial Fractions Math 121 Calculus II Spring 2015

z 0 and y even had the form

Handout NUMBER THEORY

Application. Outline. 3-1 Polynomial Functions 3-2 Finding Rational Zeros of. Polynomial. 3-3 Approximating Real Zeros of.

ON GALOIS REALIZATIONS OF THE 2-COVERABLE SYMMETRIC AND ALTERNATING GROUPS

Number Theory. Proof. Suppose otherwise. Then there would be a finite number n of primes, which we may

3.2 The Factor Theorem and The Remainder Theorem

Copy in your notebook: Add an example of each term with the symbols used in algebra 2 if there are any.

= = 3 4, Now assume that P (k) is true for some fixed k 2. This means that

Module MA3411: Abstract Algebra Galois Theory Appendix Michaelmas Term 2013

MATH PROBLEMS, WITH SOLUTIONS

RSA and Primality Testing

Factoring Polynomials

Real Roots of Univariate Polynomials with Real Coefficients

How To Know If A Domain Is Unique In An Octempo (Euclidean) Or Not (Ecl)

An Introduction to Galois Theory. Andrew Baker

SUM OF TWO SQUARES JAHNAVI BHASKAR

a. all of the above b. none of the above c. B, C, D, and F d. C, D, F e. C only f. C and F

1.7. Partial Fractions Rational Functions and Partial Fractions. A rational function is a quotient of two polynomials: R(x) = P (x) Q(x).

Polynomial Factoring. Ramesh Hariharan

1.3 Polynomials and Factoring

6.2 Permutations continued

Number Theory Hungarian Style. Cameron Byerley s interpretation of Csaba Szabó s lectures

Section 4.2: The Division Algorithm and Greatest Common Divisors

11 Ideals Revisiting Z

MOP 2007 Black Group Integer Polynomials Yufei Zhao. Integer Polynomials. June 29, 2007 Yufei Zhao

Factoring Polynomials

MATH 13150: Freshman Seminar Unit 10

Galois theory for dummies

Commutative Algebra Notes Introduction to Commutative Algebra Atiyah & Macdonald

The last three chapters introduced three major proof techniques: direct,

r + s = i + j (q + t)n; 2 rs = ij (qj + ti)n + qtn.

Zeros of a Polynomial Function

Examples of Functions

Chapter 3. if 2 a i then location: = i. Page 40

Chapter 13: Basic ring theory

Elementary Number Theory

Transcription:

Homework 1 Solutions - Sri Raga Velagapudi Algebra Section 1. Show that if n Z then for every integer a with gcd(a, n) = 1, there exists a unique x mod n such that ax = 1 mod n. By the definition of gcd, for a given a, n and d, gcd(a, n) = d = xa + yn where x, y Z. In our case, xa + yn = 1 = gcd(a, n). (xa + yn) mod n = 1 mod n xa mod n = 1 mod n In the ring Z n xa = 1 x = a 1. By the definition of the ring Z n, x is unique. 2. Here is an age-guessing game you might play at a party. You ask a fellow party-goer to divide his age by each of the numbers a, 4 and 5 and tell you the remainders. Show how to use this information to determine the age. Let the party goer s age be x. Then we have x = r 3 mod 3, x = r 4 mod 4, x = r 5 mod 5. This means x = (r 3 m 3 + r 4 m 4 + r 5 m 5 ) mod 60 where: m 3 = s 3 20 where s 3 = 20 1 mod 3 = 2 m 4 = s 4 15 where s 4 = 15 1 mod 4 = 3 m 5 = s 5 12 where s 5 = 12 1 mod 5 = 3 m 3 = 40, m 4 = 45, m 5 = 36 x = (40r 3 + 45r 4 + 36r 5 ) mod 60 3. For any integer n > 1, let φ(n) denote the number of positive integers less than n and coprime to n. If m, n are coprime then φ(m, n) = φ(m).φ(n). If n is a prime power, n = p e where φ(n) = (p e p e 1 ). Use the two results above to deduce a formula for φ(n) in terms of the prime factorization of n. Let p 1,..., p k be the set of unique prime factors of n, then we have n = p e 1 1.pe 2 2...pe k k us the appropriate power for the prime factor p i. i=k i=k φ(n) = φ(p e 1 1 )...φ(pe k k ) = φ(p e i i ) = [p e i i p e i 1 i ]. i=1 i=1 where e i 4. For each pair of rings below, determine if they are isomorphic. If they are not isomorphic prove it, else provide an isomorphis. 4-1: = Z 15, R 2 = Z 3 Z 5 = R2. Let φ be the isomorphism. For a Z 15, φ(a) = (a mod 3, a mod 5). For φ 1 (α, β) = α(5(5 1 mod 3)) + β(3(3 1 mod 5)) = 10α + 6β. The above definion of the isomorphism is bijective since φ 1 (α, β)mod3 = αandφ 1 (α, β)mod5 = β. By the properties of modulo we have φ(ab) = (ab mod 3, ab mod 5) = (a mod 3, a mod 5) (b 1

mod 3, b mod 5) = φ(a)φ(b). Similarly φ(a + b) = (a + b mod 3, a + b mod 5) = (a mod 3, a mod 5) + (b mod 3, b mod 5) = φ(a) + φ(b). 4-2: = Z 25, R 2 = Z 5 Z 5 If and R 2 are isomorphic, then corresponding elements must have the same order. Note that in Z 5 {0} = {1, 2, 3, 4} each elemet x has x 4 = 1. Then if we look at the set Z 5 Z 5 without any elements containing 0, then we have that every (a, b) 4 = (1, 1). However, this does not hold true for Z 25. 2 mod 25 in Z 25, for example, does ot match this expectation. (2 mod 25) 4 = 16 mod 25 which does not equal 1 mod 25. 4-3: = Q[x]/ < x 2 7 >, R 2 = Q[y]/ < y 2 2 > Both x 2 7 and y 2 2 are irreducible over Q[x]. Note that all elements in R1 with x = 0 must map to those in R 2 with y = 0. In, x 2 7 = 0, this implies that there is an element, g such that g 2 = 7. In order for = R2, one such element must exist in R 2 as well. Let that element be (a + by), then we have 7 = (a + by) 2 = a 2 + b 2 y 2 + 2aby = (a 2 + 2b 2 ) + (2ab) y. This means that a 2 + 2b 2 = 7 and that 2ab = 0. Solving, we have b = 7/2. Since the constants in R 2 are all in Q, b cannot exist. Therefore no element z R 2 exists such that z 2 = 7. Therefore 4-4: = R[x]/ < x 2 1 >, R 2 = R[x]/ < x 2 + 1 > x 2 1 is reducible over R[x] while x 2 + 1 is not reducible over R[x]. By CRT, = R[x]/ < x 1 > R[x]/ < x + 1 >. However, R2 cannot be isomorphic to a similar direct sum of co-primes since x 2 + 1 is irreducible in R[x]. This is a fundamental property difference. Therefore 4-5: = C[x]/ < x 2 1 >, R 2 = C[x]/ < x 2 + 1 > = R2. All constants in must map to constants in R 2. Lets map ϕ : x ix. Then we have that following: ϕ(a + bx) = a + ibx ϕ((a+bx)(c+dx)) = ϕ(ac+bd+(ad+bc)x) = (ac+bd)+i(ad+bc)x = ac+ix(ad+bc) bdx 2 = ac + iadx + ibcx bdx 2 = (a + ibx)(c + idx) = ϕ(a + bx)ϕ(c + dx) Similarly, ϕ((a+bx)+(c+dx)) = ϕ((a+c)+(b+d)x) = (a+c)+i(b+d)x = (a+ibx)+(c+idx) = ϕ(a + bx) + ϕ(c + dx). With all the constants mapping to constants and ϕ : x ix, bijectivity is satisfied. Therefore = R2. 4-6: = Q[x]/ < x 3 1 >, R 2 = Q[x]/ < x 3 + x 2 2x > Over Q[x], x 3 1 has two irreducible factors, x 1 and x 2 + x + 1. On the other hand, x 3 + x 2 2x has three irreducible factors x, x + 2 and x 1. By the CRT, this implies that x 3 1 would be isomorphic to a direct sum of two co-prime rings while x 3 + x 2 2x would be isomorphic to a direct sum of three co-prime rings. 2

Since the co-rime ring R[x]/ < x 1 > is common for both sets of direct sums, the problem reduces to showing that R[x]/ < x 2 + x + 1 > is isomorphic to R[x]/ < x > R[x]/ < x 2 >. This is, however, not an isomorphism, since the direct sum would only contain constants. Therefore 4-7: = Z 7 / < x 3 1 >, R 2 = Z 7 [x]/ < x 3 + x 2 2x > = R2. In Z 7 [x] we have three elements that satisfy the equaion x 3 1. They are 1, 2 and 4. x 3 + x 2 2x can be factored into x(x 1)(x 5). By CRT we have Z 7 [x]/ < x 3 1 > = Z 7 [x]/ < x 1 > Z 7 [x]/ < x 2 > Z 7 [x]/ < x 4 > and Z 7 [x]/ < x 3 + x 2 2x > = Z 7 [x]/ < x > Z 7 [x]/ < x 1 > Z 7 [x]/ < x 5 >. Since all polynomial divisors are of order 1, the direct sums for both rings are simply linear transformations. Therefore = R2. Complexity Section 1. Show that if a function f(x) can be computed in polynomial time using an oracle for another polynomial time compurable function g(x) then f(x) can be computed in polynomial time without the use of oracles. For a given string β and a language B, oracles can tell if β B. If f(x) is using an oracle for g(x) and is still a polynomial time function, then we must call any oracle atmost polynomial number of times. If all the calls within f(x) using any result from the oracle were replaced directly with g(x) and the resulting changed function evaluated at the necessary value, then the time taken would still be polynomial since the composition of two polynomial functions is still polynomial. 2. Show that if a function f(x) has an NC algorithm using an oracle for another NC-computable function g(x) then f(x) itself can be computed in NC witout using oracles. Similar to problem 1, if all places in f(x) using results from the oracle are replaced with g(x) directly and then f(x) would still have a polynomial size circuit because the sum of two polynomials is still a polynomial. Thus f(x) would still be NC even if it did not use oracles. Note that the depth, however would increase by k( g(x) ) where k is the number of places within f(x) where g(x) occurs and g(x) is the size of the circuit for g(x). 3. Solve the following recurrence reations in terms of n, expressing the resulting functions asymptotically: 3

3-1: T (n) = 2.T (n/2) + cn Answer to 3-1 3-2: T (n) = 3.T (n/5) + cn Answer to 3-2 3-3: T (n) = 2.T (n 1) This contin- T (n) = 2.T (n 1) = 2.2.T (n 2) = 2.2.2.T (n 3) = 2 4.T (n 4) =. ues until n x = 0 x = n. T (n) = 2 n T (n) = O(2 n ). Algorithmic Algebra Section 1. Let a, b Z. Recall that if gcd(a, b) = d, then there exists integers x, y s.t. ax + by = d. Devise an algorithm that given an a and b with a > b, computes d and an x an a y in time O( < a > < b > + < b > 3 ). Given m 0 and m 1, the euclidean algorithm for the gcd(m 0, m 1 ) proceeds by finding the remainder sequence m 0, m 1, m 2,, 0 where m i = m i 2 modm i 1 for i > 1. Then gcd(m 0, m 1 ) is the last non-zero m i. The extended euclidean algorithm works in the following manner: Let q i be the quptient of the i th remaindering step. Then m i+1 = m i 1 q i m i (i = 2,, k 1). Let (s 0,, s k ) and (t 0,, t k ) be two sequences such that m i = s i m 0 + t)im 1 (i = 0,, k). When i = k we have m k = gcd(m 0, m 1 ) = s k m 0 + t k m 1. Let s i+1 = s i 1 q i s i and t i+1 = t i 1 q i t i (i = 2,, k 1). Since m 0 = 1m 0 + 0m 1 and m 1 = 0m 0 + 1m 1, we have s 0 = 1, t 0 = 0, t 1 = 1 and s 1 = 0. Inductively, m i+1 = m i 1 q i m i = (s i 1 m 0 + t i 1 m i ) q i (s i m 0 + t i m 1 ). Time Taken: To calculate the remainders and quotients for m 0, m 1 with m 0 = a and m 1 = b we take < a > < b > + < b > < b > 2 to do a mod b and b mod m 2, m 2 mod m 3 so on < b > number of times. This is because with each consecutive mod we lose atleast 1 bit. The above calculations also generate all the q i s necessary to calculate all s i and t i values. There are atmost < b > number of s i and t i values each. Each s i calculation takes < b > 2 + < b > for the one multiplication and one subtraction. Similarly each t i calculation takes < b > 2 + < b > time. Together, all s i and t i calculations take < b > (2 < b > 2 +2 < b > ). The total operation count: < a > < b > + < b > 3 + 2 < b > 3 + 2 < b > 2 ). 1-1: Show that an analogous algorithm works for polynomials and assuming that all the underlying field operations are done in constant time, the time complexity for this is O(deg(a) 4

deg(b) + deg(b) 3 ). The extended Euclidean Algorithm would work in the following manner for polynomials: Like for integers q 1 (x) would be the quotient of the i th remaindering step. Then m i+1 (x) = m i 1 (x) q i (x)m i (x) for i {1,..., k 1}. Similarly (s 0 (x),..., s k (x)) and (t 0 (x),..., t( k (x)) would be the two polynomial sequence such that m i (x) = s i (x)m 0 (x) + t i (x)m 1 (x) for i {0,..., k}. When i = k we have m k (x) = gcd(m 0 (x), m 1 (x)) = s k (x)m 0 (x) + t k (x)m 1 (x). Let s i+1 (x) = s i 1 (x) q i (x)s i (x) and t i+1 (x) = t i 1 (x) q i (x)t i (x) for i {2,.., k 1}. Since m 0 (x) = m 0 (x) +0m 1 (x) and m 1 (x) = 0m+0(x)+m 1 (x) we have s 0 (x) = 1, t 0 (x) = 0, t 1 (x) = 1, s 1 (x) = 0. Inductively, similar to the proof given for integers we have m i+1 (x) = s i+1 m 0 + t i+1 m 1. Assuming field operations are done in constant time, the following are the time complexity details. The first mod: a mod b takes time deg(a) deg(b). Each subsequent mod takes less than deg(b) deg(b). Maximum number of subsequent mods is deg(b). This is because each mod will result in a remainder of degree atmost one less than the divisior which could be atmost b. As a result the total is O(deg(a) deg(b) + deg(b) 3 ). 2. Show that given integers a, t, m we can compute a t mod m in time O( < a >. < m > + < m > 2 < t > ). a t mod m = (a mod m) t mod m. The operatio a mod m = r 0 takes < a > < m > time. We now need to calculate r t mod m. Note that r 0 < m. Without loss of generality, we can assume that r 2 0 > m. Then we have: rt 0 mod m = (r 2 0 mod m)t/2 mod m. Calculating r 2 0 mod m = r 1 takes < m > 2 operations. Now we have t/2 number of r 1 remainders. We can repeat the same process and calulate (r 2 1 modm)t/4 mod m. r 2 1 mod m would once again take < m > 2 operations. Continueing this process we would have t/2 + t/2 + t/8 +... number of < m > 2 sized operations for calculating ri 2 modm. t > t/2 + t/4 + t/8 +... Therefore we have that the total for calculating r t mod m = < m > 2 < t >. The total time taken for calculating a t mod m is therefore < a > < m > + < m > 2 < t >. 5