login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A128333 a(0) = 0; for n > 0, a(n) = a(n-1)/2 if that number is an integer and not already in the sequence, otherwise a(n) = 3*a(n-1) + 1. 3
0, 1, 4, 2, 7, 22, 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 25, 76, 38, 19, 58, 29, 88, 44, 133, 400, 200, 100, 50, 151, 454, 227, 682, 341, 1024, 512, 256, 128, 64, 32, 97, 292, 146, 73, 220, 110, 55, 166, 83, 250, 125, 376, 188, 94, 47, 142, 71, 214, 107, 322, 161 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,3

COMMENTS

Other than a(0) = 0, the sequence misses all multiples of 3. Does it eventually hit all positive non-multiples of 3?

LINKS

Nick Hobson, Table of n, a(n) for n = 0..10000

Nick Hobson, Python program

Index entries for sequences related to 3x+1 (or Collatz) problem

EXAMPLE

Consider n = 3. We have a(3) = 2 and try to divide by 2. The result, 1, is certainly an integer, but we cannot use it because 1 is already in the sequence. So we must multiply by 3 and add 1 instead, getting a(4) = 3*2 + 1 = 7.

CROSSREFS

Cf. A126038, A005132.

Sequence in context: A261690 A211941 A050105 * A201414 A199814 A195347

Adjacent sequences:  A128330 A128331 A128332 * A128334 A128335 A128336

KEYWORD

easy,nonn

AUTHOR

Nick Hobson (nickh(AT)qbyte.org), Feb 27 2007

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 September 28 10:51 EDT 2020. Contains 337393 sequences. (Running on oeis4.)