durbin.m

来自「MATLAB programs for Durbin s MA」· M 代码 · 共 21 行

M
21
字号
function b = durbin(x,p,q)
%DURBIN	Find a moving average model using Durbin's method
%----
%Syntax is:	b = durbin(x,p,q) 
%
%	A moving average model for the input sequence x is found
%	using Durbin's method.  The coefficients are returned in
%	the vector
%		b = [b(0), b(1), ... , b(q) ]
%	
%	q :  order of the moving average model
%	p :  order of the all-pole model used to approximation 1/B(z).
%	     This parameter should be at least 4*q as mentioned in the "Moving
%	     average parameter estimation paper" by Niclas Sandgren
x   = x(:);
if p>=length(x), error('Model order too large'), end
[a,epsilon] = acm(x,p);
[b,epsilon] = acm(length(x)*a/sqrt(epsilon),q);
b = b*length(x)/sqrt(epsilon);

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?