Products & Services Solutions Academia Support User Community Company

Learn more about System Identification Toolbox   

idss - State-space model

Syntax

m = idss(A,B,C,D)
m = idss(A,B,C,D,K,x0,Ts,'Property1',Value1,...
           'PropertyN',ValueN)
mss = idss(m1)

Description

The function idss is used to construct state-space model structures with various parameterizations. It is a complement to idgrey and deals with parameterizations that do not require the user to write a special M-file. Instead it covers parameterizations that are either 'Free', that is, all parameters in the A, B, and C matrices can be adjusted freely, or 'Canonical', meaning that the matrices are parameterized as canonical forms. The parameterization can also be 'Structured', which means that certain elements in the state-space matrices are free to be adjusted, while others are fixed. This is explained below.

Ts is the sampling interval. Ts = 0 means a continuous-time model. The default is Ts = 1.

The idss object m describes state-space models in innovations form of the following kind:

Here is the time derivative for a continuous-time model and for a discrete-time model.

The model m will contain information both about the nominal/initial values of the A, B, C, D, K, and X0 matrices and about how these matrices are parameterized by the parameter vector (to be estimated).

The nominal model is defined by idss(A,B,C,D,K,X0). If K and X0 are omitted, they are taken as zero matrices of appropriate dimensions.

Defining an idss object from a given model,

mss = idss(m1)

constructs an idss model from any idmodel or LTI system m1.

If m1 is an LTI system (ss, tf, or zpk) that has no InputGroup called 'Noise', the corresponding state-space matrices A, B, C, D are used to define the idss object. The Kalman gain K is then set to zero.

If the LTI system has an InputGroup called 'Noise', these inputs are interpreted as white noise with a covariance matrix equal to the identity matrix. The corresponding Kalman gain and noise variance are then computed and entered into the idss model together with A, B, C, and D.

Parameterizations

There are several different ways to define the parameterization of the state-space matrices. The parameterization determines which parameters can be adjusted to data by the parameter estimation routine pem.

idss Properties

In addition to these properties, idss objects also have all the properties of the idmodel object. See idmodel properties, Algorithm Properties, and EstimationInfo.

Note that all properties can be set and retrieved either by the set and get commands or by subscripts. Autofill applies to all properties and values, and these are case insensitive.

m.ss='can'
set(m,'ini','z')
p = eig(m.a)

For a complete list of property values, use get(m). To see possible value assignments, use set(m).

Examples

Define a continuous-time model structure corresponding to

with initial values

and estimate the free parameters.

A = [-0.2, 0; 0, -0.3]; B = [2;4]; C=[1, 1]; D = 0
m0 = idss(A,B,C,D);
m0.As = [NaN,0;0,NaN];
m0.Bs = [NaN;NaN];
m0.Cs = [1,1];
m0.Ts = 0;
m = pem(z,m0);

Estimate a model in free parameterization. Convert it to continuous time, then convert it to canonical form and continue to fit this model to data.

m1 = n4sid(data,3);
m1 = d2c(m1);
m1.ss ='can';
m = pem(data,m1);

All of this can be done at once by

m = pem(data,3,'ss','can','ts',0)

See Also

n4sid 
pem 
setstruc 

  


Recommended Products

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