Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How to compute the multiplicative inverse of a series?

After a formula of Sergei N. Gladkovskii the logarithm of the generating function for the Pell numbers is the multiplicative inverse of sqrt(2)coth(sqrt(2)x)-1 seen as an exponential generating function.

In the words of Maple:

seq(k!*coeff(series(1/(sqrt(2)*coth(sqrt(2)*x)-1),x=0,k+2),x,k),k=0..9);
0, 1, 2, 2, -8, -56, -112, 848, 9088, 25216

How can I do this with Sage?

How to compute the multiplicative inverse of a series?

After a formula of Sergei N. Gladkovskii the logarithm of the generating function for the Pell numbers is the multiplicative inverse of sqrt(2)coth(sqrt(2)sqrt(2) coth(sqrt(2) x)-1 seen as an exponential generating function.

In the words of Maple:

seq(k!*coeff(series(1/(sqrt(2)*coth(sqrt(2)*x)-1),x=0,k+2),x,k),k=0..9);
0, 1, 2, 2, -8, -56, -112, 848, 9088, 25216

How can I do this with Sage?

How to compute the multiplicative inverse of a series?

After a formula of Sergei N. Gladkovskii the logarithm of the generating function for the Pell numbers is the multiplicative inverse of sqrt(2) coth(sqrt(2) x)-1 seen as an exponential generating function.

In the words of Maple:

seq(k!*coeff(series(1/(sqrt(2)*coth(sqrt(2)*x)-1),x=0,k+2),x,k),k=0..9);
0, 1, 2, 2, -8, -56, -112, 848, 9088, 25216

How can I do this with Sage?

Added:

If I want a compositional inverse this is what I do:

SR -> taylor -> PowerSeriesRing(SR) -> reversion() -> egf_to_ogf() -> padded_list()

If I want a multiplicative inverse this is what I want to do:

SR -> taylor -> PowerSeriesRing(SR) -> inversion() -> egf_to_ogf() -> padded_list()

Isn't this what one expects naturally? But I cannot find an 'inversion'.

How to compute the multiplicative inverse of a series?

After a formula of Sergei N. Gladkovskii the logarithm of the generating function for the Pell numbers is the multiplicative inverse of sqrt(2) coth(sqrt(2) x)-1 seen as an exponential generating function.

In the words of Maple:

seq(k!*coeff(series(1/(sqrt(2)*coth(sqrt(2)*x)-1),x=0,k+2),x,k),k=0..9);
0, 1, 2, 2, -8, -56, -112, 848, 9088, 25216

How can I do this with Sage?

Added:

If I want a compositional inverse this is what I do:

SR -> taylor -> PowerSeriesRing(SR) -> reversion() -> egf_to_ogf() -> padded_list()

If I want a multiplicative inverse this is what I want to do:

SR -> taylor -> PowerSeriesRing(SR) -> inversion() -> egf_to_ogf() -> padded_list()

Isn't this what one expects naturally? But I cannot find an 'inversion'.

Solution d'après kcrisman

x = SR.var('x')
gf = (sqrt(2)*coth(sqrt(2)*x)-1)^-1
taylor(gf,x,0,9).power_series(SR).egf_to_ogf().padded_list()
click to hide/show revision 5
retagged

How to compute the multiplicative inverse of a series?

After a formula of Sergei N. Gladkovskii the logarithm of the generating function for the Pell numbers is the multiplicative inverse of sqrt(2) coth(sqrt(2) x)-1 seen as an exponential generating function.

In the words of Maple:

seq(k!*coeff(series(1/(sqrt(2)*coth(sqrt(2)*x)-1),x=0,k+2),x,k),k=0..9);
0, 1, 2, 2, -8, -56, -112, 848, 9088, 25216

How can I do this with Sage?

Added:

If I want a compositional inverse this is what I do:

SR -> taylor -> PowerSeriesRing(SR) -> reversion() -> egf_to_ogf() -> padded_list()

If I want a multiplicative inverse this is what I want to do:

SR -> taylor -> PowerSeriesRing(SR) -> inversion() -> egf_to_ogf() -> padded_list()

Isn't this what one expects naturally? But I cannot find an 'inversion'.

Solution d'après kcrisman

x = SR.var('x')
gf = (sqrt(2)*coth(sqrt(2)*x)-1)^-1
taylor(gf,x,0,9).power_series(SR).egf_to_ogf().padded_list()