10

About a month ago, I asked a similar question about a certain class of polynomials that seem to defy the odds of "eventual divisibility", a property that is best explained by a slightly modified excerpt of the original question:

Look at the graph $G$ that is generated by the polynomial $q(x) = x^2+ax+b$ ($a,b \in \mathbb{Z}$) via the edge set $$\{(n, q(n) \text{ mod } p) : n =0,\ldots,p-1\}$$ for some prime $p \in \mathbb{P}$. After some thought, it should be clear that the statements $$``\text{Iterating } q \text{ for any input will always eventually lead to divisibility by some prime at least once.} ``$$ and $$``G \text{ has a path from any node to 0.}``$$ are equivalent. A polynomial $q$ with a prime $p$ has the property of "eventual divisibility" if one of these statements hold. Furthermore, "at least once" can be replaced by "periodically infinitely many times" and "every node has a path to $0$" can be characterized by "$G$ is weakly connected and has exactly one loop containing $0$".

After some careful case elimination, I was left with (i.e. could not prove/disprove the property for) three quadratic polynomials where linear and constant coefficients are absolutely smaller than $10$:

$(1)$ $x^2-7x-7$ (which is checked up to $p \leq 35800000$ by Mike Daas and me with no hits)

$(2)$ $x^2-7x+5$ (which is checked up to $p \leq 7100000$ by Mike Daas and me with no hits)

$(3)$ $x^2+5x+7$ (which was shown by Oscar Lanzi to be provably non-eventually divisible)

"No hits" just means that up to now this polynomial does not have a corresponding $p$ that gives it the "eventually divisible" property. Since the property seems to hold except for trivial exceptions (see other question), it seems highly unusual that these polynomials just happen to not have it by pure chance - even up in the millions as it turns out! The method that was used for $(3)$ can be applied similarly, but does not yield an exhaustive proof: Let's focus on $(2)$, since it has the smaller discriminant $\Delta = 29$. A key idea for disproving eventual divisibility is $$x^2-7x+5 \equiv 0 \mod p \text{ is not solvable} \iff \left(\frac{\Delta}{p}\right) = \left(\frac{29}{p}\right) = -1$$ Using quadratic reciprocity, we can figure out that $$\left(\frac{29}{p}\right) = \left(\frac{p}{29}\right) = -1 \iff p \equiv 2,3,8,10,11,12,14,15,17,18,19,21,26,27 \mod 29$$ i.e. $p$ congruent to one of these residues need not to be checked since the existence of a cycle at $0$ is disproven by the lack of solutions leading to $0$ when iterated. The same argument can also be applied to the fixed-point-method in the mentioned question, but the CRT guarantees that we will never cover all primes with this (and the discriminants get very, very big leading to extra casework). Thus, the list of $p$ left after this procedure begins $$p = 5,7,13,23,53,59,67,71,83,103,107,109,139,\ldots$$

For convenience, let's list the cycles present in the iteration graphs for each of these primes:

$$\begin{array}{c|c} p & \text{Cycles} \\ 5 & (0),(3) \\ 7 & (2),(6) \\ 13 & (0,5,8),(9,10) \\ 23 & (3,16,11) \\ 53 & (12),(16,43),(30,6,52,13) \\ 59 & (0,5,54,6,58,13,24),(14,44,40,27) \\ 67 & (15,58),(12,65,23,38,44,25,53,31) \\ 71 & (12,65),(48,56,51) \\ 83 & (33),(58),(36,53) \\ 103 & (48,16,46) \\ 109 & (20,47,32,42,58) \\ 139 & (21),(126),(85,102,104) \end{array}$$

As a bonus, here is a quite bizarre pattern that I spotted while generating the graph for $x^2-7x+5$ with $p=43$: Symmetric iteration graph; quite unusual outside of easy examples like x^2

I used Mathematica to generate this picture, to view different examples just change the parameters of the function:

PolyModGraph[poly_,var_,mod_] := Graph[Table[t \[DirectedEdge] Mod[poly/.x -> t,mod], {t,0,mod-1}], VertexLabels->"Name"];
PolyModGraph[x^2-7x+5,x,43]

There are many polynomial-prime combinations that show a $2$-fold, $3$-fold,... "rotational symmetry" of this kind, but there are also many that do not exhibit any symmetry at all.

The erratic behaviour of the cycle's lengths and their residue classes left me clueless and it does not spark much hope for a proof, but nonetheless:

Is it possible that the non-eventual divisibility of $x^2-7x-7$ and $x^2-7x+5$ happens to be just by chance, i.e. some anti-"strong law of small numbers" is at work here? Is there another way of proving this property besides the one given by Oscar Lanzi?

