Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: FFTW 3.3.5: Real-data DFTs Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42:
Chris@42:

Chris@42: Next: , Previous: , Up: Basic Interface   [Contents][Index]

Chris@42:
Chris@42:
Chris@42: Chris@42:

4.3.3 Real-data DFTs

Chris@42: Chris@42:
Chris@42:
fftw_plan fftw_plan_dft_r2c_1d(int n0,
Chris@42:                                double *in, fftw_complex *out,
Chris@42:                                unsigned flags);
Chris@42: fftw_plan fftw_plan_dft_r2c_2d(int n0, int n1,
Chris@42:                                double *in, fftw_complex *out,
Chris@42:                                unsigned flags);
Chris@42: fftw_plan fftw_plan_dft_r2c_3d(int n0, int n1, int n2,
Chris@42:                                double *in, fftw_complex *out,
Chris@42:                                unsigned flags);
Chris@42: fftw_plan fftw_plan_dft_r2c(int rank, const int *n,
Chris@42:                             double *in, fftw_complex *out,
Chris@42:                             unsigned flags);
Chris@42: 
Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42:

Plan a real-input/complex-output discrete Fourier transform (DFT) in Chris@42: zero or more dimensions, returning an fftw_plan (see Using Plans). Chris@42:

Chris@42:

Once you have created a plan for a certain transform type and Chris@42: parameters, then creating another plan of the same type and parameters, Chris@42: but for different arrays, is fast and shares constant data with the Chris@42: first plan (if it still exists). Chris@42:

Chris@42:

The planner returns NULL if the plan cannot be created. A Chris@42: non-NULL plan is always returned by the basic interface unless Chris@42: you are using a customized FFTW configuration supporting a restricted Chris@42: set of transforms, or if you use the FFTW_PRESERVE_INPUT flag Chris@42: with a multi-dimensional out-of-place c2r transform (see below). Chris@42:

Chris@42: Chris@42:

Arguments

Chris@42: Chris@42: Chris@42:

The inverse transforms, taking complex input (storing the non-redundant Chris@42: half of a logically Hermitian array) to real output, are given by: Chris@42:

Chris@42:
Chris@42:
fftw_plan fftw_plan_dft_c2r_1d(int n0,
Chris@42:                                fftw_complex *in, double *out,
Chris@42:                                unsigned flags);
Chris@42: fftw_plan fftw_plan_dft_c2r_2d(int n0, int n1,
Chris@42:                                fftw_complex *in, double *out,
Chris@42:                                unsigned flags);
Chris@42: fftw_plan fftw_plan_dft_c2r_3d(int n0, int n1, int n2,
Chris@42:                                fftw_complex *in, double *out,
Chris@42:                                unsigned flags);
Chris@42: fftw_plan fftw_plan_dft_c2r(int rank, const int *n,
Chris@42:                             fftw_complex *in, double *out,
Chris@42:                             unsigned flags);
Chris@42: 
Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42:

The arguments are the same as for the r2c transforms, except that the Chris@42: input and output data formats are reversed. Chris@42:

Chris@42:

FFTW computes an unnormalized transform: computing an r2c followed by a Chris@42: c2r transform (or vice versa) will result in the original data Chris@42: multiplied by the size of the transform (the product of the logical Chris@42: dimensions). Chris@42: Chris@42: An r2c transform produces the same output as a FFTW_FORWARD Chris@42: complex DFT of the same input, and a c2r transform is correspondingly Chris@42: equivalent to FFTW_BACKWARD. For more information, see What FFTW Really Computes. Chris@42:

Chris@42:
Chris@42:
Chris@42:

Chris@42: Next: , Previous: , Up: Basic Interface   [Contents][Index]

Chris@42:
Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: