|
|
A087147
|
|
Numbers k such that k!+(k+1)!+1 is prime.
|
|
2
|
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
291 is in the sequence and also is in the sequence A087146, thus (291!+292!-1,291!+292!+1) is a twin pair of primes. Any additional terms are greater than 1800 with the next prime having more than 5086 digits.
Next term is greater than 4200. - Gabriel Cunningham (gcasey(AT)mit.edu), Sep 09 2003
k+1 is not prime because (p-1)! + p! + 1 == 0 mod p and (p-1)! + p! + 1 > p where p is prime. - Seiichi Manyama, Mar 22 2018
|
|
REFERENCES
|
H. Dubner, Factorial and primorial primes, J. Rec. Math., 19 (No.3, 1987)
|
|
LINKS
|
|
|
EXAMPLE
|
3 is in the sequence because 3!+4!+1=31 is prime.
|
|
MATHEMATICA
|
v={}; Do[If[PrimeQ[n!+(n+1)!+1], v=Append[v, n]; Print[v]], {n, 1800}]; v
Select[Range[0, 25000], PrimeQ[#!+(#+1)!+1]&] (* Robert Price, Aug 26 2015 *)
|
|
PROG
|
(PARI) isok(k) = ispseudoprime(k!+(k+1)!+1); \\ Altug Alkan, Mar 22 2018
|
|
CROSSREFS
|
|
|
KEYWORD
|
more,nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|