a(n) = minimal number of steps to get from n to 1, where a step is x -> 3x+1 if x is odd, or x -> either x/2 or 3x+1 if x is even; or -1 if 1 is never reached.

A127885

a(n) = minimal number of steps to get from n to 1, where a step is x -> 3x+1 if x is odd, or x -> either x/2 or 3x+1 if x is even; or -1 if 1 is never reached.

Terms

    a(0) =0a(1) =1a(2) =7a(3) =2a(4) =5a(5) =8a(6) =16a(7) =3a(8) =11a(9) =6a(10) =14a(11) =9a(12) =9a(13) =17a(14) =17a(15) =4a(16) =12a(17) =12a(18) =20a(19) =7a(20) =7a(21) =15a(22) =15a(23) =10a(24) =23a(25) =10a(26) =23a(27) =10a(28) =18a(29) =18

External references