Trigonometric definite integral resulting in sinc-likefunction



--------------------------------------------------
From: "Dan" <vi5u0-maxima at yahoo.co.uk>
Sent: Thursday, July 15, 2010 6:57 PM
To: "Maxima mailing list" <maxima at math.utexas.edu>
Subject: Re: [Maxima] Trigonometric definite integral resulting in 
sinc-likefunction

> On Thu, 15 Jul 2010, Richard Hennessy wrote:
>
>> "which is correct for all real m."  Actually this is not exactly true.
>>
>> (%i1) sin(2*%pi*%m)/(2*%pi*m),m=0;
>> Division by 0
>> -- an error. To debug this try: debugmode(true);
>
> OK, but the algebraic expression is still a correct value of the
> integral - it's at the substituion of m = 0 stage that things go wrong
> in the above, no?
>
>> (%i2) integrate(cos(2*%pi*m*x),x,0,1),m=0;
>> (out2) 1
>>
>> This type of answer could be made correct for all m but it would 
>> complicate many results.
>
> Indeed it would.  I know asksign is deeply unpopular, but... ;-).

This would help but nobody likes it as you say, maybe a flag could be setup 
to control this if anyone wants it.  I like the idea, I don't know if anyone 
else does.

This could be the answer.
(%i12) integrate(cos(2*%pi*m*x),x,0,1);
(out12) if equal(m,0) then 1 else sin(2*%pi*m)/(2*%pi*m)
(%i13) out12,m=4;
(out13) 0
(%i14) out12,m=4.3;
rat: replaced 4.3 by 43/10 = 4.3
(out14) 0.11627906976744*sin(8.6*%pi)/%pi
(%i15) out12,m=0;
(out15) 1



>
> -- 
>
> Regards,
>
> Dan
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>