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!)
A084435 a(1) = 2, then smallest prime of the form 2^k*a(n-1) + 1. 3

%I #21 Jan 13 2019 19:14:54

%S 2,3,7,29,59,1889,3779,7559,4058207223809,32465657790473,

%T 4462046030502692971872257,9582170887127842377060195852353537

%N a(1) = 2, then smallest prime of the form 2^k*a(n-1) + 1.

%C This sequence also is generated when the initial term is 1. It is unclear if the sequence is finite or infinite. - _Bob Selcoe_, Oct 09 2015

%D Donald E. Knuth, The Art of Computer Programming, Vol. 2, Seminumerical Algorithms, problem 39, page 76.

%H Robert G. Wilson v, <a href="/A084435/b084435.txt">Table of n, a(n) for n = 1..15</a> (shortened by _N. J. A. Sloane_, Jan 13 2019)

%e a(3)=7 because 3*2+1=7 is prime;

%e a(4)=29 because 7*2+1=15 is not prime, 7*4+1=29 is prime.

%t f[s_List] := Block[{k = 0, p = s[[-1]]}, While[q = 2^k*p + 1; !PrimeQ[ q], k++]; Append[s, q]]; s = {2}; Nest[f, s, 16] (* _Robert G. Wilson v_, Mar 11 2015 *)

%o (PARI) lista(nn) = {a = 2; print1(a, ", "); for (n=1, nn, k=0; while (!isprime(2^k*a+1), k++); a = 2^k*a+1; print1(a, ", "););} \\ _Michel Marcus_, Mar 18 2015

%Y Cf. A113767, A192580.

%K nonn

%O 1,1

%A _Amarnath Murthy_, Jun 03 2003

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 04:23 EDT 2024. Contains 371264 sequences. (Running on oeis4.)