Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #8681 > unrolled thread

Why the FourierTransform gives two different answers?

Started byАлексей <avderov@gmail.com>
First post2012-02-21 11:22 +0000
Last post2012-02-23 10:50 +0000
Articles 3 — 2 participants

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Why the FourierTransform gives two different answers? Алексей <avderov@gmail.com> - 2012-02-21 11:22 +0000
    Re: Why the FourierTransform gives two different answers? "Nasser M. Abbasi" <nma@12000.org> - 2012-02-23 10:49 +0000
    Re: Why the FourierTransform gives two different answers? "Nasser M. Abbasi" <nma@12000.org> - 2012-02-23 10:50 +0000

#8681 — Why the FourierTransform gives two different answers?

FromАлексей <avderov@gmail.com>
Date2012-02-21 11:22 +0000
SubjectWhy the FourierTransform gives two different answers?
Message-ID<jhvupg$893$1@smc.vnet.net>
Why the FourierTransform gives two different answers?

In[1]     FourierTransform[ (t - 5.0)^2*Exp[-(t - 5.0)^2 ], t, w]

In[2]     FourierTransform[ (t - 5)^2*  Exp[-(t - 5)^2 ], t, w]

[toc] | [next] | [standalone]


#8709

From"Nasser M. Abbasi" <nma@12000.org>
Date2012-02-23 10:49 +0000
Message-ID<ji55kd$79k$1@smc.vnet.net>
In reply to#8681
On 2/21/2012 5:22 AM, Алексей wrote:
> Why the FourierTransform gives two different answers?
>
> In[1]     FourierTransform[ (t - 5.0)^2*Exp[-(t - 5.0)^2 ], t, w]
>
> In[2]     FourierTransform[ (t - 5)^2*  Exp[-(t - 5)^2 ], t, w]
>

It seems to be in integration part. In this below I used
the text book definition of the F.T. itself, and instead
of integrating to infinity, integrate to 'k', then take the limit
as k->Infinity of the result of the integration, and I get the
same result of both the symbolic and the numerical version.

So, the problem is with the limit to infinity with the numerical
version inside the integration code.

-----------------numerical ------------------
ClearAll[t, w, k]
f = (t - 5.0)^2*Exp[-(t - 5.0)^2];
res = Integrate[f*Exp[-I w t], {t, -k, k}];
res = Limit[res, k -> Infinity];
Plot[{Re[res], Im[res]}, {w, -5, 5}]
-------------------------


------------ symbolic -----------
ClearAll[t, w, k]
f = (t - 5)^2*Exp[-(t - 5)^2];
res = Integrate[f*Exp[-I w t], {t, -k, k}];
res = Limit[res, k -> Infinity];
Plot[{Re[res], Im[res]}, {w, -5, 5}]
-----------------------------

same result, as what one would expect.

If I change the numerical integration above to be

     Integrate[f*Exp[-I w t], {t, -Infinity, Infinity}]

Then it become zero again. So, I think it is a bug
in the integration with the limit to infinity for this
integrand.


--Nasser

[toc] | [prev] | [next] | [standalone]


#8710

From"Nasser M. Abbasi" <nma@12000.org>
Date2012-02-23 10:50 +0000
Message-ID<ji55lc$7a2$1@smc.vnet.net>
In reply to#8681
On 2/22/2012 3:25 AM, Nasser M. Abbasi wrote:
> On 2/21/2012 5:22 AM, Алексей wrote:
>> Why the FourierTransform gives two different answers?
>>
>> In[1]     FourierTransform[ (t - 5.0)^2*Exp[-(t - 5.0)^2 ], t, w]
>>
>> In[2]     FourierTransform[ (t - 5)^2*  Exp[-(t - 5)^2 ], t, w]
>>

....
>
> ------------ symbolic -----------
> ClearAll[t, w, k]
> f = (t - 5)^2*Exp[-(t - 5)^2];
> res = Integrate[f*Exp[-I w t], {t, -k, k}];
> res = Limit[res, k ->  Infinity];
> Plot[{Re[res], Im[res]}, {w, -5, 5}]
> -----------------------------
>
...

btw, to get the same result with Mathematica FourierTransform
need to use FourierParameters -> {1, -1}, like this:

---------------------------
ClearAll[t, w, k]
f = (t - 5)^2*Exp[-(t - 5)^2];
res = FourierTransform[f, t, w, FourierParameters -> {1, -1}];
Plot[{Re[res], Im[res]}, {w, -5, 5}]
--------------------------

--Nasser

[toc] | [prev] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web