#3979: Power series composition messes up precision
------------------------+---------------------------------------------------
Reporter: kedlaya | Owner: somebody
Type: defect | Status: needs_review
Priority: critical | Milestone: sage-4.7.1
Component: algebra | Keywords: power series, composition, precision
Work_issues: | Upstream: N/A
Reviewer: | Author: Francis Clarke
Merged: | Dependencies:
------------------------+---------------------------------------------------
Changes (by newvalueoldvalue):
* priority: major => critical
* status: new => needs_review
* upstream: => N/A
* component: basic arithmetic => algebra
* author: => Francis Clarke
Comment:
In the attached patch I have completely rewritten
`sage.rings.power_series_poly.__call__`. Several errors in the old
version have been corrected. The new version more closely follows the
corresponding function for polynomials, in particular referring to
variables by name is now possible.
In order to make the `__call__` function work correctly it was necessary
to change the behaviour of `sage.rings.power_series_poly.valuation`. At
the moment
{{{
sage: R.<x> = QQ[]
sage: O(x^3).valuation()
+Infinity
}}}
If we interpret `O(x^3)` as `x^3` times an unknown power series, then the
valuation could be anywhere between 3 and infinity, but 3 is a much
better, and more cautious, estimate than infinity. It is also very
strange to have a series whose valuation is greater than its precision.
The new convention is also consistent with what happens for p-adic
integers:
{{{
sage: O(7^3).valuation()
3
}}}
In the course of checking the power series code, a minor mistake in the
polynomial code has been found and corrected.
A doctest in `sage/rings/morphism.pyx` needed adjusting.
I have also deleted the doctest in
`sage.rings.power_series_mpoly.__call__` for two reason's : (1) it doesn't
use this function; (2) it makes no sense anyway. Besides the first line
of the file is
{{{
# NOT ready to be used -- possibly should be deleted.
}}}
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/3979#comment:3>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.