Updates:
Status: Fixed
Labels: Integration Series
Comment #2 on issue 1333 by asmeurer: Integral(x,x).series(x) raises
TypeError
http://code.google.com/p/sympy/issues/detail?id=1333
Indeed. I bisected it to this commit:
commit 2c99999451bf1e124e20d09c80d43b643eaa10c8
Author: Chris Smith <[email protected]>
Date: Tue Jan 18 17:41:42 2011 +0545
2124 nseries and lseries handle x0!=0
Series now should be more robust for more complex functions.
series() will call either nseries or lseries (when n=None) making
it possible to do either nseries or lseries from series.
Note: It would also be possible to just make nseries and lseries
helpers for series so there is only one "entry" to series; if the
n=None option is not desired then iter=True could perhaps trigger
the call to lseries. This could also respect the n value by returning
n terms instead of calculating up to order n.)
The handling of direction and the value of x0 is handled in
series and series. All nseries, lseries, _eval_nseries and
_eval_lseries have to do is return the series term(s) as x -> 0
from the positive direction. For this reason, x0 values and are no
longer sent to the _eval routines.
getn was moved from power.py to expr.py and geto was changed to .getO()
Derivative.lseries now works; it had an unconditional stop in it before.
In addition, it doesn't return evaluated derivatives. The dependence on
that behavior was modified to use expr.diff().
Issue 2123
If an expression has no order term then it should return right away
from lseries or else it will hang.
Issue 2122
Code in integrals.py intended for use by exponential.py was moved
to exponential.py and the general code for handling series terms
of an Integral left in integrals.py.
univariate functions don't require series variable to be given
don't return O() term when x0 != 0
sympy's current implementation of O() is only valid for the
series expansion of f(x) at x=0. Therefore, if x0!=0 the
order term is no longer returned.
lseries should not return Order term
It is possible that two terms are being returned -- no checking
is being done for this -- but no order terms are any longer
being returned.
return quickly from series et al if there is no x
This fixes the unresolved issues of issue 2085.
It looks like this commit added a test for Integral(cos(x), x).lseries, so
I think this can be closed.
--
You received this message because you are subscribed to the Google Groups
"sympy-issues" 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/sympy-issues?hl=en.