Positive lower density for prime divisors of generic linear recurrences

Abstract Let 
$d \ge 3$
 be an integer and let 
$P \in \mathbb{Z}[x]$
 be a polynomial of degree d whose Galois group is 
$S_d$
 . Let 
$(a_n)$
 be a non-degenerate linearly recursive sequence of integers which has P as its characteristic polynomial. We prove, under the generalised Riemann hypothesis, that the lower density of the set of primes which divide at least one non-zero element of the sequence 
$(a_n)$
 is positive.


Introduction
Given a sequence of integers, it is natural to consider the set of primes which divide at least one of its values (the prime divisors of the sequence).Here we consider the prime divisors of linearly recursive sequences.We assume that the elements a 1 , a 2 , . . . of the sequence and the coefficients c i in the defining recursion a n+d + c d−1 a n+d−1 + . . .+ c 0 a n = 0 are integers.The order of (a n ) is (the minimum possible value of) d.
It is a well-known result often attributed to Pólya [16] that, excluding degenerate cases, a linearly recursive sequence has infinitely many prime divisors.One naturally wonders: how dense is the set of prime divisors of a linearly recursive sequence (with respect to the set of primes)?
The case of second order sequences has been studied in a number of works under the assumption of the generalized Riemann hypothesis (GRH), under which it is known that the density of prime divisors exists, is positive (unless there are only finitely many prime divisors) and can, at least in principle, be computed explicitly (see [1], [5], [7], [9], [10,Section 8.4], [11], [12], [13], [20], [21]).Unconditional results are much more modest: in [14] it is proved that the number of primes p ≤ x which are prime divisors of such a sequence is at least of magnitude log x.
Higher order sequences have received considerably less attention.In [18] Roskam states that "Essentially nothing is known for sequences of order larger than 2", and it is mentioned that some very non-generic cases can be handled (see [1]).Roskam proceeds to proving that, under a certain generalization of Artin's conjecture on primitive roots, "generic" linear recurrences have a positive lower density of prime divisors.However, we note that a much stronger result under a significantly weaker assumption follows directly from the work of Niederreiter [15].Nevertheless, while the regular version of Artin's conjecture has been proven by Hooley [6] under GRH (see [9] for a survey), even the weakened version of the generalization seems to be out of reach under standard conjectures.See Section 8 for more discussion.
Here we prove, under GRH, that the set of prime divisors of a "generic" linear recurrences has positive lower density.This seems to be the first such result which is applicable to "almost all" sequences and which assumes only standard conjectures.
Theorem 1.1.Assume GRH.Let d ≥ 3 be an integer and let P ∈ Z[x] be a polynomial whose Galois group is the symmetric group S d and such that the quotient of no two roots of P is a root of unity.Let (a n ) be a linearly recursive sequence of integers whose characteristic polynomial is P .The set of primes which divide at least one element of the sequence (a n ) has a lower density of at least 1/(d − 1).In particular, this lower density is strictly positive.
The assumption on the quotients of the roots of P (the non-degeneracy) follows from the assumption on the Galois group for d ≥ 4.
Note that almost all polynomials of degree d have Galois group isomorphic to S d , so the result applies to "100%" of linear recurrences.The proof actually works for a slightly wider class of recurrences, and proves that almost all primes p such that P has suitable factorization modulo p are prime divisors of the sequence.
Theorem 1.2.Assume GRH.Let P ∈ Z[x] be a polynomial which has the following properties.
• P is irreducible.
• There are infinitely many primes p such that P factorizes as the product of a linear polynomial and an irreducible polynomial of degree d − 1 modulo p, that is, the Galois group of P contains an element whose cycle type is the roots of P are multiplicatively independent, and if |P (0)| = 1, some (or, equivalently, any) d − 1 roots of P are multiplicatively independent.Let (a n ) be a linearly recursive sequence of integers whose characteristic polynomial is P .Then almost all primes p such that P factorizes as the product of irreducibles of degree 1 and d − 1 modulo p divide at least one element of the sequence (a n ).In particular, the set of primes which divide at least one element of the sequence (a n ) has a strictly positive lower density.
(There are non-trivial examples of polynomials P which do not satisfy the last condition [2].) The proof also adapts to reducible characteristic polynomials in certain special cases, but as such cases are rare, we do not discuss them in detail.
The GRH used in the proofs is that the non-trivial zeros of the Dedekind zeta-function of any number field lie on the line Re(s) = 1/2.(For details, see Lemma 3.2 below and [8, Theorem 3.1].) We first provide a proof sketch, after which we give a detailed argument.We conclude by discussing challenges arising in the study of prime divisors of linear recurrences.

