login
A060646
Bonse sequence: a(n) = minimal j such that n-j+1 < prime(j).
3
1, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 5, 5, 6, 6, 6, 7, 7, 7, 7, 7, 8, 8, 8, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 14, 14, 14, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 18, 18
OFFSET
1,2
COMMENTS
For 3<n and any a(n-1)<a(n) use a(n)=a(n+1)=a(n+2) to show prime(j+1)^3 < prime(1)*...*prime(j) for j>5.
REFERENCES
R. Remak, Archiv d. Math. u. Physik (3) vol. 15 (1908) 186-193
LINKS
H. Bonse, Über eine bekannte Eigenshaft der Zahl 30 und ihre Verallgemeinerung, Archiv d. Math. u. Physik (3) vol. 12 (1907) 292-295.
H. Rademacher and O. Toeplitz, Eine Eigenschaft der Zahl 30, (A property of the number 30), Von Zahlen und Figuren (1930, reprint Springer 1968), ch. 22.
EXAMPLE
For n=5, j=3 gives 5-3+1 = 3 < prime(3) = 5, true; but if j=2 we get 5-2+1 = 4 which is not < prime(2) = 3; hence a(5) = 3.
a(75)=18 because 75-18+1=58 < 61=prime(18), but 75-17+1=59=prime(17).
MATHEMATICA
Table[j=0; While[j++; n-j+1 >= Prime[j]]; j, {n, 1, 76}] (* Jean-François Alcover, Aug 30 2011 *)
PROG
(Haskell)
import Data.List (findIndex)
import Data.Maybe (fromJust)
a060646 n = (fromJust $ findIndex ((n+1) <) a014688_list) + 1
-- Reinhard Zumkeller, Sep 16 2011
(Python)
from sympy import nextprime
from itertools import count, islice
def agen(): # generator of terms
n, pj = 1, 2
for j in count(1):
while n - j + 1 < pj: yield j; n += 1
pj = nextprime(pj)
print(list(islice(agen(), 76))) # Michael S. Branicky, Aug 09 2022
CROSSREFS
Cf. A014688.
Sequence in context: A006670 A132914 A370461 * A103298 A082429 A047744
KEYWORD
easy,nonn,nice
AUTHOR
Frank Ellermann, Apr 17 2001
STATUS
approved