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.

Previous Showing 21-21 of 21 results.

A374730 a(n) = n * binomial(floor(log_2(n)) + 1, 2).

Original entry on oeis.org

0, 0, 2, 3, 12, 15, 18, 21, 48, 54, 60, 66, 72, 78, 84, 90, 160, 170, 180, 190, 200, 210, 220, 230, 240, 250, 260, 270, 280, 290, 300, 310, 480, 495, 510, 525, 540, 555, 570, 585, 600, 615, 630, 645, 660, 675, 690, 705, 720, 735, 750, 765, 780, 795, 810, 825, 840
Offset: 0

Views

Author

DarĂ­o Clavijo, Jul 17 2024

Keywords

Crossrefs

Programs

  • Maple
    a := n -> n * binomial(ilog2(n) + 1, 2):
    seq(a(n), n = 0..56);  # Peter Luschny, Jul 19 2024
  • Mathematica
    Table[n * Binomial[BitLength[n], 2], {n, 0, 60}] (* Amiram Eldar, Jul 23 2024 *)
  • PARI
    a(n) = n * binomial(logint(n, 2) + 1, 2); \\ Michel Marcus, Jul 23 2024
  • Python
    def a(n):
        q = n.bit_length() - 1
        return n * q * (q + 1) >> 1
    print([a(n) for n in range(61)])
    

Formula

a(A000079(n)) = A001815(n+1).
a(n) = n * A000217(A000523(n)).
Previous Showing 21-21 of 21 results.