I've found a lot of situations where maxima fails to compute indefinite limits
of functions involving trigonometric expressions as x tends to infinity.
f:(4*x^3+2*x^2*sin(x)+1)/(x+1)^2;
limit(f-x*4,x,inf); # should be ind
A work-around is to force a ratsimp before the limit. For example :
(%i34) f:(4*x^3+2*x^2*sin(x)+1)/(x+1)^2;
2 3
2 x sin(x) + 4 x + 1
(%o34) ----------------------
2
(x + 1)
(%i35) limit(f-x*4,x,inf);
(%o35) - 8
(%i36) limit(ratsimp(f-x*4),x,inf);
(%o36) ind
The bug is in
simplimplus1.
This is the function that finds the limit of a sum. SpecificallyHere is a tiny putative fix to
simplimplus1
that fixes this bug. Briefly, the bit of code following the tagoon
ignores the$ind
terms. Putting a trap for this case fixes the bug.Fixed by [24a57b] (HEAD, master); appended test to rtest_limit_extra. Closing this bug as fixed.
Related
Commit: [24a57b]
Thank you for your work Barton !