login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A225089 a(n) = floor(2^A006666(m)/3^A006667(m)) - m, where m = 2n + 1. 3
0, 0, 0, 0, 0, 1, 1, 0, 2, 0, 1, 2, 1, 2, 1, 0, 1, 4, 3, 1, 0, 3, 2, 4, 4, 2, 5, 5, 4, 3, 5, 0, 6, 3, 2, 8, 7, 6, 8, 2, 7, 0, 10, 6, 5, 4, 7, 8, 10, 9, 8, 4, 3, 10, 9, 11, 14, 9, 12, 7, 6, 10, 9, 0, 14, 13, 12, 7, 6, 5, 10, 17, 13, 15, 0, 13, 12, 16, 15, 5, 8 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,9

COMMENTS

A006666 and A006667 are the number of halving and tripling steps to reach 1 in 3x+1 problem.

Properties of this sequence:

a(m) = 0 for m =  A211981(m).

LINKS

Michel Lagneau, Table of n, a(n) for n = 1..10000

EXAMPLE

a(9) = 3 because floor(2^A006666(19)/3^A006667(19)) - 19 = floor(2^14 /3^6) - 19 = floor(22.474622) - 19 = 22 - 19 = 3.

MAPLE

A:= proc(n) if type(n, 'even') then n/2; else 3*n+1 ; end if; end proc:

B:= proc(n) a := 0 ; x := n ; while x > 1 do x := A(x) ; a := a+1 ; end do; a ; end proc:

C:= proc(n) a := 0 ; x := n ; while x > 1 do if type(x, 'even') then x := x/2 ; else x := 3*x+1 ; a := a+1 ; end if; end do; a ; end proc:

D:= proc(n) C(n) ; end proc:

A006666:= proc(n) B(n)- C(n) ; end:

A006667:= proc(n) C(n)- D(n) ; end:

G:= proc(n) floor(2^A006666 (n)/3^A006667 (n)) ; end:

for i from 1 to 100 do: printf(`%d, `, G(i)-i):od:

MATHEMATICA

Collatz[n_] := NestWhileList[If[EvenQ[#], #/2, 3 # + 1] &, n, # > 1 &]; nn = 100; t = {}; n = 0; While[Length[t] < nn, n++; c = Collatz[n]; ev = Length[Select[c, EvenQ]]; od = Length[c] - ev - 1; AppendTo[t, Floor[2^ev/3^od]-n]]; t

CROSSREFS

Cf. A006666, A006667, A211981, A075680.

Sequence in context: A059835 A274659 A274661 * A262436 A093998 A247918

Adjacent sequences:  A225086 A225087 A225088 * A225090 A225091 A225092

KEYWORD

nonn

AUTHOR

Michel Lagneau, Apr 27 2013

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 24 22:41 EDT 2019. Contains 326314 sequences. (Running on oeis4.)