Harman Patil (Editor)

Cyclotomic polynomial

Updated on
Edit
Like
Comment
Share on FacebookTweet on TwitterShare on LinkedInShare on Reddit

In mathematics, more specifically in algebra, the nth cyclotomic polynomial, for any positive integer n, is the unique irreducible polynomial with integer coefficients, which is a divisor of x n 1 and is not a divisor of x k 1 for any k < n. Its roots are all nth primitive roots of unity e 2 i π k n , where k runs over the positive integers not greater than n and coprime to n. In other words, the nth cyclotomic polynomial is equal to

Contents

Φ n ( x ) = gcd ( k , n ) = 1 1 k n ( x e 2 i π k n ) .

It may also be defined as the monic polynomial with integer coefficients, which is the minimal polynomial over the field of the rational numbers of any primitive nth-root of unity ( e 2 i π / n is an example of such a root).

An important relation linking cyclotomic polynomials and primitive roots of unity is

d n Φ d ( x ) = x n 1 ,

showing that every root of x n 1 is a dth primitive root of unity for some d that divides n.

Examples

If n is a prime number, then

  Φ n ( x ) = 1 + x + x 2 + + x n 1 = k = 0 n 1 x k .

If n=2p where p is an odd prime number, then

  Φ 2 p ( x ) = 1 x + x 2 + x p 1 = k = 0 p 1 ( x ) k .

For n up to 30, the cyclotomic polynomials are:

  Φ 1 ( x ) = x 1   Φ 2 ( x ) = x + 1   Φ 3 ( x ) = x 2 + x + 1   Φ 4 ( x ) = x 2 + 1   Φ 5 ( x ) = x 4 + x 3 + x 2 + x + 1   Φ 6 ( x ) = x 2 x + 1   Φ 7 ( x ) = x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 8 ( x ) = x 4 + 1   Φ 9 ( x ) = x 6 + x 3 + 1   Φ 10 ( x ) = x 4 x 3 + x 2 x + 1   Φ 11 ( x ) = x 10 + x 9 + x 8 + x 7 + x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 12 ( x ) = x 4 x 2 + 1   Φ 13 ( x ) = x 12 + x 11 + x 10 + x 9 + x 8 + x 7 + x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 14 ( x ) = x 6 x 5 + x 4 x 3 + x 2 x + 1   Φ 15 ( x ) = x 8 x 7 + x 5 x 4 + x 3 x + 1   Φ 16 ( x ) = x 8 + 1   Φ 17 ( x ) = x 16 + x 15 + x 14 + x 13 + x 12 + x 11 + x 10 + x 9 + x 8 + x 7 + x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 18 ( x ) = x 6 x 3 + 1   Φ 19 ( x ) = x 18 + x 17 + x 16 + x 15 + x 14 + x 13 + x 12 + x 11 + x 10 + x 9 + x 8 + x 7 + x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 20 ( x ) = x 8 x 6 + x 4 x 2 + 1   Φ 21 ( x ) = x 12 x 11 + x 9 x 8 + x 6 x 4 + x 3 x + 1   Φ 22 ( x ) = x 10 x 9 + x 8 x 7 + x 6 x 5 + x 4 x 3 + x 2 x + 1 Φ 23 ( x ) = x 22 + x 21 + x 20 + x 19 + x 18 + x 17 + x 16 + x 15 + x 14 + x 13 + x 12 + x 11 + x 10 + x 9 + x 8 + x 7 + x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 24 ( x ) = x 8 x 4 + 1   Φ 25 ( x ) = x 20 + x 15 + x 10 + x 5 + 1   Φ 26 ( x ) = x 12 x 11 + x 10 x 9 + x 8 x 7 + x 6 x 5 + x 4 x 3 + x 2 x + 1   Φ 27 ( x ) = x 18 + x 9 + 1   Φ 28 ( x ) = x 12 x 10 + x 8 x 6 + x 4 x 2 + 1 Φ 29 ( x ) = x 28 + x 27 + x 26 + x 25 + x 24 + x 23 + x 22 + x 21 + x 20 + x 19 + x 18 + x 17 + x 16 + x 15 + x 14 + x 13 + x 12 + x 11 + x 10 + x 9 + x 8 + x 7 + x 6 + x 5 + x 4 + x 3 + x 2 + x + 1   Φ 30 ( x ) = x 8 + x 7 x 5 x 4 x 3 + x + 1.

