OFFSET
0,2
COMMENTS
With floor instead of ceiling, we get 1, 2, 1, 5, 1, 11, 1, 17, 1, 23, ..., which is A031368 interspersed with 1's. - Michel Marcus, Apr 08 2023
LINKS
John Tyler Rascoe, Table of n, a(n) for n = 0..10000
MATHEMATICA
a = {1}; For[n = 1, n < 80, n++, AppendTo[a, Ceiling[Prime[n]/a[[n]]]]]; a (* Stefan Steinerberger, Aug 28 2008 *)
PROG
(Python)
from math import ceil
from sympy import prime
def A140828_list(nmax):
A = [1]
for n in range(1, nmax+1):
A.append(ceil(prime(n)/A[-1]))
return A # John Tyler Rascoe, Apr 07 2023
(PARI) lista(nn) = my(va = vector(nn)); va[1] = 1; for (n=2, nn, va[n] = ceil(prime(n-1)/va[n-1]); ); va; \\ Michel Marcus, Apr 08 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, Jul 18 2008
EXTENSIONS
More terms from Stefan Steinerberger, Aug 28 2008
STATUS
approved