A216059 Smallest number not in Collatz trajectory starting at n.
2, 3, 6, 3, 3, 7, 3, 3, 3, 3, 3, 7, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 7, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 7, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3
Offset: 1
Keywords
Links
- Reinhard Zumkeller, Table of n, a(n) for n = 1..1000
- Eric Weisstein's World of Mathematics, Collatz Problem
- Wikipedia, Collatz conjecture
- Index entries for sequences related to 3x+1 (or Collatz) problem
Programs
-
Haskell
import Data.List ((\\)) a216059 n = head $ enumFromTo 1 (maximum ts + 1) \\ ts where ts = a070165_row n
-
Mathematica
scoll[n_]:=Sort[NestWhileList[If[EvenQ[#],#/2,3#+1] &,n,#>1 &]]; Join[{2,3},Table[i=1; While[scoll[n][[i]]==i,i++]; i,{n,3,86}]] (* Jayanta Basu, May 27 2013 *)
Comments