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.

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

This page as a plain text file.
%I A374730 #68 Jul 23 2024 15:25:35
%S A374730 0,0,2,3,12,15,18,21,48,54,60,66,72,78,84,90,160,170,180,190,200,210,
%T A374730 220,230,240,250,260,270,280,290,300,310,480,495,510,525,540,555,570,
%U A374730 585,600,615,630,645,660,675,690,705,720,735,750,765,780,795,810,825,840
%N A374730 a(n) = n * binomial(floor(log_2(n)) + 1, 2).
%F A374730 a(A000079(n)) = A001815(n+1).
%F A374730 a(n) = n * A000217(A000523(n)).
%p A374730 a := n -> n * binomial(ilog2(n) + 1, 2):
%p A374730 seq(a(n), n = 0..56);  # _Peter Luschny_, Jul 19 2024
%t A374730 Table[n * Binomial[BitLength[n], 2], {n, 0, 60}] (* _Amiram Eldar_, Jul 23 2024 *)
%o A374730 (Python)
%o A374730 def a(n):
%o A374730     q = n.bit_length() - 1
%o A374730     return n * q * (q + 1) >> 1
%o A374730 print([a(n) for n in range(61)])
%o A374730 (PARI) a(n) = n * binomial(logint(n, 2) + 1, 2); \\ _Michel Marcus_, Jul 23 2024
%Y A374730 Cf. A000079, A000217, A000523, A001815.
%K A374730 nonn
%O A374730 0,3
%A A374730 _DarĂ­o Clavijo_, Jul 17 2024