Construct theta format matrix from ARX polynomials.
Syntax
th = arx2th(A,B,ny,nu)
th = arx2th(A,B,ny,nu,lam,T)
Description
arx2th creates a matrix containing parameters that describe the general multi-input, multi-output model structure of ARX type:

Here
and
are matrices of dimensions ny by ny and ny by nu, respectively (ny is the number of outputs, i.e., the dimension of the vector
and nu is the number of inputs). "Defining Model Structures" on page 3-29 in the User's Guide.
The arguments A and B are matrices that contain the A matrices and the B matrices of the model:
A = [I A1 A2 ... Ana]
B = [B0 B1 ... Bnb]
Note that A always starts with the identity matrix, and that delays in the model are defined by setting the corresponding leading entries in B to zero. For a multivariate time series take B = [].
The arguments ny and nu denote the number of outputs and inputs, respectively.
The optional argument lam sets the covariance matrix of the driving noise source
in the model above. The default value is the identity matrix.
The optional argument T defines the sampling interval (Default 1).
th is returned as a model structure in the theta format. See theta.
The use of arx2th is twofold. You can use it to create models that are simulated (using idsim) or analyzed (using th2ff, th2zp, etc.). You can also use it to define initial value models that are further adjusted to data (using pem). The free parameters in the structure are consistent with the structure of A and B, i.e., leading zeros in the rows of B are regarded as fixed delays, and trailing zeros in A and B are regarded as a definition of lower order polynomials. These zeros are fixed, while all other parameters are free. The nominal values of these free parameters are set equal to the values in A and B. The free parameters can be changed by thinit and the structure can be manipulated by fixpar and unfixpar.
For a model with one output, arx2th is compatible with poly2th. The internal representation is however different, and only a model structure that has been defined by arx2th can be manipulated by fixpar and unfixpar.
Examples
Simulate a second order ARX model with one input and two outputs, and then estimate a model using the simulated data :
A1 = [-1.5 0.1;-0.2 1.5];
A2 = [0.7 -0.3;0.1 0.7];
B1 = [1;-1];
B2 = [0.5;1.2];
th0 = arx2th([eye(2) A1 A2],[[0;0],B1 B2],2,1);
u = idinput(300);
e = randn(300,2);
y = idsim([u e],th0);
th = arx([y u],[[2 2;2 2],[2;2],[1;1]]);
See Also
arx, fixpar, poly2th, th2arx, unfixpar
[ Previous | Help Desk | Next ]