Comment #14 on issue 895 by [email protected]: series method does not work if the point is not 0
http://code.google.com/p/sympy/issues/detail?id=895

OK, this work was disallowing evaluation at x0 = 0. My work has been focussed on getting it to be right. If my work is reviewed and accepted, this issue can be closed.

He notes:
    In [9]: exp(1+x).series(x,point=0).subs(x,x-1)
    Out[9]: O(1)

The problem here seems to be the O(x**6) symbol. Since,
O(f(x)) represents O(f(x)) at the point x = 0, the substitution
fails.

Yes...that's the problem. The new issue that should be opened is
1) implement O() at x0!=0
2) implement multivariate expansion as noted above

btw, here are the expression that he gave above in pull/61

    h[2] >>> (x**4).series(x,0,2)
    x**4
    h[3] >>> (x**4).series(x,1,2)
    -3 + 4*x + 6*(1 - x)**2 - 4*(1 - x)**3 + (1 - x)**4
    h[4] >>> (2**x).series(x,0,3)
    1 + x*log(2) + x**2*log(2)**2/2 + O(x**3)
    h[5] >>> (2**x).series(x,1,3)
    2 - 2*(1 - x)*log(2) + (1 - x)**2*log(2)**2
    h[6] >>> (x**x).series(x,0,3)
    1 + x*log(x) + x**2*log(x)**2/2 + O(x**3*log(x)**3)
    h[7] >>> (x**x).series(x,1,3)
    x + (1 - x)**2
    h[8] >>> ((1+x)**x).series(x,0,3)
    1 + x**2 - x**3/2 + O(x**4)
    h[9] >>> ((1+x)**x).series(x,1,3)
1 + x + (1 - x)**2*log(2) - 2*(1 - x)*log(2) + (1 - x)**2 + (1 - x)**2*log(2)**2

Note that sympy no longer returns O() if you aren't evaluating at x0=0

--
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.

Reply via email to