Four1 problem


jejunoh
11-01-2003, 12:15 PM
Can someone post their results after putting in the follwing input to four1.

[0 1 2 3 4 5 6 7]

My matlab is giving me
28.0000
-4.0000 - 9.6569i
-4.0000 - 4.0000i
-4.0000 - 1.6569i
-4.0000
-4.0000 + 1.6569i
-4.0000 + 4.0000i
-4.0000 + 9.6569i

whereas my four1 is giving me
28.0000
-4.0000 - 9.6569i
-6.8284 - 4.0000i
-12.000 + 2.3431i
-4.0000
-4.0000 + 1.6569i
-1.1700 + 4.0000i
4.0000 + 5.6569i

As for inputting [0 1 2 3 4] both results from four1 and Matlab fft give the same answer.

kvanbrunt
02-10-2005, 03:32 PM
Here is what I get:

input: {0 1 2 3 4 5 6 7}
output:
12.0000 16.0000i
0. -8.00000i
-4.00000 -4.00000i
-8.00000 0.i


However, I've been having problems reproducing the FFT of a gaussian with four1.f