iRoCS Toolbox  1.1.0
Data Structures | Public Types | Public Member Functions | Static Public Member Functions | Friends
BlitzFFTW< DataT > Class Template Reference

#include <BlitzFFTW.hh>

Collaboration diagram for BlitzFFTW< DataT >:

Public Types

typedef BlitzFFTWPlan< DataT >::real_fftw_plan blitz_fftw_plan
 
enum  DataPreservePolicy { PRESERVE, OVERWRITE }
 
enum  PaddingType { VALUE, REPEATBORDER, MIRRORBORDER, CYCLICBORDER }
 

Public Member Functions

template<int Dim>
void backward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< DataT, Dim > &out, const DataPreservePolicy policy=PRESERVE) const
 Use this method for the actual complex2real transform. More...
 
template<int Dim>
void backward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE) const
 Use this method for the actual complex2complex back transform. More...
 
template<int Dim>
void exec_guru_plan (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, blitz_fftw_plan plan, const DataPreservePolicy policy=PRESERVE) const
 
template<int Dim>
void exec_guru_plan_c2r (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< DataT, Dim > &out, blitz_fftw_plan plan, const DataPreservePolicy policy=PRESERVE) const
 
template<int Dim>
void exec_guru_plan_r2c (blitz::Array< DataT, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, blitz_fftw_plan plan, const DataPreservePolicy policy=PRESERVE) const
 
template<int Dim>
void forward (const blitz::Array< DataT, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out) const
 Use this method for the actual real2complex transform. More...
 
template<int Dim>
void forward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out) const
 Use this method for the actual complex2complex forward transform. More...
 
