OFFSET
0,3
LINKS
Paul D. Hanna, Table of n, a(n) for n = 0..1000
FORMULA
G.f.: Sum_{n>=0} x^n * (1 + x^n)^n / (1 - x + x^(n+1))^(n+1).
G.f.: Sum_{n>=0} (-x)^n * (1 - x^n)^n / (1 - x - x^(n+1))^(n+1).
EXAMPLE
G.f.: A(x) = 1 + x + 4*x^2 + 7*x^3 + 12*x^4 + 23*x^5 + 55*x^6 + 116*x^7 + 228*x^8 + 443*x^9 + 885*x^10 + 1812*x^11 + 3743*x^12 + 7635*x^13 + 15391*x^14 + ...
such that
A(x) = 1 + x*(1+x)/(1-x + x^2)^2 + x^2*(1+x^2)^2/(1-x + x^3)^3 + x^3*(1+x^3)^3/(1-x + x^4)^4 + x^4*(1+x^4)^4/(1-x + x^5)^5 + x^5*(1+x^5)^5/(1-x + x^6)^6 + x^6*(1+x^6)^6/(1-x + x^7)^7 + ...
also,
A(x) = 1/(1 - 2*x) - x*(1-x)/(1-x - x^2)^2 + x^2*(1-x^2)^2/(1-x - x^3)^3 - x^3*(1-x^3)^3/(1-x - x^4)^4 + x^4*(1-x^4)^4/(1-x - x^5)^5 - x^5*(1-x^5)^5/(1-x - x^6)^6 + x^6*(1-x^6)^6/(1-x - x^7)^7 + ...
PROG
(PARI) {a(n) = my(A = sum(m=0, n, x^m*(1 + x^m)^m/(1 - x + x^(m+1) +x*O(x^n) )^(m+1) ) ); polcoeff(A, n)}
for(n=0, 50, print1(a(n), ", "))
(PARI) {a(n) = my(A = sum(m=0, n, (-x)^m*(1 - x^m)^m/(1 - x - x^(m+1) +x*O(x^n) )^(m+1) ) ); polcoeff(A, n)}
for(n=0, 50, print1(a(n), ", "))
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul D. Hanna, Jan 26 2019
STATUS
approved