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!)
A265098 Integers n such that A138523(n) is 1 or a prime. 0
1, 2, 3, 4, 5, 28, 32 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Inspired by the following triangle for the initial terms:
1! = 1.
1! + 3! = 7.
1! + 3! + 5! = 127.
1! + 3! + 5! + 7! = 5167.
1! + 3! + 5! + 7! + 9! = 368047.
This sequence is finite since 107 divides A138523(n) for all n >= 53. - Amiram Eldar, Apr 20 2017
LINKS
EXAMPLE
a(4) = 4 because 1! + 3! + 5! + 7! = 5167 is prime.
MATHEMATICA
Select[Range@ 1000, Or[# == 1, PrimeQ@ #] &@ Sum[(2 k - 1)!, {k, #}] &] (* Michael De Vlieger, Dec 01 2015 *)
PROG
(PARI) lista(nn) = { print1(1, ", "); s = 0; for(k=1, nn, s += (2*k-1)!; if(ispseudoprime(s), print1(k, ", ")); ); }
CROSSREFS
Sequence in context: A084853 A115337 A114333 * A076209 A037399 A220891
KEYWORD
nonn,fini,full
AUTHOR
Altug Alkan, Dec 01 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 April 23 18:16 EDT 2024. Contains 371916 sequences. (Running on oeis4.)