OFFSET
1,1
COMMENTS
a(16) is divisible by the 17th prime, so there can be no a(17). - Robert Israel, Feb 23 2017
EXAMPLE
After a(2) = 9 we have a(3) = 6*9 + 1 = 55 since this is smallest such number divisible by the third prime 5.
MAPLE
a[1]:= 2:
for n from 2 to 16 do
v:= chrem([1, 0], [a[n-1], ithprime(n)]);
if v = a[n-1]+1 then a[n]:= v + a[n-1]*ithprime(n) else a[n]:= v fi
od:
seq(a[i], i=1..16); # Robert Israel, Feb 23 2017
MATHEMATICA
a = 1; Do[k = 2; While[ !IntegerQ[(k*a + 1)/Prime[n]], k++ ]; a = (k*a + 1); Print[a], {n, 1, 16}]
CROSSREFS
KEYWORD
nonn,fini,full
AUTHOR
Amarnath Murthy, Mar 23 2002
EXTENSIONS
Corrected and extended by Larry Reeves (larryr(AT)acm.org), Jul 02 2002
More terms from Robert G. Wilson v, Oct 10 2002
STATUS
approved