System Identification Toolbox    
n4sid

Estimate state-space models using a subspace method.

Syntax

Description

The function n4sid estimates models in state-space form, and returns them as an idss object m. It handles an arbitrary number of input and outputs, including the time-series case (no input). The state-space model is in the innovations form

m: The resulting model as an idss object.

data: An iddata object containing the output-input data.

order: The desired order of the state-space model. If order is entered as a row vector (like order = [1:10]), preliminary calculations for all the indicated orders are carried out. A plot will then be given that shows the relative importance of the dimension of the state vector. More precisely, the singular values of the Hankel matrices of the impulse response for different orders are graphed. You will be prompted to select the order, based on this plot. The idea is to choose an order such that the singular values for higher orders are comparatively small. If order = 'best', a model of "best" (default choice) order is computed, among the orders 1:10. This is the default choice of order.

The list of property name/property value pairs may contain any idss and algorithm properties. See idss and Algorithm Properties.

idss properties that are of particular interest for n4sid are:

nk: The delays from the inputs to the outputs, a row vector with the same number of entries as the number of input channels. Default is nk = [1 1 ... 1]. Note that delays being 0 or 1 show up as zeros or estimated parameters in the D matrix. Delays larger than 1 means that a special structure of the A, B and C matrices are used to accommodate the delays. This also means that the actual order of the state-space model will be larger than order.

Algorithm properties that are special interest are:

Algorithm

The variants of the implemented algorithm are described in Section 10.6 in Ljung (1999).

Examples

Build a fifth order model from data with three inputs and two outputs. Try several choices of auxiliary orders. Look at the frequency response of the model.

Estimate a continuous-time model, in a canonical form parameterization, focusing on the simulation behavior. Determine the order yourself after seeing the plot of singular values.

See Also

idss, pem, Algorithm Properties

References

P. vanOverschee and B. DeMoor: Subspace Identification of Linear Systems: Theory, Implementation, Applications. Kluwer Academic Publishers, 1996.

M. Verhaegen: Identification of the deterministic part of MIMO state space models. Automatica, Vol 30, pp 61-74, 1994.

W.E. Larimore: Canonical variate analysis in identification, filtering and adaptive control. In Proc. 29th IEEE Conference on Decision and Control, pp 596-604, Honolulu, 1990.


  nyquist oe