login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 59th year, we have over 358,000 sequences, and we’ve crossed 10,300 citations (which often say “discovered thanks to the OEIS”).

Other ways to Give
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A255707 Least number k > 0 such that (2*n-1)^k - 2 is prime, or 0 if no such number exists. 5
0, 2, 1, 1, 1, 4, 1, 1, 6, 1, 1, 24, 1, 2, 2, 1, 1, 2, 2, 1, 4, 1, 1, 2, 1, 8, 4, 1, 12, 4, 1, 1, 8, 3, 1, 2, 1, 1, 2, 38, 1, 4, 1, 4, 2, 1, 2, 4, 747, 1, 4, 1, 1, 2, 1, 1, 10, 1, 2, 2, 2, 6, 42, 2, 1, 2, 1, 2, 10, 1, 1, 4, 2, 16, 50, 1, 1, 2, 22, 1, 2, 38 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

LINKS

Michel Marcus, Table of n, a(n) for n = 1..152 (terms 1..143 from Robert Price)

Carlos Rivera, Puzzle 887. p(n)^c-2 is prime, The Prime Puzzles and Problems Connection.

FORMULA

a(A098090(n)) = 1. - Michel Marcus, Mar 03 2015

MATHEMATICA

lst = {0}; For[n = 2, n ≤ 143, n++, For[k = 1, k >= 1, k++, If[PrimeQ[(2*n - 1)^k - 2], AppendTo[lst, k]; Break[]]]]; lst

PROG

(PARI) a(n)=if(n==1, return(0)); k=1; while(k, if(ispseudoprime((2*n-1)^k-2), return(k)); k++)

vector(50, n, a(n)) \\ Derek Orr, Mar 03 2015

CROSSREFS

Cf. A079706, A084712, A084713, A084714, A098090, A138066.

Sequence in context: A299203 A329036 A205552 * A260757 A157114 A156786

Adjacent sequences: A255704 A255705 A255706 * A255708 A255709 A255710

KEYWORD

nonn

AUTHOR

Robert Price, Mar 02 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 December 28 19:31 EST 2022. Contains 359109 sequences. (Running on oeis4.)