OFFSET
1,3
LINKS
Andrew Howroyd, Table of n, a(n) for n = 1..500
FORMULA
MAPLE
b:= proc(n, k) option remember; `if`(n<2, k*n, (add(add(b(d, k)*
d, d=numtheory[divisors](j))*b(n-j, k), j=1..n-1))/(n-1))
end:
a:= n-> b(n, 3)-3*b(n, 2)+3*b(n, 1):
seq(a(n), n=1..23); # Alois P. Heinz, Dec 11 2020
MATHEMATICA
b[n_, k_] := b[n, k] = If[n < 2, k*n, (Sum[Sum[b[d, k]*d, {d, Divisors[j]}]*b[n - j, k], {j, 1, n - 1}])/(n - 1)];
a[n_] := b[n, 3] - 3 b[n, 2] + 3 b[n, 1];
Array[a, 23] (* Jean-François Alcover, Jan 04 2021, after Alois P. Heinz *)
PROG
(PARI) \\ See A141610 for U(N, m)
seq(n)={U(n, 3) - 3*U(n, 2) + 3*U(n, 1)}
CROSSREFS
KEYWORD
nonn
AUTHOR
Andrew Howroyd, Dec 11 2020
STATUS
approved