p**f 发帖数: 7 | 1 Let's say we have
f(x)=sin(x), and thus f"(x)=-sin(x)
and let's use Fourier as
F(k)=\int f(x) e^{-i*2*pi*k*x}dx
and thus DFT as
F(n/NT)=\sum_{j=0}^{j=N-1} f(jT)e^{-i*2*pi*n*j/N}, n=0,...N-1
As a result, we should have
F[f"(x)]=-k^2*F[f(x)]
But if I calculate F[f(x)] use FFT, and then calculate F[f"(x)] according to
F[f"(x)]=-k^2*F[f(x)]=-(n/2pi)^2*F(f(x)), n=0,...N-1, NT=2pi
I cannot recover F[f"(x)]=F[-sin(x)]
what is the problem? I am really confused now. Thanks in advance. | r****y 发帖数: 1437 | 2
I think your definition of n is wrong. n = 0, ..., N/2, -N/2+1, ...-1.
【在 p**f 的大作中提到】 : Let's say we have : f(x)=sin(x), and thus f"(x)=-sin(x) : and let's use Fourier as : F(k)=\int f(x) e^{-i*2*pi*k*x}dx : and thus DFT as : F(n/NT)=\sum_{j=0}^{j=N-1} f(jT)e^{-i*2*pi*n*j/N}, n=0,...N-1 : As a result, we should have : F[f"(x)]=-k^2*F[f(x)] : But if I calculate F[f(x)] use FFT, and then calculate F[f"(x)] according to : F[f"(x)]=-k^2*F[f(x)]=-(n/2pi)^2*F(f(x)), n=0,...N-1, NT=2pi
|
|