The Graphical Tuning window provides right-click menus for all the views available. These views include the root-locus, open-loop Bode diagrams, Nichols plot, and the closed-loop Bode diagrams. The menu items in each of these views are identical. The design requirements, however, differ, depending on which view you are accessing the menus from.
You can use the right-click menu to design a compensator by adding poles, zeros, lead, lag, and notch filters. In addition, you can use this menu to add grids and zoom in on selected regions. Also, you can open each view's Property Editor to customize units and other elements of the display.
Note: Click items on the menu bar pictured below to get help contents. |
Open-Loop Right-Click Menu
Note that if you have a closed-loop response, the Gain Target menu item is replaced by Select Compensator.
The Add Pole/Zero menu options give you the ability to add dynamics to your compensator design, including poles, zeros, lead and lag networks, and notch filters. The following pole/zero configurations are available:
Real Pole
Complex Pole
Integrator
Real Zero
Complex Zero
Differentiator
Lead
Lag
Notch
In all but the integrator and differentiator, once you select the configuration, your cursor changes to an `x'. To add the item to your compensator design, place the x at the desired location on the plot and left-click your mouse. You will see the root locus design automatically update to include the new compensator dynamics.
The notch filter has three adjustable parameters. For a discussion about how to add and adjust notch filters, see "Adding a Notch Filter" in the Control System Toolbox™ Getting Started Guide.
Note: For systems with FRD plants, you cannot add or modify poles and zeros outside the plotted frequency range on Bode and Nichols plots. Instead, you can make such modifications using the Compensator Editor pane of the Control and Estimation Tools Manager. For more information, see Compensator Editor. |
This example shows you how to add a complex pair of poles to the open-loop Bode diagram. First, type
load ltiexamples controlSystemDesigner('bode',sys_dc)
at the MATLAB^{®} prompt. This opens the SISO Design Tool with the DC motor example loaded and the open-loop Bode diagram displayed in the Graphical Tuning window.
To add a complex pair of poles:
Select Add Pole/Zero->Complex Pole from the right-click menu
Place the mouse cursor where you want the pole to be located
Left-click to add the pole
Your Graphical Tuning window should look similar to this.
In the case of Bode diagrams, when you place a complex pole, the default damping value is 1, which means you have a double real pole. To change the damping, grab the red `x' by left-clicking on it and drag it upward with your mouse. You will see damping ratio change in the Status pane at the bottom of the SISO Design Tool.
Select Delete Pole/Zero to delete poles and zeros from your compensator design. When you make this selection, your cursor changes to an eraser. Place the eraser over the pole or zero you want to delete and left-click your mouse.
Note the following:
You can only delete compensator poles and zeros. Plant (G in the feedback structure pane) poles and zeros cannot be altered.
If you delete one of a pair of poles or zeros, the other member of the pair is also removed.
Edit Compensator opens the Compensator Editor pane in the SISO Design Task. You can use this pane to adjust the compensator gain and add or remove compensator poles and zeros from your compensator (C) or prefilter (F) design. See Compensator Editor for a discussion of this pane.
This feature is intended for users of the Simulink^{®} Control Design™ software. It is nonfunctional in the Control System Toolbox software.
Use Show to select/deselect the display of characteristics relevant to which view you are working with. This figure displays the Show submenu for the open-loop Bode diagram.
For this particular view, the options available are magnitude, phase, and stability margins. Selecting any of these toggles between showing and hiding the feature. A check next to the feature means that it is currently displayed on the Bode diagram plots. Although the characteristics are different for each view in the Graphical Tuning window, they all toggle on and off in the same manner.
This menu is enabled only when you import or open the SISO Design Tool with row or column arrays of LTI models.
Use Multimodel Display to view the responses of models in an LTI array as individual responses or as an envelope encompassing all responses on the Bode and Nichols plots.
On the Root Locus plot, use this menu to show or hide the pole/zero locations of all models in the array, except the nominal one.
For more information on control design analysis for multiple models, see Control Design Analysis of Multiple Models in the Getting Started Guide.
When designing compensators, it is common to have design specifications that call for specific settling times, damping ratios, and other characteristics. The Graphical Tuning window provides tools for design requirements that can help make the task of meeting design specifications easier.
The New Design Requirement dialog box lets you create design requirements by creating graphical representations for feasible and nonfeasible regions, automatically changes to reflect which design requirements are available for the view in which you are working. Select Design Requirements > New to open the New Design Requirement dialog box.
Since each view has a different set of design requirements, click the following links to go to the appropriate descriptions:
For row or column arrays of LTI models, the design requirements are for the nominal plant that you are designing the controller for. You can analyze the effects of this controller on the remaining models. See Control Design Analysis of Multiple Models in the Getting Started Guide.
For the root locus, you can use the following design requirements:
Use the Design requirement type drop-down list to select a design requirement. In each case, to specify the design requirement, enter the value in the Design requirement parameters pane. You can select any or all of them, or have more than one of each.
Settling Time. If you specify a settling time in the continuous-time root locus, a vertical line appears on the root locus plot at the pole locations associated with the settling time value provided (using a first-order approximation). This vertical line is exact for a second order system and is only an approximation for higher order systems. In the discrete-time case, the design requirement boundary is a curved line.
Percent Overshoot. Specifying percent overshoot in the continuous-time root locus causes two rays, starting at the root locus origin, to appear. These rays are the locus of poles associated with the percent value (using a second-order approximation). In the discrete-time case, the design requirement appears as two curves originating at (1,0) and meeting on the real axis in the left-hand plane.
Note that the percent overshoot (p.o.) design requirement can be expressed in terms of the damping ratio, as in this equation:
$$p.o.=100\mathrm{exp}\left(-\frac{\pi \zeta}{\sqrt{1-{\zeta}^{2}}}\right)$$
where ζ is the damping ratio.
Damping Ratio. Specifying a damping ratio in the continuous-time root locus causes two rays, starting at the root locus origin, to appear. These rays are the locus of poles associated with the damping ratio. In the discrete-time case, the design requirement boundary appears as curved lines originating at (1,0) and meeting on the real axis in the left-hand plane.
Natural Frequency. If you specify a natural frequency lower bound, a semicircle centered around the root locus origin appears. If you specify a natural frequency upper bound, the inverse of this semicircle appears. The radius equals the natural frequency.
Region Constraint. Specifying a region constraint at given locations causes black lines and a yellow area to appear. The vertices of this free-form piecewise region are defined by the specified real and imaginary values.
This example adds a damping ratio design requirement of 0.707.
At the MATLAB prompt, type the following:
load ltiexamples controlSystemDesigner(sys_dc)
This opens the SISO Design Tool with the DC motor example imported.
From the root locus right-click menu, select Design Requirement > New to open the New Design Requirement dialog box.
To add the design requirement, select Damping Ratio as the design requirement. Click OK to accept the default damping ratio of 0.707.
The Graphical Tuning window should now look similar to this figure.
Damping Ratio Requirements in the Root Locus
The two rays centered at (0,0) represent the damping ratio boundaries. The dark edge is the region boundary, and the shaded area outlines the exclusion region. This figure explains what this means for this design requirement.
You can, for example, use this design requirement to ensure that the closed-loop poles, represented by the red squares, have some minimum damping. Try adjusting the gain until the damping ratio of the closed-loop poles is 0.7.
For both the open- and closed-loop Bode diagrams, you have the following options:
Specifying any of these design requirements causes lines to appear in the Bode magnitude curve. To specify an upper or lower gain limit, enter the frequency range, the magnitude limit, and/or the slope in decibels per decade, in the appropriate fields of the New design requirement dialog box. You can have as many gain limit design requirements as you like in your Bode magnitude plots.
Upper Gain Limit. You can specify one or multiple piecewise linear upper gain limits over a frequency range, which appear as straight lines on the Bode magnitude curve. You must select frequency limits, the upper gain limit in decibels, and the slope in dB/decade.
Lower Gain Limit. You can specify one or multiple lower gain limit in the same fashion as the upper gain limit.
Gain and Phase Margin. You can specify a lower bound for the gain, the phase margin, or both. The specified bounds appear in text on the Bode magnitude plot.
This example shows you how to add two upper gain limit requirements to the open-loop Bode diagram.
At the MATLAB prompt, type the following:
load ltiexamples controlSystemDesigner('bode',Gservo)
This opens the SISO Design Tool with the servomechanism model loaded.
Use the right-click menu to add a grid.
To add an upper gain limit requirement of 0 dB from 10 rad/sec to 100 rad/sec, open the New Design Requirement dialog box and select Upper gain limit from the pull-down menu. Fill in the dialog box fields as shown in the following figure.
Your Graphical Tuning window should now look like this (you may have to adjust some axis limits).
To constrain the roll off, open the New Design Requirement dialog box and add an upper gain limit from 100 rad/sec to 1000 rad/sec with a slope of -20 db/decade. This figure shows the result.
With these design requirements in place, you can see how much you can increase the compensator gain and still meet design specifications.
Note that you can change the design requirements by moving them with your mouse. See Editing Design Requirements for more information.
For open-loop Nichols plots, you have the following design requirement options:
Specifying any of these design requirements causes lines or curves to appear in the Nichols plot. In each case, to specify the design requirement, enter the value in the Design requirement parameters pane. You can select any or all of them, or have more than one of each.
Phase Margin. Specify a minimum phase margin at a given location. For example, you can require a minimum of 30 degrees at the -180 degree crossover. The phase margin specified should be a number greater than 0. The location must be a -180 plus a multiple of 360 degrees. If you enter an invalid location point, the closest valid location is selected.
Gain Margin. Specify a gain margin at a given location. For example, you can require a minimum of 20 dB at the -180 degree crossover. The location must be -180 plus a multiple of 360 degrees. If you enter an invalid location point, the closest valid location is selected.
Closed-Loop Peak Gain. Specify a peak closed-loop gain at a given location. The specified dB value can be positive or negative. The design requirement follows the curves of the Nichols plot grid, so it is recommended that you have the grid on when using this feature.
Gain-Phase Design Requirement. Specify both a gain and phase design requirement at a given location. The vertices of this free-form piecewise region are defined by the specified open-loop phase and open-loop gain values.
This example shows how to add a closed-loop peak gain design requirement to the Nichols plot.
At the MATLAB prompt, type the following:
load ltiexamples controlSystemDesigner('nichols',Gservo)
This opens the SISO Design Tool with Gservo
imported
as the plant.
Use the right-click menu to add a grid, as this figure shows.
To add closed-loop peak gain of 1 dB at -180 degrees, open the New Design Requirement dialog box and select Closed-Loop Peak Gain from the pull-down menu. Set the peak gain field to 1 dB.
The figure shows the resulting design requirement.
As long as the curve is outside of the gray region, the closed-loop gain is guaranteed to be less than 1 dB. Note that this is equivalent, up to second order, to specifying the peak overshoot in the time domain. In this case, a 1 dB closed-loop peak gain corresponds to an overshoot of 15%.
To edit an existing design requirement, left-click on the design requirement boundary to select it. Two black squares appear on the design requirement when it is selected. In general, there are two ways to adjust a design requirement:
Click on the design requirement boundary and drag it. Generally, this does not change the shape of the boundary. That is, the adjustment is strictly a translation of the design requirement.
Grab a black square and drag it. In this case, you can rotate, expand, and/or contract the design requirement.
For example, in Bode diagrams you can move an upper gain limit by clicking on it and moving it anywhere in the plot region. As long as you haven't grabbed a black square, the length and slope of the gain limit will not change as you move the line. On the other hand, you can change the slope of the upper gain limit by grabbing one of the black squares and rotating the line. In all cases, the Status pane at the bottom of the Graphical Tuning window displays the design requirement values as they change.
This figure shows the process of editing an upper gain limit in the open-loop Bode diagram.
An alternative way to adjust a design requirement is to select Design Requirements->Edit from the right-click menu. The Edit Design Requirement window opens.
To adjust a design requirement, select the boundary by clicking on it and change the values in the fields of the Design requirement parameters pane. If you have additional design requirement in, for example, the Bode diagram, you can edit them directly from this window by selecting Open-Loop Bode from the Editor menu.
To delete a design requirement, place your cursor directly over the design requirement yellow region. Right-click to open a menu containing Edit and Delete. Select Delete from the menu list; this eliminates the design requirement. You can also delete design requirements by left-clicking on a design requirement boundary and then pressing the BackSpace or Delete key on your keyboard.
Finally, you can delete design requirements by selecting Undo Add Design Requirement from the Edit menu, or pressing Ctrl+Z if adding design requirements was the last action you took.
Grid adds a grid to the selected plot.
Selecting Full View causes the plot to scale limits so that the entire curve is visible.
Properties opens the Property Editor, which is a GUI for customizing root locus, Bode diagrams, and Nichols plots inside the Graphical Tuning window. The Property Editor automatically reconfigures as you select among the different plots open.
This picture shows the open window for the root locus.
You can use this window to change titles and axis labels, reset axes limits, add grid lines, and change the aspect ratio of the plot. Note that you can also activate this menu by double-clicking anywhere in the root locus away from the curve.
The are only three panes in the Property Editor: Labels, Limits, and Options. The configuration of each page differs, depending on whether you're working with the root-locus, Bode diagrams, or the open-loop Nichols plot. Click the Help button on the Property Editor you have open to view information specific to that editor, or click on the links below:
This option allows you to select which compensator to edit for closed-loop Bode response.
The Status pane is located at the bottom of the Graphical Tuning window. It displays the most recent action you have performed, occasionally provides advice on how to use the window, and tracks key parameters when moving objects in the design views.