FIR adaptive filter that uses sliding window fast transversal least squares
adaptfilt.swftf
will be removed in a future
release. Use dsp.FastTransversalFilter
instead.
ha = adaptfilt.swftf(l,delta,blocklen,gamma,gstates,
dstates,...coeffs,states)
ha = adaptfilt.swftf(l,delta,blocklen,gamma,gstates,
constructs a sliding
window fast transversal least squares adaptive filter
dstates,...coeffs,states)ha
.
For information on how to run data through your adaptive filter
object, see the Adaptive Filter Syntaxes section of the reference
page for filter
.
Entries in the following table describe the input arguments
for adaptfilt.swftf
.
Input Argument  Description 

 Adaptive filter length (the number of coefficients or
taps) and it must be a positive integer. 
 Softconstrained initialization factor. This scalar should
be positive and sufficiently large to maintain stability. 
 Block length of the sliding window. This must be an integer
at least as large as the filter length 
 Conversion factor. 
 States of the Kalman gain updates. 
 Desired signal states of the adaptive filter. 
 Vector of initial filter coefficients. It must be a length 
 Vector of initial filter states. 
Since your adaptfilt.swftf
filter is an object,
it has properties that define its behavior in operation. Note that
many of the properties are also input arguments for creating adaptfilt.swftf
objects.
To show you the properties that apply, this table lists and describes
each property for the filter object.
Name  Range  Description 

 None  Defines the adaptive filter algorithm the object uses during adaptation 
 Returns the predicted samples generated during adaptation. See References — Adaptive Filters for details about linear prediction.  
 Block length of the sliding window. This must be an integer
at least as large as the filter length  
 Vector of elements  Vector containing the initial filter coefficients. It
must be a length 
 Conversion factor. Called  
 Desired signal states of the adaptive filter.  
 Any positive integer  Reports the length of the filter, the number of coefficients or taps 
 Contains the predicted values for samples during adaptation. Compare these to the actual samples to get the error and power.  
 Softconstrained initialization factor. This scalar should
be positive and sufficiently large to prevent an excessive number
of Kalman gain rescues.  
 Empty when you construct the object, this gets populated after you run the filter.  
 Contains the states of the Kalman gains for the adaptive algorithm. Initialized to a vector of double data type entries.  

 Determine whether the filter states get restored to their
starting values for each filtering operation. The starting values
are the values in place when you create the filter if you have not
changed the filter since you constructed it. 
 Vector of elements, data type double  Vector of the adaptive filter states. 
Over 500 iterations, perform a system identification of a 32coefficient FIR filter.
x = randn(1,500); % Input to the filter b = fir1(31,0.5); % FIR system to be identified n = 0.1*randn(1,500); % Observation noise signal d = filter(b,1,x)+n; % Desired signal L = 32; % Adaptive filter length del = 0.1; % Softconstrained initialization factor N = 64; % block length ha = adaptfilt.swftf(L,del,N); [y,e] = filter(ha,x,d); subplot(2,1,1); plot(1:500,[d;y;e]); title('System Identification of an FIR Filter'); legend('Desired','Output','Error'); xlabel('Time Index'); ylabel('Signal Value'); subplot(2,1,2); stem([b.',ha.Coefficients.']); legend('Actual','Estimated'); xlabel('Coefficient #'); ylabel('Coefficient Value'); grid on;
Review the figure for the results of the example. When you evaluate the example you should get the same results, within the differences in the random noise signal you use.
Slock, D.T.M., and T. Kailath, "A Modular Prewindowing Framework for Covariance FTF RLS Algorithms," Signal Processing, vol. 28, pp. 4761, 1992
Slock, D.T.M., and T. Kailath, "A Modular Multichannel MultiExperiment Fast Transversal Filter RLS Algorithm," Signal Processing, vol. 28, pp. 2545, 1992
adaptfilt.ap
 adaptfilt.apru
 adaptfilt.ftf
 adaptfilt.swrls