The algorithm

Two separate loops are needed for solving the Yule-Walker problem. One loop ``solves'' the $ k$th order Yule-Walker type of equations. We say ``solves'' because in fact the solution is not calculated, but only the factors determining the solution are calculated. A second loop will construct the solution, given the two sequences of numbers constructed by the first loop.

Given the generators $ u,v$ and the diagonal $ d$ of the symmetric positive definite semiseparable matrix $ S+D$, the following algorithm computes the solution $ y$ such that $ (S+D)y=-v$. Two extra vectors are needed for the algorithm. In the vector $ a$ we will store the separate values of the parameter $ \alpha$, and in the vector $ f$, the consecutive factors $ f_i$.

%---- First Part: Generate the two vectors -----
% Initialization, the system for i=1 is solved
a(1)=-v(1)/(d(1)+u(1)*v(1));
f(1)=1;
% Calculate the inner product for the next loop
ip=a(1)*v(1);
% The main loop
for i=2:n
  t=u(i)*ip+v(i);
  % Store the new calculated alpha
  a(i)=-t/(u(i)*t+d(i));
  % Store the new factor f
  f(i)=1+u(i)*a(i);
  % Calculation of the inner product for the next loop
  ip=f(i)*ip+v(i)*a(i);  
end


%---- Second Part: Construct the solution-------
% The vectors f and a are given,
% construct now the solution with these vectors.
% Initialization before the loop
y(n)=a(n);
factor=f(n);
% Construct the solution vector from bottom to top
for i=n-1:-1:1  
  y(i)=factor*a(i);
  factor=factor*f(i);
end

So the overall cost is $ 12n-8$ operations6 for solving the Yule-Walker-like system of equations for positive definite symmetric semiseparable plus diagonal matrices.



Raf Vandebril 2005-04-25