Maths Olympiad Prep

Library / /32 of 37

Number theory Difficulty 8.3 Shortlist Find the answer

Find all integers n2n \ge 2 for which there exists an integer mm and a polynomial P(x)P(x) with integer coefficients satisfying the following three conditions: [list] [*]m>1m > 1 and gcd(m,n)=1\gcd(m,n) = 1; [*]the numbers P(0)P(0), P2(0)P^2(0), \ldots, Pm1(0)P^{m-1}(0) are not divisible by nn; and [*]Pm(0)P^m(0) is divisible by nn. [/list] Here PkP^k means PP applied kk times, so P1(0)=P(0)P^1(0) = P(0), P2(0)=P(P(0))P^2(0) = P(P(0)), etc.

Carl Schildkraut

A number or a short expression. Spacing and $ signs are ignored.

Solution

We need to find all integers n2 n \ge 2 for which there exists an integer m m and a polynomial P(x) P(x) with integer coefficients satisfying the following conditions:
1. m>1 m > 1 and gcd(m,n)=1 \gcd(m, n) = 1 ;
2. The numbers P(0),P2(0),,Pm1(0) P(0), P^2(0), \ldots, P^{m-1}(0) are not divisible by n n ;
3. Pm(0) P^m(0) is divisible by n n .

### Part A: Necessity

We start by proving a critical lemma about cycles modulo pt p^t .

Lemma: Consider the mapping from Z/ptZ \mathbb{Z}/p^t\mathbb{Z} to itself defined by xP(x) x \mapsto P(x) . Then the length of each cycle in this mapping must be p p -smooth (i.e., each prime factor does not exceed p p ).

Proof: We use induction on t t . The base case t=1 t = 1 is obvious as the length of each cycle is 1,2,,p 1, 2, \ldots, p . Assume this is true for t1 t-1 . Consider a cycle
aP(a)P(P(a))P(n)(a)=a a \to P(a) \to P(P(a)) \to \cdots \to P^{(n)}(a) = a
and let m m be the smallest integer such that pt1P(m)(a)a p^{t-1} \mid P^{(m)}(a) - a (i.e., the length of the cycle viewed modulo pt1 p^{t-1} ). Clearly, mn m \mid n and m m is p p -smooth. Let T(x)=P(m)(x) T(x) = P^{(m)}(x) . Then T(a),T(T(a)), T(a), T(T(a)), \ldots must be congruent to a(modpt1) a \pmod{p^{t-1}} . There are p p such residues that are congruent to a(modpt1) a \pmod{p^{t-1}} , so m/n{1,2,,p} m/n \in \{1, 2, \ldots, p\} , which implies the claim. \blacksquare

Now, order all primes p1<p2< p_1 < p_2 < \cdots in increasing order and suppose that n=p1a1p2a2pkak n = p_1^{a_1} p_2^{a_2} \cdots p_k^{a_k} works where a1,a2,,ak>0 a_1, a_2, \ldots, a_k > 0 . Since m>1 m > 1 , there exists an index i i such that the length \ell of the cycle of P P modulo piai p_i^{a_i} that contains 0 0 is >1 > 1 . However, by the lemma, \ell must be pi p_i -smooth, which is forced to be not coprime to n n , a contradiction.

### Part B: Sufficiency

Let p p be the largest prime divisor of n n and t=νp(n) t = \nu_p(n) . Due to the condition on n n , there exists a prime q<p q < p that does not divide n n . Take m=q m = q . First, we construct this polynomial modulo pt p^t .

Claim: There exists a polynomial QZ[x] Q \in \mathbb{Z}[x] such that the length of the cycle containing 0 0 modulo pt p^t is exactly q q .

Proof: Take any integers x1,x2,,xq1 x_1, x_2, \ldots, x_{q-1} of your choice such that they are distinct modulo p p . Set x0=xq=0 x_0 = x_q = 0 . Take the Lagrange Interpolation polynomial
Q(x)=i=0q1xi+1(jij{0,1,,q1}xxjxixj)(modpt) Q(x) = \sum_{i=0}^{q-1} x_{i+1} \left( \prod_{\substack{j \ne i \\ j \in \{0, 1, \ldots, q-1\}}} \frac{x - x_j}{x_i - x_j} \right) \pmod{p^t}
so that Q(xi)=xi+1 Q(x_i) = x_{i+1} for all i=0,1,2,,q1 i = 0, 1, 2, \ldots, q-1 . Fractions are acceptable since the denominators are not divisible by p p , so we use inverses modulo pt p^t . \blacksquare

Take Q Q from above and let Q(x)=i=0daixi Q(x) = \sum_{i=0}^{d} a_i x^i . We construct bi b_i such that
bi0(modnpt),biai(modpt), \begin{align*} b_i &\equiv 0 \pmod{\frac{n}{p^t}}, \\ b_i &\equiv a_i \pmod{p^t}, \end{align*}
and let P(x)=i=0dbixi P(x) = \sum_{i=0}^d b_i x^i . It's clear that modulo npt \frac{n}{p^t} , P P maps 0 0 to itself, while modulo pt p^t , it takes q q applications of P P to get back to 0 0 . Hence m=q m = q works and we are done.

Thus, the answer is: n n works if and only if the set of prime divisors of n n is not the set of the first k k primes for some k k .

The answer is: n works if and only if the set of prime divisors of n is not the set of the first k primes for some k\boxed{n \text{ works if and only if the set of prime divisors of } n \text{ is not the set of the first } k \text{ primes for some } k}.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: Omni-MATH, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.