Robust Control Toolbox™ Previous page   Next Page 
loopmargin
 Provide feedback about this page

Comprehensive stability margin analysis of LTI and Simulink® feedback loops

Syntax

Description

[cm,dm,mm] = loopmargin(L) analyzes the multivariable feedback loop consisting of the loop transfer matrix L (size N-by-N) in negative feedback with an N-by-N identity matrix.

cm, or classical gain and phase margins, is an N-by-1 structure corresponding to loop-at-a-time gain and phase margins for each channel (See allmargin for details on the fields of cm.).

dm is an N-by-1 structure corresponding to loop-at-a-time disk gain and phase margins for each channel. The disk margin for the i-th feedback channel defines a circular region centered on the negative real axis at the average GainMargin (GM), e.g. , (GMlow+GMhigh)/2, such that L(i,i) does not enter that region. Gain and phase disk margin bounds are derived from the radius of the circle, calculated based on the balanced sensitivity function (see Algorithm section).

mm, or multiloop disk margin, is a structure corresponding to simultaneous, independent, variations in the individual channels of loop transfer matrix L. mm calculates the largest region such that for all gain and phase variations, occurring independently in each channel, lie inside the region, that the closed-loop system is stable. Note that mm is a single structure, independent of because the number of channels, variations in all channels are handled simultaneously. As in the case for disk margin, the guaranteed bounds are calculated based on a balanced sensitivity function.

If L is a ss/tf/zpk object, the frequency range and number of frequency points used to calculate dm and mm margins are chosen automatically.

Output arguments can be limited to only those requested using an optional character string argument. [m1,m2] = loopmargin(L,'m,c') returns the multi-loop diskmargin ('m') in m1, and the classical margins ('c') in m2. Use 'd' to specify the disk margin. This optional second argument may be any combination, in any order, of the 3 characters 'c', 'd' and 'm'.

[cmi,dmi,mmi,cmo,dmo,mmo,mmio] = loopmargin(P,C) analyzes the multivariable feedback loop consisting of the controller C in negative feedback with the plant, P. C should only be the compensator in the feedback path, without reference channels, if it is a 2-dof architecture. That is, if the closed-loop system has a 2-dof architecture the reference channel of the controller should be eliminated, resulting in a 1-dof architecture, as shown.

cmi,dmi and mmi structures correspond to the classical loop-at-a-time gain and phase margins, disk margins and multiloop channel margins at the plant input respectively. The structures cmo, dmo and mmo have the same fields as described for cmi, dmi and mmi though they correspond to the plant outputs. mmio, or multi-input/multi-output margins, is a structure corresponding to simultaneous, independent, variations in all the individual input and output channels of the feedback loops. mmio has the same fields as mmi and mmo.

If the closed-loop system is an ss/tf/zpk, the frequency range and number of points used to calculate cm, dm and mm margins are chosen automatically.

Output arguments can be limited to only those requested using an optional character string argument. [m1,m2,m3] = loopmargin(L,'mo,ci,mm') returns the multi-loop diskmargin at the plant output ('mo') in m1, the classical margins at the plant input (`ci') in m2, and the disk margins for simultaneous, independent variations in all input and output channels ('mm') in m3. This optional third argument may be any comnination, in any order, of the 7 character pairs 'ci', 'di', 'mi', 'co', 'do', 'mo', and 'mm'.

Usage with Simulink®

[cm,dm,mm] = loopmargin(Model,Blocks,Ports) does a multi-loop stability margin analysis using Simulink® Control Design™ software. Model specifies the name of the Simulink diagram for analysis. The margin analysis points are defined at the output ports (Ports) of blocks (Blocks) within the model. Blocks is a cell array of full block path names and Ports is a vector of the same dimension as Blocks. If all Blocks have a single output port, then Ports would be a vector of ones with the same length as Blocks.

Three types of stability margins are computed: loop-at-a-time classical gain and phase margins (cm), loop-at-a-time disk margins (dm) and a multi-loop disk margin (mm).

[cm,dm,mm] = loopmargin(Model,Blocks,Ports,OP) uses the operating point object OP to create linearized systems from the Simulink Model.

[cm,dm,mm,info] = loopmargin(Model,Blocks,Ports,OP) returns info in addition to the margins. info is a structure with fields OperatingPoint, LinearizationIO and SignalNames corresponding to the analysis.

Margin output arguments can be limited to only those requested using an optional charcter string argument. INFO is always the last output. For example, [mm,cm,info] = loopmargin(Model,Blocks,Ports,'m,c') returns the multi-loop diskmargin (`m') in mm, the classical margins (`c') in cm, and the info structure.