template<int Dim>
blitz_fftw_plan get_plan_backward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< DataT, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 
template<int Dim>
blitz_fftw_plan get_plan_backward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 
template<int Dim>
blitz_fftw_plan get_plan_forward (blitz::Array< DataT, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 
template<int Dim>
blitz_fftw_plan get_plan_forward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 
template<int Dim, typename IndexT >
blitz::TinyVector< IndexT, Dim > getPaddedShape (const blitz::TinyVector< IndexT, Dim > &minimumExtents) const
 If you need to know the extents of a padded dataset without actually padding the data, you can use this lookup function that returns the shape vector that would result if an Array of the given shape would be padded using the pad method. More...
 
template<>
BlitzFFTW< float > * instance ()
 
template<>
BlitzFFTW< double > * instance ()
 
void loadWisdom ()
 Loads the local user/system wisdom. More...
 
template<int Dim, typename IndexT >
void pad (const blitz::Array< DataT, Dim > &in, blitz::Array< DataT, Dim > &out, blitz::TinyVector< IndexT, Dim > &lb, blitz::TinyVector< IndexT, Dim > &ub, const blitz::TinyVector< IndexT, Dim > &minimumExtents=IndexT(0), const PaddingType paddingMode=VALUE, const DataT paddingValue=static_cast< DataT >(0)) const
 Pads the given blitz::Array to Array-Extents that are suitable for fast FFT calculation. More...
 
template<int Dim, typename IndexT >
void pad (const blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, blitz::TinyVector< IndexT, Dim > &lb, blitz::TinyVector< IndexT, Dim > &ub, const blitz::TinyVector< IndexT, Dim > &minimumExtents=IndexT(0), const PaddingType paddingMode=VALUE, const std::complex< DataT > paddingValue=static_cast< std::complex< DataT > >(0)) const
 Pads the given complex blitz::Array to Array-Extents that are suitable for fast FFT calculation. More...
 
template<int Dim>
void plan_backward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< DataT, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided. More...
 
template<int Dim>
void plan_backward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided. More...
 
template<int Dim>
void plan_forward (blitz::Array< DataT, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided. More...
 
template<int Dim>
void plan_forward (blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const DataPreservePolicy policy=PRESERVE, const unsigned int plan_flags=FFTW_MEASURE) const
 Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided. More...
 
void saveWisdom () const
 Saves the local user wisdom. More...
 
template<int Dim>
void translate (const blitz::Array< DataT, Dim > &data, blitz::Array< DataT, Dim > &dataTrans, const BlitzIndexT t, const int d) const
 
template<int Dim>
void translate (const blitz::Array< DataT, Dim > &data, blitz::Array< DataT, Dim > &dataTrans, const blitz::TinyVector< BlitzIndexT, Dim > &t) const
 
template<int Dim, typename IndexT >
void unpad (const blitz::Array< DataT, Dim > &in, blitz::Array< DataT, Dim > &out, const blitz::TinyVector< IndexT, Dim > &lb, const blitz::TinyVector< IndexT, Dim > &ub) const
 Unpads the given blitz::Array using the Range corners provided. More...
 
template<int Dim, typename IndexT >
void unpad (const blitz::Array< std::complex< DataT >, Dim > &in, blitz::Array< std::complex< DataT >, Dim > &out, const blitz::TinyVector< IndexT, Dim > &lb, const blitz::TinyVector< IndexT, Dim > &ub) const
 Unpads the given complex blitz::Array using the Range corners provided. More...
 
template<int Dim>
void unShuffle (const blitz::Array< DataT, Dim > &in, blitz::Array< DataT, Dim > &out) const
 Reorder the Array such that the original order is reconstructed. More...
 

Static Public Member Functions

static void clear ()
 Deletes the BlitzFFTW Singleton Object and frees all associated resources. More...
 
static BlitzFFTWinstance ()
 Get a handle to the Singleton BlitzFFTW Object. More...
 
static size_t nextBestFFTSize (const size_t size)
 Return the next best size (>= the given) for a FFT. More...
 
static const std::set< size_t > & nextBestFFTSizes ()
 
static size_t prevBestFFTSize (const size_t size)
 

Friends

class BlitzFFTWDestructor
 

Detailed Description

template<typename DataT>
class BlitzFFTW< DataT >

Definition at line 75 of file BlitzFFTW.hh.

Member Typedef Documentation

◆ blitz_fftw_plan

template<typename DataT>
typedef BlitzFFTWPlan<DataT>::real_fftw_plan BlitzFFTW< DataT >::blitz_fftw_plan

Definition at line 78 of file BlitzFFTW.hh.

Member Enumeration Documentation

◆ PaddingType

template<typename DataT>
enum BlitzFFTW::PaddingType
Enumerator
VALUE 
REPEATBORDER 
MIRRORBORDER 
CYCLICBORDER 

Definition at line 80 of file BlitzFFTW.hh.

◆ DataPreservePolicy

template<typename DataT>
enum BlitzFFTW::DataPreservePolicy
Enumerator
PRESERVE 
OVERWRITE 

Definition at line 81 of file BlitzFFTW.hh.

Member Function Documentation

◆ instance() [1/3]

template<typename DataT>
static BlitzFFTW* BlitzFFTW< DataT >::instance ( )
static

Get a handle to the Singleton BlitzFFTW Object.

If no instance exists so far a new one will be created and the User/System Wisdom will be loaded

Parameters
policyThe value of this enum decides how the library handles given Arrays: PRESERVE - The contents of the input Arrays are preserved under all circumstances. If necessary copies are allocated, leading to up to doubled memory consumption. OVERWRITE - The library may overwrite given Arrays as needed to avoid additional memory usage. This means, that plan() above ESTIMATE-mode will alter the input and output Array. All data will be lost after planning. execute() in c2r-Mode (backward transform) overwrites the complex input Array.
Returns
A pointer to the Singleton BlitzFFTW Object

◆ clear()

template<typename DataT>
static void BlitzFFTW< DataT >::clear ( )
static

Deletes the BlitzFFTW Singleton Object and frees all associated resources.

Before removing the fftw data, the user wisdom will be updated

◆ loadWisdom()

template<typename DataT>
void BlitzFFTW< DataT >::loadWisdom ( )

Loads the local user/system wisdom.

This function is called by the Singleton-Constructor. There is normally no need to call it explicitly.

◆ saveWisdom()

template<typename DataT>
void BlitzFFTW< DataT >::saveWisdom ( ) const

Saves the local user wisdom.

If you used hours for plan computation and don't want to waste that time again, save the plans to the wisdom file using this method. If you're done with FFT calculation you can call clear() instead. Additional to saving the wisdom it also frees used fftw resources.

◆ getPaddedShape()

template<typename DataT>
template<int Dim, typename IndexT >
blitz::TinyVector<IndexT,Dim> BlitzFFTW< DataT >::getPaddedShape ( const blitz::TinyVector< IndexT, Dim > &  minimumExtents) const

If you need to know the extents of a padded dataset without actually padding the data, you can use this lookup function that returns the shape vector that would result if an Array of the given shape would be padded using the pad method.

This is useful if you need to plan a new set of fft's using the plan method.

IndexT should be BlitzIndexT. Templatization is only provided for backward compatibility to the old int indexing

Parameters
minimumExtentsThe extents for which an FFTW-optimal pad should be computed
Returns
The shape of the padded version of an Array of shape minimumExtents

◆ pad() [1/2]

template<typename DataT>
template<int Dim, typename IndexT >
void BlitzFFTW< DataT >::pad ( const blitz::Array< DataT, Dim > &  in,
blitz::Array< DataT, Dim > &  out,
blitz::TinyVector< IndexT, Dim > &  lb,
blitz::TinyVector< IndexT, Dim > &  ub,
const blitz::TinyVector< IndexT, Dim > &  minimumExtents = IndexT(0),
const PaddingType  paddingMode = VALUE,
const DataT  paddingValue = static_cast< DataT >(0) 
) const

Pads the given blitz::Array to Array-Extents that are suitable for fast FFT calculation.

The padding strategy can be selected.

IndexT should be BlitzIndexT. Templatization is only provided for backward compatibility to the old int indexing

Parameters
inThe Array to get a padded version of
outThe Array padded data will be returned in. You can give the same Array for in and out
lbReturns the upper left corner of the data Range in the padded Array
ubReturns the lower right corner of the data Range in the padded Array
minimumExtentsThe Array will be padded to at least these extents
paddingModeSwitches the padding behavior. At the moment four modes are implemented:
  • VALUE - Pads the Array with the fixed value provided in paddingValue
  • REPEATBORDER - Fills the Pad with the values of the nearest data points
  • MIRRORBORDER - Fills the Pad with the values of the mirrored data points
  • CYCLICBORDER - Fills the Pad with the values of the cyclicly continued array
paddingValueIn padding mode VALUE, the Array will be padded using this fixed value

◆ pad() [2/2]

template<typename DataT>
template<int Dim, typename IndexT >
void BlitzFFTW< DataT >::pad ( const blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
blitz::TinyVector< IndexT, Dim > &  lb,
blitz::TinyVector< IndexT, Dim > &  ub,
const blitz::TinyVector< IndexT, Dim > &  minimumExtents = IndexT(0),
const PaddingType  paddingMode = VALUE,
const std::complex< DataT >  paddingValue = static_cast< std::complex< DataT > >(0) 
) const

Pads the given complex blitz::Array to Array-Extents that are suitable for fast FFT calculation.

The padding strategy can be selected.

IndexT should be BlitzIndexT. Templatization is only provided for backward compatibility to the old int indexing

Parameters
inThe Array to get a padded version of
outThe Array padded data will be returned in. You can give the same Array for in and out
lbReturns the upper left corner of the data Range in the padded Array
ubReturns the lower right corner of the data Range in the padded Array
minimumExtentsThe Array will be padded to at least these extents
paddingModeSwitches the padding behavior. At the moment four modes are implemented:
  • VALUE - Pads the Array with the fixed value provided in paddingValue
  • REPEATBORDER - Fills the Pad with the values of the nearest data points
  • MIRRORBORDER - Fills the Pad with the values of the mirrored data points
  • CYCLICBORDER - Fills the Pad with the values of the cyclicly continued array
paddingValueIn padding mode VALUE, the Array will be padded using this fixed value

◆ unpad() [1/2]

template<typename DataT>
template<int Dim, typename IndexT >
void BlitzFFTW< DataT >::unpad ( const blitz::Array< DataT, Dim > &  in,
blitz::Array< DataT, Dim > &  out,
const blitz::TinyVector< IndexT, Dim > &  lb,
const blitz::TinyVector< IndexT, Dim > &  ub 
) const

Unpads the given blitz::Array using the Range corners provided.

IndexT should be BlitzIndexT. Templatization is only provided for backward compatibility to the old int indexing

Parameters
inThe Array to unpad
outThe Array unpadded data will be returned in. You can give the same Array for in and out
lbThe upper left corner of the data Range to retrieve
ubThe lower right corner of the data Range to retrieve

◆ unpad() [2/2]

template<typename DataT>
template<int Dim, typename IndexT >
void BlitzFFTW< DataT >::unpad ( const blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const blitz::TinyVector< IndexT, Dim > &  lb,
const blitz::TinyVector< IndexT, Dim > &  ub 
) const

Unpads the given complex blitz::Array using the Range corners provided.

IndexT should be BlitzIndexT. Templatization is only provided for backward compatibility to the old int indexing

Parameters
inThe Array to unpad
outThe Array unpadded data will be returned in. You can give the same Array for in and out
lbThe upper left corner of the data Range to retrieve
ubThe lower right corner of the data Range to retrieve

◆ plan_forward() [1/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::plan_forward ( blitz::Array< DataT, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided.

If there already exists a plan (either through former ffts or from a wisdom file), it will be used, otherwise a new plan will be computed. This is the version for forward FFT real to complex

Parameters
inblitz++-Array containing real valued data entries. The contents are irrelevant, it only has to be given with the correct extents. In fact, the Array should not be initialized, because depending on the planning mode data will be overwritten!
outA blitz++-Array containing complex-valued data entries. It's extents should be equal to the extents of the input Array except for the last Dimension, which should be out[Dim - 1] = in[Dim - 1] / 2 + 1.
plan_flagsWith these flags you can customize the planning mode Usually planning is performed in exhaustive mode allowing destruction of the input data array. Possible flags are: FFTW_ESTIMATE (fastest, but may yield bad transform performance) FFTW_MEASURE (slower, medium transform performance) FFTW_PATIENT (even slower, slightly better transform performance) FFTW_EXHAUSTIVE (slowest, guarantees best transform performance)

◆ plan_backward() [1/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::plan_backward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< DataT, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided.

If there already exists a plan (either through former ffts or from a wisdom file), it will be used, otherwise a new plan will be computed. This is the version for backward FFT complex to real

Parameters
inA blitz++-Array containing complex-valued data entries. The contents are irrelevant, it only has to be given with the correct extents. In fact, the Array should not be initialized, because depending on the planning mode data will be overwritten!
outblitz++-Array containing real valued data entries. It's extents should be equal to the extents of the input Array except for the last Dimension, which should be out[Dim - 1] = (in[Dim - 1] - 1) * 2.
plan_flagsWith these flags you can customize the planning mode Usually planning is performed in exhaustive mode allowing destruction of the input data array. Possible flags are: FFTW_ESTIMATE (fastest, but may yield bad transform performance) FFTW_MEASURE (slower, medium transform performance) FFTW_PATIENT (even slower, slightly better transform performance) FFTW_EXHAUSTIVE (slowest, guarantees best transform performance)

◆ plan_forward() [2/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::plan_forward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided.

If there already exists a plan (either through former ffts or from a wisdom file), it will be used, otherwise a new plan will be computed. This is the version for backward FFT complex to real

Parameters
inA blitz++-Array containing complex-valued data entries. The contents are irrelevant, it only has to be given with the correct extents. In fact, the Array should not be initialized, because depending on the planning mode data will be overwritten!
outblitz++-Array containing complex-valued data entries. It's extents should be equal to the extents of the input Array.
plan_flagsWith these flags you can customize the planning mode Usually planning is performed in exhaustive mode allowing destruction of the input data array. Possible flags are: FFTW_ESTIMATE (fastest, but may yield bad transform performance) FFTW_MEASURE (slower, medium transform performance) FFTW_PATIENT (even slower, slightly better transform performance) FFTW_EXHAUSTIVE (slowest, guarantees best transform performance)

◆ get_plan_forward() [1/2]

template<typename DataT>
template<int Dim>
blitz_fftw_plan BlitzFFTW< DataT >::get_plan_forward ( blitz::Array< DataT, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

◆ get_plan_forward() [2/2]

template<typename DataT>
template<int Dim>
blitz_fftw_plan BlitzFFTW< DataT >::get_plan_forward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

◆ plan_backward() [2/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::plan_backward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

Use this method to compute a new fftw Plan, for execution of a transform of a pair of Arrays of the extents provided.

If there already exists a plan (either through former ffts or from a wisdom file), it will be used, otherwise a new plan will be computed. This is the version for backward FFT complex to real

Parameters
inA blitz++-Array containing complex-valued data entries. The contents are irrelevant, it only has to be given with the correct extents. In fact, the Array should not be initialized, because depending on the planning mode data will be overwritten!
outblitz++-Array containing complex-valued data entries. It's extents should be equal to the extents of the input Array.
plan_flagsWith these flags you can customize the planning mode Usually planning is performed in exhaustive mode allowing destruction of the input data array. Possible flags are: FFTW_ESTIMATE (fastest, but may yield bad transform performance) FFTW_MEASURE (slower, medium transform performance) FFTW_PATIENT (even slower, slightly better transform performance) FFTW_EXHAUSTIVE (slowest, guarantees best transform performance)

◆ get_plan_backward() [1/2]

template<typename DataT>
template<int Dim>
blitz_fftw_plan BlitzFFTW< DataT >::get_plan_backward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< DataT, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

◆ get_plan_backward() [2/2]

template<typename DataT>
template<int Dim>
blitz_fftw_plan BlitzFFTW< DataT >::get_plan_backward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE,
const unsigned int  plan_flags = FFTW_MEASURE 
) const

◆ forward() [1/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::forward ( const blitz::Array< DataT, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out 
) const

Use this method for the actual real2complex transform.

Before transformation a plan is selected. If no plan for the current Array- combination exists it will be computed using the FFTW_ESTIMATE method. If you want to do many transforms with Arrays of the same shape it is highly recommended to use fftPlan() once before. This is the forward transform real to complex.

Parameters
inThe input data Array containing the float data to transform
outThe complex output Array, the transform will be written to

◆ forward() [2/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::forward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out 
) const

Use this method for the actual complex2complex forward transform.

Before transformation a plan is selected. If no plan for the current Array-combination exists it will be computed using the FFTW_ESTIMATE method. If you want to do many transforms with Arrays of the same shape it is highly recommended to use fftPlan() once before. This is the forward transform real to complex.

Parameters
inThe input data Array containing the float data to transform
outThe complex output Array, the transform will be written to

◆ backward() [1/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::backward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< DataT, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE 
) const

Use this method for the actual complex2real transform.

Before transformation a plan is selected. If no plan for the current Array- combination exists it will be computed using the FFTW_ESTIMATE method. If you want to do many transforms with Arrays of the same shape it is highly recommended to use fftPlan() once before. This is the backward transform complex to real.

Parameters
inThe complex input Array containing the FFT to transform back
outThe float array to save the back transformed data into

◆ backward() [2/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::backward ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
const DataPreservePolicy  policy = PRESERVE 
) const

Use this method for the actual complex2complex back transform.

Before transformation a plan is selected. If no plan for the current Array-combination exists it will be computed using the FFTW_ESTIMATE method. If you want to do many transforms with Arrays of the same shape it is highly recommended to use fftPlan() once before. This is the backward transform complex to real.

Parameters
inThe complex input Array containing the FFT to transform back
outThe float array to save the back transformed data into

◆ exec_guru_plan()

template<typename DataT>
template<int Dim>
template void BlitzFFTW< DataT >::exec_guru_plan ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
blitz_fftw_plan  plan,
const DataPreservePolicy  policy = PRESERVE 
) const

◆ exec_guru_plan_r2c()

template<typename DataT>
template<int Dim>
template void BlitzFFTW< DataT >::exec_guru_plan_r2c ( blitz::Array< DataT, Dim > &  in,
blitz::Array< std::complex< DataT >, Dim > &  out,
blitz_fftw_plan  plan,
const DataPreservePolicy  policy = PRESERVE 
) const

◆ exec_guru_plan_c2r()

template<typename DataT>
template<int Dim>
template void BlitzFFTW< DataT >::exec_guru_plan_c2r ( blitz::Array< std::complex< DataT >, Dim > &  in,
blitz::Array< DataT, Dim > &  out,
blitz_fftw_plan  plan,
const DataPreservePolicy  policy = PRESERVE 
) const

◆ unShuffle()

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::unShuffle ( const blitz::Array< DataT, Dim > &  in,
blitz::Array< DataT, Dim > &  out 
) const

Reorder the Array such that the original order is reconstructed.

This is needed after a fftw forward/backward-transform, because the ordering is destroyed when computing fftws.

Parameters
inThe input Array containing the FFT to unshuffle
outThe float array to save the unshuffled data into

◆ nextBestFFTSize()

template<typename DataT>
static size_t BlitzFFTW< DataT >::nextBestFFTSize ( const size_t  size)
static

Return the next best size (>= the given) for a FFT.

Parameters
inThe size of the data you want to transform
outThe next bigger size that the fftw performs well for

◆ prevBestFFTSize()

template<typename DataT>
static size_t BlitzFFTW< DataT >::prevBestFFTSize ( const size_t  size)
static

◆ nextBestFFTSizes()

template<typename DataT>
static const std::set<size_t>& BlitzFFTW< DataT >::nextBestFFTSizes ( )
static

◆ translate() [1/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::translate ( const blitz::Array< DataT, Dim > &  data,
blitz::Array< DataT, Dim > &  dataTrans,
const BlitzIndexT  t,
const int  d 
) const

◆ translate() [2/2]

template<typename DataT>
template<int Dim>
void BlitzFFTW< DataT >::translate ( const blitz::Array< DataT, Dim > &  data,
blitz::Array< DataT, Dim > &  dataTrans,
const blitz::TinyVector< BlitzIndexT, Dim > &  t 
) const

◆ instance() [2/3]

template<>
BlitzFFTW< float > * BlitzFFTW< float >::instance ( )

◆ instance() [3/3]

template<>
BlitzFFTW< double > * BlitzFFTW< double >::instance ( )

Friends And Related Function Documentation

◆ BlitzFFTWDestructor

template<typename DataT>
friend class BlitzFFTWDestructor
friend

Definition at line 636 of file BlitzFFTW.hh.


The documentation for this class was generated from the following files: