TooN::WLS<-1 > Class Template Reference

#include <wls.h>

List of all members.

Public Member Functions

 WLS (unsigned int s)
 Default constructor.
void Identity (Matrix<> &M, double d)
void clear (double prior=0)
void add_prior (double val)
template<int VSize, class Accessor>
void add_prior (const FixedVector< VSize, Accessor > &v)
template<int MSize, class Accessor>
void add_prior (const FixedMatrix< MSize, MSize, Accessor > &m)
template<int VSize, class Accessor>
void add_df (double m, const FixedVector< VSize, Accessor > &J, double weight=1)
template<class Accessor>
void add_df (double m, const DynamicVector< Accessor > &J, double weight=1)
void compute ()
const Vectorget_mu () const
 Returns mu.
Vectorget_mu ()
const Matrixget_C_inv () const
 Returns the inverse covariance matrix.
Matrixget_C_inv ()
const Vectorget_vector () const
 Returns my_vector.
Vectorget_vector ()
 WLS (unsigned int s)
 Default constructor.
void Identity (Matrix<> &M, double d)
void clear (double prior=0)
void add_prior (double val)
template<int VSize, class Accessor>
void add_prior (const FixedVector< VSize, Accessor > &v)
template<int MSize, class Accessor>
void add_prior (const FixedMatrix< MSize, MSize, Accessor > &m)
template<int VSize, class Accessor>
void add_df (double m, const FixedVector< VSize, Accessor > &J, double weight=1)
template<class Accessor>
void add_df (double m, const DynamicVector< Accessor > &J, double weight=1)
void compute ()
const Vectorget_mu () const
 Returns mu.
Vectorget_mu ()
const Matrixget_C_inv () const
 Returns the inverse covariance matrix.
Matrixget_C_inv ()
const Vectorget_vector () const
 Returns my_vector.
Vectorget_vector ()


Detailed Description

template<>
class TooN::WLS<-1 >

Performs weighted least squares computation.
Parameters:
Size The number of dimensions in the system

Definition at line 156 of file wls.h.


Member Function Documentation

void TooN::WLS<-1 >::clear ( double  prior = 0  )  [inline]

Clear all the measurements and apply a constant regularisation term. Equates to a prior that says all the parameters are zero with $\sigma^2 = \frac{1}{\text{val}}$.

Parameters:
prior The strength of the prior

Definition at line 181 of file wls.h.

References TooN::Identity().

void TooN::WLS<-1 >::add_prior ( double  val  )  [inline]

Applies a constant regularisation term. Equates to a prior that says all the parameters are zero with $\sigma^2 = \frac{1}{\text{val}}$.

Parameters:
val The strength of the prior

Definition at line 191 of file wls.h.

template<int VSize, class Accessor>
void TooN::WLS<-1 >::add_prior ( const FixedVector< VSize, Accessor > &  v  )  [inline]

Applies a regularisation term with a different strength for each parameter value. Equates to a prior that says all the parameters are zero with $\sigma_i^2 = \frac{1}{\text{v}_i}$.

Parameters:
v The vector of priors

Definition at line 201 of file wls.h.

template<int MSize, class Accessor>
void TooN::WLS<-1 >::add_prior ( const FixedMatrix< MSize, MSize, Accessor > &  m  )  [inline]

Applies a whole-matrix regularisation term. This is the same as adding the $m$ to the inverse covariance matrix.

Parameters:
m The inverse covariance matrix to add

Definition at line 211 of file wls.h.

template<int VSize, class Accessor>
void TooN::WLS<-1 >::add_df ( double  m,
const FixedVector< VSize, Accessor > &  J,
double  weight = 1 
) [inline]

Add a single measurement

Parameters:
m The value of the measurement
J The Jacobian for the measurement $\frac{\partial\text{m}}{\partial\text{param}_i}$
weight The inverse variance of the measurement (default = 1)

Definition at line 220 of file wls.h.

template<class Accessor>
void TooN::WLS<-1 >::add_df ( double  m,
const DynamicVector< Accessor > &  J,
double  weight = 1 
) [inline]

Add a single measurement

Parameters:
m The value of the measurement
J The Jacobian for the measurement $\frac{\partial\text{m}}{\partial\text{param}_i}$
weight The inverse variance of the measurement (default = 1)

Definition at line 236 of file wls.h.

void TooN::WLS<-1 >::clear ( double  prior = 0  )  [inline]

Clear all the measurements and apply a constant regularisation term. Equates to a prior that says all the parameters are zero with $\sigma^2 = \frac{1}{\text{val}}$.

Parameters:
prior The strength of the prior

Definition at line 181 of file wls.h.

References TooN::Identity().

void TooN::WLS<-1 >::add_prior ( double  val  )  [inline]

Applies a constant regularisation term. Equates to a prior that says all the parameters are zero with $\sigma^2 = \frac{1}{\text{val}}$.

Parameters:
val The strength of the prior

Definition at line 191 of file wls.h.

template<int VSize, class Accessor>
void TooN::WLS<-1 >::add_prior ( const FixedVector< VSize, Accessor > &  v  )  [inline]

Applies a regularisation term with a different strength for each parameter value. Equates to a prior that says all the parameters are zero with $\sigma_i^2 = \frac{1}{\text{v}_i}$.

Parameters:
v The vector of priors

Definition at line 201 of file wls.h.

template<int MSize, class Accessor>
void TooN::WLS<-1 >::add_prior ( const FixedMatrix< MSize, MSize, Accessor > &  m  )  [inline]

Applies a whole-matrix regularisation term. This is the same as adding the $m$ to the inverse covariance matrix.

Parameters:
m The inverse covariance matrix to add

Definition at line 211 of file wls.h.

template<int VSize, class Accessor>
void TooN::WLS<-1 >::add_df ( double  m,
const FixedVector< VSize, Accessor > &  J,
double  weight = 1 
) [inline]

Add a single measurement

Parameters:
m The value of the measurement
J The Jacobian for the measurement $\frac{\partial\text{m}}{\partial\text{param}_i}$
weight The inverse variance of the measurement (default = 1)

Definition at line 220 of file wls.h.

template<class Accessor>
void TooN::WLS<-1 >::add_df ( double  m,
const DynamicVector< Accessor > &  J,
double  weight = 1 
) [inline]

Add a single measurement

Parameters:
m The value of the measurement
J The Jacobian for the measurement $\frac{\partial\text{m}}{\partial\text{param}_i}$
weight The inverse variance of the measurement (default = 1)

Definition at line 236 of file wls.h.


The documentation for this class was generated from the following files:
Generated on Fri Feb 22 18:26:57 2008 for QVision by  doxygen 1.5.3