Status: Accepted
Owner: ----
Labels: Type-Defect Priority-Medium
New issue 3111 by [email protected]: series(cot(x**20 + x**21 + x**22),
x, 0, 1) is wrong
http://code.google.com/p/sympy/issues/detail?id=3111
These series expansions are wrong
```
from sympy import *
x = Symbol('x')
series(cot(x**20 + x**21 + x**22), x, 0, 1)
x**(-20) + O(x)
series(cot(x**20 + x**21 + x**22), x, 0, 2)
x**(-20) - 1/x**19 - 1/x**18 + O(x**2)
series(cot(x**20 + x**21 + x**22), x, 0, 3)
x**(-20) - 1/x**19 + 2/x**17 + x**(-16) + O(x**3)
series(cot(x**20 + x**21 + x**22), x, 0, 4)
x**(-20) - 1/x**19 + x**(-17) - 2/x**16 - 3/x**15 - 1/x**14 + O(x**4)
```
in particular in all of them all singular terms should be present;
only some are present, not always with correct coefficient;
the correct result at order `O(x**4)` is
```
sage: p = cot(x**20 + x**21 + x**22)
sage: taylor(p, x, 0, 3)
-x^2 + x - 1/x + 1/x^2 - 1/x^4 + 1/x^5 - 1/x^7 + 1/x^8 - 1/x^10 + 1/x^11 -
1/x^13 + 1/x^14 - 1/x^16 + 1/x^17 - 1/x^19 + 1/x^20
```
--
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.