[23] in mathematical software users group
Re: Integrals involving abs and signum
daemon@ATHENA.MIT.EDU (daemon@ATHENA.MIT.EDU)
Thu Mar 26 19:16:56 1992
Date: Thu, 26 Mar 92 18:37 EST
From: Jeffrey P. Golden <jpg@ALLEGHENY.SCRC.Symbolics.COM>
To: msug@MIT.EDU
Cc: jpg@ALLEGHENY.SCRC.Symbolics.COM
In-Reply-To: <199203260213.AA09662@titan.cc.deakin.OZ.AU>
Date: Thu, 26 Mar 1992 12:13:04 +1000
From: chen@deakin.OZ.AU
Please tell me the result for the following integration by Maple and Mma:
inte(abs(x^3), x from -2 to 2)
inte(sgn(x)*x^3, x from -2 to 2)
--------------------------------------------
In my previous mail, the integration specifies the symbolic integration.
Please use symbolic integration rather than numeric integration.
Please try
inte(abs(x^3), x from -c to c)
inte(sgn(x)*x^3, x from -c to c)
The following is done with the current Symbolics MACSYMA 417.100
SPARC (Sun-4) release:
(c1) intanalysis:false$
(c2) integrate(abs(x^3),x,-2,2);
(d2) 8
(c3) integrate(signum(x)*x^3,x,-2,2);
(d3) 8
(c4) assume(c>0)$
(c5) integrate(abs(x^3),x,-c,c);
4
c
(d5) --
2
(c6) integrate(signum(x)*x^3,x,-c,c);
4
c
(d6) --
2
---------------------------------------------
Why are your requests so restrictive? Why only integrate over
intervals symmetric about the origin?
However, MACSYMA thanks you for it:
The fact is MACSYMA is not using any code here that specifically
integrates (knows about) ABS or SIGNUM (that's why integration
analysis (INTANALYSIS) is turned off in C1) and it can still do
your problems as given! It's using the facts that the intervals
are symmetric about the origin and that the integrands are even
functions. In this case you can integrate from 0 to 2 (or to C)
instead and the ABS and SIGNUM are simplified away! (You then
simply multiply by 2 at the end.)
From: Jeffrey P. Golden <jpg@ALLEGHENY.SCRC.Symbolics.COM>
Organization: Symbolics MACSYMA Division