OFFSET
1,4
FORMULA
a(n) == 1 (mod 18).
EXAMPLE
G.f.: A(x) = x + x^2 + x^3 + 19*x^4 + 163*x^5 + 2269*x^6 + 34093*x^7 +...
Let G(x) = A(A(A(x))):
G(x) = x + 3*x^2 + 9*x^3 + 81*x^4 + 891*x^5 + 11907*x^6 + 184437*x^7 +...
such that G(x) = x + 2*x^2 + x*G(G(G(x))):
G(G(G(x))) = x + 9*x^2 + 81*x^3 + 891*x^4 + 11907*x^5 + 184437*x^6 +...
PROG
(PARI) {a(n)=local(A=x+x^2, B=x+2*x^2); for(i=1, n+1, B=x+2*x^2+x*subst(B, x, subst(B, x, B+x*O(x^n))));
for(j=1, n+1, A=round((2*A+subst(B, x, serreverse(subst(A, x, A+x*O(x^n)))))/3));; polcoeff(A, n)}
for(n=1, 31, print1(a(n), ", "))
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul D. Hanna, Aug 03 2012
STATUS
approved