OFFSET
0,4
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..500
FORMULA
a(n) = Sum_{k=0..n} k * A281871(n,k).
EXAMPLE
a(4) = 7: {1}, {4}, {1,3}, {2,3,4}.
a(5) = 12: {1}, {4}, {1,3}, {4,5}, {1,3,5}, {2,3,4}.
MAPLE
b:= proc(n, s) option remember; `if`(n=0, `if`(issqr(s),
[1, 0], 0), b(n-1, s)+(p-> p+[0, p[1]])(b(n-1, s+n)))
end:
a:= n-> b(n, 0)[2]:
seq(a(n), n=0..35);
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Nov 01 2024
STATUS
approved