Main Content

Analyze Design in PID Tuner

To determine whether your PID controller meets your requirements, you can analyze the system response using thePID Tunerresponse plots.

Plot System Responses

To determine whether the compensator design meets your requirements, you can analyze the system response using the response plots. On thePID Tunertab, select a response plot from theAdd Plotmenu. TheAdd Plotmenu also lets you choose from several step plots (time-domain response) or Bode plots (frequency-domain response).

For 1-DOF PID controller types such as PI, PIDF, and PDF, the software computes system responses based upon the following single-loop control architecture, whereGis your specified plant andCis the PID controller:

For 2-DOF PID controller types such as PI2, PIDF2, and I-PD, the software computes responses based upon the following architecture:

The system responses are based on the decomposition of the 2-DOF PID controller,C, into a setpoint componentCrand a feedback componentCy, as described inTwo-Degree-of-Freedom PID Controllers.

The following table summarizes the available responses for analysis plots.

Response Plotted System (1-DOF) Plotted System (2-DOF) Description
Plant G G Plant response. Use to examine plant dynamics.
Open-loop GC –GCy Response of the open-loop controller-plant system. Use for frequency-domain design.
Use when your design specifications include robustness criteria such as open-loop gain margin and phase margin.
Reference tracking

G C 1 + G C (fromrtoy)

G C r 1 G C y (fromrtoy)

Closed-loop system response to a step change in setpoint. Use when your design specifications include setpoint tracking.
Controller effort

C 1 + G C (fromrtou)

C r 1 G C y (fromrtou)

Closed-loop controller output response to a step change in setpoint. Use when your design is limited by practical constraints, such as controller saturation.
Input disturbance rejection

G 1 + G C (fromd1toy)

G 1 G C y (fromd1toy)

Closed-loop system response to load disturbance (a step disturbance at the plant input). Use when your design specifications include input disturbance rejection.
Output disturbance rejection

1 1 + G C (fromd2toy)

1 1 G C y (fromd2toy)

Closed-loop system response to a step disturbance at plant output. Use when you want to analyze sensitivity to modeling errors.

Compare Tuned Response to Block Response

By default,PID Tunerplots system responses using both:

  • The PID coefficient values in the controller block in the Simulink®model (Block response).

  • The PID coefficient values of the currentPID Tunerdesign (Tuned response).

As you adjust the currentPID Tunerdesign, such as by moving the sliders, theTuned responseplots change, while theBlock responseplots do not.

To write the currentPID Tunerdesign to the Simulink model, click. When you do so, the currentTuned responsebecomes theBlock response. Further adjustment of the current design creates a newTuned responseline.

To hide theBlock response, clickOptions, and clearShow Block Response.

View Numeric Values of System Characteristics

You can view the values for system characteristics, such as peak response and gain margin, either:

  • 直接在反应——用right-clic的阴谋k menu to add characteristics, which appear as blue markers. Then, left-click the marker to display the corresponding data panel.

  • In thePerformance and robustnesstable — To display this table, clickShow Parameters.

Export Plant or Controller toMATLABWorkspace

You can export the linearized plant model computed byPID Tunerto the MATLAB®workspace for further analysis. To do so, clickUpdate Blockand selectExport.

In the Export dialog box, check the models that you want to export. ClickOKto export the plant or controller to the MATLAB workspace as state-space (ss) model object orpidobject, respectively.

Refine the Design

If the response of the initial controller design does not meet your requirements, you can interactively adjust the design.PID Tunergives you twoDomainoptions for refining the controller design:

  • Timedomain (default) — Use theResponse Timeslider to make the closed-loop response of the control system faster or slower. Use theTransient Behaviorslider to make the controller more aggressive at disturbance rejection or more robust against plant uncertainty.

  • Frequency— Use theBandwidthslider to make the closed-loop response of the control system faster or slower (the response time is 2/wc, wherewcis the bandwidth). Use thePhase Marginslider to make the controller more aggressive at disturbance rejection or more robust against plant uncertainty.

In both modes, there is a tradeoff between reference tracking and disturbance rejection performance. For an example that shows how to use the sliders to adjust this tradeoff, seeTune PID Controller to Favor Reference Tracking or Disturbance Rejection.

Once you find a compensator design that meets your requirements, verify that it behaves in a similar way in the nonlinear Simulink model. For instructions, seeVerify the PID Design in Your Simulink Model.

Tip

To revert to the initial controller design after moving the sliders, clickReset Design.

See Also

Related Topics