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!)
A261730 Values of n such that prime(n)! - n! + 1 is a prime number. 0
1, 2, 8, 85, 308 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Inspired by A261457.

Initial primes of the form prime(n)! - n! + 1 are 2, 5, 121645100408791681.

LINKS

Table of n, a(n) for n=1..5.

EXAMPLE

For n=1, prime(1)!-1!+1 = 2 is a prime number.

MATHEMATICA

Select[Range[400], PrimeQ[Prime[#]! - #! + 1] &] (* Vincenzo Librandi, Aug 31 2015 *)

PROG

(PARI) for(n=1, 1e3, if(isprime(prime(n)!-n!+1), print1(n", ")))

(MAGMA) [n: n in [1..80] | IsPrime(Factorial(NthPrime(n))-Factorial(n)+1)]; // Vincenzo Librandi, Aug 31 2015

CROSSREFS

Cf. A261457.

Sequence in context: A134089 A136647 A306001 * A052456 A276991 A000532

Adjacent sequences:  A261727 A261728 A261729 * A261731 A261732 A261733

KEYWORD

nonn,more

AUTHOR

Altug Alkan, Aug 30 2015

EXTENSIONS

a(4)-a(5) from Giovanni Resta, Aug 30 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 August 12 23:52 EDT 2022. Contains 356077 sequences. (Running on oeis4.)