login
A353009
a(n) = Sum_{k=0..floor(n/2)} (n-2*k)^(n-2*k).
2
1, 1, 5, 28, 261, 3153, 46917, 826696, 16824133, 388247185, 10016824133, 285699917796, 8926117272389, 303160806510049, 11120932942830405, 438197051187369424, 18457865006652382021, 827678458937524133601, 39364865940303189957445
OFFSET
0,3
LINKS
FORMULA
G.f.: ( Sum_{k>=0} (k * x)^k )/(1 - x^2).
a(2*n-1) = A061787(n), a(2*n) = A061788(n) + 1. - Seiichi Manyama, Apr 17 2022
MATHEMATICA
a[n_] := Sum[If[2*k == n, 1, (n - 2*k)^(n - 2*k)], {k, 0, Floor[n/2]}]; Array[a, 20, 0] (* Amiram Eldar, Apr 16 2022 *)
PROG
(PARI) a(n) = sum(k=0, n\2, (n-2*k)^(n-2*k));
(PARI) my(N=20, x='x+O('x^N)); Vec(sum(k=0, N, (k*x)^k)/(1-x^2))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Seiichi Manyama, Apr 16 2022
STATUS
approved