wls.m
来自「rang doppler imaging and motion compensa」· M 代码 · 共 34 行
M
34 行
function polyestim = wls(x,y,w,order)
%
% Calculates polynomial estimates using weighted least squares fitting.
% x: Time coordinates of the measurements.
% y: Instananeous range measurements.
% w: Weight for the measurements. In this algorithm, the magnitude of
% the segment is considered as weight.
% [m,n]=size(y); if m == 1 m = n; n = 1; y = y(:); end [mm,nn]=size(x); if mm == 1 mm = nn; nn = 1; x = x(:); end xvect=[]; for ord = 0:order xpower=x.^ord; xvect=[xvect,xpower]; end wmat=diag(w); polyest=inv(xvect'*wmat*xvect)*xvect'*wmat*y; polyestim=flipud(polyest);
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?