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

lti::cartesianToPolar< T > Class Template Reference

Computes the elements of the polar coordinate system (value,phase) based on the parameters of the cartesian coordinate system (x,y). More...

#include <ltiCartesianToPolar.h>

Inheritance diagram for lti::cartesianToPolar< T >:
Inheritance graph
[legend]
Collaboration diagram for lti::cartesianToPolar< T >:
Collaboration graph
[legend]

List of all members.

Classes

class  parameters
 the parameters for the class cartesianToPolar More...

Public Types

typedef T value_type

Public Member Functions

 cartesianToPolar ()
 cartesianToPolar (const parameters &thePars)
 cartesianToPolar (bool useLUT)
 cartesianToPolar (const cartesianToPolar &other)
virtual ~cartesianToPolar ()
virtual const char * getTypeName () const
bool apply (matrix< T > &r_abs, matrix< T > &i_ph)
bool apply (vector< T > &r_abs, vector< T > &i_ph)
bool apply (const matrix< T > &real, const matrix< T > &imaginary, matrix< T > &absvalue, matrix< T > &phase)
bool apply (const vector< T > &real, const vector< T > &imaginary, vector< T > &absvalue, vector< T > &phase)
bool apply (const tpointList< T > &src, tpointList< double > &dest, const tpoint< double > origin=tpoint< double >(0.0, 0.0)) const
cartesianToPolarcopy (const cartesianToPolar &other)
virtual functorclone () const
const parametersgetParameters () const

Detailed Description

template<class T>
class lti::cartesianToPolar< T >

Computes the elements of the polar coordinate system (value,phase) based on the parameters of the cartesian coordinate system (x,y).


Member Typedef Documentation

template<class T >
typedef T lti::cartesianToPolar< T >::value_type

value type of the used matrices


Constructor & Destructor Documentation

template<class T >
lti::cartesianToPolar< T >::cartesianToPolar (  ) 

default constructor

template<class T >
lti::cartesianToPolar< T >::cartesianToPolar ( const parameters thePars  ) 

constructor with parameters

template<class T >
lti::cartesianToPolar< T >::cartesianToPolar ( bool  useLUT  ) 

constructor which uses the arctan lookup table if its argument is true

template<class T >
lti::cartesianToPolar< T >::cartesianToPolar ( const cartesianToPolar< T > &  other  ) 

copy constructor

Parameters:
other the object to be copied
template<class T >
virtual lti::cartesianToPolar< T >::~cartesianToPolar (  )  [virtual]

destructor


Member Function Documentation

template<class T >
bool lti::cartesianToPolar< T >::apply ( const tpointList< T > &  src,
tpointList< double > &  dest,
const tpoint< double >  origin = tpoint< double >(0.0, 0.0) 
) const

operates on a copy of the given parameters.

When this apply is invoked the Arctan Lookup Table is not used regardless of the useLUT parameter.

Parameters:
src list of points with the cartesian data.
dest resulting list, in which the points contains in their member x the magnitude (or radius) and the angle in the y.
origin optional parameter which gives the position considered as origin for the cartesic-polar conversion
template<class T >
bool lti::cartesianToPolar< T >::apply ( const vector< T > &  real,
const vector< T > &  imaginary,
vector< T > &  absvalue,
vector< T > &  phase 
)

operates on a copy of the given parameters.

If the source matrices have different sizes, the returned data will be empty.

Parameters:
real vector with the real part of the source data.
imaginary vector the imaginary part of the source data.
absvalue absolute value of the input data.
phase phase of the input data.
template<class T >
bool lti::cartesianToPolar< T >::apply ( const matrix< T > &  real,
const matrix< T > &  imaginary,
matrix< T > &  absvalue,
matrix< T > &  phase 
)

operates on a copy of the given parameters.

If the source matrices have different sizes, the returned data will be empty.

Parameters:
real matrix<T> with the real source data.
imaginary matrix<T> the imaginary source data.
absvalue absolute value of the input data.
phase phase of the input data.
template<class T >
bool lti::cartesianToPolar< T >::apply ( vector< T > &  r_abs,
vector< T > &  i_ph 
)

operates on the given parameter.

Parameters:
r_abs the real part of the source data (magnitude will be left here).
i_ph the imaginary part of the source data (phase will be left here).
template<class T >
bool lti::cartesianToPolar< T >::apply ( matrix< T > &  r_abs,
matrix< T > &  i_ph 
)

operates on the given parameter.

Parameters:
r_abs the real part of the source data (magnitude will be left here).
i_ph the imaginary part of the source data (phase will be left here).
template<class T >
virtual functor* lti::cartesianToPolar< T >::clone (  )  const [virtual]

returns a pointer to a clone of this functor.

Implements lti::functor.

template<class T >
cartesianToPolar& lti::cartesianToPolar< T >::copy ( const cartesianToPolar< T > &  other  ) 

copy data of "other" functor.

Parameters:
other the functor to be copied
Returns:
a reference to this functor object

Reimplemented from lti::functor.

template<class T >
const parameters& lti::cartesianToPolar< T >::getParameters (  )  const

returns used parameters

Reimplemented from lti::transform.

template<class T >
virtual const char* lti::cartesianToPolar< T >::getTypeName (  )  const [virtual]

returns the name of this type ("cartesianToPolar")

Reimplemented from lti::transform.


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

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