OFFSET
0,3
LINKS
Michael De Vlieger, Table of n, a(n) for n = 0..10000 (a(0..999) from Robert Price)
Hsien-Kuei Hwang, Svante Janson, and Tsung-Hsi Tsai, Identities and periodic oscillations of divide-and-conquer recurrences splitting at half, arXiv:2210.10968 [cs.DS], 2022, pp. 6, 30.
MATHEMATICA
Table[(n+1)^2 -Sum[Sum[Mod[Binomial[m, k], 2], {k, 0, m}], {m, 0, n}], {n, 0, 60}]
a[0] = 0; a[1] = 1; a[n_] := a[n] = 2 a[Floor[#]] + a[Ceiling[#]] &[n/2]; Array[(# + 1)^2 - a[# + 1] &, 52, 0] (* Michael De Vlieger, Nov 01 2022 *)
PROG
(PARI) {a(n) = (n+1)^2 - sum(m=0, n, sum(k=0, m, binomial(m, k)%2))};
for(n=0, 60, print1(a(n), ", ")) \\ G. C. Greubel, Apr 11 2019
(Magma) [(n+1)^2 - (&+[ (&+[ Binomial(m, k) mod 2: k in [0..m]]): m in [0..n]]): n in [0..60]]; // G. C. Greubel, Apr 11 2019
(Sage) [(n+1)^2 - sum(sum(binomial(m, k)%2 for k in (0..m)) for m in (0..n)) for n in (0..60)] # G. C. Greubel, Apr 11 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Roger L. Bagula, Dec 07 2009
EXTENSIONS
Edited by G. C. Greubel, Apr 11 2019
Definition corrected by Georg Fischer, Jun 21 2020
STATUS
approved