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.

A253676 Irregular triangle T read by rows in which row n is the result of iterating the function S defined in A257480 and terminating at the first occurrence of 1, assuming the 3x+1 (or Collatz) conjecture.

This page as a plain text file.
%I A253676 #10 Nov 05 2015 14:29:47
%S A253676 1,2,1,3,5,4,2,1,4,2,1,5,4,2,1,6,1,7,8,5,4,2,1,8,5,4,2,1,9,7,8,5,4,2,
%T A253676 1,10,5,4,2,1,11,41,31,35,59,149,112,95,107,608,770,145,109,82,16,14,
%U A253676 2,1,12,5,4,2,1,13,10,5,4,2,1,14,2,1,15,17,13,10,5,4,2,1
%N A253676 Irregular triangle T read by rows in which row n is the result of iterating the function S defined in A257480 and terminating at the first occurrence of 1, assuming the 3x+1 (or Collatz) conjecture.
%e A253676 T begins:
%e A253676 .    1
%e A253676 .    2  1
%e A253676 .    3  5  4  2  1
%e A253676 .    4  2  1
%e A253676 .    5  4  2  1
%e A253676 .    6  1
%e A253676 .    7  8  5  4  2   1
%e A253676 .    8  5  4  2  1
%e A253676 .    9  7  8  5  4   2   1
%e A253676 .   10  5  4  2  1
%e A253676 .   11 41 31 35 59 149 112 95 107 608 770 145 109 82 16 14 2 1
%e A253676 .   12  5  4  2  1
%e A253676 .   13 10  5  4  2   1
%e A253676 .   14  2  1
%e A253676 .   15 17 13 10  5   4   2  1
%t A253676 v[n_] := IntegerExponent[n, 2]; f[x_] := (3*x + 1)/2^v[3*x + 1]; s[n_] := (3 + (3/2)^v[1 + f[4*n - 3]]*(1 + f[4*n - 3]))/6; t[n_] := NestWhileList[s[#] &, n, # > 1 &]; Flatten[Table[t[n], {n, 15}]] (* Replace Flatten with Grid to get the irregular triangle. *)
%Y A253676 Cf. A257480 and cross references therein.
%K A253676 nonn,tabf
%O A253676 1,2
%A A253676 _L. Edson Jeffery_, May 02 2015