Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

FFT in a single C-file [closed]

Tags:

c

fft

I was looking for a FFT implementation in C. However, I am not looking for a huge library (like FFTW) but for a easy to use single C-file implementation. Unfortunately I haven't been able to find anything like this.

Can someone recommend a simple implementation?

like image 256
mijc Avatar asked Jan 10 '12 09:01

mijc


People also ask

What is Kiss FFT?

KISS FFT - A mixed-radix Fast Fourier Transform based up on the principle, "Keep It Simple, Stupid." There are many great fft libraries already around. Kiss FFT is not trying to be better than any of them.

How do you calculate FFT of a signal?

Y = fft( X ) computes the discrete Fourier transform (DFT) of X using a fast Fourier transform (FFT) algorithm. If X is a vector, then fft(X) returns the Fourier transform of the vector. If X is a matrix, then fft(X) treats the columns of X as vectors and returns the Fourier transform of each column.

How does an FFT work?

The FFT operates by decomposing an N point time domain signal into N time domain signals each composed of a single point. The second step is to calculate the N frequency spectra corresponding to these N time domain signals. Lastly, the N spectra are synthesized into a single frequency spectrum. separate stages.


1 Answers

Your best bet is KissFFT - as its name implies it's simple, but it's still quite respectably fast, and a lot more lightweight than FFTW. It's also free, wheras FFTW requires a hefty licence fee if you want to include it in a commercial product.

like image 78
Paul R Avatar answered Oct 30 '22 04:10

Paul R