Hi, You should apply the 1D FFT for the columns and rows of the matrix. I can only give you an example code from a previous work (no longer actively developed): http://code.google.com/p/gico-lib/source/browse/src/fft.c?r=6a628e7c666b6051647d8cb69f8d9707c66ff96d
In particular, the function gico_fft_matrix() perform the 1D FFT to rows or columns on a given matrix. You could generate a similar function which performs the FFT on both columns and rows. There are plently of comments, so I guess the code should be clear (which does not mean it will be optimal or even correct :-( ). Good luck! *Alejandro Cámara* PhD Student of the GICO <http://www.ucm.es/info/giboucm/> 2011/5/23 Goo Creations <[email protected]> > Hi all, > > I know this question was answered sometime last year, but I can't figure > out > how to use 2D FFT. > > What I currently have > > *//4x4 array. Every i is real, every i+1 is imag > ** //This array is 16, because 4x4, and *2, because we have to store real > and imag* > > *double *a = new double[16*2]; > > gsl_fft_complex_radix2_forward(a, 1, 16); > * > > Now as far as I know, to solve 2D FFT, I must first do a column-based FFT > and then a row-based FFT (according to last years post). > How exactly will I do this, is there another function in GSL? > > Thanks for any help!! > _______________________________________________ > Help-gsl mailing list > [email protected] > https://lists.gnu.org/mailman/listinfo/help-gsl > _______________________________________________ Help-gsl mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-gsl
