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!)
A242041 Number of k >= 1 that make n + k! and n - k! both prime. 1
0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 2, 0, 2, 0, 1, 0, 0, 1, 1, 0, 1, 0, 2, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 2, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 0, 2, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,35
COMMENTS
0 <= a(n) <= min{A125162(n), A175940(n)}.
a(n) < A020639(n). - Robert Israel, Aug 12 2014
LINKS
MAPLE
a:= n -> nops(select(k -> isprime(n+k!) and isprime(n-k!),
[$1 ..min(numtheory:-factorset(n))-1])):
0, seq(a(n), n=2..100); # Robert Israel, Aug 12 2014
PROG
(PARI)
a(n)=c=0; for(k=1, n, if(ispseudoprime(n+k!)&&ispseudoprime(n-k!), c++)); return(c)
vector(100, n, a(n))
CROSSREFS
Sequence in context: A352558 A324735 A219495 * A224937 A035193 A004556
KEYWORD
nonn
AUTHOR
Derek Orr, Aug 12 2014
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 March 29 00:26 EDT 2024. Contains 371264 sequences. (Running on oeis4.)