|
|
A335063
|
|
a(n) = Sum_{k=0..n} (binomial(n,k) mod 2) * k.
|
|
2
|
|
|
0, 1, 2, 6, 4, 10, 12, 28, 8, 18, 20, 44, 24, 52, 56, 120, 16, 34, 36, 76, 40, 84, 88, 184, 48, 100, 104, 216, 112, 232, 240, 496, 32, 66, 68, 140, 72, 148, 152, 312, 80, 164, 168, 344, 176, 360, 368, 752, 96, 196, 200, 408, 208, 424, 432, 880, 224, 456, 464, 944, 480
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
Modulo 2 binomial transform of nonnegative integers.
|
|
LINKS
|
|
|
FORMULA
|
G.f.: (x/2) * (d/dx) Product_{k>=0} (1 + 2 * x^(2^k)).
|
|
MAPLE
|
g:= proc(n, k) local L, M, t, j;
L:= convert(k, base, 2);
M:= convert(n, base, 2);
1-max(zip(`*`, L, M))
end proc:
f:= n -> add(k*g(n-k, k), k=0..n):
|
|
MATHEMATICA
|
Table[Sum[Mod[Binomial[n, k], 2] k, {k, 0, n}], {n, 0, 60}]
(* or *)
nmax = 60; CoefficientList[Series[(x/2) D[Product[(1 + 2 x^(2^k)), {k, 0, Log[2, nmax]}], x], {x, 0, nmax}], x]
|
|
PROG
|
(PARI) a(n) = n*2^(hammingweight(n)-1); \\ Michel Marcus, May 22 2020
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|