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.

A221474 Number of families of numbers requiring n iterations of the Collatz (3x+1) function to reach 1.

This page as a plain text file.
%I A221474 #5 Feb 13 2013 19:14:44
%S A221474 1,0,0,0,0,1,0,2,0,2,0,2,2,3,3,4,4,5,4,6,5,6,5,7,6,7,7,8,7,9,8,9,9,10,
%T A221474 10,11,10,11,11,12,11,13,12,13,13,14,14,15,14,16,15,16,16,17,17,18,17,
%U A221474 18,18,19,19,20,19,21,20,22,21,23,22,24
%N A221474 Number of families of numbers requiring n iterations of the Collatz (3x+1) function to reach 1.
%C A221474 Looking at the graph of A221473, it is apparent that the numbers requiring n iterations clump into families.
%t A221474 nn = 41; s = {1}; t = Join[s, Table[s = Union[2 s, (Select[s, Mod[#, 3] == 1 && OddQ[(# - 1)/3] && (# - 1)/3 > 1 &] - 1)/3]; s, {n, nn-1}]]; t2 = Join[{{t[[1]]}}, Table[Select[t[[i]], OddQ], {i, 2, nn}]]; Table[t3 = t2[[n]]; If[Length[t3] <= 1, Length[t3], s = Round[Rest[t3]/Most[t3]]; Length[Select[s, # > 1 &]] + 1], {n, nn}]
%K A221474 nonn
%O A221474 0,8
%A A221474 _T. D. Noe_, Feb 13 2013