[clean-list] FFT with Clean

eli+@gs211.sp.cs.cmu.edu eli+@gs211.sp.cs.cmu.edu
Mon, 6 Nov 2000 12:24:30 -0500 (EST)


Siegfried Gonzi wrote:
> So, now comes my problem: what in hell is the Start code doing:
> 
> Start:: {#Real}
> Start= {xx.[i] \\i<- [1..8]}
> where
>     xx= FFT delta
>     delta = {x \\ x <- ([1.0]++(repeatn 4095 0.0))}
> 
> 
> What should that suspected '4095' mean? What say me the above code: I get
> an array with 8 members, where every member is the result of the FFT from
> values ranging from 1,0,0,...0,0,0 (until 4095 zeros) ?
> FFT {1.0,0.0,0.0,0.0,0.0...0.0} and that 8 times? I cannot cope with
> that.

The 4095 is presumably because the FFT routine is radix-2 and wants
power-of-two sizes.

That code generates a 4096-element test input, and takes its
real-to-real FFT.  It then extracts the second through ninth elements
of the result.  Each element is expected to be equal to 1.

(You can think of this as taking the transform of a delta function to
get constant 1, though really there are sampling comb functions
complicating matters.)

-- 
     Eli Brandt  |  eli+@cs.cmu.edu  |  http://www.cs.cmu.edu/~eli/