next up previous
Next: The bulge chasing Up: The algorithm Previous: Useful functions

The reduction to a triangular semiseparable matrix

The following function reduces an arbitrary matrix of dimension $ m$ by $ n$ to an upper triangular semiseparable matrix. Assuming that $ n\leq
m$.

algorithm 3  

funcion S=triuSS(A)
[m,n]=size(A);
% annihilating the lower triangular part
% and making the upper triangular part
% semiseparable
for i=1:n-1
  A=HouseRight(A,i+1,i);
  A=HouseLeft(A,i+2,i);
  A=GivLeft(A,i+1,i,i);
  for j=i:-1:2
    A=GivRight(A,j,j-1,j-1);
    A=GivLeft(A,j,j-1,j-1);
  end
end
% making zeros in  the last column (if m> n)
A=HouseLeft(A,n+1,n);

S=A;



Raf Vandebril 2004-04-19