The case of the 105th cyclotomic polynomial is interesting because 105 is the lowest integer that is the product of three distinct odd prime numbers and this polynomial is the first one that has a coefficient other than 1, 0, or -1:

Φ 105 ( x ) = x 48 + x 47 + x 46 x 43 x 42 2 x 41 x 40 x 39 + x 36 + x 35 + x 34 + x 33 + x 32 + x 31 x 28 x 26 x 24 x 22 x 20 + x 17 + x 16 + x 15 + x 14 + x 13 + x 12 x 9 x 8 2 x 7 x 6 x 5 + x 2 + x + 1.

Fundamental tools

The cyclotomic polynomials are monic polynomials with integer coefficients that are irreducible over the field of the rational numbers. Except for n equal to 1 or 2, they are palindromics of even degree.

The degree of Φ n , or in other words the number of nth primitive roots of unity, is φ ( n ) , where φ is Euler's totient function.

The fact that Φ n is an irreducible polynomial of degree φ ( n ) in the ring Z [ x ] is a nontrivial result due to Gauss. Depending on the chosen definition, it is either the value of the degree or the irreducibility which is a nontrivial result. The case of prime n is easier to prove than the general case, thanks to Eisenstein's criterion.

A fundamental relation involving cyclotomic polynomials is

x n 1 = 1 k n ( x e 2 i π k n ) = d n 1 k n gcd ( k , n ) = d ( x e 2 i π k n ) = d n Φ n / d ( x ) = d n Φ d ( x ) .

which means that each n-th root of unity is a primitive d-th root of unity for a unique d dividing n.

The Möbius inversion formula allows the expression of Φ n ( x ) as an explicit rational fraction:

Φ n ( x ) = d n ( x d 1 ) μ ( n / d ) ,

where μ is the Möbius function.

The Fourier transform of functions of the greatest common divisor together with the Möbius inversion formula gives:

  Φ n ( x ) = k = 1 n ( x gcd ( k , n ) 1 ) cos ( 2 π k n ) .

The cyclotomic polynomial Φ n ( x ) may be computed by (exactly) dividing x n 1 by the cyclotomic polynomials of the proper divisors of n previously computed recursively by the same method:

Φ n ( x ) = x n 1 d < n d | n Φ d ( x )

(Recall that Φ 1 ( x ) = x 1 .)

This formula allows to compute Φ n ( x ) on a computer for any n, as soon as integer factorization and division of polynomials are available. Many computer algebra systems have a built in function to compute the cyclotomic polynomials. For example, this function is called by typing cyclotomic_polynomial(n,'x') in SageMath, numtheory[cyclotomic](n,x); in Maple, and Cyclotomic[n,x] in Mathematica.

Easy cases for computation

As noted above, if n is a prime number, then

Φ n ( x ) = 1 + x + x 2 + + x n 1 = i = 0 n 1 x i .

If n is an odd integer greater than one, then

Φ 2 n ( x ) = Φ n ( x ) .

In particular, if n=2p is twice an odd prime, then (as noted above)

Φ n ( x ) = 1 x + x 2 + x p 1 = i = 0 p 1 ( x ) i .

If n=pm is a prime power (where p is prime), then

Φ n ( x ) = Φ p ( x p m 1 ) = i = 0 p 1 x i p m 1 .

More generally, if n=pmr with r relatively prime to p, then

Φ n ( x ) = Φ p r ( x p m 1 ) .

These formulas may be applied repeatedly to get a simple expression for any cyclotomic polynomial Φ n ( x ) in term of a cyclotomic polynomial of square free index: If q is the product of the prime divisors of n (its radical), then

Φ n ( x ) = Φ q ( x n / q ) .

This allows to give formulas for the nth cyclotomic polynomial when n has at most one odd prime factor: If p is an odd prime number, and h and k are positive integers, then:

Φ 2 h ( x ) = x 2 h 1 + 1 Φ p k ( x ) = i = 0 p 1 x i p k 1 Φ 2 h p k ( x ) = i = 0 p 1 ( 1 ) i x i 2 h 1 p k 1

