-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Series/limit fails unless expression is simplified first. #9173
Comments
Any update on why this might be happening? It still seems to be an issue. |
It seems that there is a bug in the computation of the series expansion of
It is caused by an incorrect loop count in |
Fixed in f572eea.
Fixed in f572eea.
close sympy/sympy#3112 (MrvAsympt was added in diofant#6) close sympy/sympy#9173 (test was added in 5a510ac) close sympy/sympy#9808 (fixed in 09e539b) close sympy/sympy#9341 (fixed in af98a00) close sympy/sympy#9908 (fixed in cc3fa8d) close sympy/sympy#6171 (test added in d278031) close sympy/sympy#9276 (diagnose_imports.py removed in ab8c535) close sympy/sympy#10201 (fixed in 0d0fc5f) close sympy/sympy#9057 (test was added in 8290a0c) close sympy/sympy#11159 (test was added in ffb76cb) close sympy/sympy#2839 (new AST transformers are used, see diofant#278 and diofant#167) close sympy/sympy#11081 (see ed01e16 and bb92329) close sympy/sympy#10974 (see 73fc425) close sympy/sympy#10806 (test in 539929a) close sympy/sympy#10801 (test in 2fe3da5) close sympy/sympy#9549 (test in 88bdefa) close sympy/sympy#4231 (test was added in fb411d5) close sympy/sympy#8634 (see 2fcbb58) close sympy/sympy#8481 (see 1ef20d3) close sympy/sympy#9956 (fixed in a34735f) close sympy/sympy#9747 (see e117c60) close sympy/sympy#7853 (see 3e4fbed) close sympy/sympy#9634 (see 2be03f5) close sympy/sympy#8500 (fixed in diofant#104 and finally in diofant#316) close sympy/sympy#9192 (see 9bf622f) close sympy/sympy#7130 (see e068fa3) close sympy/sympy#8514 (see b2d543b) close sympy/sympy#9334 (see 90de625) close sympy/sympy#8229 (see 9755b89) close sympy/sympy#8061 (see 7054f06) close sympy/sympy#7872 (tested in diofant#6) close sympy/sympy#3496 (tested in test_log_symbolic) close sympy/sympy#2929 (see da7db7a) close sympy/sympy#8203 (oo is not a real, see diofant#36) close sympy/sympy#7649 (0 is imaginary since diofant#8) close sympy/sympy#7256 (fixed in c0a4549) close sympy/sympy#6783 (see cb28d63) close sympy/sympy#5662 (is_integer issue fixed in 6bfa9f8, there is no is_bounded anymore) close sympy/sympy#5295 (fixed with diofant#354) close sympy/sympy#4856 (we now have flake/pep tests) close sympy/sympy#4555 (flake8 enabled after diofant#214) close sympy/sympy#5773 (cmp_to_key removed after diofant#164 and c9acbf0) close sympy/sympy#5484 (see above) Added regression tests: from https://groups.google.com/forum/#!topic/sympy/LkTMQKC_BOw fixes sympy/sympy#8825 (probably via diofant#209) fixes sympy/sympy#8635 fixes sympy/sympy#8157 fixes sympy/sympy#7872 fixes sympy/sympy#7599 fixes sympy/sympy#6179 fixes sympy/sympy#5415 fixes sympy/sympy#2865 fixes sympy/sympy#5907 fixes sympy/sympy#11722 Closes diofant#347
close sympy/sympy#3112 (MrvAsympt was added in diofant#6) close sympy/sympy#9173 (test was added in 5a510ac) close sympy/sympy#9808 (fixed in 09e539b) close sympy/sympy#9341 (fixed in af98a00) close sympy/sympy#9908 (fixed in cc3fa8d) close sympy/sympy#6171 (test added in d278031) close sympy/sympy#9276 (diagnose_imports.py removed in ab8c535) close sympy/sympy#10201 (fixed in 0d0fc5f) close sympy/sympy#9057 (test was added in 8290a0c) close sympy/sympy#11159 (test was added in ffb76cb) close sympy/sympy#2839 (new AST transformers are used, see diofant#278 and diofant#167) close sympy/sympy#11081 (see ed01e16 and bb92329) close sympy/sympy#10974 (see 73fc425) close sympy/sympy#10806 (test in 539929a) close sympy/sympy#10801 (test in 2fe3da5) close sympy/sympy#9549 (test in 88bdefa) close sympy/sympy#4231 (test was added in fb411d5) close sympy/sympy#8634 (see 2fcbb58) close sympy/sympy#8481 (see 1ef20d3) close sympy/sympy#9956 (fixed in a34735f) close sympy/sympy#9747 (see e117c60) close sympy/sympy#7853 (see 3e4fbed) close sympy/sympy#9634 (see 2be03f5) close sympy/sympy#8500 (fixed in diofant#104 and finally in diofant#316) close sympy/sympy#9192 (see 9bf622f) close sympy/sympy#7130 (see e068fa3) close sympy/sympy#8514 (see b2d543b) close sympy/sympy#9334 (see 90de625) close sympy/sympy#8229 (see 9755b89) close sympy/sympy#8061 (see 7054f06) close sympy/sympy#7872 (tested in diofant#6) close sympy/sympy#3496 (tested in test_log_symbolic) close sympy/sympy#2929 (see da7db7a) close sympy/sympy#8203 (oo is not a real, see diofant#36) close sympy/sympy#7649 (0 is imaginary since diofant#8) close sympy/sympy#7256 (fixed in c0a4549) close sympy/sympy#6783 (see cb28d63) close sympy/sympy#5662 (is_integer issue fixed in 6bfa9f8, there is no is_bounded anymore) close sympy/sympy#5295 (fixed with diofant#354) close sympy/sympy#4856 (we now have flake/pep tests) close sympy/sympy#4555 (flake8 enabled after diofant#214) close sympy/sympy#5773 (cmp_to_key removed after diofant#164 and c9acbf0) close sympy/sympy#5484 (see above) Added regression tests: from https://groups.google.com/forum/#!topic/sympy/LkTMQKC_BOw fixes sympy/sympy#8825 (probably via diofant#209) fixes sympy/sympy#8635 fixes sympy/sympy#8157 fixes sympy/sympy#7872 fixes sympy/sympy#7599 fixes sympy/sympy#6179 fixes sympy/sympy#5415 fixes sympy/sympy#2865 fixes sympy/sympy#5907 fixes sympy/sympy#11722 Closes diofant#347
I think this issue is resolved in the current master.
|
I can confirm @mohitacecode 's results. This only needs a test. |
Initially the issue was the failure of series/limit unless the expression is simplified first, but it is resoved in current master. So I have added test case addressing this one.
I run the code for this expression in the terminal having installed sympy version 1.7.1 but here the coefficients of y**2 and y are not simplified to final answer. Anyone guide me regarding this issue whether it is done with some purpose or this should be fixed?
|
I came across this issue while trying to address something similar and I realize this now ends up giving an even more complicated result than before and even if we simplify first .... we don't get the correct result which is a worse condition than what we had before !
I guess this was closed without adding a test hence we haven't come across this before, hence I guess we should reopen this now . Feel free to correct me if I'm missing something here ! |
I would like to work on this issue! Let me know if its available so I can get assigned! |
Hi! I am working on adding tests right now! |
Hello, I saw this issue and I checked some of the other linked threads. In particular, I saw that in #20724 the issue was closed because it was solved elsewhere, but when testing locally on versions 1.8+, the issue still persisted. Locally, I edited expr.py to include the same proposed change as #20724, and it seemed to solve the issue. However, it has started to fail testcases and I am unsure about how to proceed. I would greatly appreciate any guidance. |
Hello, I managed to fix this bug by incorporating ratsimp and it passes all of the test_expr test cases. However, when tested with tan(x).series(x, 2, 6, "+"), the output is incorrect. Any guidance would be greatly appreciated.
|
I'm not sure that there is an issue here. The example comes out more complicated than it needs to but it is correct. If we want to canonicalise the outputs then we should really use ringseries. |
I think best thing is just to add some test cases since they were not added before. |
Consider the following:
The
y**2
coefficient should beb_2
, but is computed to be something else unless the expression is simplified first. The issues seems to be withlimit
, and so might be related to #9075:The text was updated successfully, but these errors were encountered: