OFFSET
1,3
COMMENTS
Is the sequence unbounded? We know that k exists for any n but is the value of k unbounded?
LINKS
Zak Seidov, Table of n, a(n) for n = 1..1000
MAPLE
a[1]:= 2: a[2]:= 3:b[1]:= 1: b[2]:= 1:
for n from 2 to 1000 do
if n::odd then delta:= 2*n
else delta:= n
fi:
for q from a[n] + delta by delta while not isprime(q) do od:
a[n+1]:= q:
b[n]:= (q - a[n])/n;
od:
seq(b[n], n=1..1000); # Robert Israel, Oct 26 2015
MATHEMATICA
a=2; Table[k=1; While[!PrimeQ[b=a+k*n], k++]; a=b; k, {n, 1000}]
PROG
(PARI) lista(nn) = {a = 2; for (n=1, nn, k=1; while (!isprime(na=a+k*n), k++); print1(k, ", "); a = na; ); } \\ Michel Marcus, Oct 21 2015
CROSSREFS
KEYWORD
nonn
AUTHOR
Zak Seidov, Oct 18 2015
STATUS
approved