CVR-Lib last update 20 Sep 2009

cvr::qrSolution< T > Class Template Reference
[-LibFormatRequired Classes imported from the LTI-Lib-1.]

QR solution functor. More...

#include <cvrQrSolution.h>

Inheritance diagram for cvr::qrSolution< T >:

Inheritance graph
[legend]
Collaboration diagram for cvr::qrSolution< T >:

Collaboration graph
[legend]

List of all members.

Classes

class  parameters
 qrSolution parameter class More...

Public Member Functions

 qrSolution ()
 qrSolution (const qrSolution &other)
 qrSolution (const parameters &theParams)
 qrSolution (const matrix< T > &theMatrix)
const parametersgetParameters () const
double apply (vector< T > &b)
double apply (const vector< T > &b, vector< T > &x)
qrSolutioncopy (const qrSolution &other)
const std::string & name () const
virtual qrSolutionclone () const
virtual qrSolutionnewInstance () const

Protected Attributes

vector< double > dcmpVec_
vector< double > helpVec_


Detailed Description

template<class T>
class cvr::qrSolution< T >

QR solution functor.

Solves the linear equation Ax=b as a least-squares problem using QR decomposition A=QR (Householder transformation) of the given (m,n)-matrix A.

See also:
decompositionSolution::parameters

Constructor & Destructor Documentation

template<class T >
cvr::qrSolution< T >::qrSolution (  ) 

default constructor

template<class T >
cvr::qrSolution< T >::qrSolution ( const qrSolution< T > &  other  ) 

copy constructor

template<class T >
cvr::qrSolution< T >::qrSolution ( const parameters theParams  ) 

constructor, sets the parameters

template<class T >
cvr::qrSolution< T >::qrSolution ( const matrix< T > &  theMatrix  ) 

constructor, sets the matrix A


Member Function Documentation

template<class T >
double cvr::qrSolution< T >::apply ( const vector< T > &  b,
vector< T > &  x 
)

Apply on copy.

Solves the least-squares problem Ax=b and returns the residuum if computeResiduum==true.

WARNING: For use with multiple right sides b of a set of equation systems Ax=b, the matrix decomposition is computed only on calling apply() the first time. After that the existing decomposition will be used until calling setParameters().

template<class T >
double cvr::qrSolution< T >::apply ( vector< T > &  b  ) 

Apply on place.

Solves the least-squares problem Ax=b and returns the residuum if computeResiduum==true.

WARNING: For use with multiple right sides b of a set of equation systems Ax=b, the matrix decomposition is computed only on calling apply() the first time. After that the existing decomposition will be used until calling setParameters().

template<class T >
virtual qrSolution* cvr::qrSolution< T >::clone (  )  const [virtual]

Returns a pointer to a clone of this functor.

Implements cvr::functor.

template<class T >
qrSolution& cvr::qrSolution< T >::copy ( const qrSolution< T > &  other  ) 

Copy data of "other" functor.

template<class T >
const parameters& cvr::qrSolution< T >::getParameters (  )  const

returns the current parameters.

Reimplemented from cvr::decompositionSolution< T >.

template<class T >
const std::string& cvr::qrSolution< T >::name (  )  const [virtual]

Returns the name of this class.

Reimplemented from cvr::decompositionSolution< T >.

template<class T >
virtual qrSolution* cvr::qrSolution< T >::newInstance (  )  const [virtual]

Returns a pointer to a new instance of this functor.

Implements cvr::functor.


Member Data Documentation

template<class T >
vector<double> cvr::qrSolution< T >::dcmpVec_ [protected]

Decomposed vector.

template<class T >
vector<double> cvr::qrSolution< T >::helpVec_ [protected]

Helper vector.


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

Generated on Sun Sep 20 22:09:02 2009 for CVR-Lib by Doxygen 1.5.8