The polynomial
f(n) = n⁴ − 74n³ + 1525n² − 5772n + 10159
This monic quartic integer polynomial produces a run of
38 consecutive prime values when evaluated at
consecutive integers starting at n = 0. As usual in this
context, primality is tested on the absolute value |f(n)|.
Run length: L = 38
Category: monic quartic prime-generating polynomial
The polynomial
f(n) = n⁴ − 74n³ + 1525n² − 5772n + 10159
is a monic quartic polynomial, since the leading coefficient (the coefficient of n⁴) is equal to 1. This places it within the class of monic quartic prime-generating polynomials, a mathematically significant and more restrictive family than generic quartic polynomials.
In this stricter category, achieving a long consecutive prime run is notably difficult. The polynomial above attains a run length of:
L = 38
establishing an exceptionally long documented prime-generating run for a monic quartic polynomial.
From L = 35 to L = 38 via translation
The starting polynomial (L = 35)
The genealogy starts from the quartic
g(n) = n⁴ − 62n³ + 913n² + 1488n + 4651
which generates L = 35 consecutive primes starting
at n = 0. Explicitly, |g(n)| is prime for
n = 0, 1, …, 34, and the first composite value occurs at
n = 35:
g(35) = 17531 = 47 × 373.
The n → n − 1 translation method
Given a polynomial P(n) with a long prime run, one can
construct a translated polynomial
Q(n) = P(n − 1).
If the newly introduced value P(−1) is also prime, then
the prime run of Q(n) starting at n = 0 is
extended by one:
P(n)is prime forn = 0, …, L − 1,P(L)is composite,P(−1)is prime,
which implies that Q(n) = P(n − 1) is prime for
n = 0, …, L, with the first composite at
n = L + 1. Iterating this translation constructs a
genealogical tree of quartic polynomials, each step
corresponding to a shift by n → n − 1.
Structural nature of the record
Applying this method repeatedly to the starting polynomial with
L = 35 yields the structural record
f(n) = n⁴ − 74n³ + 1525n² − 5772n + 10159
with run length L = 38. The process cannot be
extended further within this genealogy, as the next value on the
negative side is composite
(f(−1) = 17531 = 47 × 373), preventing another
successful translation step that would increase L.
The genealogical tree (L = 38 → L = 1)
Starting from the structural record with L = 38, we
obtain a full genealogical family of monic quartic polynomials by
iterated translations. Each polynomial fL(n)
has the form
fL(n) = n⁴ + a n³ + b n² + c n + d
and generates exactly L consecutive primes for
n = 0, …, L − 1. For every entry in this family, the
first composite appears at n = L and takes the same
value:
fL(L) = 17531 = 47 × 373.
The complete genealogical table is:
| L | Quartic polynomial fL(n) |
|---|---|
| 38 | n⁴ − 74n³ + 1525n² − 5772n + 10159 |
| 37 | n⁴ − 70n³ + 1309n² − 2940n + 5839 |
| 36 | n⁴ − 66n³ + 1105n² − 528n + 4139 |
| 35 | n⁴ − 62n³ + 913n² + 1488n + 4651 |
| 34 | n⁴ − 58n³ + 733n² + 3132n + 6991 |
| 33 | n⁴ − 54n³ + 565n² + 4428n + 10799 |
| 32 | n⁴ − 50n³ + 409n² + 5400n + 15739 |
| 31 | n⁴ − 46n³ + 265n² + 6072n + 21499 |
| 30 | n⁴ − 42n³ + 133n² + 6468n + 27791 |
| 29 | n⁴ − 38n³ + 13n² + 6612n + 34351 |
| 28 | n⁴ − 34n³ − 95n² + 6528n + 40939 |
| 27 | n⁴ − 30n³ − 191n² + 6240n + 47339 |
| 26 | n⁴ − 26n³ − 275n² + 5772n + 53359 |
| 25 | n⁴ − 22n³ − 347n² + 5148n + 58831 |
| 24 | n⁴ − 18n³ − 407n² + 4392n + 63611 |
| 23 | n⁴ − 14n³ − 455n² + 3528n + 67579 |
| 22 | n⁴ − 10n³ − 491n² + 2580n + 70639 |
| 21 | n⁴ − 6n³ − 515n² + 1572n + 72719 |
| 20 | n⁴ − 2n³ − 527n² + 528n + 73771 |
| 19 | n⁴ + 2n³ − 527n² − 528n + 73771 |
| 18 | n⁴ + 6n³ − 515n² − 1572n + 72719 |
| 17 | n⁴ + 10n³ − 491n² − 2580n + 70639 |
| 16 | n⁴ + 14n³ − 455n² − 3528n + 67579 |
| 15 | n⁴ + 18n³ − 407n² − 4392n + 63611 |
| 14 | n⁴ + 22n³ − 347n² − 5148n + 58831 |
| 13 | n⁴ + 26n³ − 275n² − 5772n + 53359 |
| 12 | n⁴ + 30n³ − 191n² − 6240n + 47339 |
| 11 | n⁴ + 34n³ − 95n² − 6528n + 40939 |
| 10 | n⁴ + 38n³ + 13n² − 6612n + 34351 |
| 9 | n⁴ + 42n³ + 133n² − 6468n + 27791 |
| 8 | n⁴ + 46n³ + 265n² − 6072n + 21499 |
| 7 | n⁴ + 50n³ + 409n² − 5400n + 15739 |
| 6 | n⁴ + 54n³ + 565n² − 4428n + 10799 |
| 5 | n⁴ + 58n³ + 733n² − 3132n + 6991 |
| 4 | n⁴ + 62n³ + 913n² − 1488n + 4651 |
| 3 | n⁴ + 66n³ + 1105n² + 528n + 4139 |
| 2 | n⁴ + 70n³ + 1309n² + 2940n + 5839 |
| 1 | n⁴ + 74n³ + 1525n² + 5772n + 10159 |
Computational verification (sketch)
The structural record and all polynomials in the genealogical tree were verified by exhaustive evaluation and deterministic primality checks on 64-bit integers.
For the record polynomial
f(n) = n⁴ − 74n³ + 1525n² − 5772n + 10159
we have:
|f(n)|is prime forn = 0, 1, …, 37,- the first composite appears at
n = 38, f(38) = 17531 = 47 × 373.
Minimal Python snippet
The following code reproduces the run length L = 38 for
the structural record:
""" Deterministic primality test for the structural monic quartic record: f(n) = n^4 - 74*n^3 + 1525*n^2 - 5772*n + 10159 """ A = -74 B = 1525 C = -5772 D = 10159 def is_prime(n: int) -> bool: if n < 2: return False if n % 2 == 0: return n == 2 d = 3 while d * d <= n: if n % d == 0: return False d += 2 return True def f(n: int) -> int: return n**4 + A*n**3 + B*n**2 + C*n + D def main(): primes = [] n = 0 while True: v = f(n) if v < 2 or not is_prime(abs(v)): break primes.append((n, v)) n += 1 L = len(primes) print("Structural quartic record:") print(f" (a, b, c, d) = ({A}, {B}, {C}, {D})") print("\\nLength of the consecutive prime run (L):", L) print(f"First composite at n = {L}: f(n) = {f(L)}") if __name__ == "__main__": main()