USGS

Isis 3.0 Object Programmers' Reference

Home

Isis::FourierTransform Class Reference

Fourier Transform class. More...

#include <FourierTransform.h>

Collaboration diagram for Isis::FourierTransform:
Collaboration graph

Public Member Functions

 FourierTransform ()
 Constructs the FourierTransform object.
 
 ~FourierTransform ()
 Destroys the FourierTransform object.
 
std::vector< std::complex
< double > > 
Transform (std::vector< std::complex< double > > input)
 Applies the Fourier transform on the input data and returns the result.
 
std::vector< std::complex
< double > > 
Inverse (std::vector< std::complex< double > > input)
 Applies the inverse Fourier transform on the input data and returns the result.
 
bool IsPowerOfTwo (int n)
 Checks to see if the input integer is a power of two.
 
int lg (int n)
 This function returns the floor of log2(n)
 
int BitReverse (int n, int x)
 Reverses the binary representation of the input integer in the number of bits specified.
 
int NextPowerOfTwo (int n)
 This function returns the next power of two greater than or equal to n.
 

Detailed Description

Fourier Transform class.

This class is used to apply a Fourier transform to a vector of complex

data as well as the inverse Fourier transform. Applying the Fourier transform on data in the spatial domain will convert it to data in the Fourier (or frequency) domain. The inverse transform takes data from the frequency domain to the spatial.

If you would like to see FourierTransform being used in implementation, see fft.cpp or ifft.cpp.

Author
2005-11-28 Jacob Danton

Definition at line 48 of file FourierTransform.h.

Constructor & Destructor Documentation

Isis::FourierTransform::FourierTransform ( )

Constructs the FourierTransform object.

Definition at line 29 of file FourierTransform.cpp.

Isis::FourierTransform::~FourierTransform ( )

Destroys the FourierTransform object.

Definition at line 32 of file FourierTransform.cpp.

Member Function Documentation

int Isis::FourierTransform::BitReverse ( int  n,
int  x 
)

Reverses the binary representation of the input integer in the number of bits specified.

bitReverse(n,x) = n/2*(2^-a1 + 2^-a2 + ... + 2^-ak) where x = 2^a1 + 2^a2 + ... + 2^ak

Parameters
nThe number of bits
xThe input integer
Returns
int - The reverse of the binary representation of the input integer

Definition at line 152 of file FourierTransform.cpp.

std::vector< std::complex< double > > Isis::FourierTransform::Inverse ( std::vector< std::complex< double > >  input)

Applies the inverse Fourier transform on the input data and returns the result.

Parameters
inputThe data to be transformed.
Returns
vector

Definition at line 90 of file FourierTransform.cpp.

bool Isis::FourierTransform::IsPowerOfTwo ( int  n)

Checks to see if the input integer is a power of two.

Parameters
nThe input integer
Returns
bool - Returns true if the input is a power of two and false if it is not

Definition at line 115 of file FourierTransform.cpp.

int Isis::FourierTransform::lg ( int  n)

This function returns the floor of log2(n)

Parameters
nThe input integer
Returns
int - the floor of log2(n)

Definition at line 131 of file FourierTransform.cpp.

int Isis::FourierTransform::NextPowerOfTwo ( int  n)

This function returns the next power of two greater than or equal to n.

If n is a power of two, it returns n.

Parameters
nThe number of bits
Returns
int - the next power of two greater than or equal to n

Definition at line 175 of file FourierTransform.cpp.

Referenced by Isis::ForstnerOperator::Interest().

std::vector< std::complex< double > > Isis::FourierTransform::Transform ( std::vector< std::complex< double > >  input)

Applies the Fourier transform on the input data and returns the result.

Parameters
inputThe data to be transformed.
Returns
vector

Definition at line 43 of file FourierTransform.cpp.

References Isis::PI().

Referenced by Isis::ForstnerOperator::Interest().


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