init_sharf.m
来自「卡尔曼滤波器设计的一个例子」· M 代码 · 共 41 行
M
41 行
% [u,w,e,c,d,mu,Px,Py]=init_sharf(N,M,L,u0,w0,e0,c0,d0,mu0)
%
% Creates and initializes the variables required for the
% Simple Hyperstable Adaptive Recursive Filter (SHARF)
% algorithm. The filter transfer function is given by
%
% A(z)
% w(z) = ----------
% 1 - B(z)
%
% where A(z) = a_0 + a_1 z^(-1) + ... + a_(N-1) z^(-N+1)
% and B(z) = b_1 z^(-1) + ... + b_M z^(-M)
%
% Input arguments:
% N : Number of coefficients of A(z)
% M : Number of coefficients of B(z)
% L : Number of coefficients of error smoothing filter c
% u0 : [x(0) x(-1) ... x(-N+1) y(-1) ... y(-M)]', [N+M x 1]
% w0 : [a_0 a_1 ... a_(N-1) b_1 ... b_M]', [N+M x 1]
% e0 : [e(-1) e(-2) ... e(-L)]', [L x 1]
% c0 : [c_0 c_1 ... c_(L-1)]', [L x 1]
% d0 : desired sample at time index 0 [1 x 1]
% mu0 : step size vector [N+M x 1]
%
% Output Parameters:
% u : Initialized composite delay line [zeros].
% w : Initialized filter vector [zeros].
% e : Initialized error vector [e=d-y].
% c : Initialized error smoothing filter [fir1(L-1,.05)]
% d : Initialized desired sample
% mu : Initialized step size vector 0.01*[1 ... 1].
% Px : Initialized power of x(n).
% Pd : Initialized power of d(n).
%
% SEE ALSO ASPTSHARF, MODEL_SHARF
% Author : John Garas PhD.% Version 2.1, Release October 2002.% Copyright (c) DSP ALGORITHMS 2000-2002.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?