# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/
Search: id:a171378
Showing 1-1 of 1
%I A171378 #30 Nov 02 2022 07:47:26
%S A171378 0,1,4,7,14,21,30,37,52,67,84,99,120,139,160,175,206,237,270,301,338,
%T A171378 373,410,441,486,529,574,613,662,705,750,781,844,907,972,1035,1104,
%U A171378 1171,1240,1303,1380,1455,1532,1603,1684,1759,1836,1899,1992,2083,2176,2263
%N A171378 a(n) = (n+1)^2 - A006046(n+1).
%H A171378 Michael De Vlieger, Table of n, a(n) for n = 0..10000 (a(0..999) from Robert Price)
%H A171378 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.
%t A171378 Table[(n+1)^2 -Sum[Sum[Mod[Binomial[m,k],2], {k,0,m}], {m,0,n}], {n,0, 60}]
%t A171378 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 *)
%o A171378 (PARI) {a(n) = (n+1)^2 - sum(m=0,n, sum(k=0,m, binomial(m,k)%2))};
%o A171378 for(n=0,60, print1(a(n), ", ")) \\ _G. C. Greubel_, Apr 11 2019
%o A171378 (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
%o A171378 (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
%Y A171378 Cf. A006046, A001316.
%K A171378 nonn,easy
%O A171378 0,3
%A A171378 _Roger L. Bagula_, Dec 07 2009
%E A171378 Edited by _G. C. Greubel_, Apr 11 2019
%E A171378 Definition corrected by _Georg Fischer_, Jun 21 2020
# Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE