cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A135941 a(n) = floor(n/S2(n)), where S2(n) is the binary weight of n.

Original entry on oeis.org

1, 2, 1, 4, 2, 3, 2, 8, 4, 5, 3, 6, 4, 4, 3, 16, 8, 9, 6, 10, 7, 7, 5, 12, 8, 8, 6, 9, 7, 7, 6, 32, 16, 17, 11, 18, 12, 12, 9, 20, 13, 14, 10, 14, 11, 11, 9, 24, 16, 16, 12, 17, 13, 13, 11, 18, 14, 14, 11, 15, 12, 12, 10, 64, 32, 33, 22, 34, 23, 23, 17, 36, 24, 24, 18, 25, 19, 19, 15
Offset: 1

Views

Author

Ctibor O. Zizka, Mar 02 2008

Keywords

Crossrefs

Cf. A000120.

Programs

  • Mathematica
    Table[Floor[n/First@ DigitCount[#, 2] &@ n], {n, 79}] (* Michael De Vlieger, Nov 30 2015 *)
  • PARI
    a(n) = n\hammingweight(n); \\ Michel Marcus, Nov 30 2015

Formula

a(n) = floor(n/A000120(n)).

Extensions

a(0) removed by Michel Marcus, Nov 30 2015