TheOutZ
  • 1,489
  • 11
  • 22
  • 2
    I wrote some slow-ish sagemath code and let it run for about 12 hours today on the polynomial $x^2 - 7x + 5$. I have confirmed that it is not eventually divisible for all primes $p \leq 6,881,261$. For all but $500$ or so of these, $1 \mod p$ already fails to reach $0 \mod p$, and most of these exceptions then fail for $2 \mod p$. If those pass, some first-fails occur more often than others, but it's erratic. Notable are $p = 1327$, which fails first only for $606$, and perhaps most impressively, $p = 572,357$ which only fails first for $117,997$. I'll run the same code for $x^2- 7x - 7$ soon – Mike Daas Mar 13 '24 at 00:46
  • 2
    Now I really begin to wonder whether this is at all related to what Sangchul Lee asked about a few years ago. This is likely to be more complicated, because it is not just about squaring (conjugated or not). Intriguing! – Jyrki Lahtonen Mar 13 '24 at 17:37
  • 2
    As promised, I also ran my code on $x^2 - 7x - 7$ and I was able to confirm that it is not eventually divisible for all primes $p < 4,000,000$. In this range, only about $400$ did not already fail for $1 \mod p$, again many of those failing for $2 \mod p$, and this time the only prime that really put up a fight being $p = 92,377$ that first fails only for $14,839$ – Mike Daas Mar 14 '24 at 00:58
  • 1
    @MikeDaas I wrote some (quite fast) C++ code that is currently checking these examples. The combination of your idea to just look at $0, 1, ... \mod p$ and check if we are stuck in a non-zero loop combined with the Jacobi symbol eliminating hopeless cases leads to blazingly fast checking! One could probably further speed this up by parallelizing the checking, since the computations are independent of one another. – TheOutZ Aug 09 '24 at 15:34
  • There was a small hiccup at $p = 12030089$ for $x^2-7x-7$, but we can resolve this by checking if $x^2-8x-7 = 0$ has solutions, i.e. if $\left(\frac{92}{p}\right) = 1$. As it turns out, $3149477$ is a modular square root of $92$ and we can discard this $p$ as a potential candidate. – TheOutZ Aug 10 '24 at 11:03
  • This is very interesting! Can I ask how you generated the functional graph? I'd love to look at more of these. What it suggests to me is that there is a symmetry of order $3$ (for example, some other polynomial or similar which commutes with the action of $p$) and it would be interesting to see if this generalizes at all. – Qiaochu Yuan Aug 11 '24 at 22:42
  • Please [edit] your post to make it self-contained, so we don't have to read the link or the other question to understand what is being asked here. You say "the property" but you don't ever define the property; please fix that. Please define precisely which polynomials are acceptable and which are not, in this question. What does 'no hits' mean? Please state more clearly what you are asking. – D.W. Aug 12 '24 at 09:19
  • @D.W. Yes, you are right, after rereading this question after quite some time, I will add the required details to make it self-contained and with less obfuscated terminology. – TheOutZ Aug 12 '24 at 18:15
  • 1
    @QiaochuYuan I am honored that this question has attracted your interest! Sure thing: I used a Mathematica Graph object that is based on a table that maps the residues to their output (with [DirectedEdge]) under a certain given polynomial. The image is generated by simply evaluating such a Graph object. I will add the code snippet to the question while I polish it. – TheOutZ Aug 12 '24 at 18:19
  • Thank you for the revisions. I still am not clear on what property you are trying to prove/disprove. Are you trying to check whether $q(x)=x^2-7x-7$ is eventually divisible for all primes $p$? whether there exists a prime $p$ such that $q(x)=x^2-7x-7$ is eventually divisible for $p$? – D.W. Aug 12 '24 at 20:04
  • @D.W. The second one, I thought of a better way to phrase it and stay consistent with the original question, but apparently it didn't quite succeed. – TheOutZ Aug 13 '24 at 07:14
  • 1
    A very crude heuristic suggests it could well just be chance. Suppose (as a crude heuristic) we model the map $x \mapsto q(x) \bmod p$ as a random function ${0,\dots,p-1} \to {0,\dots,p-1}$. The probability that this function is eventually divisible for $p$ is $p!/p^p$. Therefore, by a union bound, the probability that there exists $p$ for which this function is eventually divisible is $\le \sum_p p!/p^p$, where $p$ ranges over all primes $p$. This sum is $<0.77$. Therefore, the crude heuristic predicts there should exist polynomials that are not eventually divisible for any prime $p$. – D.W. Aug 13 '24 at 08:05
  • @D.W. I get that a random approximation might be the only hope to model this problem in a sensible way, but these problems are entirely deterministic - we can even categorically rule out most polynomials by proof using computation, determinants etc. So any "randomness" argument, I'm afraid, does not give much of an indication. Feel free to suggest why I might be mistaken here, my knowledge on distributions of polynomial values in finite fields is a bit muddy. – TheOutZ Aug 13 '24 at 12:45
  • 1
    @QiaochuYuan One thing that might be able to explain the symmetry of (only) the given example is the following: The only two polynomial sequences that commute with other members of their sequence are the power polynomials and the Chebyshev polynomials (up to conjugation of the elements by a linear polynomial). Let's take the conjugate $\sigma(x) := x + \frac{7}{2}$, then $\sigma(f(\sigma^{-1}(x))) = x^2 - 7x + \frac{63}{4}$ (where $f(x) := x^2$) commutes with all the other conjugated power polynomials. In this case, since $\frac{63}{4} = 5 \mod 43$, we get the original polynomial back. – TheOutZ Aug 16 '24 at 11:17
  • @QiaochuYuan Okay, I admit I might have confused myself a bit, but how can we actually take e.g. commuting polynomials and explain the symmetries with them? I suspect something between the polynomials $\sigma \circ x \mapsto x^2 \circ \sigma^{-1}$ and $\sigma \circ x \mapsto x^3 \circ \sigma^{-1}$ is at work here (symmetry of order $3$ and $6$), but I can't see the argument. – TheOutZ Aug 19 '24 at 12:59

