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!)
A037036 Least k such that 2^n+1-k is a prime. 0
0, 0, 0, 2, 0, 2, 4, 2, 0, 4, 4, 10, 4, 2, 4, 20, 0, 2, 6, 2, 4, 10, 4, 16, 4, 40, 6, 40, 58, 4, 36, 2, 6, 10, 42, 32, 6, 26, 46, 8, 88, 22, 12, 58, 18, 56, 22, 116, 60, 82, 28, 130, 48, 112, 34, 56, 6, 14, 28, 56, 94, 2, 58, 26, 60, 50, 6, 20, 24, 20, 36, 232, 94, 70, 36, 98, 16, 34 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
LINKS
EXAMPLE
a(5)=2 because 2^5+1-2=31 that is a prime.
PROG
(PARI) a(n) = my(k = 0); while (! isprime(2^n+1-k), k++); k; \\ Michel Marcus, Sep 28 2013
CROSSREFS
Cf. A016014.
Sequence in context: A338227 A350861 A144182 * A055947 A015910 A182256
KEYWORD
nonn
AUTHOR
EXTENSIONS
More terms from Erich Friedman
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 24 04:14 EDT 2024. Contains 371918 sequences. (Running on oeis4.)