Overview of the method
For concreteness we consider the sequence a n defined by ) is reducible and thus not of the form of Theorem 1.1, but we only use this example to demonstrate the idea.(The proof of Theorem 1.1 can be adapted to this sequence, though.) In the case when 2 is a quadratic residue modulo p the period of the sequence (a n ) modulo p divides p − 1.We are unable to say anything about whether such primes are prime divisors of (a n ) or not.
The case when 2 is a quadratic nonresidue modulo p, however, turns out to be accessible.Write n = (p + 1)k + r, k, r ∈ Z.We may view the numbers 3 ± √ 2 as elements of F p 2 , and by norms (3 ± √ 2) p+1 = 7. Hence The equation a (p+1)k+r ≡ 0 (mod p) may thus be written as 5 2  7 Artin's primitive root conjecture states that a given rational number a is a primitive root modulo p for infinitely many primes p as long as a is not −1 or a square.Under GRH one can prove this in a quantative form: the set of such primes has a positive density (as long as its infinite) [6].This density is often quite large.For example, for a = 2 the density is roughly 37%.
It turns out that the order of a rational number a modulo primes is almost always almost maximal assuming a ∈ {−1, 0, 1} (under GRH).More precisely, the density of primes p with ord p (a) ≥ (p − 1)/C goes to 1 as C → ∞. (See [22,Section 5] or Lemma 3.2 below.) Note also that if ord p (a) = (p − 1)/h, then the function x → a x (mod p), x ∈ Z attains all non-zero hth powers modulo p as its values.
In this light, to prove that (2.1) is solvable for almost any prime p it suffices to show that the equation has a solution (x, r) with x = 0 for almost any prime p.
Note the right hand side is a linear recurrence.Denote it by b r .We aim to prove that the sequence b 1 , b 2 , . . .almost always attains a hth power as its value modulo p.
By using results from Galois theory and the Chebotarev density theorem, it is not very hard to show that this is true, for example, if there is an infinite subsequence of (b r ) whose elements are distinct primes.
Of course, we cannot guarantee that a linear recurrence has infinitely many prime values.However, there are only a very few cases where such an idea does not work.To name one, if b r is always two times a square, then if 2 is a quadratic nonresidue modulo p (which happens for a positive density of primes, and in this example case for all p we consider), the sequence b r may avoid all squares modulo p.
In general, the only obstructions are that the values of the linear recurrence are almost perfect powers.By applying Zannier's result on Pisot's dth root conjecture [23] we reduce to considering whether a linearly recursive sequence arising in the proof is the power of another recurrence.From here only elementary observations are needed.
As we already mentioned, the sequence a n considered here is not of the form Theorem 1.1, and the general case is more complicated.There are two notable differences.
To perform the "norm-trick" and to arrive to an equation of the form (2.1) we need to control the norms of the roots of the characteristic polynomial in finite fields.To do so, in the situation of Theorem 1.1 we consider those primes p for which P factorizes as the product of irreducibles of degrees 1 and d − 1 modulo p.
From here we are able to reduce to an equation similar to (2.2), though this time the right hand side is not necessarily a linear recurrence of integers but of algebraic numbers.By taking norms we reduce to the integer case, the same idea can be implemented and we are able to show that the reduction of at least one term of the sequence of algebraic numbers to F p is a hth power almost always.
In Section 3 we state the GRH-conditonal result mentioned earlier.In Section 4 we reduce the problem to a polynomial equation in a similar manner as above.We note that the equation is solvable for a set of primes of density 1 if certain field extensions are linearly disjoint.We present the tool to handle such questions in Section 5. To apply the tool we have to check that our sequence is not roughly a perfect power, as done in Section 6.We wrap up the proof in Section 7.

