cannam@95: cannam@95:
cannam@95:cannam@95: Next: Guru Real-data DFTs, cannam@95: Previous: Guru vector and transform sizes, cannam@95: Up: Guru Interface cannam@95:
fftw_plan fftw_plan_guru_dft( cannam@95: int rank, const fftw_iodim *dims, cannam@95: int howmany_rank, const fftw_iodim *howmany_dims, cannam@95: fftw_complex *in, fftw_complex *out, cannam@95: int sign, unsigned flags); cannam@95: cannam@95: fftw_plan fftw_plan_guru_split_dft( cannam@95: int rank, const fftw_iodim *dims, cannam@95: int howmany_rank, const fftw_iodim *howmany_dims, cannam@95: double *ri, double *ii, double *ro, double *io, cannam@95: unsigned flags); cannam@95:cannam@95:
cannam@95: These two functions plan a complex-data, multi-dimensional DFT
cannam@95: for the interleaved and split format, respectively.
cannam@95: Transform dimensions are given by (rank, dims) over a
cannam@95: multi-dimensional vector (loop) of dimensions (howmany_rank,
cannam@95: howmany_dims). dims and howmany_dims should point
cannam@95: to fftw_iodim arrays of length rank and
cannam@95: howmany_rank, respectively.
cannam@95:
cannam@95:
flags is a bitwise OR (‘|’) of zero or more planner flags,
cannam@95: as defined in Planner Flags.
cannam@95:
cannam@95:
In the fftw_plan_guru_dft function, the pointers in and
cannam@95: out point to the interleaved input and output arrays,
cannam@95: respectively. The sign can be either -1 (=
cannam@95: FFTW_FORWARD) or +1 (= FFTW_BACKWARD). If the
cannam@95: pointers are equal, the transform is in-place.
cannam@95:
cannam@95:
In the fftw_plan_guru_split_dft function,
cannam@95: ri and ii point to the real and imaginary input arrays,
cannam@95: and ro and io point to the real and imaginary output
cannam@95: arrays. The input and output pointers may be the same, indicating an
cannam@95: in-place transform. For example, for fftw_complex pointers
cannam@95: in and out, the corresponding parameters are:
cannam@95:
cannam@95:
ri = (double *) in; cannam@95: ii = (double *) in + 1; cannam@95: ro = (double *) out; cannam@95: io = (double *) out + 1; cannam@95:cannam@95:
Because fftw_plan_guru_split_dft accepts split arrays, strides
cannam@95: are expressed in units of double. For a contiguous
cannam@95: fftw_complex array, the overall stride of the transform should
cannam@95: be 2, the distance between consecutive real parts or between
cannam@95: consecutive imaginary parts; see Guru vector and transform sizes. Note that the dimension strides are applied equally to the
cannam@95: real and imaginary parts; real and imaginary arrays with different
cannam@95: strides are not supported.
cannam@95:
cannam@95:
There is no sign parameter in fftw_plan_guru_split_dft.
cannam@95: This function always plans for an FFTW_FORWARD transform. To
cannam@95: plan for an FFTW_BACKWARD transform, you can exploit the
cannam@95: identity that the backwards DFT is equal to the forwards DFT with the
cannam@95: real and imaginary parts swapped. For example, in the case of the
cannam@95: fftw_complex arrays above, the FFTW_BACKWARD transform
cannam@95: is computed by the parameters:
cannam@95:
cannam@95:
ri = (double *) in + 1; cannam@95: ii = (double *) in; cannam@95: ro = (double *) out + 1; cannam@95: io = (double *) out; cannam@95:cannam@95: cannam@95: cannam@95: