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!)
A096303 Number of iterations of n -> n + (number of 1's in binary representation of n) needed for the trajectory of n to join the trajectory of A010062. 4
0, 0, 0, 1, 0, 4, 0, 3, 2, 0, 1, 0, 2, 0, 1, 1, 0, 2, 0, 1, 6, 0, 2, 5, 0, 4, 1, 0, 3, 2, 0, 3, 2, 1, 1, 0, 5, 0, 2, 4, 0, 3, 1, 0, 2, 7, 0, 7, 1, 6, 1, 0, 5, 3, 0, 2, 4, 2, 1, 0, 3, 1, 6, 0, 0, 2, 0, 1, 5, 0, 2, 4, 0, 3, 1, 0, 2, 5, 0, 5, 1, 4, 1, 0, 3, 10, 0, 2, 2, 9, 1, 0, 1, 8, 1, 0, 8, 0, 7, 7, 0, 6, 6, 6, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,6

COMMENTS

Conjecture: For any positive integer starting value n, iterations of n -> n + (number of 1's in binary representation of n) will eventually join A010062.

LINKS

Rémy Sigrist, Table of n, a(n) for n = 1..10000

Index entries for Colombian or self numbers and related sequences

EXAMPLE

a(6)=4 because the trajectory for 1 (sequence A010062) starts

1->2->3->5->7->10->12->14->17->19->22->25...

and the trajectory for 6 starts

6->8->9->11->14->17->19->22->25->28->31->36...

so the sequence beginning with 6 joins A010062 after 4 steps.

PROG

(PARI) a(n) = { my (o=1); for (k=0, oo, while (o<n, o=o+hammingweight(o)); if (o==n, return (k), n=n+hammingweight(n))) } \\ Rémy Sigrist, Apr 05 2020

CROSSREFS

Cf. A010062.

For records see A229743, A229744.

Sequence in context: A086165 A301408 A227290 * A262695 A021252 A195775

Adjacent sequences:  A096300 A096301 A096302 * A096304 A096305 A096306

KEYWORD

base,nonn

AUTHOR

Jason Earls, Jun 25 2004

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 July 14 00:22 EDT 2020. Contains 335716 sequences. (Running on oeis4.)