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 A062060 #35 Feb 16 2025 08:32:44 %S A062060 43,86,87,89,172,173,174,177,178,179,344,346,348,349,354,355,356,357, %T A062060 358,385,423,688,692,693,696,698,705,708,709,710,712,714,716,717,729, %U A062060 761,769,770,771,777,846,847,1376,1384,1386,1392,1393,1396,1397,1410,1411,1415 %N A062060 Numbers with 10 odd integers in their Collatz (or 3x+1) trajectory. %C A062060 The Collatz (or 3x+1) function is f(x) = x/2 if x is even, 3x+1 if x is odd. %C A062060 The Collatz trajectory of n is obtained by applying f repeatedly to n until 1 is reached. %C A062060 A078719(a(n)) = 10; A006667(a(n)) = 9. %D A062060 J. Shallit and D. Wilson, The "3x+1" Problem and Finite Automata, Bulletin of the EATCS #46 (1992) pp. 182-185. %H A062060 Reinhard Zumkeller, <a href="/A062060/b062060.txt">Table of n, a(n) for n = 1..10000</a> %H A062060 J. Shallit and D. Wilson, <a href="http://www.cs.uwaterloo.ca/~shallit/Papers/wilson.ps">The "3x+1" Problem and Finite Automata</a>, Bulletin of the EATCS #46 (1992) pp. 182-185. %H A062060 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/CollatzProblem.html">Collatz Problem</a> %H A062060 Wikipedia, <a href="http://en.wikipedia.org/wiki/Collatz_conjecture">Collatz conjecture</a> %H A062060 <a href="/index/3#3x1">Index entries for sequences related to 3x+1 (or Collatz) problem</a> %H A062060 <a href="/index/Ar#2-automatic">Index entries for 2-automatic sequences</a>. %e A062060 The Collatz trajectory of 43 is (43, 130, 65, 196, 98, 49, 148, 74, 37, 112, 56, 28, 14, 7, 22, 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1), which contains 10 odd integers. %t A062060 Collatz[n_] := NestWhileList[If[EvenQ[#], #/2, 3 # + 1] &, n, # > 1 &]; countOdd[lst_] := Length[Select[lst, OddQ]]; Select[Range[1000], countOdd[Collatz[#]] == 10 &] (* _T. D. Noe_, Dec 03 2012 *) %o A062060 (Haskell) %o A062060 import Data.List (elemIndices) %o A062060 a062060 n = a062060_list !! (n-1) %o A062060 a062060_list = map (+ 1) $ elemIndices 10 a078719_list %o A062060 -- _Reinhard Zumkeller_, Oct 08 2011 %o A062060 (Python) %o A062060 def a(n): %o A062060 l=[n] %o A062060 while True: %o A062060 if n%2==0: n//=2 %o A062060 else: n = 3*n + 1 %o A062060 if n not in l: %o A062060 l.append(n) %o A062060 if n<2: break %o A062060 else: break %o A062060 return len([1 for i in l if i%2]) %o A062060 print([n for n in range(40, 1501) if a(n)==10]) # _Indranil Ghosh_, Apr 14 2017 %Y A062060 Cf. A062052-A062059. %Y A062060 Column k=10 of A354236. %K A062060 nonn,look %O A062060 1,1 %A A062060 _David W. Wilson_