Package: dsp
Compute output, error and coefficients using Recursive Least Squares (RLS) algorithm
The RLSFilter
object filters each channel
of the input using RLS filter implementations.
To filter each channel of the input:
Define and set up your RLS filter. See Construction.
Call step
to filter each channel
of the input according to the properties of dsp.RLSFilter
.
The behavior of step
is specific to each object in
the toolbox.
H = dsp.RLSFilter
returns
an adaptive RLS filter System object™, H
. This System object computes
the filtered output, filter error and the filter weights for a given
input and desired signal using the RLS algorithm.
H = dsp.RLSFilter('
returns an RLS filter System object, PropertyName
',PropertyValue
,
...)H
,
with each specified property set to the specified value.
H = dsp.RLSFilter(LEN, '
returns an RLS filter System object, PropertyName
', PropertyValue
,
...)H
.
This System object has the Length property set to LEN
,
and other specified properties set to the specified values.

Method to calculate the filter coefficients You can specify the method used to calculate filter coefficients
as one of  

Length of filter coefficients vector Specify the length of the RLS filter coefficients vector as
a scalar positive integer value. The default value is 

Width of the sliding window Specify the width of the sliding window as a scalar positive
integer value greater than or equal to the Length property value.
This property is applicable only when the Method property is set to 

RLS forgetting factor Specify the RLS forgetting factor as a scalar positive numeric
value less than or equal to 1. Setting this property value to 1 denotes
infinite memory, while adapting to find the new filter. The default
value is 

Initial coefficients of the filter Specify the initial values of the FIR adaptive filter coefficients
as a scalar or a vector of length equal to the 

Initial inverse covariance Specify the initial values of the inverse covariance matrix
of the input signal. This property must be either a scalar or a square
matrix, with each dimension equal to the 

Initial square root inverse covariance Specify the initial values of the square root inverse covariance
matrix of the input signal. This property must be either a scalar
or a square matrix with each dimension equal to the 

Initial square root covariance Specify the initial values of the square root covariance matrix
of the input signal. This property must be either a scalar or a square
matrix with each dimension equal to the 

Lock coefficient updates Specify whether the filter coefficient values should be locked.
When you set this property to 
clone  Create System object with same property values 
isLocked  Locked status for input attributes and nontunable properties 
msesim  Meansquare error for RLS filter 
release  Allow property value and input characteristics changes 
reset  Reset the internal states of a System object 
step  Process inputs using RLS filter 
The dsp.RLSFilter
System object, when Conventional RLS
is selected, recursively
computes the least squares estimate (RLS) of the FIR filter weights.
The System object estimates the filter weights or coefficients,
needed to convert the input signal into the desired signal. The input
signal can be a scalar or a column vector. The desired signal must
have the same data type, complexity, and dimensions as the input signal.
The corresponding RLS filter is expressed in matrix form as P(n)
:
$$\begin{array}{l}k(n)=\frac{{\lambda}^{1}P(n1)u(n)}{1+{\lambda}^{1}{u}^{H}(n)P(n1)u(n)}\\ y(n)={w}^{T}(n1)u(n)\\ e(n)=d(n)y(n)\\ w(n)=w(n1)+k(n)e(n)\\ P(n)={\lambda}^{1}P(n1){\lambda}^{1}k(n){u}^{H}(n)P(n1)\end{array}$$
where λ^{1} denotes the reciprocal of the exponential weighting factor. The variables are as follows:
Variable  Description 

n  The current time index 
u(n)  The vector of buffered input samples at step n 
P(n)  The inverse correlation matrix at step n 
k(n)  The gain vector at step n 
w(n)  The vector of filter tap estimates at step n 
y(n)  The filtered output at step n 
e(n)  The estimation error at step n 
d(n)  The desired response at step n 
λ  The forgetting factor 
u, w, and k are all column vectors.
[1] M Hayes, Statistical Digital Signal Processing and Modeling, New York: Wiley, 1996
[2] S. Haykin, Adaptive Filter Theory, 4th Edition, Upper Saddle River, NJ: Prentice Hall, 2002
[3] A.A. Rontogiannis and S. Theodoridis, "Inverse factorization adaptive leastsquares algorithms," Signal Processing, vol. 52, no. 1, pp. 3547, July 1996.
[4] S.C. Douglas, "Numericallyrobust O(N^{2}) RLS algorithms using leastsquares prewhitening," Proc. IEEE Int. Conf. on Acoustics, Speech, and Signal Processing, Istanbul, Turkey, vol. I, pp. 412415, June 2000.
[5] A. H. Sayed, Fundamentals of Adaptive Filtering, Hoboken, NJ: John Wiley & Sons, 2003
Adaptive Noise Cancellation Using RLS Adaptive Filtering  dsp.AffineProjectionFilter
 dsp.FIRFilter
 dsp.LMSFilter