OFFSET
2,1
LINKS
Harry J. Smith, Table of n, a(n) for n = 2..200
EXAMPLE
a(6) = 17 because 17*6! = 12240, 12240 + 1 and 12240 - 1 are twin primes, and there is no prime less than 17 for which this pairing will work.
MATHEMATICA
Do[k = 1; While[ !PrimeQ[ Prime[k]*n! - 1] || !PrimeQ[ Prime[k]*n! + 1], k++ ]; Print[ Prime[k]], {n, 2, 75} ]
PROG
(PARI) { allocatemem(932245000); for (n=2, 200, f=n!; p=2; while (!isprime(p*f + 1) || !isprime(p*f - 1), p=nextprime(p + 1)); write("b064998.txt", n, " ", p) ) } \\ Harry J. Smith, Oct 03 2009
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Oct 31 2001
STATUS
approved