Orders of reductions of algebraic numbers
The following lemma is used when transforming our problem into a polynomial equation.This lemma is the only part of the proof that relies on GRH.Lemma 3.1.Assume GRH.Let P ∈ Z[x] be non-constant and irreducible.Assume P is not a cyclotomic polynomial, i.e. no root of P is a root of unity, and that P is not the identity.Let S denote the set of primes such that the equation P (x) ≡ 0 (mod p) has at least one solution f (p).For C > 0 let S C denote the set of primes p ∈ S for which the order of f (p) modulo p is at least (p − 1)/C.The (lower) density of S C with respect to S approaches 1 as C → ∞.
Note that we do not say anything about which root f (p) of P modulo p we choose if there are several of them.The result is true no matter how the choices are made.
This result is equivalent to the following algebraic number theoretic formulation.
The results of Lenstra [8] imply that T k has a density for all k.This density is given by where the sum is absolutely convergent.Let

Reduction to a polynomial equation
We consider the setup of Theorem 1.1.The proof also works in the situation of Theorem 1.2.
Let P and (a n ) be as in Theorem 1.1.Assume (a n ) is never zero.Let S denote the set of primes p such that P factorizes as the product of polynomials of degree 1 and d − 1 modulo p.By the assumption and the Chebotarev density theorem the density of S is 1/(d − 1).We prove that the density of primes of S which are prime divisors of (a n ) is one.
We write , where α 1 , . . ., α n are the roots of P and γ 1 , . . ., γ d are constants, and (for further purposes) we define where F is the splitting field of P , N := N F/Q (α 1 ) and h ∈ Z + is a parameter fixed later.For an algebraic number field K we let O K denote the ring of integers of K.
For each (unramified) prime p ∈ S there exists a homomorphism ϕ : O F → F p d−1 mapping one of the roots α i , say α 1 , to an element of F p , and the other roots to elements of F p d−1 whose degrees over F p are d − 1.Let K = Q(α 1 ).
Note that for n = k(p d−1 − 1)/(p − 1) + r one has and (Clearly ϕ(α 1 ) = 0 for all but finitely many p.) Hence We then note that α d+1 1 /N is not a root of unity: Otherwise the conjugates α d+1 i /N are roots of unity as well.Hence the product 1≤i≤d α d+1 i /N = N is a root of unity.Hence N = ±1, and thus the numbers α i are roots of unity.This contradicts the non-degeneracy of P .
We may hence apply Lemma 3.1 to α d+1 1 /N .It suffices to show that for any h ∈ Z + the equation is solvable in F p for almost all primes p ≡ 1 (mod h).This may be reformulated as follows: almost all prime ideals of O K(ζ h ) split in at least one of the fields K r := K(ζ h , b 1/h r ), r = 1, 2, . . .

