OFFSET
0,2
COMMENTS
A136218 is a triangle where row n+1 is generated from row n by first inserting zeros in row n at positions {[m*(m+7)/6], m>=0} and then taking partial sums, starting with a '1' in row 0.
FORMULA
G.f. A(x) = (1+x+x^2)/(1-x)^3 - [Sum_{n>=0} x^b(n)]/(1-x)^2 where exponents b(n) = A136169(n) satisfy: b(n) = 2*b(n-1) - [(n+1)/3] for n>0 with b(0)=1 and the g.f. of the exponents is B(z) = [1 - z^2*(1+z+z^2)/(1-z^3)^2]/(1-2*z).
EXAMPLE
G.f. A(x) = (1+x+x^2)/(1-x)^3 - (x+x^2+x^3+x^5+x^9+x^16+x^30+x^58+...)/(1-x)^2.
PROG
(PARI) {a(n)=local(A, X=x+x*O(x^n), bd=#binary(2*n), B=(1 - x^2*(1+x+x^2)/(1-x^3+x*O(x^bd))^2 )/(1-2*x)); A=(1+x+x^2)/(1-X)^3 - sum(k=0, bd, x^polcoeff(B, k))/(1-X)^2; polcoeff(A, n)}
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul D. Hanna, Dec 23 2007
STATUS
approved