A247116 Corresponding values of np for A246791.
1, 1, 2, 3, 5, 8, 12, 17, 9, 16, 14, 20, 20, 18
Offset: 1
Crossrefs
Cf. A246791.
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.
a(15) = 2552265, since np(2552265) = 24, np(2552265+1) = 23 , ..., np(2552265+13) = 11, np(2552265+14) = 10 are 15 consecutive numbers in descending order.
np[t_] := np[t] = Length[Select[Range[Prime[t]+1,Prime[t]^(1+1/t)],PrimeQ]]; a[1]=1; a[n_] := a[n] = (For[m = a[n-1],c = Table[np[m+k-1],{k,n}]; c != Reverse[Range[Min[c], Max[c]]], m++]; m); Do[Print[a[n]],{n,15}]
np(n) = primepi(prime(n)^(1+1/n))-n; isok(m, n) = {for (k=1, n, if (np(m+k-1) != np(m)-k+1, return (0));); return (1);} a(n) = {m = 1; while (! isok(m, n), m++); m;} \\ Michel Marcus, Dec 07 2014
Comments