New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

order-1 series wrong with non-zero expansion point #9351

Closed
cbm755 opened this Issue Apr 27, 2015 · 0 comments

Comments

Projects
None yet
1 participant
@cbm755
Copy link
Contributor

cbm755 commented Apr 27, 2015

This looks wrong:

f = exp(x)
f.series(x, 10, 1)
Out[51]: O(x - 10, (x, 10))

Surely it should be exp(10) + O(x - 10, (x, 10))?

Other orders/points work:

f.series(x, 10, 2)    # yes good
Out[52]: exp(10) + (x - 10)*exp(10) + O((x - 10)**2, (x, 10))

f.series(x, 10, 0)   # yes good
Out[53]: O(1, (x, 10))

f.series(x, 0, 1)   # yes good
Out[9]: 1 + O(x)

@cbm755 cbm755 added the series label Apr 27, 2015

cbm755 added a commit to cbm755/octsympy that referenced this issue Apr 29, 2015

taylor: xtest for an upstream SymPy bug
Degree 1 Taylor series do not work with non-zero expansion points
as filed at sympy/sympy#9351.

skirpichev added a commit to diofant/diofant that referenced this issue May 6, 2015

skirpichev added a commit to diofant/diofant that referenced this issue May 7, 2015

Fix O.contains expr.is_Add heuristics (was invalid for point != 0)
Closes sympy/sympy#9351.  Also fixes broken test in test_issue_5654().

asmeurer pushed a commit that referenced this issue Jun 28, 2017

Fix O.contains expr.is_Add heuristics (was invalid for point != 0)
Closes #9351.  Also fixes broken test in test_issue_5654().

[Cherry-picked from skirpichev/omg/commit/ec0542034fb2332fdbff6bc48c6374846682ea4f]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment