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.
%I A067433 #18 Dec 23 2021 10:04:12 %S A067433 1,3,1,1,6,2,3,1,6,2,3,1,2,3,1,9,3,1,9,3,1,3,1,12,4,6,2,3,1,12,4,6,2, %T A067433 3,1,4,6,2,3,1,15,5,6,2,3,1,15,5,6,2,3,1,5,6,2,3,1,18,6,2,3,1,18,6,2, %U A067433 3,1,6,2,3,1,21,7,9,3,1,21,7,9,3,1,7,9,3 %N A067433 Triangle in which row n gives trajectory of n under the map k -> k/3 if k is divisible by 3, otherwise k -> next multiple of 3, stopping when reaching 1 (the initial term n is not included). %C A067433 These numbers converge to various last 3-digit endings and only to 2 last 2-digit numbers: 2,1 or 3,1. m=3. p=1 below. If m=2, p=1 you get the x+1 conjecture. If m=2, p=3 you get the 3x+1 conjecture. See Link for numbers with a large number of digits. Other conjectures are possible by trial-and-error input of m and n. It is interesting to note that for many m and p=m+1 the program converges to 1. However, for m prime and p=m+1 the program always converges to m^2, m, 1. Also for m+1 prime the program converges to m^2, m, 1 most of the time. An exception is m=6. The sequence converges but to what I call an uninteresting ending. %H A067433 Cino Hilliard, <a href="http://groups.msn.com/BC2LCC/page.msnw?fc_p=%2Fkx%2Bp%20problems&fc_a=0">The x+1 conjecture</a> [Dead link] %e A067433 4 -> 6 -> 2 -> 3 -> 1, so row 4 is 6,2,3,1. Row 5 is the same. %t A067433 nxt[n_]:=If[Divisible[n,3],n/3,3(Floor[n/3]+1)]; Join[{1},Flatten[ Table[ Rest[ NestWhileList[nxt,i,#!=1&]],{i,30}]]] (* _Harvey P. Dale_, Sep 16 2012 *) %o A067433 (PARI) multxp2(n,m,p) = { print1(1" "); for(j=1,n, x=j; c=0; while(x>1, r = x%m; if(r==0,x=x/m,x=x*p+m-r); print1(x" "); ); ) } %Y A067433 Cf. A080816. %K A067433 easy,tabf,nonn %O A067433 1,2 %A A067433 _Cino Hilliard_, Mar 29 2003 %E A067433 Corrected by _Harvey P. Dale_, Sep 16 2012