A092892 Smallest starting value in a Collatz '3x+1' sequence such that the sequence contains exactly n halving steps.
1, 2, 4, 8, 5, 3, 6, 12, 24, 17, 11, 7, 14, 9, 18, 36, 25, 49, 33, 65, 43, 86, 57, 39, 78, 153, 105, 203, 135, 270, 185, 123, 246, 169, 329, 219, 159, 295, 569, 379, 283, 505, 377, 251, 167, 111, 222, 444, 297, 593, 395, 263, 175, 350, 233, 155, 103, 206, 137, 91, 182
Offset: 0
Examples
a(5)=3 because the Collatz sequence 3,10,5,16,8,4,2,1 is the first sequence containing 5 halving steps.
Links
- T. D. Noe, Table of n, a(n) for n=0..500
- Eric Weisstein's World of Mathematics, Collatz Problem.
- Index entries for sequences related to 3x+1 (or Collatz) problem
Programs
-
Haskell
import Data.List (elemIndex); import Data.Maybe (fromJust) a092892 = (+ 1) . fromJust . (`elemIndex` a006666_list) -- Reinhard Zumkeller, Mar 14 2014
-
Mathematica
coll[n_]:= NestWhileList[If[EvenQ[#], #/2, 3#+1] &, n, #>1 &]; Table[i = 1; While[Count[coll[i], ?EvenQ] != n, i++]; i, {n, 0, 60}] (* _Jayanta Basu, Jun 05 2013 *)
Comments