A linear disjointness result
We use the following basic result from Galois theory [4].
Lemma 5.1.Let h be a positive integer, let K be a number field containing a hth root of unity, and let a 1 , a 2 , . . ., a k be a sequence of integers.Assume that for any integers 0 ≤ e i < h, not all zero, one has a Lemma 5.2.Let (x n ) be a linearly recursive sequence of integers.Assume that there do not exist a number field K and integers A, B ≥ 1, D ≥ 2 such that x An+B is always a Dth power of an element of K. Then there exist a subsequence x n 1 , x n 2 , . . . of (x n ) and primes p 1 , q 1 , p 2 , q 2 , . . .such that • the primes p 1 , q 1 , p 2 , q 2 , . . .are pairwise distinct Proof.Note that the condition implies that (x n ) has infinitely many prime divisorsotherwise choose A = 1, B = 0, D = 2 and K to be Q( √ p 1 , √ p 2 , . . ., √ p n ), where p 1 , . . ., p n are the prime divisors of (x n ).Note also that for all except finitely many primes p, say for all p not belonging to T , the sequence (x n ) is periodic modulo p k for all k ∈ Z + .We will inductively choose the indices n i and the primes p i , q i , additionally requiring that p i , q i ∈ T .Assume we have already choosen some n 1 , . . ., n k , p 1 , . . ., p k , q 1 , . . ., q k satisfying the conditions.We now pick n k+1 , p k+1 , q k+1 .Let S = {p 1 , q 1 , . . ., p k , q k } ∪ T .
Pick some prime divisor p k+1 ∈ S, let v p k+1 (x n 0 ) = t > 0 for some n 0 such that x n 0 = 0.By periodicity modulo p t+1 k+1 , there exists an arithmetic progression An + B, n = 1, 2, . . .such that v p k+1 (x An+B ) = t for all n If there exist some prime q k+1 ∈ S∪{p k+1 } and n ∈ Z + such that gcd(v q k+1 (x An+B ), t) = 1, we are done.Assume this is not the case.
If for any prime q k+1 ∈ S and any n we had gcd(v q k+1 (x An+B ), t) = t, then we could write for some functions f, f s : Z + → Z ≥0 .Then x An+B would always be a perfect tth power in a number field containing the tth roots of all primes of s and a 2tth root of unity, contrary to the assumption.Hence there exist a prime q k+1 ∈ S and n ∈ Z + such that t := gcd(v q k+1 (x An+B ), t) < t.Repeat the above argument with q k+1 in place of p k+1 and t in place of t.The value of t decreases.It must happen that for some value of p k+1 and t we find a prime q k+1 with gcd(v q k+1 (x An+B ), t) = 1.
Lemma 5.3.Let h ∈ Z + and let F be a number field containing a hth root of unity.Let (x n ) be a linearly recursive sequence of integers satisfying the assumption of Lemma 5.2.Then there exists a subsequence x n 1 , x n 2 , . . . of (x n ) such that the extensions F (x 1/h n 1 )/F, F (x 1/h n 2 )/F, . . .are linearly disjoint and of degree h.
Proof.Note first that there exists a constant c (depending on F ) such that if x is an integer with x 1/h ∈ F , then all prime divisors of x which are greater than c have multiplicity divisible by h.(If p is a prime with h v p (x), then p is ramified in the Q(x 1/h ).If Q(x 1/h ) ⊂ F , then p is ramified in F , and only finitely many primes ramify in F .) Let (x n i ) be a subsequence constructed in Lemma 5.2.We may assume that the corresponding primes p i , q i are larger than c.We prove that this subsequence works by showing that By the choice of c, (5.1) implies that the prime divisors of x e 1 n 1 • • • x e k n k which are larger than c have multiplicity divisible by h.By the choice of the primes p i , q i this implies h | e i for all i.

Linear recurrences and perfect powers
In this section we show that Lemma 5.3 may be applied to the sequence (c n ).Assume not, so c An+B is always a Dth power of an element in a fixed number field.
By a result of Zannier [23], the only case when a linear recurrence is always a Dth power is when it is the Dth power of a linear recurrence.We may hence write , where d is a linearly recursive sequence (whose elements are not necessarily integers).Write d as an exponential polynomial where the coefficients e m,k are non-zero, σ m,1 , σ m,2 , . . ., σ m,um are non-zero and pairwise distinct, and i m > 0 for all m ≤ t.
We first show that t = 0, i.e. that the characteristic polynomial of (d n ) has no repeated roots.Assume not.Now one sees that d D n may be written as where e n is an exponential polynomial whose polynomial terms have degree less than Dt.
Since the representation of a linear recurrence as an exponential polynomial is unique, one sees that c An+B = d D n cannot hold for all n ∈ Z.We may thus write Each of σ i can be written in the form α d , where x i,j are rational numbers [17].Let M ∈ Z + be such that x i,j M ∈ Z for all i, j.Write the equation for all i, j.Indeed: Since the Galois group of P is S d , we have d i=1 α By basic results on linear recurrences, this implies that for any In particular, the left hand side is a perfect Dth power in C[X ±1  1 , . . ., X ±1 d ].Perform a suitable transformation of the form X i → c i X i , clear out constants and simplify.One obtains that is a Dth power of a polynomial, where A := AM .This is clearly impossible if D (h−1)A .
Otherwise we may drop the term (X 1 • • • X d ) (h−1)A .One sees that the polynomials are pairwise coprime, and hence each of them must be a Dth power.This is not the case, as can be seen, for example, by considering the partial derivative of X A 2 + . . .+ X A d with respect to X 2 at (X 2 , X 3 , . . ., X d ) = (x 0 , 1, . . ., 1), where = 0 for all integers n only if Q is zero.Proceeding as before, we have that is a Dth power of a polynomial in the variables X 1 , . . ., X d−1 (with possibly negative exponents in the monomials), where is coprime with all the other terms of the product, and, as before, this is not a Dth power of a polynomial.

