semsolve4.m 413 Bytes
Newer Older
Simone Liuzzo's avatar
Simone Liuzzo committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14
function sk=semsolve4(drv,resp,neig)

if nargin < 3, neig=60; end
nresp=length(resp);
displines=length(resp)-224+(1:224);
nfit=8;
sk=zeros(size(drv,2),nfit);
for i=1:nfit
    lines=[semselect([2*i-1 2*i],[2*i-1 2*i]) displines];
    ok=isfinite(resp(lines));
    sk(:,i)=qemsvd(drv(lines(ok),:),resp(lines(ok)),neig);
%    r=resp-drv*sk(:,i);
%    disp(sprintf('%g %g',std2(resp(lines),1),std2(r(lines),1)));
end