Stability Analysis on Bode / Nyquist Plots
Stability Margins
We use [GM, PM] = margin(G) to find gain margin (GM) and phase margin (PM).
We use [GM, PM, wg, wphi] = margin(G) to find gain margin (GM), phase margin (PM), gain crossover frequency (wg), and phase crossover frequency (wphi).
The margin function is invoked in conjunction with the bode function to compute gain and phase margins. If the margin(G) is invoked without left-hand arguments, the Bode plot is automatically generated with gain margin, phase margin, gain crossover frequency, and phase crossover frequency labeled on the plot. This is illustrated in Fig. M8.7.
s = tf('s');
G = 1/(s^2+0.8*s+1);
margin(G);
Fig. M8.7
Stability margins, and gain and phase crossover frequencies are also given by the right-clicking feature on the plots generated using the MATLAB functions nyquist and bode .