| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → System Identification Toolbox |
| Contents | Index |
| Learn more about System Identification Toolbox |
idmodel is an object that you do not deal with directly. It contains all the common properties of the model objects idarx, idgrey, idpoly, idproc, and idss, which are returned by the different estimation routines.
If you just estimate models from data, the model objects should be transparent. All parametric estimation routines return idmodel results.
m = arx(Data,[2 2 1])
The model m contains all relevant information. Just typing m will give a brief account of the model. present(m) also gives information about the uncertainties of the estimated parameters. get(m) gives a complete list of model properties.
Most of the interesting properties can be directly accessed by subreferencing:
m.a m.da
See the property list obtained by get(m), as well as the property lists of idgrey, idarx, idpoly, and idss in Functions – Alphabetical List for more details on this. See also idprops.
The characteristics of the model m can be directly examined and displayed by commands like impulse, step, bode, nyquist, and pzmap. The quality of the model is assessed by commands like compare and resid. When you have Control System Toolbox software installed, you can use view(m) to access various display functions.
To extract state-space matrices, transfer function polynomials, etc., use the commands arxdata, polydata, tfdata, ssdata, and zpkdata.
To compute the frequency response of the model, use the commands idfrd and freqresp.
If you want to define a model to use, for example, for simulating data, you need to use the model creator functions:
idarx, for multivariable ARX models
idgrey, for user-defined grey-box state-space models
idpoly, for single-output polynomial models
idproc, for simple, continuous-time process models
idss, for state-space models
If you want to estimate a state-space model with a specific internal parameterization, you need to create an idss model or an idgrey model. See the reference pages for these functions.
For multivariable models, you construct submodels containing a subset of inputs and outputs by simple subreferencing. The outputs and input channels can be referenced according to
m(outputs,inputs)
Use a colon (:) to denote all channels and an empty matrix ([]) to denote no channels. The channels can be referenced by number or by name. For several names, you must use a cell array, such as
m3 = m('position',{'power','speed'})
or
m3 = m(3,[1 4])
Thus m3 is the model obtained from m by looking at the transfer functions from input numbers 1 and 4 (with input names 'power' and 'speed') to output number 3 (with name position).
For a single-output model m,
m4 = m(inputs)
selects the corresponding input channels, and for a single-input model,
m5 = m(outputs)
selects the indicated output channels.
Subreferencing is quite useful, for example, when a plot of just some channels is desired.
The estimated models have two kinds of input channels: the measured inputs u and the noise inputs e. For a general linear model m, we have
![]()
where u is the nu-dimensional
vector of measured input channels and e is the ny-dimensional
vector of noise channels. The covariance matrix of e is
given by the property 'NoiseVariance'. Occasionally
this matrix
is written in factored form,
![]()
This means that e can be written as
![]()
where
is white noise with identity
covariance matrix (independent noise sources with unit variances).
If m is a time series (nu = 0), G is empty and the model is given by
![]()
For the model m, the restriction to the transfer function matrix G is obtained by
m1 = m('measured') or just m1 = m('m')
Then e is set to 0 and H is removed.
Analogously,
m2 = m('noise') or just m2 = m('n')
creates a time-series model m2 from m by ignoring the measured input. That is, m2 describes the signal He.
For a system with measured inputs, bode, step, and other transformation and display functions deal with the transfer function matrix G. To obtain or graph the properties of the disturbance model H, it is therefore important to make the transformations m('n'). For example,
bode(m('n'))
plots the additive noise spectra according to the model m, while
bode(m)
just plots the frequency responses of G.
To study the noise contributions in more detail, it is useful to convert the noise channels to measured channels, using the command noisecnv.
m3 = noisecnv(m)
This creates a model m3 with all input channels, both measured u and noise sources e, treated as measured signals. That is, m3 is a model from u and e to y, describing the transfer functions G and H. The information about the variance of the innovations e is lost. For example, studying the step response from the noise channels does not take into consideration how large the noise contributions actually are.
To include that information, e should first
be normalized,
, so that
becomes white noise with an identity
covariance matrix.
m4 = noisecnv(m,'Norm')
This creates a model m4 where u and v are treated as measured signals.
![]()
For example, the step responses from v to y will now reflect the typical size of the disturbance influence because of the scaling by L. In both cases, the previous noise sources that have become regular inputs will automatically get input names that are related to the corresponding output. The unnormalized noise sources e have names like 'e@ynam1' (noise e at output channel ynam1), while the normalized sources v are called 'v@ynam1'.
The functions that retrieve transfer function properties, ssdata, tfdata, and zpkdata, behave, as follows, for a model with measured inputs. (fcn is ssdata, tfdata, or zpkdata.)
fcn(m) returns the properties of G (ny outputs and nu inputs).
fcn(m('n')) returns the properties of the transfer function H (ny outputs and ny inputs).
fcn(noisecnv(m,'Norm')) returns the properties of the transfer function [G HL} (ny outputs and ny+nu inputs). Analogously,
m1 = m('n');
fcn(noisecnv(m1,'Norm'))
returns the properties of the transfer function HL (ny outputs and ny inputs).
If m is a time-series model, fcn(m) returns the properties of H, while
fcn(noisecnv(m,'Norm'))
returns the properties of HL.
Note that the estimated covariance matrix NoiseVariance itself is uncertain. This means that the uncertainty information about H is different from that of HL.
In the list below, ny is the number of output channels, and nu is the number of input channels:
Name: An optional name for the data set. An arbitrary string.
OutputName, InputName: Cell arrays of length ny-by-1 and nu-by-1 containing the names of the output and input channels. For estimated models, these are inherited from the data. If not specified, they are given default names {'y1','y2',...} and {'u1','u2',...}.
OutputUnit, InputUnit: Cell arrays of length ny-by-1 and nu-by-1 containing the units of the output and input channels. Inherited from data for estimated models.
TimeUnit: Unit for the sampling interval.
Ts: Sampling interval. A nonnegative scalar. Ts = 0 denotes a continuous-time model. Note that changing just Ts will not recompute the model parameters. Use c2d and d2c for recomputing the model to other sampling intervals.
ParameterVector: Vector of adjustable parameters in the model structure. Initial/nominal values or estimated values, depending on the status of the model. A column vector.
PName: The names of the parameters. A cell array of the length of the parameter vector. If not specified, it will contain empty strings. See also setpname.
CovarianceMatrix: Estimated covariance matrix of the parameter vector. For a nonestimated model this is the empty matrix. For state-space models in the 'Free' parameterization the covariance matrix is also the empty matrix, since the individual matrix elements are not identifiable then. Instead, in this case, the covariance information is hidden (in the hidden property 'Utility') and retrieved by the relevant functions when necessary. Setting CovarianceMatrix to 'None' inhibits calculation of covariance and uncertainty information. This can save substantial time for certain models.
NoiseVariance: Covariance matrix of the noise source e. An ny-by-ny matrix.
InputDelay: Vector of size nu-by-1, containing the input delay from each input channel. For a continuous-time model (Ts = 0) the delay is measured in TimeUnit, while for discrete-time models (Ts > 0) the delay is measured as the number of samples. Note the difference between InputDelay and nk (which is a property of idarx, idss, and idpoly). 'Nk' is a model structure property that tells the model structure to include such an input delay. In that case, the corresponding state-space matrices and polynomials will explicitly contain Nk input delays. The property InputDelay, on the other hand, is an indication that in addition to the model as defined, the inputs should be shifted by the given amount. InputDelay is used by sim and the estimation routines to shift the input data. When computing frequency responses, the InputDelay is also respected. Note that InputDelay can be both positive and negative.
Algorithm: See the reference page for Algorithm Properties.
EstimationInfo: See the reference page for EstimationInfo.
Notes: An arbitrary field to store extra information and notes about the object.
UserData: An arbitrary field for any possible use.
Note All properties can be set or retrieved either by these commands or by subscripts. Autofill applies to all properties and values, and is case insensitive. |
For a complete list of property values, use get(m). To see possible value assignments, use set(m).
The outputs and input channels can be referenced according to
m(outputs,inputs)
Use a colon (:) to denote all channels and an empty matrix ([ ]) to denote no channels. The channels can be referenced by number or by name. For several names, you must use a cell array.
m2 = m('y3',{'u1','u4'})
m3 = m(3,[1 4])
For a single output model m,
m4 = m(inputs)
selects the corresponding input channels, and for a single input model,
m5 = m(outputs)
selects the indicated output channels.
The string 'measured' (or any abbreviation like 'm') means the measured input channels.
m4 = m(3,'m')
m('m') is the same as m(:,'m')
Similarly, the string 'noise' (or any abbreviation) refers to the noise input channels. See Noise Channels for more details.
Adding input channels,
m = [m1,m2,...,mN]
creates an idmodel object m, consisting of all the input channels in m1,... mN. The output channels of mk must be the same.
Adding output channels,
m = [m1;m2;... ;mN]
creates an idmodel object m consisting of all the output channels in m1, m2, ..mN. The input channels of mk must all be the same.
Type idhelp idmodel, idprops idmodel, idprops idmodel algorithm.
| Algorithm Properties | |
| EstimationInfo | |
| compare | |
| idarx | |
| idgrey | |
| idpoly | |
| idproc | |
| idss | |
| noisecnv |
![]() | idmdlsim | idnlarx | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |