Bug in lower limit of integration ?



On Mon, 2006-05-22 at 18:57 -0300, Henry Lenzi wrote:

> 1) Why does Maxima not accept -sqrt(something) and proceeds to do
> sqrt(-something)?
> 
> (%i8) integrate(r,z,-sqrt(20-r^2),sqrt(20-r^2));

I guess you expect 20-r^2 to be positive.

>      2
> Is  r  - 20  positive, negative, or zero?
> 
> positive;
I think you got confused here. The simplification process in Maxima
transformed your input (20-r^2) into -(r^2-20). That means you should
answer that r^2-20 is negative, to get the answer I guess you were
expecting:

     2
Is  r  - 20  positive, negative, or zero?


negative;
                                              2
(%o8)                          2 r sqrt(20 - r )

I hope this helps,
Jaime