The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A323355 a(1)=1; for n >= 2, a(n) = Sum_{i=1..A000120(n)} a(z(i)), where z(i) are the positions of 1's in the binary expansion of n, counted from left to right. 2
1, 1, 2, 1, 3, 2, 4, 1, 2, 3, 4, 2, 3, 4, 5, 1, 4, 2, 5, 3, 6, 4, 7, 2, 5, 3, 6, 4, 7, 5, 8, 1, 3, 4, 6, 2, 4, 5, 7, 3, 5, 6, 8, 4, 6, 7, 9, 2, 4, 5, 7, 3, 5, 6, 8, 4, 6, 7, 9, 5, 7, 8, 10, 1, 5, 3, 7, 4, 8, 6, 10, 2, 6, 4, 8, 5, 9, 7, 11, 3, 7, 5, 9, 6, 10, 8, 12, 4, 8, 6, 10, 7, 11, 9, 13, 2, 6, 4 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
LINKS
EXAMPLE
n=13, decimal 13 is 1101 in binary, the 1's are at positions 1,2,4. So a(13) = a(1) + a(2) + a(4).
MATHEMATICA
a[1] = 1; a[n_] := a[n] = Total[a /@ (Position[IntegerDigits[n, 2], 1] // Flatten)]; Array[a, 100] (* Amiram Eldar, Jul 24 2023 *)
PROG
(PARI) lista(nn) = {my(va = vector(nn), vb); va[1] = 1; for (n=2, nn, vb = binary(n); va[n] = sum(k=1, #vb, vb[k]*va[k]); ); va; } \\ Michel Marcus, Jan 12 2019
CROSSREFS
Sequence in context: A363489 A363944 A367581 * A367587 A363942 A363487
KEYWORD
base,nonn
AUTHOR
Ctibor O. Zizka, Jan 12 2019
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 13 17:23 EDT 2024. Contains 372522 sequences. (Running on oeis4.)