A284262 a(n) = where A284259 for the first time obtains value n (positions of its records).
1, 2, 6, 105, 5005, 85085, 1616615, 37182145, 6685349671, 247357937827, 10141675450907, 436092044389001, 20496326086283047, 9156001667401012567, 558516101711461766587, 37420578814667938361329, 2656861095841423623654359, 193950859996423924526768207, 15322117939717490037614688353, 1271735788996551673122019133299
Offset: 0
Keywords
Links
- G. C. Greubel, Table of n, a(n) for n = 0..335
Crossrefs
Programs
-
Mathematica
A[n_]:= If[n<1, 0, Block[{k=1}, While[Prime[n + k - 1] > Prime[k]^2, k++]; k - 1]]; a[n_]:=If[n<2, n + 1, Product[Prime[i], {i, A[n] + 1, A[n] + n}]]; Table[a[n], {n, 0, 51}] (* Indranil Ghosh, Mar 24 2017 *)
-
PARI
A(n) = { my(k=1); if(0==n, 0, while(prime(n+k-1) > (prime(k)^2), k = k+1); (k-1)); }; a(n) = prod(i=A(n) + 1, A(n) + n, prime(i)); for(n=0, 51, print1(a(n),", ")) \\ Indranil Ghosh, after Antti Karttunen, Mar 24 2017
-
Python
from sympy import prime from operator import mul from functools import reduce def A(n): if n<1: return 0 k=1 while prime(n + k - 1)>prime(k)**2:k+=1 return k - 1 def a(n): return n + 1 if n<2 else reduce(mul, [prime(i) for i in range(A(n) + 1, A(n) + n + 1)]) print([a(n) for n in range(21)]) # Indranil Ghosh, Mar 24 2017
-
Scheme
(define (A284262 n) (A242378bi (A284263 n) (A002110 n))) ;; Where A242378bi(k,n) applies prime shift A003961(n) k times. See A242378.
Comments