Basic Syntax

[cm,dm,mm] = loopmargin(L) cm is calculated using the allmargin command and has the same fields as allmargin. The cm is a structure with the following fields:

Field
Description
GMFrequency
All -180 deg crossover frequencies (in rad/s)
GainMargin
Corresponding gain margins (GM = 1/L where L is the gain at crossover)
PhaseMargin
Corresponding phase margins (in degrees)
PMFrequency
All 0 dB crossover frequencies (in rad/s)
DelayMargin
Delay margins (in seconds for continuous-time systems, and multiples of the sample time for discrete-time systems)
Stable
1 if nominal closed loop is stable, 0 otherwise. If L is a frd or ufrd object, the Stable flag is set to NaN.

dm, or Disk Margin, is a structure with the following fields

Field
Description
GainMargin
Smallest gain variation (GM) such that a disk centered at the point -(GM(1) + GM(2))/2 would just touch the loop transfer function
PhaseMargin
Smallest phase variation, in degrees, corresponding to the disk described in the GainMargin field (degrees)
Frequency
Associated with GainMargin/PhaseMargin fields (rad/s)

mm is a structure with the following fields:

Field
Description
GainMargin
Guaranteed bound on simultaneous, independent, gain variations allowed in all plant channels
PhaseMargin
Guaranteed bound on simultaneous, independent, phase variations allowed in all plant channels (degrees)
Frequency
Associated with GainMargin/PhaseMargin fields (rad/s)

Example

MIMO Loop-at-a-Time Margins

This example is designed to illustrate that loop-at-a-time margins (gain, phase, and/or distance to -1) can be inaccurate measures of multivariable robustness margins. You will see that margins of the individual loops can be very sensitive to small perturbations within other loops.

The nominal closed-loop system considered here is as follows

G and K are 2-by-2 multiinput/multioutput (MIMO) systems, defined as

Set alpha:= 10, construct G in state-space form, and compute its frequency response.

First consider the margins at the input to the plant. The first input channel has infinite gain margin and 90 degrees of phase margin based on the results from the allmargin command, smi(1). The disk margin analysis, dmi, of the first channel provides similar results.

The second input channel has a gain margin of 2.105 and infinite phase margin based on the single-loop analysis, cmi(2). The disk margin analysis, dmi(2), which allows for simultaneous gain and phase variations a loop-at-a-time results in maximum gain margin variations of 0.475 and 2.105 and phase margin variations of +/- 39.18 degs.

The multiple margin analysis of the plant inputs corresponds to allowing simultaneous, independent gain and phase margin variations in each channel. Allowing independent variation of the input channels further reduces the tolerance of the closed-loop system to variations at the input to the plant. The multivariable margin analysis, mmi, leads to a maximum allowable gain margin variation of 0.728 and 1.373 and phase margin variations of +/- 17.87 deg. Hence even though the first channel had infinite gain margin and 90 degrees of phase margin, allowing variation in both input channels leads to a factor of two reduction in the gain and phase margin.

