Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How can I take a fractional power and a power series inverse?

I am attempting to take the power series inverse of the Taylor series expansion of $(x^4-x)^{1/3}$ around the point 0.

When I attempt to define g=(x^4-x)^{1/3} :

sage: R.<x> = LaurentPolynomialRing(QQ);
sage: g = (x^4-x)^{1/3}
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-21-675538f6f472> in <module>()
----> 1 g = (x**Integer(4)-x)**{Integer(1)/Integer(3)}

sage/rings/polynomial/laurent_polynomial.pyx in sage.rings.polynomial.laurent_polynomial.LaurentPolynomial_univariate.__pow__ (/usr/lib/sagemath//src/build/cythonized/sage/rings/polynomial/laurent_polynomial.c:10802)()

TypeError: int() argument must be a string or a number, not 'set'

Now, when I define $g$ as follows, I am unable to take the power series inverse:

sage: var('x')
x
sage: g = (1-x)**(1/3)
sage: G = g.taylor(x, 0, 10)
sage: 1/G
-4782969/(55913*x^10 + 64515*x^9 + 75735*x^8 + 90882*x^7 + 112266*x^6 + 144342*x^5 + 196830*x^4 + 295245*x^3 + 531441*x^2 + 1594323*x - 4782969)
sage: 1/G + O(x^10)

---------------------------------------------------------------------------
ArithmeticError                           Traceback (most recent call last)
<ipython-input-12-9fe94787aacb> in <module>()
----> 1 Integer(1)/G + O(x**Integer(10))

/usr/lib/sagemath/local/lib/python2.7/site-packages/sage/rings/big_oh.py in O(*x, **kwds)
    154     elif hasattr(x, 'O'):
    155         return x.O(**kwds)
--> 156     raise ArithmeticError("O(%s) not defined" % (x,))

ArithmeticError: O(x^10) not defined
sage: G.inverse()
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-14-34018a4209b6> in <module>()

How can I have the best of both worlds? In the end, I would like to have an element in the Laurent Series Ring, for the next stage is to take the formal integral of the result, and the inverse of this formal integral.

How can I take a fractional power and a power series inverse?

I am attempting to take the power series inverse of the Taylor series expansion of $(x^4-x)^{1/3}$ around the point 0.

When I attempt to define g=(x^4-x)^{1/3} :

sage: R.<x> = LaurentPolynomialRing(QQ);
sage: g = (x^4-x)^{1/3}
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-21-675538f6f472> in <module>()
----> 1 g = (x**Integer(4)-x)**{Integer(1)/Integer(3)}

sage/rings/polynomial/laurent_polynomial.pyx in sage.rings.polynomial.laurent_polynomial.LaurentPolynomial_univariate.__pow__ (/usr/lib/sagemath//src/build/cythonized/sage/rings/polynomial/laurent_polynomial.c:10802)()

TypeError: int() argument must be a string or a number, not 'set'

Now, when I define $g$ as follows, I am unable to take the power series inverse:

sage: var('x')
x
sage: g = (1-x)**(1/3)
sage: G = g.taylor(x, 0, 10)
sage: 1/G
-4782969/(55913*x^10 + 64515*x^9 + 75735*x^8 + 90882*x^7 + 112266*x^6 + 144342*x^5 + 196830*x^4 + 295245*x^3 + 531441*x^2 + 1594323*x - 4782969)
sage: 1/G + O(x^10)

---------------------------------------------------------------------------
ArithmeticError                           Traceback (most recent call last)
<ipython-input-12-9fe94787aacb> in <module>()
----> 1 Integer(1)/G + O(x**Integer(10))

/usr/lib/sagemath/local/lib/python2.7/site-packages/sage/rings/big_oh.py in O(*x, **kwds)
    154     elif hasattr(x, 'O'):
    155         return x.O(**kwds)
--> 156     raise ArithmeticError("O(%s) not defined" % (x,))

ArithmeticError: O(x^10) not defined
sage: G.inverse()
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-14-34018a4209b6> in <module>()

How can I have the best of both worlds? In the end, I would like to have an element in the Laurent Series Ring, for the next stage is to take the formal integral of the result, and the composition inverse of this formal integral.