login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A087147 Numbers k such that k!+(k+1)!+1 is prime. 2
0, 3, 7, 9, 67, 291, 1343, 6984, 12861 (list; graph; refs; listen; history; text; internal format)
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
a(10) > 25000. - Robert Price, Aug 26 2015
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
Eric Weisstein's World of Mathematics, Wilson's Theorem
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
Primes in A118913. [From Dmitry Kamenetsky, Oct 21 2008]
Sequence in context: A088801 A003033 A193945 * A363572 A337613 A152607
KEYWORD
more,nonn
AUTHOR
Farideh Firoozbakht, Aug 19 2003
EXTENSIONS
a(8)-a(9) from Robert Price, Aug 26 2015
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 27 23:17 EDT 2024. Contains 374651 sequences. (Running on oeis4.)