From: Barton W. <wi...@un...> - 2023-02-22 14:43:02
|
There are some (too many, I’d say) tests in our testsuite that set numer to true and use ev. Here is one of them: ev(integrate(x^3/(exp(x)-1),x,0,inf),numer) First, given the unintended consequences of ev, I think it would be better to write this test as block([numer : true], integrate(x^3/(exp(x)-1),x,0,inf)) Second, I think getting limit and integrate (likely others) to work for correctly when numer is true is more work than it’s worth. You can set numer to false at the top level of these mostly symbolically-based functions only to have it change later on. I have a few bits of code that allow Maxima to symbolically compute this integral: (%i4) block([numer : false], integrate(x^3/(exp(x)-1),x,0,inf)); (%o4) %pi^4/15 (Current Maxima gives a limit nounform for this definite integral.) But when numer is true, my code says the integral diverges—why? Well two terms that should exactly cancel don't—look at first term with the coefficient of 1.11...x10^-16. 3" Enter "limit" "[1.110223024625157*10^-16*%pi^2*x^2+(-0.1166666666666667*%pi^4\-0.5*log(-1)^2*%pi^2-0.25*log(-1)^4),x,inf,think] I'll continue looking for the place where numer gets set to true (it is set to false at the top of the my limit code. But I'm tempted to change the test to float(integrate(x^3/(exp(x)-1),x,0,inf)) --Barton |