Documentation |
On this page… |
---|
Dynamic models in System Identification Toolbox™ software are mathematical relationships between the system's inputs u(t) and outputs y(t). You can use these relationships to compute the current output from previous inputs and outputs. The general form of a model in discrete time is:
y(t) = f(u(t - 1), y(t - 1), u(t - 2), y(t - 2), . . .)
Such a model is nonlinear if the function f is a nonlinear function. f may represent arbitrary nonlinearities, such as switches and saturations.
In practice, all systems are nonlinear and the output is a nonlinear function of the input variables. However, a linear model is often sufficient to accurately describe the system dynamics. In most cases, you should first try to fit linear models.
Here are some scenarios when you might need the additional flexibility of nonlinear models:
You might need nonlinear models when a linear model provides a poor fit to the measured output signals and cannot be improved by changing the model structure or order. Nonlinear models have more flexibility in capturing complex phenomena than the linear models of similar orders.
From physical insight or data analysis, you might know that a system is weakly nonlinear. In such cases, you can estimate a linear model and then use this model as an initial model for nonlinear estimation. Nonlinear estimation can improve the fit by using nonlinear components of the model structure to capture the dynamics not explained by the linear model. For more information, see Using Linear Model for Nonlinear ARX Estimation and Using Linear Model for Hammerstein-Wiener Estimation.
You might have physical insight that your system is nonlinear. Certain phenomena are inherently nonlinear in nature, including dry friction in mechanical systems, actuator power saturation, and sensor nonlinearities in electro-mechanical systems. You can try modeling such systems using the Hammerstein-Wiener model structure, which lets you interconnect linear models with static nonlinearities. For more information, see Identifying Hammerstein-Wiener Models.
Nonlinear models might be necessary to represent systems that operate over a range of operating points. In some cases, you might fit several linear models, where each model is accurate at specific operating conditions. You can also try using the nonlinear ARX model structure with tree partitions to model such systems. For more information, see Identifying Nonlinear ARX Models.
If you know the nonlinear equations describing a system, you can represent this system as a nonlinear grey-box model and estimate the coefficients from experimental data. In this case, the coefficients are the parameters of the model. For more information, see Grey-Box Model Estimation.
Before fitting a nonlinear model, try transforming your input and output variables such that the relationship between the transformed variables becomes linear. For example, you might be dealing with a system that has current and voltage as inputs to an immersion heater, and the temperature of the heated liquid as an output. In this case, the output depends on the inputs via the power of the heater, which is equal to the product of current and voltage. Instead of fitting a nonlinear model to two-input and one-output data, you can create a new input variable by taking the product of current and voltage and then fitting a linear model to the single-input/single-output data.
You might have multiple data sets that capture the linear and nonlinear dynamics separately. For example, one data set with low amplitude input (excites the linear dynamics only) and another data set with high amplitude input (excites the nonlinear dynamics). In such cases, first estimate a linear model using the first data set. Next, use the model as an initial model to estimate a nonlinear model using the second data set. For more information, see Using Linear Model for Nonlinear ARX Estimation and Using Linear Model for Hammerstein-Wiener Estimation.
System Identification Toolbox supports these nonlinear models:
Nonlinear ARX models extend the linear ARX models to the nonlinear case and have this structure:
y(t) = f(y(t - 1), ..., y(t - na), u(t - nk), ..., u(t -nk -nb + 1))
where the function f depends on a finite number of previous inputs u and outputs y. na is the number of past output terms and nb is the number of past input terms used to predict the current output. nk is the delay from the input to the output, specified as the number of samples.
Typically, you use nonlinear ARX models as black-box structures. The nonlinear function of the nonlinear ARX model is a flexible nonlinearity estimator with parameters that need not have physical significance.
System Identification Toolbox software uses idnlarx objects to represent nonlinear ARX models. For more information about estimation, see Nonlinear ARX Models.
Hammerstein-Wiener models describe dynamic systems using one or two static nonlinear blocks in series with a linear block. The linear block is a discrete transfer function and represents the dynamic component of the model.
You can use the Hammerstein-Wiener structure to capture physical nonlinear effects in sensors and actuators that affect the input and output of a linear system, such as dead zones and saturation. Alternatively, use Hammerstein-Wiener structures as black box structures that do not represent physical insight into system processes.
System Identification Toolbox software uses idnlhw objects to represent Hammerstein-Wiener models. For more information about estimation, see Hammerstein-Wiener Models.
Nonlinear state-space models have this representation:
$$\begin{array}{l}\dot{x}\left(t\right)=F\left(x\left(t\right),u\left(t\right)\right)\\ y\left(t\right)=H\left(x\left(t\right),u\left(t\right)\right)\end{array}$$
where F and H can have any parameterization. A nonlinear ordinary differential equation of high order can be represented as a set of first order equations. You use the idnlgrey object to specify the structures of such models based on physical insight about your system. The parameters of such models typically have physical interpretations.
For more information about estimating nonlinear state-space models, see Grey-Box Model Estimation.