The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A355598 a(1) = 3. For n > 1, a(n) = smallest prime q such that q^(a(n-1)-1) == 1 (mod a(n-1)^2). 5

%I #6 Jul 23 2023 18:59:39

%S 3,17,131,659,503,9833,49603,327317,13900147,144229223,5872276013

%N a(1) = 3. For n > 1, a(n) = smallest prime q such that q^(a(n-1)-1) == 1 (mod a(n-1)^2).

%C Is this overall an increasing sequence or does it enter a cycle?

%C The sequence decreases for the first time at n = 5.

%t sp[n_]:=Module[{p=2},While[PowerMod[p,n-1,n^2]!=1,p=NextPrime[p]];p]; NestList[sp,3,8] (* _Harvey P. Dale_, Jul 23 2023 *)

%o (PARI) seq(start, terms) = my(x=start, i=1); print1(start, ", "); while(1, forprime(q=1, , if(Mod(q, x^2)^(x-1)==1, print1(q, ", "); x=q; i++; if(i >= terms, break({2}), break))))

%o seq(3, 20) \\ Print initial 20 terms of sequence

%Y Row n = 2 of A249162.

%Y Cf. A355597, A355599, A355600, A355601, A355602.

%K nonn,hard,more

%O 1,1

%A _Felix Fröhlich_, Jul 09 2022

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 June 3 10:30 EDT 2024. Contains 373060 sequences. (Running on oeis4.)