   function mu =  shift2(A)
%% function mu =  shift2(A);
%% gets smallest eigenv. of A([n,n-1,n,n-1])
   n = size(A,1);
   n1 = n-1;
   del = A(n1,n1)*A(n,n) - A(n1,n)*A(n,n1);
%% 
   s = 0.5*(A(n1,n1) + A(n,n));
if (s*s >= del)  
   if (s>0) 
       mu = s - sqrt(s*s - del) ;
   else 
       mu = s + sqrt(s*s - del) ;
   end
 else 
    mu = s + i*sqrt(del-s*s); 
 end
