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.

A110201 a(n) = sum of squares of numbers < 2^n having exactly [n/2]+1 ones in their binary expansion.

Original entry on oeis.org

1, 9, 70, 535, 3906, 29274, 215900, 1628175, 12197570, 92830430, 704127060, 5400199350, 41331491124, 318871044756, 2456608834680, 19039140186495, 147401590706370, 1146463189301430, 8909683732878500, 69495629981713650
Offset: 1

Views

Author

Paul D. Hanna, Jul 16 2005

Keywords

Comments

a(n) equals the largest term in row n of triangle A110200.

Crossrefs

Cf. A110200 (triangle), A002450 (column 1), A110202 (column 2), A110203 (column 3), A110204 (column 4).

Programs

  • Mathematica
    Join[{1},Table[Total[Select[Range[2^n],DigitCount[#,2,1]==Floor[ n/2]+ 1&]^2],{n,2,20}]] (* Harvey P. Dale, Aug 22 2021 *)
  • PARI
    a(n)=(4^n-1)/3*binomial(n-2,n\2)+(2^n-1)^2*binomial(n-2,n\2-1)

Formula

a(n) = (4^n-1)/3*C(n-2, n\2) + (2^n-1)^2*C(n-2, n\2-1).