cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A346591 Composite numbers k such that A006577(k) sets a new record.

This page as a plain text file.
%I A346591 #12 Jul 28 2021 12:56:52
%S A346591 4,6,9,18,25,27,54,108,129,171,231,327,649,703,871,1161,2223,2463,
%T A346591 2919,3711,6171,10971,13255,17647,23529,26623,34239,35655,52527,77031,
%U A346591 106239,142587,156159,216367,230631,410011,511935,626331,837799,1117065,1501353,1723519
%N A346591 Composite numbers k such that A006577(k) sets a new record.
%H A346591 <a href="/index/3#3x1">Index entries for sequences related to 3x+1 (or Collatz) problem</a>
%t A346591 s[n_]:=s[n]=(i=0;r=n;While[r!=1,i++;If[EvenQ@r,r=r/2,r=r*3+1]];i);
%t A346591 lst={};max=1;Do[If[!PrimeQ@k,t=s[k];If[t>max,AppendTo[lst,k];max=t]],{k,10^4}];lst (* _Giorgos Kalogeropoulos_, Jul 28 2021 *)
%o A346591 (PARI) a6577(n0)={my(n=n0,k=0);while(n>1,k++;n=if(n%2,3*n+1,n/2));k};
%o A346591 a346591(limit)={msteps=0;forcomposite(c=4,limit,my(m=a6577(c));if(m>msteps,print1(c,", ");msteps=m))};
%o A346591 a346591(2000000)
%Y A346591 Cf. A006577, A346592, A346593.
%Y A346591 A006877 is the union of A244638 and this sequence.
%K A346591 nonn
%O A346591 1,1
%A A346591 _Hugo Pfoertner_, Jul 28 2021