GPLIB++
|
Implements a recursive least-squares adaptive filter, as described in Haykin, p. 443. More...
#include <RLSCanceller.h>
Public Member Functions | |
void | SetLambda (const double Mylambda) |
Set the forgetting factor , usually . More... | |
double | GetLambda () |
Get the current forgetting factor. More... | |
void | SetDelta (const double Mydelta) |
Set the regularization factor. More... | |
double | GetDelta () |
virtual void | AdaptFilter (const gplib::rvec &Input, const gplib::rvec &Desired) |
Adapt the filter weights given the Input and Desired vectors. More... | |
RLSCanceller (const int inputsize) | |
RLSCanceller (const int inputsize, const double MyDelta, const double MyLambda) | |
virtual | ~RLSCanceller () |
Public Member Functions inherited from gplib::LSSOFilter | |
virtual void | CalcOutput (const gplib::rvec &Input, gplib::rvec &Output) |
The way to calculate the output is the same for all single output filters, we implement it here. More... | |
double | CalcOutput (const gplib::rvec &Input) |
For single channel output we can also just return the output as a double. More... | |
const gplib::rvec & | GetWeights () |
Return the current set of weights. More... | |
virtual const gplib::rvec & | GetWeightsAsVector () |
Implement the abstract function from adaptive filter, in this case just another name for GetWeights. More... | |
virtual void | PrintWeights (std::ostream &output) |
Print the weights to output stream. More... | |
LSSOFilter (const int filterlength) | |
The constructor only needs the filter length, outputsize for Adaptive filter is 1. More... | |
virtual | ~LSSOFilter () |
Public Member Functions inherited from gplib::AdaptiveFilter | |
const gplib::rvec & | GetFilterOutput () const |
Access to the last calculated output (not sure if needed) More... | |
const gplib::rvec & | GetEpsilon () const |
Return the last estimation error. More... | |
AdaptiveFilter (const int inputsize, const int outputsize) | |
The constructor needs to know the length of the input and output vectors for memory allocation. More... | |
virtual | ~AdaptiveFilter () |
Protected Member Functions | |
const gplib::rmat & | GetP () |
const gplib::rvec & | GetPi () |
const gplib::rvec & | GetK () |
Protected Member Functions inherited from gplib::LSSOFilter | |
gplib::rvec & | SetWeights () |
Protected Member Functions inherited from gplib::AdaptiveFilter | |
unsigned int | GetInputLength () |
Access function for derived classes for the inputlength. More... | |
unsigned int | GetOutputLength () |
Access function for derived classes for the outputlength. More... | |
void | SetEpsilon (const gplib::rvec &MyEps) |
Possibility for derived classes to set estimation error. More... | |
void | SetOutput (const gplib::rvec &Out) |
Possibility for derived classes to set output. More... | |
Implements a recursive least-squares adaptive filter, as described in Haykin, p. 443.
The RLS filter is a more eeffective, but computationally much more expensive version of the LMS filter.
Definition at line 16 of file RLSCanceller.h.
gplib::RLSCanceller::RLSCanceller | ( | const int | inputsize | ) |
Definition at line 14 of file RLSCanceller.cpp.
gplib::RLSCanceller::RLSCanceller | ( | const int | inputsize, |
const double | MyDelta, | ||
const double | MyLambda | ||
) |
Definition at line 21 of file RLSCanceller.cpp.
|
virtual |
Definition at line 29 of file RLSCanceller.cpp.
|
virtual |
Adapt the filter weights given the Input and Desired vectors.
Implements gplib::AdaptiveFilter.
Reimplemented in gplib::AMRLSCanceller.
Definition at line 33 of file RLSCanceller.cpp.
References gplib::AdaptiveFilter::GetEpsilon(), gplib::AdaptiveFilter::GetFilterOutput(), gplib::AdaptiveFilter::SetEpsilon(), and gplib::LSSOFilter::SetWeights().
Referenced by gplib::AMRLSCanceller::AdaptFilter().
|
inline |
Definition at line 53 of file RLSCanceller.h.
|
inlineprotected |
Definition at line 33 of file RLSCanceller.h.
Referenced by gplib::AMRLSCanceller::AdaptFilter().
|
inline |
Get the current forgetting factor.
Definition at line 44 of file RLSCanceller.h.
Referenced by gplib::AMRLSCanceller::AdaptFilter().
|
inlineprotected |
Definition at line 25 of file RLSCanceller.h.
Referenced by gplib::AMRLSCanceller::AdaptFilter().
|
inlineprotected |
Definition at line 29 of file RLSCanceller.h.
|
inline |
Set the regularization factor.
Definition at line 49 of file RLSCanceller.h.
|
inline |
Set the forgetting factor , usually .
Definition at line 39 of file RLSCanceller.h.
Referenced by gplib::AMRLSCanceller::AdaptFilter().