LTI-Lib latest version v1.9 - last update 10 Apr 2010

lti::realInvFFT Class Reference

A class for inverse FFT. More...

#include <ltiRealInvFFT.h>

Inheritance diagram for lti::realInvFFT:
Inheritance graph
[legend]
Collaboration diagram for lti::realInvFFT:
Collaboration graph
[legend]

List of all members.

Public Types

typedef realFFT::parameters parameters

Public Member Functions

 realInvFFT (void)
 ~realInvFFT (void)
const parametersgetParameters () const
virtual const char * getTypeName () const
virtual functorclone () const
void apply (const vector< float > &realInput, const vector< float > &imagInput, vector< float > &realOutput) const
void apply (const vector< double > &realInput, const vector< double > &imagInput, vector< double > &realOutput) const
void apply (const matrix< float > &realInput, const matrix< float > &imagInput, matrix< float > &realOutput) const

Detailed Description

A class for inverse FFT.

realFFT is a class for Fast Fourier Transforms on lti::vectors and lti::matrix<float>. The input can either be in polar or cartesic format, specified by the parameter inputMode. The FFT on matrix<float> works full-sized input matrices (i.e the size of the output data), while the vector FFT works only one half (!) of the Fourier coefficients per dimension (real and imaginary). Note that cartesic input data computes faster! The apply-methods are based on fast inverse FFT-routines written by Takuya Ooura (the original code can be found here) that have been adapted for the use on lti::vectors and matrix<float>. Note that the cartesic output is faster ! Usage:

  #include "ltiRealInvFFT.h"
  #include "ltiRealFFT.h"

  lti::realFFT fft2d;       // for 2-dimensional FFT
  lti::realInvFFT ifft2d;   // for 2-dimensional inverse FFT

  lti::realFFT::parameters par2d;

  par2d.mode = lti::realFFT::parameters::Polar;

  ifft2d.setParameters(par2d);
  fft2d.setParameters(par2d);


  fft2d.apply(R, re, im);       // the actual FFT

  ifft2d.apply(re, im, back);   // inverse FFT

Member Typedef Documentation

Parameter class of the realInvFFT class (are compatible with the parameters of the realFFT functor).


Constructor & Destructor Documentation

lti::realInvFFT::realInvFFT ( void   ) 

constructor

lti::realInvFFT::~realInvFFT ( void   ) 

detsructor


Member Function Documentation

void lti::realInvFFT::apply ( const matrix< float > &  realInput,
const matrix< float > &  imagInput,
matrix< float > &  realOutput 
) const

on-copy method for matrix<float>.

The input data has the half the size of the output data (i.e. only the positive coefficients are used). Note that the DC component of the signal is in the upper-left corner of the two-dimensional FFT. (corresponds to the FFT output)

Parameters:
realInput the real part of the Fourier coefficients (Polar or Cartesic), size n
imagInput the imaginary part of the Fourier coefficients (Polar or Cartesic), size n
realOutput the real inverse-computed signal, size n
void lti::realInvFFT::apply ( const vector< double > &  realInput,
const vector< double > &  imagInput,
vector< double > &  realOutput 
) const

on-copy method vor vectors.

The input data has the half the size of the output data (i.e. only the positive coefficients are used).

Parameters:
realInput the real part of the Fourier coefficients (Polar or Cartesic), size (n/2)+1
imagInput the imaginary part of the Fourier coefficients (Polar or Cartesic), size (n/2)+1
realOutput the real inverse-computed signal, size n
void lti::realInvFFT::apply ( const vector< float > &  realInput,
const vector< float > &  imagInput,
vector< float > &  realOutput 
) const

on-copy method vor vectors.

The input data has the half the size of the output data (i.e. only the positive coefficients are used).

Parameters:
realInput the real part of the Fourier coefficients (Polar or Cartesic), size (n/2)+1
imagInput the imaginary part of the Fourier coefficients (Polar or Cartesic), size (n/2)+1
realOutput the real inverse-computed signal, size n
virtual functor* lti::realInvFFT::clone (  )  const [virtual]

returns a pointer to a clone of the functor.

Implements lti::functor.

const parameters& lti::realInvFFT::getParameters (  )  const

returns current parameters.

Reimplemented from lti::transform.

virtual const char* lti::realInvFFT::getTypeName (  )  const [virtual]

returns the name of this type

Reimplemented from lti::transform.


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

Generated on Sat Apr 10 15:27:45 2010 for LTI-Lib by Doxygen 1.6.1