For the other values of n, the computation of the nth cyclotomic polynomial is similarly reduced to that of Φ q ( x ) , where q is the product of the distinct odd prime divisors of n. To deal with this case, one has that, for p prime and not dividing n,

Φ n p ( x ) = Φ n ( x p ) / Φ n ( x ) .

Integers appearing as coefficients

The problem of bounding the magnitude of the coefficients of the cyclotomic polynomials has been the object of a number of research papers.

If n has at most two distinct odd prime factors, then Migotti showed that the coefficients of Φ n are all in the set {1, −1, 0}.

The first cyclotomic polynomial for a product of 3 different odd prime factors is Φ 105 ( x ) ; it has a coefficient −2 (see its expression above). The converse is not true: Φ 231 ( x ) = Φ 3 × 7 × 11 ( x ) only has coefficients in {1, −1, 0}.

If n is a product of more odd different prime factors, the coefficients may increase to very high values. E.g., Φ 15015 ( x ) = Φ 3 × 5 × 7 × 11 × 13 ( x ) has coefficients running from −22 to 22, Φ 255255 ( x ) = Φ 3 × 5 × 7 × 11 × 13 × 17 ( x ) , the smallest n with 6 different odd primes, has coefficients up to ±532.

Let A(n) denote the maximum absolute value of the coefficients of Φn. It is known that for any positive k, the number of n up to x with A(n) > nk is at least c(k)⋅x for a positive c(k) depending on k and x sufficiently large. In the opposite direction, for any function ψ(n) tending to infinity with n we have A(n) bounded above by nψ(n) for almost all n.

Gauss's formula

Let n be odd, square-free, and greater than 3. Then

4 Φ n ( z ) = A n 2 ( z ) ( 1 ) n 1 2 n z 2 B n 2 ( z )

where both An(z) and Bn(z) have integer coefficients, An(z) has degree φ(n)/2, and Bn(z) has degree φ(n)/2 − 2. Furthermore, An(z) is palindromic when its degree is even; if its degree is odd it is antipalindromic. Similarly, Bn(z) is palindromic unless n is composite and ≡ 3 (mod 4), in which case it is antipalindromic.

The first few cases are

4 Φ 5 ( z ) = 4 ( z 4 + z 3 + z 2 + z + 1 ) = ( 2 z 2 + z + 2 ) 2 5 z 2 4 Φ 7 ( z ) = 4 ( z 6 + z 5 + z 4 + z 3 + z 2 + z + 1 ) = ( 2 z 3 + z 2 z 2 ) 2 + 7 z 2 ( z + 1 ) 2 4 Φ 11 ( z ) = 4 ( z 10 + z 9 + z 8 + z 7 + z 6 + z 5 + z 4 + z 3 + z 2 + z + 1 ) = ( 2 z 5 + z 4 2 z 3 + 2 z 2 z 2 ) 2 + 11 z 2 ( z 3 + 1 ) 2

Lucas's formula

Let n be odd, square-free and greater than 3. Then

Φ n ( z ) = U n 2 ( z ) ( 1 ) n 1 2 n z V n 2 ( z )

where both Un(z) and Vn(z) have integer coefficients, Un(z) has degree φ(n)/2, and Vn(z) has degree φ(n)/2 − 1. This can also be written

Φ n ( ( 1 ) n 1 2 z ) = C n 2 ( z ) n z D n 2 ( z ) .

If n is even, square-free and greater than 2 (this forces n to be ≡ 2 (mod 4)),

Φ n / 2 ( z 2 ) = C n 2 ( z ) n z D n 2 ( z )

where both Cn(z) and Dn(z) have integer coefficients, Cn(z) has degree φ(n), and Dn(z) has degree φ(n) − 1. Cn(z) and Dn(z) are both palindromic.

The first few cases are:

Φ 3 ( z ) = z 2 z + 1 = ( z + 1 ) 2 3 z Φ 5 ( z ) = z 4 + z 3 + z 2 + z + 1 = ( z 2 + 3 z + 1 ) 2 5 z ( z + 1 ) 2 Φ 3 ( z 2 ) = z 4 z 2 + 1 = ( z 2 + 3 z + 1 ) 2 6 z ( z + 1 ) 2

Cyclotomic polynomials over Zp

For any prime number p which does not divide n, the cyclotomic polynomial Φ n is irreducible over Zp if and only if p is a primitive root modulo n. That is, the p does not divide n, and its multiplicative order modulo n is φ ( n ) (which is also the degree of Φ n ).

Polynomial values

If x takes any real value, then Φ n ( x ) > 0 for every n ≥ 2 (this follow from the fact that the roots of a cyclotomic polynomial are all non-real, for n ≥ 2).

For studying the values that a cyclotomic polynomial may take when x is given an integer value, it suffices to consider only the case n ≥ 2, as the cases n = 1 and n = 2 are trivial (one has Φ 1 ( x ) = x 1 and Φ 2 ( x ) = x + 1 ).

For n ≥ 2, one has

Φ n ( 0 ) = 1 , Φ n ( 1 ) = 1 if n is not a prime power, Φ n ( 1 ) = p if n = p k is a prime power with k ≥ 0.

The values that a cyclotomic polynomial Φ n ( x ) may take for other integer values of x is strongly related with the multiplicative order modulo a prime number.

More precisely, given a prime number p and an integer b coprime with p, the multiplicative order of b modulo p, is the smallest positive integer n such that p is a divisor of x n 1. For b > 1, the multiplicative order of b modulo p is also the shortest period of the representation of 1/p in the numeral base b (see Unique prime; this explains the notation choice).

The definition of the multiplicative order implies that, if n is the multiplicative order of b modulo p, then p is a divisor of Φ n ( b ) . The converse is not true, but one has the following.

If n > 0 is a positive integer and b > 1 is an integer, then (see below for a proof)

Φ n ( b ) = 2 k g h ,

where

  • k is a non-negative integer, always equal to 0 when b is even.
  • g is an odd square-free integer, which is a divisor of n.
  • h is odd, coprime with n, and its prime factors are exactly the odd primes p such that n is the multiplicative order of b modulo p.
  • This implies that, if p is an odd prime divisor of Φ n ( b ) , then either n is a divisor of p − 1 or p is a divisor of n. In the latter case p 2 does not divides Φ n ( b ) .

    Zsigmondy's theorem implies that the only cases where b > 1 and h = 1 are

    Φ 1 ( 2 ) = 1 , Φ 2 ( 2 k 1 ) = 2 k for k > 0, Φ 6 ( 2 ) = 3.

    It follows from above factorization that the odd prime factors of

    Φ n ( b ) gcd ( n , Φ n ( b ) )

    are exactly the odd primes p such that n is the multiplicative order of b modulo p. This fraction may be even only when b is odd. In this case, the multiplicative order of b modulo 2 is always 1.

    There are many pairs (n, b) with b > 1 such that Φ n ( b ) is prime. In fact, Bunyakovsky conjecture implies that, for every n, there are infinitely many b > 1 such that Φ n ( b ) is prime. See  A085398 for the list of the smallest b > 1 such that Φ n ( b ) is prime. See also  A206864 for the list of the smallest primes of the form Φ n ( b ) with n > 2 and b > 1, and, more generally,  A206942, for the smallest positive integers of this form.

    Applications

    Using Φ n , one can give an elementary proof for the infinitude of primes congruent to 1 modulo n, which is a special case of Dirichlet's theorem on arithmetic progressions.

    Let p 1 , p 2 . . . p k be a finite list of primes congruent to 1 mod n . Let N = n p 1 p 2 . . . p k and consider Φ n ( N ) . Let q be a prime factor of Φ n ( N ) (to see that Φ n ( N ) is not ± 1 , decompose it into linear factors and note that 1 is the closest root of unity to N ). Since Φ n ( x ) ± 1 mod x , we know that q is a new prime not in the list. We will show that q 1 mod n .

    Let m be the order of N mod q . Since Φ n ( N ) N n 1 we have N n 1 0 mod q . Thus m n . We will show that m = n .

    Assume for contradiction that m < n . Since N m 1 d m Φ d ( N ) 0 mod q we have Φ d ( N ) 0 mod q for some d < n . Then N is a double root of d n Φ d ( x ) x n 1 mod q . Thus N must be a root of the derivative so d ( x n 1 ) d x | N n N n 1 0 mod q . But q N and therefore q n . This is a contradiction so m = n . The order of N mod q , which is n , must divide q 1 . Thus q 1 mod n .

    References

    Cyclotomic polynomial Wikipedia