Concluding the proof
We aim to prove that almost all primes of K(ζ h ) split in at least one of the fields . By the Chebotarev density theorem it suffices to construct a subsequence b n 1 , b n 2 , . . . of (b n ) such that the fields

. are linearly disjoint
In Section 6 we checked that we may apply Lemma 5.3 to the norm sequence (c n ).Let c n 1 , c n 2 , . . .denote a subsequence given by the lemma with the base field F (ζ h ), so . .are of degree h and linearly disjoint.We claim that this implies that . .are of degree h and linearly disjoint, too.
By Lemma 5.1 it suffices to show that . By the choice of c n i this happens only if e i = 0 for all i.
Finally, note that linear disjointness over . .are linearly disjoint, as desired.

Discussion
The presented proof considers the primes p such that P has factorization type (1, d − 1) modulo p. Naturally one wonders whether other factorization types could be handled as well.
Unfortunately, this is the only case our argument is able to handle (for irreducible P ): The proof relies crucially on transforming the problem of zeros of linear recurrences to perfect power values of linear recurrences modulo primes.To do so, we first extract norms of the roots of P via the substitution n = k(p d−1 − 1)/(p − 1) + r.One has much less control over the norms in finite fields if P has more than two irreducible factors modulo p.We then apply Lemma 3.1, which requires that P has a root in F p .These two limitations result in having to consider the factorization type (1, d − 1).
By an approach also based on reduction to a polynomial equation, Roskam has settled the case where P remains irreducible modulo p, assuming an analogue of Lemma 3.1 holds for roots of P of degree d over F p (namely that the multiplicative orders of the roots are of magnitude p d almost always).Note that given a linear recurrence (a n ) with a squarefree characteristic polynomial P , the period of (a n ) modulo p is, for large enough primes p, equal to the least common multiple of the multiplicative orders of the roots of P in extensions of F p .Hence Roskam's assumption is equivalent to the period of (a n ) modulo p being of order p d for almost all primes p for which P is irreducible modulo p.
A theorem of Niederreiter [15,Theorem 4.1] gives a stronger result under a weaker assumption: as long as the period of the sequence modulo p is at least of magnitude p d/2+1 , the sequence does not only attain the value 0 (mod p), but the sequence is approximately equidistributed modulo p. (While we have managed to avoid the consideration of the period of a n (mod p), our approach does not yield equidistribution results or even nontrivial lower bounds for the number of values attained by a n modulo p.) We hence see that analogies of Lemma 3.1 to roots of P in extensions of F p are central to understanding the behavior of linear recurrences modulo primes.While it seems likely that such variants of Lemma 3.1 hold (one can present a similar heuristic as for Artin's conjecture), our understanding is very limited.Unconditionally, we only know that given an integer a, |a| > 1, the order of a modulo p is almost always > p 1/2 [3].Under GRH one has Lemma 3.1, and an involved variant of Hooley's classical (conditional) solution of Artin's conjecture yields an analogue of Lemma 3.1 in the case where P is of degree 2 and remains irreducible modulo p [19].It seems that all other cases are open, and as explained in [19], Hooley's argument does not adapt to higher degrees without new ideas.
We conclude by remarking that the case where P splits into d linear factors modulo p seems to be the most difficult to analyze.In these cases the period of the linear recurrence modulo p divides p−1, and heuristically there is a positive density of split primes which are not prime divisors of the sequence (see [18]).For example, we are not able to say essentially anything about the prime divisors of 3 n + 2 n + 1 other than that there are infinitely many of them.In contrast, heuristics suggest that if P is irreducible and deg(P ) ≥ 3, then almost all non-split primes are prime divisors of the corresponding sequence (excluding degenerate cases).This suggests that the lower bound 1/(d − 1) in Theorem 1.1 could be replaced with 1 − 1/d!.

Lemma 3 . 2 .
Assume GRH.Let α be a non-zero algebraic number which is not a root of unity.Let K = Q(α) and let O K denote the ring of integers of K. Let T denote the set of prime ideals of O K whose norm is a prime.For C > 0 let T C denote the set of primes p of T such that the reduction of α in O K /p ∼ = F p has order at least (p − 1)/C, where p is the norm of p.The (lower) density of T C with respect to T approaches 1 as C → ∞ (where ideals are ordered by norm).Proof.(Cf.[22,Section 5].)Note that almost all ideals of