1 Answers1

2

I will post further developments as an answer to not clutter the exposition in the question too much. To reduce the amount of case checking we have to do, we can put the ideas about higher iterates mentioned in the question to the test: Define $q(x):=x^2-7x+5$. Since

$$q(x)-x = \underbrace{x^2-8x+5}_{\Delta_1=44}$$ $$q^{(2)}(x)-x = \underbrace{(x^2-8x+5)}_{\Delta_1}\underbrace{(x^2-6x-1)}_{\Delta_2 = 40}$$ $$q^{(3)}(x)-x = (x^2-8x+5)(x^3-13x^2+40x+13)(x^3-7x^2+4x+1) \stackrel{t = x+\frac{13}{3},s=x+\frac{7}{3}}{=} \underbrace{(x^2-8x+5)}_{\Delta_1}\underbrace{(t^3-\frac{49}{3}t+\frac{637}{27})}_{-\frac{\Delta_t}{108} = -\frac{2401}{108}}\underbrace{(s^3-\frac{37}{3}s-\frac{407}{27})}_{-\frac{\Delta_s}{108} = -\frac{1369}{108}}$$ we get additional conditions based on if one of the discriminants of these factors is a quadratic residue (refer to the quadratic and cubic formula if this is not clear):

$$\left(\frac{\Delta_1}{p}\right) = \left(\frac{44}{p}\right) = \left(\frac{11}{p}\right) \stackrel{!}{=} 1$$

$$\left(\frac{\Delta_2}{p}\right) = \left(\frac{40}{p}\right) = \left(\frac{2}{p}\right) \left(\frac{5}{p}\right) \stackrel{!}{=} 1$$

$$\left(\frac{-108^{-1}\Delta_t}{p}\right) = \left(-\frac{108^{-1}2401}{p}\right) = \left(\frac{-3^{-1}}{p}\right) = \left(\frac{-3}{p}\right) = \left(\frac{-1}{p}\right)\left(\frac{3}{p}\right) \stackrel{!}{=} 1$$

$$\left(\frac{-108^{-1}\Delta_s}{p}\right) = \left(\frac{108^{-1}1369}{p}\right) = \left(\frac{-3^{-1}}{p}\right) = \left(\frac{-3}{p}\right) = \left(\frac{-1}{p}\right)\left(\frac{3}{p}\right) \stackrel{!}{=} 1$$

Putting everything together, we have the existence of one-cycles if (remember that $p$ is prime) $$p \equiv 1, 4, 5, 6, 7, 9, 16, 19, 20, 24, 25, 26, 28, 30, 34, 35, 36, 37, 39, \ 42, 43 \mod 44 \iff p \equiv 1,5,7,9,19,25,35,37,39,43 \mod 44$$ the existence of (true) two-cycles if $$p \equiv 1,3,9,13,27,31,37,39 \mod 40$$ and the existence of (true) three-cycles if $$p \equiv 1,4,7,10 \mod 12 \iff p \equiv 1,7 \mod 12$$ in addition to the $\mod 29$-condition given in the question. Now, the list of primes that have precursors to zero (quadratic residue modulo $29$) but no cycles of length upto three (quadratic nonresidue, so not fulfilling their modulo conditions) starts as [TODO: There must be some mistake in either my table or this calculation.] $$p = 23, 59, 149, 179, 233, 383, 419, 593, 647, 701, \ldots$$

TheOutZ
  • 1,489
  • 11
  • 22
  • When you go to degree $3$ or higher, whether the sqyare root argument is quadratic no longer reliably determines whether roots exist. For instance, if the square root radicand in a cubic root is nonquadratic, there may or may not be a set of three distinct roots $\bmod p$. – Oscar Lanzi Aug 13 '24 at 12:35
  • @OscarLanzi That is true, when I get the time I will update my answer accordingly. Thanks! – TheOutZ Aug 13 '24 at 12:37
  • @OscarLanzi I don't exactly get what you are trying to get me to do here - if $P(r^2-7r+5)$ is divisible by $P(r)$, isn't the remainder of the polynomial division always $0$? – TheOutZ Aug 15 '24 at 08:56
  • 1
    I realized that later. – Oscar Lanzi Aug 15 '24 at 14:52