ifft limitations
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hi all,
I'm stumped by the following:
z = poisspdf(30:60,1); % generates Poisson signal
fz = fft(z);
zf = ifft(fz);
but both z and zf are not the same. However, it seems fine for the following:
a = [1 2 3 4 5]*1e-100; % generate signal with small energy
fa = fft(a);
af = ifft(fa);
Is there some kind of aliasing effect going on, or am I missing something? It seems to not work on fast decaying signals.
0 comentarios
Respuesta aceptada
Dr. Seis
el 5 de Feb. de 2012
It looks like the results are very close to being the same between column 1 and column 10:
>>[z;zf]
ans =
Columns 1 through 5
1.3869e-33 4.4739e-35 1.3981e-36 4.2366e-38 1.2461e-39
1.3869e-33 4.4739e-35 1.3981e-36 4.2366e-38 1.2461e-39
Columns 6 through 10
3.5602e-41 9.8894e-43 2.6728e-44 7.0337e-46 1.8035e-47
3.5602e-41 9.8894e-43 2.6728e-44 7.0339e-46 1.8056e-47
Columns 11 through 15
4.5088e-49 1.0997e-50 2.6183e-52 6.0892e-54 1.3839e-55
4.1885e-49 -2.3624e-50 -1.1036e-50 -2.1899e-50 -2.3753e-50
Columns 16 through 20
3.0753e-57 6.6855e-59 1.4225e-60 2.9634e-62 6.0478e-64
-2.0649e-50 -2.2115e-50 -2.5909e-50 -2.2244e-50 -1.1036e-50
Columns 21 through 25
1.2096e-65 2.3717e-67 4.561e-69 8.6056e-71 1.5936e-72
-3.1556e-50 -3.259e-50 2.108e-50 1.8364e-50 -3.9725e-50
Columns 26 through 30
2.8975e-74 5.1741e-76 9.0774e-78 1.5651e-79 2.6527e-81
-1.3752e-50 -1.0454e-50 -3.9014e-50 -1.3827e-50 -1.0139e-49
Column 31
4.4211e-83
7.1734e-50
If you look at difference in amplitude between column 1 and column 10 you will notice it is 14 orders of magnitude. It looks like the problem comes down to machine precision... if you have amplitudes that differ more than 14 orders of magnitude (~double precision) then you will start to see artifacts introduced.
2 comentarios
Más respuestas (0)
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!