User`s guide
Refining Linear Parametric Models
Example – Refining an ARMAX Model with Initial Parameter
Guesses at the Command Line
The following example shows how to refine models for which you have initial
parameter guesses. This example estimates an ARM AX model for the data
and requi res you to init ia li ze the A, B,andC polynomials.
In this case, you must first create a model object and set the initial parameter
values in the model properties. N ext, you provide this initial model as input
to
pem, w hich refines the initial parameter guesses using the data.
load iddata8
% Define model parameters
A = [1 -1. 2 0.7];
B(1,:) = [0 1 0.5 0.1]; % first input
B(2,:) = [0 1.5 -0.5 0]; % second input
B(3,:) = [0 -0.1 0.5 -0.1]; % third input
C=[10000];
Ts = 1;
% Leading zeros in B matr ix indicate input d elay (nk),
% which is 1 for each inp ut channel. The trailing zeros
% in B(2,:)) make the number of coefficients equal
% for all channels.
% Create model object
init_model = idpoly(A,B,C,'Ts',1);
% Use pem to refine initial model
model = pem(z8,init_model)
% Compare the two models
compare(z8,init_model,model)
For more information about estimating polynomial models, see “Identifying
Input-Output Polynomial Models” on page 3-41.
3-107