Main Content

Validate Linearization in Frequency Domain Using Model Linearizer

This example shows how to validate linearization results using an estimated linear model.

In this example, you linearize a Simulink® model using the I/Os specified in the model. You then estimate the frequency response of the model using the same operating point (model initial condition). Finally, you compare the estimated response to the exact linearization result.

Linearize Model

Open the model.

openExample("scdDCMotor")

Open the Model Linearizer app for the model.

In the Simulink model window, in the Apps gallery, click Model Linearizer.

Linearize the model at the default operating point and analysis I/Os, and generate a bode plot of the result. To do so, click Bode.

The Bode plot of the linearized plant appears, and the linearized plant linsys1 appears in the Linear Analysis Workspace.

Estimate Frequency Response of Model

For frequency-domain validation of linearization, use a sinestream input signal. By analyzing one sinusoidal frequency at a time, the software can ignore some of the impact of nonlinear effects.

Input SignalUse WhenSee Also
SinestreamAll linearization inputs and outputs are on continuous signals.frest.Sinestream
Sinestream with fixed sample timeOne or more of the linearization inputs and outputs is on a discrete signalfrest.createFixedTsSinestream

You can create a sinestream signal based on your linearized model. The software uses the linearized model characteristics to accurately predict the number of sinusoid cycles at each frequency to reach steady state.

When diagnosing the frequency response estimation, you can use the sinestream signal to determine whether the time series at each frequency reaches steady state.

Create a sinestream input signal for computing an approximation of the model by frequency response estimation. On the Estimation tab, in the Input Signal drop-down list, select Sinestream.

Initialize the input signal frequencies and parameters based on the linearized model.

In the System drop-down list, select linsys1. Click Initialize frequencies and parameters.

The frequency display in the dialog box is populated with frequency points. The software chooses the frequencies and input signal parameters automatically based on the dynamics of linsys1.

Set the amplitude of the input signal at all frequency points to 1. In the frequency display, select all the frequency points.

Enter 1 in the Amplitude field, and click OK. The new input signal in_sine1 appears in the Linear Analysis Workspace.

Estimate the frequency response and plot its frequency response on the existing Bode plot of the linearized system response. Click Bode Plot 1.

Examine Estimation Results

Bode Plot 1 now shows the Bode responses for the estimated model and the linearized model.

The frequency response for the estimated model matches that of the linearized model.

For more information about frequency response estimation, see Frequency Response Estimation Basics.

See Also

Related Topics