The guaranteed region of phase and gain variations for the closed-loop system can be illustrated graphically. The disk margin analysis, dmi(2), indicates the closed-loop system will remain stable for simultaneous gain variations of 0.475 and 2.105 (± 6.465 dB) and phase margin variations of ± 39.18 deg in the second input channel. This is denoted by the region associated with the large ellipse in the following figure. The multivariable margin analysis at the input to the plant, mmi, indicates that the closed-loop system will be stable for independent, simultaneous, gain margin variation up to 0.728 and 1.373 (±2.753 dB) and phase margin variations up to ± 17.87 deg (the dark ellipse region) in both input channels.

The output channels have single-loop margins of infinite gain and 90 deg phase variation. The output multivariable margin analysis, mmo, leads to a maximum allowable gain margin variation of 0.607 and 1.649 and phase margin variations of +/- 27.53 degs. Hence even though both output channels had infinite gain margin and 90 degrees of phase margin, simultaneous variations in both channels significantly reduce the margins at the plant outputs.

If all the input and output channels are allow to vary independently, mmio, the gain margin variation allow are 0.827 and 1.210 and phase margin variations allowed are +/- 10.84 deg.

Algorithm

Two well-known loop robustness measures are based on the sensitivity function S=(I-L)-1 and the complementary sensitivity function T=L(I-L)-1 where L is the loop gain matrix associated with the input or output loops broken simultaneously. In the following figure, S is the transfer matrix from summing junction input u to summing junction output e. T is the transfer matrix from u to y. If signals e and y are summed, the transfer matrix from u to e+y is given by (I+L)·(I-L)-1, the balanced sensitivity function. It can be shown (Dailey, 1991, Blight, Daily and Gangass, 1994) that each broken-loop gain can be perturbed by the complex gain (1+capital delta)(1-capital delta) where |capital delta|<1/µ(S+T) or |capital delta|<1/sigmamax(S+T) at each frequency without causing instability at that frequency. The peak value of µ(S+T) or sigmamax(S+T) gives a robustness guarantee for all frequencies, and for µ(S+T) the guarantee is nonconservative (Blight, Daily and Gangass, 1994).

This figure shows a comparison of a disk margin analysis with the

the classical notations of gain and phase margins.

The Nyquist plot is of the loop transfer function L(s)

The disk margin and multiple channel margins calculation involve the balanced sensitivity function S+T. For a given peak value of µ(S+T), any simultaneous phase and gain variations applied to each loop independently will not destabilize the system if the perturbations remain inside the corresponding circle or disk. This corresponds to the disk margin calculation to find dmi and dmo.

Similarly, the multiple channel margins calculation involves the balanced sensitivity function S+T. Instead of calculating µ(S+T) a single loop at a time, all the channels are included in the analysis. A µ- analysis problem is formulated with each channel perturbed by an independent, complex perturbation. The peak µ(S+T) value guarantees that any simultaneous, independent phase and gain variations applied to each loop simultaneously will not destabilize the system if they remain inside the corresponding circle or disk of size µ(S+T).

Reference

Barrett, M.F., Conservatism with robustness tests for linear feedback control systems, Ph.D. Thesis, Control Science and Dynamical Systems, University of Minnesota, 1980.

Blight, J.D., R.L. Dailey, and D. Gangsass, "Practical control law design for aircraft using multivariable techniques," International Journal of Control, Vol. 59, No. 1, 1994, pp. 93-137.

Bates, D., and I. Postlethwaite, "Robust Multivariable Control of Aerospace Systems," Delft University Press, Delft, The Netherlands, ISBN: 90-407-2317-6, 2002.

See Also
allmargin   Finds all stability margins and crossover frequencies

bode        Plots Bode frequency response of LTI models

loopsens    Calculates sensitivity functions of feedback loop

mussv       Calculate bounds on the Structured Singular Value (µ)

robuststab  Calculate stability margins of uncertain systems

wcgain      Calculates worst-case gain of a system

wcsens      Calculate worst-case sensitivities for feedback loop

wcmargin    Calculate worst-case margins for feedback loop


 Provide feedback about this page 

Previous page frd/loglog loopsens Next page

 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS