|
EXAMPLE
|
G.f.: A(x) = 1 + x + 3*x^2 + 11*x^3 + 45*x^4 + 198*x^5 + 914*x^6 +...
Related expansions:
A(x)^2 = 1 + 2*x + 7*x^2 + 28*x^3 + 121*x^4 + 552*x^5 + 2615*x^6 +...
A(x)^3 = 1 + 3*x + 12*x^2 + 52*x^3 + 237*x^4 + 1122*x^5 + 5463*x^6 +...
A(x)^5 = 1 + 5*x + 25*x^2 + 125*x^3 + 630*x^4 + 3211*x^5 + 16545*x^6 +...
where A(x) = 1 + x*A(x)^2 + x^2*A(x)^3 + x^3*A(x)^5.
The logarithm of the g.f. A = A(x) equals the series:
log(A(x)) = (1 + x*A)*x*A + (1 + 2^2*x*A + x^2*A^2)*x^2*A^2/2 +
(1 + 3^2*x*A + 3^2*x^2*A^2 + x^3*A^3)*x^3*A^3/3 +
(1 + 4^2*x*A + 6^2*x^2*A^2 + 4^2*x^3*A^3 + x^4*A^4)*x^4*A^4/4 +
(1 + 5^2*x*A + 10^2*x^2*A^2 + 10^2*x^3*A^3 + 5^2*x^4*A^4 + x^5*A^5)*x^5*A^5/5 +
(1 + 6^2*x*A + 15^2*x^2*A^2 + 20^2*x^3*A^3 + 15^2*x^4*A^4 + 6^2*x^5*A^5 + x^6*A^6)*x^6*A^6/6 +...
more explicitly,
log(A(x)) = x + 5*x^2/2 + 25*x^3/3 + 129*x^4/4 + 686*x^5/5 + 3713*x^6/6 + 20350*x^7/7 +...
Given G(x) where 1+x*G(x) is the g.f. of A004148, then the coefficients in the powers of G(x) begin:
1: [(1), 1, 2, 4, 8, 17, 37, 82, 185, 423, 978, ...];
2: [1,(2), 5, 12, 28, 66, 156, 370, 882, 2112, ...];
3: [1, 3,(9), 25, 66, 171, 437, 1107, 2790, 7009, ...];
4: [1, 4, 14,(44), 129, 364, 1000, 2696, 7172, 18892, ...];
5: [1, 5, 20, 70,(225), 686, 2015, 5760, 16135, 44500, ...];
6: [1, 6, 27, 104, 363,(1188), 3713, 11214, 32994, 95106, ...];
7: [1, 7, 35, 147, 553, 1932,(6398), 20350, 62734, 188650, ...];
8: [1, 8, 44, 200, 806, 2992, 10460,(34936), 112585, 352560, ...];
9: [1, 9, 54, 264, 1134, 4455, 16389, 57330,(192726), 627406, ...]; ...;
the coefficients in parenthesis form the initial terms of this sequence:
[1/1, 2/2, 9/3, 44/4, 225/5, 1188/6, 6398/7, 34936/8, 192726/9, ...].
The coefficients in the logarithm of the g.f. is also a diagonal in the above table.
|
|
PROG
|
(PARI) {a(n)=local(A=1+x); for(i=1, n, A=(1+x*A^2)*(1+x^2*A^3)+x*O(x^n)); polcoeff(A, n)}
(PARI) {a(n)=polcoeff(1/x*serreverse(x*(1-x-x^2 + sqrt((1+x+x^2)*(1-3*x+x^2)+x*O(x^n)))/2), n)}
(PARI) {a(n)=local(A=1+x); for(i=1, n, A=exp(sum(m=1, n, sum(j=0, m, binomial(m, j)^2*x^j*A^j)*(x*A+x*O(x^n))^m/m))); polcoeff(A, n, x)}
(PARI) {a(n)=local(A=1+x); for(i=1, n, A=exp(sum(m=1, n, (1-x*A)^(2*m+1)*sum(j=0, n, binomial(m+j, j)^2*x^j*A^j)*x^m*A^m/m))); polcoeff(A, n, x)}
|