next up previous contents
Next: 7 asptrlslbpef Up: 5 Lattice Adaptive Algorithms Previous: 5 asptrlslattice   Contents


6 asptrlslattice2

Purpose
Performs filtering and coefficient update for the Recursive Least Squares Lattice (joint process estimator) using the a priori estimation errors with error feedback

Syntax
[ff,bb,cf,b,y,e,kf,kb,c] =
asptrlslattice2(ff,bb,kf,kb,c,cf,b,a,x,d)



Description
asptrlslattice2() implements the joint process estimator shown in Fig. 5.10. Similar to the LMS joint process estimator (Fig. 5.6), it estimates a process $d(n)$ from another correlated process $x(n)$ and consists of two separate parts, the lattice predictor part and the linear combiner part. Unlike the LMS lattice however, the forward and backward PARCOR coefficients are not equal in the case of the RLS lattice structure. The adaptive joint process estimator adjusts the forward PARCOR coefficients $kf_i;\; i=1,2,\cdots,M$, the backward PARCOR coefficients $kb_i;\; i=1,2,\cdots,M$, and the linear combiner coefficients $c_i;\; i=1,2,\cdots,M$ simultaneously. The PARCOR coefficients are adjusted to minimize the forward and backward prediction errors, while the linear combiner coefficients are adjusted to minimize the error signal $e(n)$ in the RLS sense.

The input and output parameters of asptrlslattice2() of $L$ stages are summarized below.
Input Parameters:: 
   ff  : last autocorrelation of forward prediction error (f)
   bb  : last autocorrelation of backward prediction error (b)
   kf  : last forward lattice coefficients kf(n-1)
   kb  : last backward lattice coefficients kb(n-1)
   c   : last linear combiner coefficients c(n-1)
   cf  : last conversion factor vector
   b   : last backward a priori prediction error vector
   a   : forgetting factor
   x   : newest input sample x(n)
   d   : desired response d(n)

Output parameters::
   ff  : updated autocorrelation of forward prediction error 
   bb  : updated autocorrelation of backward prediction error 
   cf  : updated conversion factor vector
   b   : updated backward a priori estimation error vector
   y   : linear combiner output 
   e   : error signal 
   kf  : updated forward lattice coefficients kf(n)
   kb  : updated backward lattice coefficients kb(n)
   c   : updated linear combiner coefficients c(n)



Figure 5.10: Block diagram of the RLS adaptive Joint Process Estimator.


\epsfig{file=/home/john/winD/docs/aspt/aspt/figs/rlslattice_jpe.eps,width=\textwidth}


Example
% RLSLATTICE2 used in a simple system identification application.
% By the end of this script the adaptive filter w 
% should have the same coefficients as the unknown filter h.

iter = 5000;                  % samples to process
% Complex unknown impulse response
h  = [.9 + i*.4; 0.7+ i*.2; .5; .3+i*.1; .1];     
xn = 2*(rand(iter,1)-0.5);   % Input signal
% although xn is real, dn will be complex since h is complex
dn = osfilter(h,xn);         % Unknown filter output 
en = zeros(iter,1);          % error signal

% Initialize RLSLATTICE2 with a filter of 10 coef.
L   = 10;                    % filter length
a   = .99;                   % forgetting factor
[ff,bb,cf,b,d,y,e,kf,kb,w]=init_rlslattice2(L);

%% Processing Loop
for (m=1:iter)
  
   x = xn(m,:);                % new input sample
   d = dn(m,:) + 1e-3*rand;    % additive noise var = 1e-6 
   [ff,bb,cf,b,y,e,kf,kb,w] = 
                 asptrlslattice2(ff,bb,kf,kb,w,cf,b,a,x,d); 
   % save the last error sample to plot later
   en(m,:) = e;  
end;

% display the results
subplot(2,2,1);stem([real(w) imag(w)]); grid;
subplot(2,2,2);
eb = filter(.1, [1 -.9], en .* conj(en));
plot(10*log10(eb  ));grid



Figure 5.11: The adaptive linear combiner coefficients after convergence and the learning curve for the complex system identification problem using the RLSLATTICE-2 algorithm.
Running the above script will produce the graph shown in Fig. 5.11. The left side graph of the figure shows the adaptive linear combiner coefficients after convergence which are almost identical to the unknown filter h. The right side graph shows the square error in dB versus time during the adaptation process, which is usually called the learning curve. The lower limit of the error signal power in the learning curve is defined here by the additive white noise added at the filter output (-60 dB). Note that the asptrlslattice2() does not suffer from the fluctuations of the PARCOR coefficients and the final misadjustment is not affected by this fluctuations. The filter also shows very fast convergence rate and high degree of stability once it converged.


\epsfig{file=/home/john/winD/docs/aspt/aspt/figs/rlslattice2ex1.eps,width=0.9\textwidth}


Remarks
The joint process estimator simultaneously updates the PARCOR coefficients of the lattice predictor and the coefficients of the linear combiner. Updating the PARCOR coefficients results in changing all the backward prediction errors which are the inputs to the linear combiner. In the case of the LMSLATTICE this has the undesirable effect of increasing the final misadjustment due to the perturbation of the PARCOR coefficients. This problem does not appear to be of concern in the case of RLSLATTICE algorithms since the backward and forward prediction errors are minimized in the RLS sense using the exponentially windowed observed past prediction errors. The following points are also of interest.
  • asptrlslattice2() supports real as well as complex signals.
  • The backward prediction errors $e_{b0}(n), e_{b1}(n), \cdots, e_{bM}(n)$ are uncorrelated with one another for any input sequence $x(n)$. This accelerates the convergence of the linear combiner coefficients.
  • asptrlslattice2() has been found to be less sensitive to numerical rounding errors compared to asptrlslattice().

Algorithm
asptrlslattice2() performs the following operations
  • Calculates the backward (bb) and forward (ff) autocorrelations for each lattice stage,
  • Calculates the forward and backward prediction errors for the lattice structure stages using the order update equations,
  • Updates the forward and backward PARCOR coefficients of the lattice predictor and the conversion factor $e_{bn}/e_{b(n-1)}$,
  • Evaluates the linear combiner output and error signal,
  • Updates the linear combiner coefficients,
  • Updates the conversion factor vector.



Resources
The resources required to implement an RLSLATTICE-2 filter of length $L$ in real time is given in the table below. The computations given are those required to process one sample.


MEMORY $9L + 6$
MULTIPLY $9L $
ADD $18L + 1 $
DIVIDE 4L

See Also
INIT_ RLSLATTICE2, ASPTRLSLATTICE.

Reference
[2] and [4] for analysis of the adaptive Lattice filters.


next up previous contents
Next: 7 asptrlslbpef Up: 5 Lattice Adaptive Algorithms Previous: 5 asptrlslattice   Contents