OFFSET
1,2
COMMENTS
a(n) = M*n for some integer M >= 0.
a(n) = n times least m >= 0 such that (n-1)!+m is prime. - Jens Kruse Andersen, Jul 30 2014
LINKS
Jens Kruse Andersen, Table of n, a(n) for n = 1..2001
FORMULA
a(n) = n*A033932(n-1), except a(3) = 0 where A033932 demands positive values. - Jens Kruse Andersen, Jul 30 2014
EXAMPLE
(4!+0)/4 = 6 is not prime.
(4!+1)/4 = 25/4 is not prime.
(4!+2)/4 = 26/4 is not prime.
(4!+3)/4 = 27/4 is not prime.
(4!+4)/4 = 7 is prime. Thus a(4) = 4.
PROG
(PARI)
a(n)=for(k=0, 10^6, s=(n!+k)/n; if(floor(s)==s, if(ispseudoprime(s), return(k))))
n=1; while(n<100, print1(a(n), ", "); n++)
CROSSREFS
KEYWORD
nonn
AUTHOR
Derek Orr, Jul 29 2014
STATUS
approved