cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A349644 Array read by antidiagonals, n >= 2, m >= 0: T(n,m) is the smallest prime p = prime(k) such that all n-th differences of (prime(k), ..., prime(k+n+m)) are zero.

This page as a plain text file.
%I A349644 #12 Dec 05 2021 06:05:25
%S A349644 3,251,17,9843019,347,347,121174811,2903,2903,41
%N A349644 Array read by antidiagonals, n >= 2, m >= 0: T(n,m) is the smallest prime p = prime(k) such that all n-th differences of (prime(k), ..., prime(k+n+m)) are zero.
%C A349644 T(n,m) = prime(k), where k is the smallest positive integer such that A095195(j,n) = 0 for k+n <= j <= k+n+m.
%C A349644 Equivalently, T(n,m) is the smallest prime p = prime(k) such that there is a polynomial f of degree at most n-1 such that f(j) = prime(j) for k <= j <= k+n+m.
%F A349644 T(n,m) <= T(n-1,m+1).
%F A349644 T(n,m) <= T(n, m+1).
%F A349644 Sum_{j=0..n} (-1)^j*binomial(n,j)*prime(k+i+j) = 0 for 0 <= i <= m, where prime(k) = T(n,m).
%e A349644 Array begins:
%e A349644   n\m|   0       1           2           3           4
%e A349644   ---+------------------------------------------------
%e A349644   2  |   3     251     9843019   121174811           ?
%e A349644   3  |  17     347        2903       15373      128981
%e A349644   4  | 347    2903       15373      128981    19641263
%e A349644   5  |  41    8081      128981    19641263   245333213
%e A349644   6  | 211  128981    19641263   245333213   245333213
%e A349644   7  | 271  386471    81028373   245333213 27797667517
%e A349644   8  |  23 2022971   245333213 27797667517           ?
%e A349644   9  | 191 7564091 10246420463           ?           ?
%o A349644 (Python)
%o A349644 from sympy import nextprime
%o A349644 def A349644(n,m):
%o A349644     d = [float('inf')]*(n-1)
%o A349644     p = [0]*(n+m)+[2]
%o A349644     c = 0
%o A349644     while 1:
%o A349644         del p[0]
%o A349644         p.append(nextprime(p[-1]))
%o A349644         d.insert(0,p[-1]-p[-2])
%o A349644         for i in range(1,n):
%o A349644             d[i] = d[i-1]-d[i]
%o A349644         if d.pop() == 0:
%o A349644             if c == m: return p[0]
%o A349644             c += 1
%o A349644         else:
%o A349644             c = 0
%Y A349644 Cf. A006560 (row n=2), A349642 (row n=3), A349643 (column m=0).
%Y A349644 Cf. A095195.
%K A349644 nonn,tabl,hard,more
%O A349644 2,1
%A A349644 _Pontus von Brömssen_, Nov 23 2021