GPLIB++
|
Base class for least squares filter with a single output value. More...
#include <LSSOFilter.h>
Public Member Functions | |
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... | |
virtual void | AdaptFilter (const gplib::rvec &Input, const gplib::rvec &Desired)=0 |
Adapt the filter weights given the Input and Desired vectors. 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 | |
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... | |
Base class for least squares filter with a single output value.
Base class for Least-Square filters with a single output value currently used for LMS and RLS filters, implements all virtual functions from AdaptiveFilters apart from AdaptFilter, which depends on the functionality of the individual filter
Definition at line 20 of file LSSOFilter.h.
gplib::LSSOFilter::LSSOFilter | ( | const int | filterlength | ) |
The constructor only needs the filter length, outputsize for Adaptive filter is 1.
Definition at line 9 of file LSSOFilter.cpp.
|
virtual |
Definition at line 16 of file LSSOFilter.cpp.
|
virtual |
The way to calculate the output is the same for all single output filters, we implement it here.
Implements gplib::AdaptiveFilter.
Definition at line 28 of file LSSOFilter.cpp.
References gplib::AdaptiveFilter::SetOutput().
Referenced by CalcOutput().
|
inline |
For single channel output we can also just return the output as a double.
Definition at line 34 of file LSSOFilter.h.
References CalcOutput().
|
inline |
Return the current set of weights.
Definition at line 41 of file LSSOFilter.h.
Referenced by gplib::LMSCanceller::AdaptFilter(), gplib::WienerInterpolator::AdaptFilter(), gplib::WienerInterpolator::CalcCoefficients(), and main().
|
inlinevirtual |
Implement the abstract function from adaptive filter, in this case just another name for GetWeights.
Implements gplib::AdaptiveFilter.
Definition at line 46 of file LSSOFilter.h.
|
virtual |
Print the weights to output stream.
Implements gplib::AdaptiveFilter.
Definition at line 20 of file LSSOFilter.cpp.
|
inlineprotected |
Definition at line 26 of file LSSOFilter.h.
Referenced by gplib::LMSCanceller::AdaptFilter(), gplib::WienerInterpolator::AdaptFilter(), and gplib::RLSCanceller::AdaptFilter().