April 01, 2024
In 1974, 23-year-old Yuri Matiyasevich shattered Hilbert’s dream to find a universal algorithm that would input an arbitrary polynomial of several variables with integer coefficients and determine whether it has integer solutions. It used, in a very clever way, sequences that satisfy second-order linear recurrences with integer coefficients. A side effect of his proof was the construction of infinite families of Diophantine equations for which the existence of solutions is decidable, the so-called Pell equations.
This was extended to higher-order (third and fourth) recurrences in a deep study by Matiyasevich’s student, Maxim Vsemirnov, using sophisticated algebraic number theory. In the present, mostly expository, article, we revisit some of Vsemirnov’s results from a more elementary viewpoint, and supplement it with a Maple implementation that would enable anyone to actually construct many families of decidable diophantine equations. Our method also can construct such diophantine equations for which one can prove that no solutions exist.
Dedicated to Yuri Matiyasevich, a modern day Diophantus.
A diophantine equation is an equation of the form \(P(x_1, x_2, \dots, x_n) = 0\) where \(P\) is an integer coefficient polynomial, and we restrict the variables \(x_k\) to be integers. The most famous diophantine equation of all time is \[x^2-2y^2=0.\] Hippasus of Metapontum discovered that this equation has no solution in the positive integers [1]. Though Hippasus could not have phrased his argument completely rigorously, he might have enjoyed something like this: Any solution \((x, y)\) satisfies \(x > y > 0\), and it is not hard to check that \((2y - x, x - y)\) is also a positive solution with a smaller second coordinate. (Note that \(2y - x > x - y\) because \(x \geq (3/2) y\) is impossible.) This is a contradiction, because it would imply arbitrarily small positive integers.
Another equation where this kind of argument applies is Pell’s equation \[x^2-2 y^2 = \pm 1.\] If \((x, y)\) is a solution, then so is \((x+2y,x+y)\). A simple brute force search reveals the solution \((1, 1)\), and then this argument yields \((3, 2)\), \((7, 5)\), \((17, 12)\), and so on. A little more effort will show that all positive solutions come from repeatedly applying this map to \((1, 1)\) [2], [3].
The previous two examples covered cases where a diophantine equation had no solutions, and one where it had infinitely many. But both had some subtle technical details that make it hard to imagine generalizing them to other equations. In the early 1900’s, David Hilbert believed that there should be an argument that does generalize to all diophantine equations. The tenth problem on his famous 1900 list was to find it. But in 1970, 23-year-old Yuri Matiyasevich, standing on the shoulders of Julia Robinson, Martin Davis, and Hilary Putnam, shocked the world of mathematics by showing that Hilbert’s dream is impossible. There is no algorithm to determine whether an integer coefficient polynomial has integer roots [4]–[6].
Of course, for specfic equations, or even specific infinite families, one can often decide the question. For example, Sir Andrew Wiles proved that \[x^n+y^n=z^n\] has no positive integer solutions for \(n > 2\), and Noam Elkies proved that \[A^4+B^4+C^4=D^4\] has infinitely many solutions [7], [8].
A key fact in Matiyasevich’s proof is that the solutions to the diophantine equation \[\label{example-eqn} x^2 - b xy + y^2 = 1,\tag{1}\] where \(x\) and \(y\) are variables and \(b\) is an integer “parameter,” are described by the second-order linear recurrence \[\begin{align} a_b(0) &= 0,\;a_b(1) = 1 \\ a_b(n+2) &= b \cdot a_b(n+1)-a_b(n). \end{align}\] This is precise in the following sense: integers \(x > y\) satisfy 1 if and only if \((x, y) = (a_b(n + 1), a_b(n))\) for some integer \(n\) ([5] and [9]). The first step towards this result begins with the matrix identity \[\begin{bmatrix} a_b(n + 1) & -a_b(n) \\ a_b(n) & -a_b(n - 1) \end{bmatrix} = \begin{bmatrix} b & -1 \\ 1 & 0 \end{bmatrix}^n,\] which is easily established by induction. Taking the determinant of both sides and applying \(a_b(n)\)’s defining recurrence shows that consecutive terms of \(a_b(n)\) satisfy 1 . The converse relies on some slightly technical arguments.
From a high level, Matiyasevich showed that a certain family of second order recurrences were “equivalent” to a certain family of diophantine equations. This was enough to resolve Hilbert’s tenth problem, but it suggests a follow up question: What about higher order recurrences? This question was brilliantly investigated by M. A. Vsemirnov, a student of Matiyasevich, in the late 1990’s [10], [11]. Roughly speaking, Vsemirnov proved that only certain recurrences up to order four can be equivalent to a diophantine equation, and he determined all such third order recurrences. Vsemirnov’s techniques rely on sophisticated algebraic number theory. Here, we will show an elementary, constructive approach which relies only on calculus and our computers.
Let us first describe the construction which takes us from recurrences to diophantine equations. Consider the linear recurrence \[\label{recdef} a(n) = c_1 a(n - 1) + \cdots + c_d a(n - d).\tag{2}\] Our recipe has two parts. First, the “companion matrix” \[B = \begin{bmatrix} c_1 & c_2 & \cdots & c_d \\ 1 & 0 & \cdots & 0 \\ 0 & 1 & \cdots & 0 \\ & & \cdots\\ 0 & 0 & \cdots \;1 & 0 \end{bmatrix}\] satisfies the forward identity \[\begin{bmatrix} a(n + 1) \\ a(n) \\ \vdots \\ a(n - d + 2) \end{bmatrix} = B \begin{bmatrix} a(n) \\ a(n - 1) \\ \vdots \\ a(n - d + 1) \end{bmatrix}\] for any sequence which satisfies 2 . Second, 2 has \(d\) “fundamental solutions” which form a basis for all solutions [12]. They are the solutions whose initial conditions (the values \((a(0), a(1), \dots, a(d - 1))\)) are all zero except for a single entry, which is instead one. We will call these solutions \(e_k(n)\), and give them the following initial conditions: \[\begin{bmatrix} 1 & 0 & 0 & \cdots & 0 \\ 0 & 1 & 0 & \cdots & 0 \\ 0 & 0 & 1 & \cdots & 0 \\ & & & \cdots & \\ 0 & 0 & 0 & \cdots & 1 \\ \end{bmatrix} = \begin{bmatrix} e_0(d - 1) & e_1(d - 1) & \cdots & e_{d - 1}(d - 1) \\ e_0(d - 2) & e_1(d - 2) & \cdots & e_{d - 1}(d - 2) \\ e_0(d - 3) & e_1(d - 3) & \cdots & e_{d - 1}(d - 3) \\ & \cdots & \\ e_0(0) & e_1(0) & \cdots & e_{d - 1}(0) \\ \end{bmatrix}.\] This implies the relation \[\label{matident} B^n = B^n I = \begin{bmatrix} e_0(n + d - 1) & e_1(n + d - 1) & \cdots & e_{d - 1}(n + d - 1) \\ e_0(n + d - 2) & e_1(n + d - 2) & \cdots & e_{d - 1}(n + d - 2) \\ e_0(n + d - 3) & e_1(n + d - 3) & \cdots & e_{d - 1}(n + d - 3) \\ & \cdots & \\ e_0(n) & e_1(n) & \cdots & e_{d - 1}(n) \\ \end{bmatrix}.\tag{3}\] From the elementary theory of difference equations (again see [12]), every solution to 2 —including the fundamental ones—can be expressed as a linear combination of the sequences \(e_0(n)\), \(e_0(n + 1)\), …, \(e_0(n + d - 1)\). Therefore every entry in the right-hand side of 3 is actually a linear combination of shifts of \(e_0(n)\). Taking determinants in 3 yields \[P(e_0(n), e_0(n + 1), \dots, e_0(n + d - 1)) = (\det B)^n\] for some polynomial \(P\), and Laplace expansion on the first row gives \(\det B = (-1)^{d + 1} c_d\). If we take \(c_d = (-1)^{d + 1}\) then the right-hand side is \(1\).
These considerations lead to the following proposition.
Proposition 1. For any integers \(c_1, c_2, \dots, c_{d - 1}\), not all zero, there is a nonzero polynomial \(P(x_1, x_2, \dots, x_d)\) such that the diophantine equation \[P(x_1, x_2, \dots, x_d) = 1\] has infinitely many solutions. In particular, the points \((a(n), a(n + 1), \dots, a(n + d - 1))\) are solutions, where \(a(n)\) satisfies \[a(n) = \sum_{k = 1}^{d - 1} c_k a(n - k) + (-1)^{d + 1} a(n - d)\] and has initial conditions \(0, 0, \dots, 0, 1\).
This is roughly half of Matiyasevich’s proof characterizing solutions to 1 . The next step is to generalize the converse, and show that the diophantine equations in Proposition 1 are sometimes solved by only the recurrence solutions. This goal is too lofty in general, but we have arguments which apply to an infinite family of recurrences, and one detailed case study concerning the Tribonacci numbers.
Definition 1. Define the numbers \(T_n\) by \[\begin{align} T_0 &= T_1 = 0 \\ T_2 &= 1 \\ T_n &= T_{n - 1} + T_{n - 2} + T_{n - 3}, \end{align}\] the polynomial \(P_T\) by \[P_T(x, y, z) = x^3+2x^2y+x^2z+2xy^2-2xyz-xz^2+2y^3-2yz^2+z^3,\] and the map \(R_T\) by \[R_T(x, y, z) = (y, z, x + y + z).\] Note that \(P_T\) is invariant under \(R_T\), i.e., \(P_T \circ R_T = P_T\).
Proposition 2. If \(P_T(x, y, z) = 1\) for integers \((x, y, z)\), then \((x, y, z)\) is the result of repeatedly applying \(R_T\) or its inverse to a nonnegative increasing solution. That is, there exist integers \(0 \leq a < b < c\) and a positive integer \(n\) such that \(P_T(a, b, c) = 1\) and \((x, y, z)\) is \(R_T^n(a, b, c)\) or \(R_T^{-n}(a, b, c)\).
Proof. Repeatedly applying \(R_T\) to our initial point \((x, y, z)\) produces a sequence \(a(n)\) which satisfies \[a(n) = a(n - 1) + a(n - 2) + a(n - 3)\] with initial conditions \((a(0), a(1), a(2)) = (x, y, z)\). Because \(P_T\) is invariant under \(R_T\) we have \(P_T(a(n), a(n + 1), a(n + 2)) = 1\) for all \(n\). The elementary theory of difference equations implies \(a(n) \sim c \cdot \alpha^n\) where \(\alpha \approx 1.8393\) is the unique real root of \(X^3 - X^2 - X - 1\) and \[c = \alpha \frac{(\alpha^2 - \alpha - 1) a(0) + (\alpha - 1) a(1) + a(2)}{\alpha^2 + 2 \alpha + 3}.\]
Note that \(c\) is real. If \(c < 0\), then we eventually obtain a strictly negative solution, which is impossible because \(P_T(x, y, z) \leq 0\) if \(x, y, z \leq 0\). If \(c = 0\) then \((\alpha^2 - \alpha - 1) a(0) + (\alpha - 1) a(1) + a(2) = 0\), and this is impossible because \(\{1, \alpha, \alpha^2\}\) is linearly independent over the rationals. (The minimal polynomial is a cubic and irreducible over \(\mathbf{Q}\), so \(\alpha\) is a degree three algebraic integer.) The remaining possibility is \(c > 0\), which implies that we eventually have \(0 < a(n) < a(n + 1) < a(n + 2)\). We get back to \((x, y, z)\) by repeatedly applying the inverse map \(R_T^{-1}\). ◻
Proposition 3. If \(P_T(x, y, z) = 1\) for integers \(0 < x < y < z\), then \((x, y, z) = (T_n, T_{n + 1}, T_{n + 2})\) for some integer \(n \geq 0\).
Proof. The map \(R_T^{-1}(x, y, z) = (z - x - y, x, y)\) takes solutions to other solutions. Note that if \(0 < z - x - y < x\), then the new solution is also positive and increasing, and in fact strictly smaller in magnitude. We will show that \(0 < z - x - y < x\) for all increasing solutions with sufficiently large \(z\).
If we divide both sides of the equation \(P_T(x, y, z) = 1\) by \(z^3\), and make the change of variables \((t, s) = (x / z, y / z)\), then we obtain \[\label{trib-cubic} 2s^3+2s^2t+2st^2+t^3-2st+t^2-2s-t+1 = \frac{1}{z^3}.\tag{4}\] Call the left-hand side of this equation \(f(s, t)\) and note that it is a cubic defined on the unit square. It is a routine (computer-assisted) calculus exercise to show that the minimum of \(f(s, t)\) on the region \(1 - t - s \leq 0\) is \[\frac{398 - 68 \sqrt{34}}{27} > 0.\] Therefore we cannot have both 4 and \(1 - t - s \leq 0\) for \[z > \left( \frac{398 - 68 \sqrt{34}}{27} \right)^{-1/3} \approx 2.6235.\] It follows that \(0 < z - x - y\) for all increasing solutions to \(P_T(x, y, z) = 1\) with \(z \geq 3\). By an analogous argument on the region \(1 - t - s \geq t\), all increasing solutions to \(P_T(x, y, z) = 1\) with \(z \geq 5\) satisfy \(z - x - y < x\).
Repeatedly applying the “backwards” map \(R_T^{-1}\) produces smaller, positive, increasing solutions as long as \(z \geq 5\), and so this process terminates at a solution with \(0 < x < y < z < 5\). It is simple to check that all such solutions return to the point \((0, 0, 1)\) under the map \(R_T^{-1}\), and so all increasing positive solutions come from applying the “forward” map \(R_T\) to \((0, 0, 1)\). This produces exactly the Tribonacci numbers. ◻
See Figure 1 for a visual representation of the maps and regions in Proposition 3.
Theorem 1. If \(P_T(x, y, z) = 1\) for integers \(x, y, z\), then \((x, y, z) = (T_n, T_{n + 1}, T_{n + 2})\) for some integer \(n\).
Proof. By the previous two propositions, every solution comes from applying the maps \((x, y, z) \mapsto (y, z, x + y + z)\) and \((x, y, z) \mapsto (z - x - y, x, y)\) to the solution \((0, 0, 1)\), which produces exactly the Tribonacci numbers with positive and negative indices. ◻
The arguments from the previous section carry over almost verbatim to the general third-order recurrence. The main difficulty is in establishing the minimum of the analogous cubic 4 . For any specific recurrence it is completely routine to check whether the proof of Proposition 3 works, but Proposition 5 gives a weaker statement about an infinite family.
Definition 2. For any positive integers \(a\) and \(b\), define the polynomial \(P_{ab}(x, y, z)\) as \[a^2y^2z+abxyz+aby^3+b^2xy^2+ax^2z+axy^2-2ayz^2+2bx^2y-bxz^2-by^2z+x^3-3xyz+y^3+z^3\]
Proposition 4. Let \(a\) and \(b\) be positive integers such that \(X^3 - a X^2 - bX - 1\) is irreducible over \(\mathbf{Q}\) and has a single largest root which is real and greater than \(1\). Then all integer solutions to \(P_{ab}(x, y, z) = 1\) are generated by applying the map \((x, y, z) \mapsto (z - ay - bx, x, y)\) or its inverse to a positive, increasing solution.
Proof. The argument is the same as in Proposition 2. The irreducibility of \(X^3 - a X^2 - bX - 1\), with largest root \(\alpha > 1\), implies the linear independence of \(\{1, \alpha, \alpha^2\}\) over the rationals and gives the correct asymptotics. ◻
Proposition 5. Fix positive integers \(a\) and \(b\) and consider the recurrence \[\label{3-rec} u(n) = a u(n - 1) + b u(n - 2) + u(n - 3).\qquad{(1)}\] If \(a\) is sufficiently large relative to \(b\), then all solutions \(0 < x < y < z\) to the diophantine equation \(P_{ab}(x, y, z) = 1\) are generated by applying ?? to finitely many solutions.
It should be noted that while the following proof is non-constructive, the method is not. Carrying out the proof for any specific integers \(a\) and \(b\) will determine an exact bound under which the finitely many initial conditions can be found.
Proof. The polynomial \(P_{ab}(x, y, z)\) is invariant under the map \[\label{backwards-gen} (x, y, z) \mapsto (z - ay - bx, x, y),\tag{5}\] so it takes solutions to solutions. Note that \[\begin{align} |(z - ay - bx, x, y)|^2 - |(x, y, z)|^2 = (ay + bx)(ay + bx - 2z) < 0 \end{align}\] provided that the conditions \(x, y \geq 0\) and \[\label{gen-condition} \quad ay + bx - 2z < 0\tag{6}\] are satisfied, meaning that solutions are taken to smaller solutions in this case. We will show that, given an increasing solution \(0 \leq x < y < z\) with sufficiently large \(z\), condition 6 holds, and that the new solution determined by 5 is also nonnegative, increasing and satisfies 6 .
If we divide both sides of \(P_{ab}(x, y, z) = 1\) by \(z^3\) and make the change of variables \((t, s) = (x / z, y / z)\), then we obtain \(f_{ab}(t, s) = z^{-3}\) where \(f_{ab}\) is a cubic in \(t\) and \(s\) on the unit square. The region that we wish to avoid is \[R_{ab} = \{as + bt \geq 2 \} \cup \{1 - as - bt \leq 0\} \cup \{1 - as - bt \geq t\},\] where we implicitly are restricting everything to the unit square. Note that the first set in the union is contained in third set if \(b \geq 1\), so our region is really just \[R_{ab} = \{1 - as - bt \leq 0\} \cup \{1 - as - bt \geq t\}.\] Because \(f_{ab}\) is a cubic, it is possible to exactly compute its critical points on the unit square, as well as the critical points of boundary functions such as \(f_{ab}(0, s)\) and \(f_{ab}(1, s)\). If we treat \(b\) as a constant and perform asymptotic expansions as \(a \to \infty\) of these critical points, it turns out that the minimum of \(f_{ab}\) on the region \(R_{ab}\) occurs on the line \(1 - as - bt = 0\), and it equals \[\frac{1}{a^6} - \frac{b^2}{4 a^7} - \frac{9b}{2a^8} + O(a^{-9}).\] So \(f_{ab}(t, s) = z^{-3}\) fails if \[\label{asy-bound} z > a^2 + \frac{b^2}{12} a + \frac{3b}{2} + \frac{b^4}{72} + O(a^{-1}).\tag{7}\] It follows that the inequalities \[\begin{align} 0 < 1 - as - bt < t &\iff 0 < z - ay - bx < x \\ as + bt < 2 &\iff ay + bx < 2z \end{align}\] hold for any solution \(0 < x < y < z\) with sufficiently large \(z\). We may therefore iterate 5 on such a solution until we reach one where \(z\) is below the bound implied by 7 , and there are only finitely many of these. ◻
Theorem 2. Let \(a\) and \(b\) be positive integers such that
\(X^3 - a X^2 - bX - 1\) is irreducible over the rationals and has a single largest root which is real and greater than \(1\); and
\(a\) is sufficiently large relative to \(b\) (in the non-constructive sense of proposition 4).
Then all integer solutions to \(P_{ab}(x, y, z) = 1\) are generated by applying ?? forwards or backwards to finitely many initial solutions.
Note that the first condition is not very restrictive. The cubic \(X^3 - a X^2 - bX - 1\) has a rational root (by the rational root test) only if \(b = a + 2\).
The characteristic equation \[X^3 - 10 X^2 - 3 X - 1\] leads to the diophantine equation \[x^3+6x^2y+10x^2z+19xy^2+27xyz-3xz^2+31y^3+97y^2z-20yz^2+z^3 = 1.\] Theorem 2 (along with explicit arguments from Proposition 5) shows that all solutions to this equation are generated by applying the maps \((x, y, z) \mapsto (y, z, 10z + 3y + x)\) and \((x, y, z) \mapsto (z - 10y - 3x, x, y)\) to the initial solution \((0, 0, 1)\).
The characteristic equation \[X^3 - 2 X^2 - 3 X - 1\] leads to the diophantine equation \[x^3+6x^2y+2x^2z+11xy^2+3xyz-3xz^2+7y^3+y^2z-4yz^2+z^3 = 1.\] Theorem 2 (along with explicit arguments from Proposition 5) shows that all solutions to this equation are generated by applying the maps \((x, y, z) \mapsto (y, z, 3z + 2y + x)\) and \((x, y, z) \mapsto (z - 3y - 2x, x, y)\) to the initial solutions \[(0, 0, 1), (0, 1, 3), (0, 2, 7), (1, 1, 4),\] none of which can be obtained from any other.
See Figure 2 for a visual demonstration of these maps.
The characteristic equation \[X^3 - X^2 - 3X - 1 = (X - 1)(X^2 - 2X - 1)\] corresponds to setting \(a = 1\) and \(b = 3\), which leads to the diophantine equation \[x^3+6x^2y+x^2z+10xy^2-3xz^2+4y^3-2y^2z-2yz^2+z^3 = 1.\] Our method fails here on two counts. First, the proof of Proposition 5 does not go through (\(a = 1\) is not big enough relative to \(b = 3\)). Second, this recurrence has degenerate integer solutions like \((-1)^n\) which do not have the correct asymptotics.
As mentioned before the proof of Proposition 5, most of our arguments here can be made effective for any set of fixed parameters. The authors have written a Maple package,
Hilbert10.txt, available at https://sites.math.rutgers.edu/~zeilberg/mamarim/mamarimhtml/hilbert10.html. Execute the command
ezra(); to receive a help display.
To execute the proof of Proposition 5 on a specific recurrence, use the command allSolns([a, b, c]). The procedure requires a list of length three with \(c = 1\). This is slightly awkward, but we leave it as is to suggest the challenge of generalizing it.
The following example computes the Diophantine equation induced by the Tribonacci recurrence and finds all of its solutions:
> allSolns([1, 1, 1]);
findAbsoluteMin: making a floating point guess: -2. <= 0
allSolns: looking for monotonically increasing solutions up to 5
{[0, 0, 1]}
The output states that all solutions are generated by applying the Tribonacci recurrence to the initial solution \((0, 0, 1)\). Note that allSolns searches (without loss of generality) for
monotonically increasing solutions.
The following example does the same thing for a different third-order recurrence:
> allSolns([5, 3, 1]);
findAbsoluteMin: making a floating point guess: -7.333333333 <= 0
allSolns: looking for monotonically increasing solutions up to 36
{[0, 0, 1]}
And finally, an example with several generating initial conditions:
> allSolns([2, 3, 1]);
findAbsoluteMin: making a floating point guess: -2. <= 0
allSolns: looking for monotonically increasing solutions up to 17
{[0, 0, 1], [0, 1, 3], [0, 2, 5], [1, 1, 4]}
The package also includes a verbose “proof printer,” verboseProof, which fills in the details of Proposition 5 for specific parameters.
> verboseProof([2, 3, 1]);
findAbsoluteMin: making a floating point guess: -2. <= 0
THEOREM. The nonnegative, increasing solutions to the
diophantine equation
3 2 2 2 2 3
x + 6 x y + 2 x z + 11 x y + 3 x y z - 3 x z + 7 y
2 2 3
+ y z - 4 y z + z = 1
are generated by applying the recurrence
[2, 3, 1]
to finitely many initial solutions.
PROOF. Let P be the polynomial P on the left-hand side.
Note that it is invariant under the recurrence:
P - P(shift) is, 0
The backwards shift formula to get the previous term
from the triple (x, y, z) is
z - 3 x - 2 y
We will show that this backwards shift gives a smaller
increasing solution for sufficiently large z.
3
Divide both sides of our equation by, z ,
and make the change of variables {t = x / z, s = y / z}
This gives
3 2 2 3 2 2
7 s + 11 s t + 6 s t + t + s + 3 s t + 2 t - 4 s
1
- 3 t + 1 = ----
3
z
where (t, s) is in the unit square.
Let (x, y, z) be a generic solution. Then the following
inequalities are routine calculus exercises.
the inequality, 0 < z - 3 x - 2 y, also known as,
0 < -2 s - 3 t + 1, holds for
1
-------------------------- <= z
/ 1/2\(1/3)
|50371 1718 859 |
|----- - -----------|
\81675 81675 /
more explicitly for
16.36065936 <= z
the inequality, z - 3 x - 2 y < x, also known as,
-2 s - 3 t + 1 < t, holds for
1
----------------------- <= z
/ 1/2\(1/3)
|161 53 1219 |
|--- - ----------|
\216 2484 /
more explicitly for
13.33123227 <= z
We only need to look for solutions with, z < 16.36065936
and there are finitely many of these.
Q.E.D.
Many thanks are due to Yuri Matiyasevich for telling us about the deep work of Maxim Vsemirnov.