rtoy / maxima

A Clone of Maxima's repo
Other
0 stars 0 forks source link

integrate gives a negative result #88

Open rtoy opened 4 months ago

rtoy commented 4 months ago

Imported from SourceForge on 2024-07-01 18:06:18 Created by mstanev on 2017-05-22 13:15:33 Original: https://sourceforge.net/p/maxima/bugs/3310


There is a discussion https://sourceforge.net/p/maxima/mailman/maxima-discuss/thread/1130339961.5365646.1494311181007%40mail.yahoo.com/#msg35829809 about a wrong result of integrate(f,y,0,1). It was suggested to report a bug.

It seems that the function f defined in (i2) makes the maxima-function integrate() to fail.

(i1)     bug_report();
(%o1) ... build_info(version="5.38.1",timestamp="2016-10-19 00:27:24",host="x86_64-suse-linux-gnu",lisp_name="CLISP",lisp_version= "2.49 (2010-07-07) (built on cloud112 [127.0.0.1])") ...
(i2)     f:(y^2-1)*asin((sqrt(1-y^2)*sqrt(y-y^2))/(y^2-1))$
(i3)     integrate(f,y,0,1);/* wrong answer */;
(%o3) -(15%pi+32)/45
(i4)     integrate(expand(f),y,0,1);/* right answer */;
(%o4) (15*%pi-32)/45
rtoy commented 4 months ago

Imported from SourceForge on 2024-07-01 18:06:18 Created by robert_dodier on 2017-06-13 04:51:48 Original: https://sourceforge.net/p/maxima/bugs/3310/#1a1a


Diff:


--- old
+++ new
@@ -3,6 +3,7 @@

 It seems that the function f defined in (i2) makes the maxima-function integrate() to fail.

+~~~~
 (i1)     bug_report();
 (%o1) ... build_info(version="5.38.1",timestamp="2016-10-19 00:27:24",host="x86_64-suse-linux-gnu",lisp_name="CLISP",lisp_version= "2.49 (2010-07-07) (built on cloud112 [127.0.0.1])") ...
 (i2)     f:(y^2-1)*asin((sqrt(1-y^2)*sqrt(y-y^2))/(y^2-1))$
@@ -10,3 +11,4 @@
 (%o3) -(15%pi+32)/45
 (i4)     integrate(expand(f),y,0,1);/* right answer */;
 (%o4) (15*%pi-32)/45
+~~~~