| System Identification Toolbox™ | ![]() |
| On this page… |
|---|
Why Compute a Linearize Approximation of a Nonlinear Model? Choosing Your Linear Approximation Approach Linear Approximation of Nonlinear Black-Box Models for a Given Input |
Linearizing a nonlinear model is required for linear control design and linear analysis. After you linearize your model, you can use Control System Toolbox™ software to design a controller and perform linear analysis. For more information, see Using Models with Control System Toolbox™ Software.
System Identification Toolbox™ software provides two approaches for computing a linear approximation of Nonlinear ARX and Hammerstein-Wiener models.
To generate a linear approximation of a nonlinear model for a given input signal, use the linapp command. The resulting model is only valid for the same input you use to generate the linear approximation. For more information, see Linear Approximation of Nonlinear Black-Box Models for a Given Input.
If you want a tangent approximation of the nonlinear dynamics that is accurate near the system operating point, use the linearize command. The resulting model is a first-order Taylor series approximation for the system about this operating point, which is defined by a constant input and model state values. For more information, see Tangent Linearization of Nonlinear Black-Box Models.
linapp computes the best linear approximation—in an mean-square-error sense—of a nonlinear ARX or Hammerstein-Wiener model for a given input or a randomly generated input.
linapp estimates the best linear model that is structurally similar to the original nonlinear model and provides the best fit between a given input and the corresponding simulated response of the nonlinear model.
To compute a linear approximation of a nonlinear black-box model for a given input, you must have the following variables in the MATLAB workspace:
Nonlinear ARX (idnlarx) or Hammerstein-Weiner (idnlhw) model.
Input signal for which you want to obtain a linear approximation, specified as a real matrix or an iddata object.
You use the specified input signal to compute a linear approximation, as follows:
For nonlinear ARX models, linapp estimates a linear ARX model using the same model orders na, nb, and nk as the original model.
For Hammerstein-Wiener models, linapp estimates a linear Output-Error (OE) model using the same model orders nb, nf, and nk.
To compute a linear approximation of a nonlinear black-box model for a randomly generated input, you must also have the minimum and maximum scalar input values for generating white-noise input with a magnitude in this rectangular range, umin and umax in the MATLAB workspace.
For more information, see the linapp reference page.
The resulting linear model is only valid for the same input signal as you the one you used to generate the linear approximation.
linearize computes a first-order Taylor series approximation for nonlinear system dynamics about and operating point, which is defined by a constant input and model state values.
To compute a tangent linear approximation of a nonlinear black-box model, you must have the following variables in the MATLAB workspace:
Nonlinear ARX (idnlarx) or Hammerstein-Weiner (idnlhw) model.
Operating point
The resulting linear model is accurate in the local neighborhood of the operating conditions you used to compute the linear approximation.
To specify a known the operating point for your system, you must specify the constant input and the states. For more information about state definitions for each type of parametric model, see the corresponding reference pages:
If you do not know the operating point values for your system, see Computing Operating Points for Nonlinear Black-Box Models. For more information, see the linearize(idnlarx) or linearize(idnlhw) reference page.
The linearize command for computing a first-order Taylor series approximation for the system requires that you specify an operating point. An operating point is defined by a constant input and model state values.
If you do not know the operating conditions of your system, you can use the findop command to compute the operating point from specifications, as follows:
You can compute an operating point from steady-state specifications, as follows:
Using values of input and output signals.
If either the steady-state input or output value is unknown, you
can specify it as NaN to estimate this value.
This is especially useful when modeling MIMO systems, where only a
subset of the input and output steady-state values are known.
Using more complex steady-state specifications.
You construct an object to store the specifications for computing the operating point, including input and output bounds, known values, and initial guesses. For more information, see operspec(idnlarx) or operspec(idnlhw).
For more information, see the findop(idnlarx) or findop(idnlhw) reference page.
You can compute an operating point at a specific time during the model simulation (snapshot). You must specify the snapshot time and the input value for which you want to compute the operating point. If you do not know the equilibrium values of states, you can compute them using an input level that causes the output level to reach a steady-state after a finite time.
If your system is at steady state and you are working with linear or Hammerstein-Wiener models, you do not need to specify the initial states because they do not affect the steady-state values. For nonlinear ARX models, there can be multiple steady states and you should generally specify the initial states because they can affect steady-state values. By default, initial states are set to zero.
However, if your system has not reached steady state at the snapshot time, you must specify the initial states. If you do not know the initial states, you can compute them using the findstates command. For more information, see the findstates(idnlarx) or findstates(idnlhw) reference pages.
![]() | Next Steps After Estimating Nonlinear Black-Box Models | Estimating ODE Parameters (Grey-Box Models) | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |