Bode Response of Simulink Model

This example shows how to use the Linear Analysis Tool to linearize a model at the operating point specified in the model. The model operating point consists of the model initial state values and input signals.

The Linear Analysis Tool linearizes at the model operating point by default. If you want to specify a different operating point for linearization, see Linearize at Trimmed Operating Point.

 Code Alternative

  1. Open Simulink® model.

    sys = 'watertank';

    The Water-Tank System block represents the plant in this control system and includes all of the system nonlinearities.

  2. Open the Linear Analysis Tool for the model.

    In the Simulink Editor, select Analysis > Control Design > Linear Analysis.

  3. In the Simulink Editor, define the portion of the model to linearize:

    1. Right-click the PID Controller block output signal, which is the input to the plant. Select Linear Analysis Points > Input Perturbation.

    2. Right-click the Water-Tank System output signal, and select Linear Analysis Points > Open-loop Output.

    Inserting this open loop point removes the effects of the feedback signal on the linearization without changing the model operating point.

    When you add linear analysis points, marker appear at their locations in the model.

  4. In the Plot Result list, select a visualization.

    For example, select New Bode.

  5. Linearize the model.

    Click .

    The Bode plot of the linearized system appears.

    The linearized system, linsys1 appears in the Linear Analysis Workspace.

    linsys1 represents the system linearized at the model operating point. If you do not specify an operating point for linearization, the Linear Analysis Tool uses the model operating point by default.

  6. Close Simulink model.

Was this topic helpful?