fft(single) is giving inconsistent results

2 vues (au cours des 30 derniers jours)
Jeremy
Jeremy le 4 Oct 2013
I have found that if I have an array of singles and I want to run it through fft so the transform is performed independently for each column, I get a different answer if I add on additional columns. I haven't been able to reproduce using random inputs, but i did save my inputs out from my workspace so the issue can be reproduced. the input time histories are attached.
I basically have a 10000x20 array of single precision, real numbers. If I add on an additional 10 columns of single precision, real numbers and run it through fft, I get a different result than if I just run the 20 columns through fft. There seems to be some interaction between the columns during the calculation, and the transform should definitely be performed independently for each channel.
I am running on 2012b 64-bit, I see the same result on 2010b 64-bit and 2012b 32-bit but NOT on 2010b 32-bit
load('fft vars.mat');
xxx=[bData mData];
isequal(bData(:,2),xxx(:,2))
f1=fft(xxx,[],1);
f2=fft(bData);
f1(591,2)
f2(591,2)
%what?!!
ans =
1
ans =
-40.3370 -39.9248i
ans =
-38.6038 -39.4498i
  1 commentaire
Walter Roberson
Walter Roberson le 4 Oct 2013
check class(xxx) and class(bData) and class(mData)

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Fourier Analysis and Filtering dans Help Center et File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by