The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A073443 Numbers n such that n! - n - 1 is prime. 4
3, 4, 10, 12, 346 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
Clearly n <> 2 (mod 3). For n>3, n!-n, n!-n+1, ..., n!-3, n!-2 is a sequence of n-1 consecutive composite numbers. Additional terms are greater than 2000.
a(5) > 7500. - Michael S. Branicky, Mar 04 2021
LINKS
MATHEMATICA
Select[Range[3, 346], PrimeQ[#! - # - 1] &] (* Arkadiusz Wesolowski, Jan 04 2012 *)
PROG
(PARI) for(n=3, 2000, if(isprime(n!-n-1), print1(n, ", ")))
(Python)
from math import factorial
from sympy import isprime
def ok(n): return isprime(factorial(n) - n - 1)
print([m for m in range(3, 500) if ok(m)]) # Michael S. Branicky, Mar 04 2021
CROSSREFS
Cf. A073444 (corresponding primes), A002982 (n!-1 is prime), A073308 (n!+n+1 is prime).
Sequence in context: A092434 A239632 A031367 * A257494 A302347 A092119
KEYWORD
nonn,hard,more
AUTHOR
Rick L. Shepherd, Jul 31 2002
EXTENSIONS
Offset corrected by Arkadiusz Wesolowski, Jan 04 2012
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 June 5 01:34 EDT 2024. Contains 373102 sequences. (Running on oeis4.)