Bug in limit or integrate



Well, I think I found out something that is fundamentally wrong with pw.mac. 
The function pwint(expr,x,a,b) that is supposed to be the definite integral 
of the expr is wrong.  It does nothing of the sort.  I just takes the 
difference between the antidiff of the expr at b and a and subtracts.  That 
way does not always work.  I think there is no easy fix to this problem. 
Back to the drawing board I guess.  A quick fix could be to rename pwint() 
to pwantidiff() and eliminate the last two (optional) arguments a and b and 
eliminate pwdefint() completely since it does the same thing.

Rich

-----Original Message----- 
From: Barton Willis
Sent: Saturday, December 31, 2011 8:57 AM
To: rich.hennessy at verizon.net
Cc: maxima at math.utexas.edu
Subject: Re: [Maxima] Bug in limit or integrate

The function x |->  -gamma_incomplete(1/4,x^4)*x/(4*abs(x)) is not 
continuous at zero. To do
the calculation correctly, you need to consider the intervals (-inf,0) and 
(0, inf) separately.
Doing that, the definite integral is correct, I think.

Sometime ago, I wrote a bit of code that attempts to determine when an 
expression is continuous. I know
that in general this is algorithmically impossible--I was aiming for a 
satisficing (good enough) method.

--Barton

-----maxima-bounces at math.utexas.edu wrote: -----


I get this incorrect result for the following calculations:

(%i4) kill(all);

(%o0) done
(%i1) exp(-x^4);

(%o1) %e^-x^4
(%i2) integrate(%o1,x,minf,inf);

(%o2) gamma(1/4)/2
(%i3) integrate(%o1,x);

(%o3) -gamma_incomplete(1/4,x^4)*x/(4*abs(x))
(%i4) limit(%o3,x,inf)-limit(%o3,x,minf);

(%o4) 0

The limit should give the same answer as the more direct definite  integral. 
I can’t take the analysis much further because I know very  little 
about the gamma_incomplete function.  It looks like a bug.

Rich
  _______________________________________________
Maxima mailing list
Maxima at math.utexas.edu
http://www.math.utexas.edu/mailman/listinfo/maxima