OFFSET
1,2
MATHEMATICA
km = 0; Reap[Do[k = 1; While[ ! PrimeQ[2*n*k + 1], k++]; If[k > km, km = k; Sow[k]], {n, 20000}]][[2, 1]]
lk[n_]:=Module[{k=1}, While[!PrimeQ[2n k+1], k++]; k]; DeleteDuplicates[Array[ lk, 10^7], GreaterEqual] (* Harvey P. Dale, Jun 20 2023 *)
PROG
(PARI) A016014(n)=my(k); while(!isprime(2*n*k+++1), ); k
r=0; for(n=1, 1e8, t=A016014(n); if(t>r, r=t; print1(r", "))) \\ Jianing Song, Mar 09 2021, based on the program of A239727
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Zak Seidov, Mar 26 2014
EXTENSIONS
a(37)-a(40) from Giovanni Resta, Mar 26 2014
STATUS
approved