OFFSET
0,2
COMMENTS
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..440
FORMULA
a(n) = A104988(n+1, 0)/2 for n>=0.
MATHEMATICA
T[n_, k_]:= T[n, k]= If[k<0 || k>n, 0, If[k==n, 1, If[k==n-1, n, k*T[n, k+1] + Sum[T[j, 0]*T[n, j+k+1], {j, 0, n-k-1}]]]];
Table[T[n+3, 3], {n, 0, 30}] (* G. C. Greubel, Jun 07 2021 *)
PROG
(PARI) {a(n) = if(n<0, 0, (matrix(n+4, n+4, m, j, if(m==j, 1, if(m==j+1, -m+1, -polcoeff((1-1/sum(i=0, m, i!*x^i))/x +O(x^m), m-j-1))))^-1)[n+4, 4])}
(Sage)
@CachedFunction
def T(n, k):
if (k<0 or k>n): return 0
elif (k==n): return 1
elif (k==n-1): return n
else: return k*T(n, k+1) + sum( T(j, 0)*T(n, j+k+1) for j in (0..n-k-1) )
[T(n+3, 3) for n in (0..30)] # G. C. Greubel, Jun 07 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul D. Hanna, Apr 10 2005
STATUS
approved