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 A362940 #12 Jul 09 2025 05:02:24 %S A362940 0,0,3,1,2,3,9,1,10,3,7,3,5,9,8,2,6,10,11,3,3,8,7,3,13,5,61,10,9,8,59, %T A362940 2,14,7,6,10,12,11,18,4,60,3,17,8,8,8,57,3,14,13,12,6,5,61,62,10,18, %U A362940 10,17,8,10,59,58,3,15,14,15,7,7,7,56,10,64,12,7,12 %N A362940 Consider the Collatz trajectory from n to 1, assuming the Collatz conjecture is true. Then a(n) = number of terms in the trajectory that are greater than 1 and congruent to 1 mod 3. If n never reaches 1, set a(n) = -1. %C A362940 The terms in the trajectory counted by a(n) might be called "branch points", since they are exactly the numbers that can be reached in more than one way under the Collatz map. So a(n) is a measure of the "Collatz complexity" of n. The term (with a slightly different definition) was suggested by _Emanuel Landeholm_. %H A362940 Michael De Vlieger, <a href="/A362940/b362940.txt">Table of n, a(n) for n = 1..10000</a> %e A362940 The Collatz trajectory of 7 is 7 22 34 17 52 26 13 40 20 10 5 16 8 4 2 1, which contains 9 terms > 1 and 1 mod 3, so a(7) = 9. %t A362940 Table[Count[NestWhileList[If[EvenQ[#], #/2, 3 # + 1] &, k, # > 1 &], _?(And[# != 1, Mod[#, 3] == 1] &)] , {k, 100}] (* _Michael De Vlieger_, Sep 11 2023 *) %Y A362940 Cf. A006577, A008908. %K A362940 nonn %O A362940 1,3 %A A362940 _N. J. A. Sloane_, Sep 11 2023, suggested by a sequence submitted by _Emanuel Landeholm_ on Sep 10 2023 but later withdrawn, which had a somewhat different definition and contained errors