OFFSET
0,4
COMMENTS
Differs from A053499 first at n=27. - Alois P. Heinz, Jan 25 2014
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..200
FORMULA
E.g.f.: exp( Sum_{n>=0} x^(3^n)/3^n ).
EXAMPLE
E.g.f.: A(x) = 1 + x + x^2/2! + 3*x^3/3! + 9*x^4/4! + 21*x^5/5! + 81*x^6/6! +...
where
log(A(x)) = x + x^3/3 + x^9/9 + x^27/27 + x^81/81 +...+ x^3^n/3^n +...
MAPLE
a:= proc(n) option remember; `if`(n<0, 0, `if`(n=0, 1,
add(mul(n-i, i=1..3^j-1)*a(n-3^j), j=0..ilog[3](n))))
end:
seq(a(n), n=0..30); # Alois P. Heinz, Jan 25 2014
PROG
(PARI) {a(n)=n!*polcoeff(exp(sum(k=0, ceil(log(n+1)/log(3)), x^(3^k)/3^k)+x*O(x^n)), n)}
for(n=0, 30, print1(a(n), ", "))
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul D. Hanna, Oct 17 2012
STATUS
approved