Introduction: Why Nyquist Plots Matter in Control Design

Nyquist plots are a cornerstone of frequency‑domain stability analysis for linear time‑invariant (LTI) control systems. Unlike Bode plots, which separate magnitude and phase into two independent graphs, a Nyquist plot preserves the full complex relationship in a single polar representation. This compact view makes it especially powerful for applying the Nyquist stability criterion, which uses the encirclement of the critical point ‑1 + j0 to evaluate closed‑loop stability. By examining the shape and position of the Nyquist curve, engineers can directly assess gain margin (GM) and phase margin (PM) — two metrics that quantify how much the system can tolerate parameter variations or time delays before becoming unstable. These margins are not merely academic values; they are practical safety buffers that ensure a design remains stable under real‑world manufacturing tolerances, aging components, and unexpected disturbances. This article provides a thorough, step‑by‑step guide to reading Nyquist plots for GM and PM, explains the underlying theory without unnecessary jargon, and shows how to compute margins both manually and with modern software tools.

The Nyquist Stability Criterion

The Nyquist criterion relates the open‑loop frequency response G() of a system to its closed‑loop stability. The key concept is the number of clockwise encirclements of the point ‑1 + j0 (often called the “critical point” or “stability margin point”) as ω varies from ‑∞ to +∞. For a rational open‑loop transfer function with P unstable poles (poles in the right‑half plane, RHP), the closed‑loop system is stable if and only if the Nyquist plot encircles the critical point exactly N = P times counter‑clockwise (or, equivalently, ‑P clockwise encirclements). Most practical designs assume P = 0 (open‑loop stable), so the Nyquist plot must not encircle the critical point at all. This is the foundation for measuring GM and PM: the closer the plot approaches ‑1, the closer the system is to instability.

Gain Margin and Phase Margin Defined

Gain margin and phase margin are derived from the open‑loop frequency response and indicate how much additional gain or phase shift can be tolerated before the closed‑loop system reaches the verge of instability (the point where the Nyquist curve passes exactly through ‑1 + j0).

  • Gain Margin (GM): The factor by which the open‑loop gain can be increased (in dB) before the Nyquist curve crosses the negative real axis at ‑1. It is measured at the frequency where the phase shift is ‑180° (the phase crossover frequency ωφ). A GM of, say, 6 dB means the gain can be doubled before instability.
  • Phase Margin (PM): The amount of additional negative phase (in degrees) that can be added at the gain crossover frequency ωg (where |G()| = 1) before the plot reaches the critical point. For example, a PM of 45° means the system can tolerate up to 45° of extra phase lag without becoming unstable.

Typical design guidelines recommend a GM of at least 6 dB and a PM of 30° to 60° for a robust control system. Higher margins improve robustness but may reduce bandwidth and response speed. Understanding how to read these values from a Nyquist plot is essential for making informed trade‑offs.

Reading Gain and Phase Margins from a Nyquist Plot

A Nyquist plot is the locus of the complex number G() in the real‑imaginary plane as ω sweeps from 0 to ∞. The critical point is at ‑1 (real axis) and 0 (imaginary axis). The following steps describe how to extract GM and PM from such a plot.

Step 1: Identify the Phase Crossover Point

The phase crossover occurs where the Nyquist curve crosses the negative real axis (imaginary part = 0, real part negative). At that intersection, the phase of G() is exactly ‑180°. The frequency at that crossing is ωφ. The distance from this intersection point to the critical point ‑1 along the real axis gives the gain margin. Specifically:

  • Let the real part of the intersection be x (e.g., ‑0.5). Then the gain margin in absolute units is 1 / |x|.
  • In decibels: GM (dB) = 20 log₁₀ (1 / |x|) = ‑20 log₁₀(|x|).
  • If the curve never crosses the negative real axis, the GM is infinite (the system cannot be made unstable by gain increase alone).

Step 2: Find the Gain Crossover Point

The gain crossover frequency ωg is the point where the magnitude of G() equals 1 (0 dB). In the Nyquist plane, this corresponds to the intersection of the curve with the unit circle (radius 1 centered at the origin). At that frequency, the angle (phase) of the vector from the origin to the point on the curve is measured. The phase margin is the angle difference between that phase and ‑180°:

  • PM = ∠G(g) + 180°.
  • A positive PM indicates stability; a negative PM means instability.

Step 3: Visual Interpretation on the Plot

On a well‑drawn Nyquist plot, the critical point is marked clearly. The gain margin is the reciprocal of the real‑axis distance from the curve to ‑1 at the phase crossover. The phase margin is the angle between the line drawn from the origin through the gain crossover point and the negative real axis. If the curve passes exactly through ‑1, both margins are zero and the system is marginally stable. Plots that encircle ‑1 indicate instability. Practice with examples (e.g., first‑order, second‑order, and marginally stable systems) builds intuition.

Practical Calculation Using Software Tools

While manual extraction from a Nyquist plot is conceptually valuable, engineers routinely use software to generate the plot and compute margins automatically. The two most common environments are MATLAB and Python’s control library.

MATLAB Example

MATLAB provides the nyquist function to create the plot and the margin function to compute GM, PM, and their respective crossover frequencies. Consider a simple open‑loop transfer function:

G = tf(1, [1 2 1 0]);   % G(s) = 1/(s^3 + 2s^2 + s)
nyquist(G);
[Gm, Pm, Wcg, Wcp] = margin(G);
disp(['Gain Margin (dB): ', num2str(20*log10(Gm))]);
disp(['Phase Margin (deg): ', num2str(Pm)]);

The output shows the margins directly. Wcg is the phase crossover frequency (where phase = ‑180°) and Wcp is the gain crossover frequency. You can also call margin(G) without outputs to see a plot with the margins annotated. MATLAB’s nyquist plot automatically highlights the critical point. Refer to the official MATLAB Nyquist documentation for more details.

Python (control library) Example

In Python, the control library offers similar functionality. Install with pip install control.

import control as ct
import matplotlib.pyplot as plt

s = ct.TransferFunction.s
G = 1 / (s**3 + 2*s**2 + s)
ct.nyquist(G, plt.subplot())
plt.show()
gm, pm, wcg, wcp = ct.margin(G)
print(f"Gain Margin: {20 * np.log10(gm):.2f} dB, Phase Margin: {pm:.2f} deg")

Both margin functions assume a unity‑feedback loop and calculate GM and PM from the open‑loop response. Note that the phase margin reported is often the minimum margin for systems with multiple gain crossover frequencies (see pitfalls below).

Manual Calculation Using Frequency Response Data

If you obtain experimental frequency response data (magnitude and phase at several frequencies), you can compute margins by interpolation. Identify the frequencies where phase passes through ‑180° (for GM) and where magnitude passes through 0 dB (for PM). Then approximate the margins using the nearest measured points. This manual method is useful when a transfer function model is unavailable. Many oscilloscopes and VNA (vector network analyzers) provide these measurements.

Interpreting Margins in Design Trade-offs

While large GM and PM guarantee robustness, they often come at the cost of performance. A system with very high gain margin might be sluggish because the crossover frequency is low. Conversely, a system with a PM of only 10° may have a fast response but will ring or become unstable if any parameter changes. The table below summarizes typical design ranges:

Margin TypeTypical RangeBehavior
Gain Margin6–12 dBGood robustness, moderate overshoot
Phase Margin30°–60° Well‑damped step response, good stability
GM < 3 dB or PM < 15°Fragile, sensitive to modelling errors

Engineers must balance these quantities according to the application. For example, a servo motor for a CNC machine may require a PM above 45° to avoid overshoot, while a temperature controller can tolerate lower margins because the process is slow. The Nyquist plot allows you to see the whole frequency response at once, making it easier to spot resonant peaks or non‑minimum phase zeros that degrade margins.

Common Pitfalls and Misinterpretations

Several subtle issues can arise when using Nyquist plots for margin assessment:

Multiple Phase Crossover Frequencies

Some systems cross the negative real axis more than once (e.g., systems with multiple 180° phase shifts). The gain margin is defined as the worst‑case (smallest) margin among all crossings. The Nyquist plot may encircle the critical point locally but not globally; visual inspection of the entire curve is mandatory. Software functions like margin typically return the minimum GM, but you should verify by looking at the plot.

Conditionally Stable Systems

In systems where the gain must be decreased to achieve stability (e.g., systems with a dip in the Nyquist curve that moves away from the critical point with increasing gain), the gain margin concept becomes ambiguous. The Nyquist plot may not even cross the negative real axis for certain frequency ranges. These designs require careful analysis; standard margins may not capture the full picture. A detailed resource on conditionally stable systems can help.

Phase Margin for Non‑Minimum Phase Systems

Systems with zeros in the right‑half plane (RHP) can have positive PM while still being unstable. The Nyquist plot might show a phase that crosses ‑180° at a magnitude greater than 1, leading to a misleading PM. Always cross‑check with a Bode plot or a full Nyquist encirclement analysis. The MathWorks margin function documentation discusses these edge cases.

Reading Margins from a Polar Plot vs. Cartesian Coordinates

Some Nyquist plots are displayed in polar coordinates (angle and magnitude) rather than real‑imaginary axes. Gain and phase margins are still extracted the same way, but you need to know the map from polar to Cartesian. Always ensure the plot uses a linear scale for both axes; logarithmic scales can distort the critical point distance.

Conclusion

Nyquist plots provide a direct visual method for evaluating the stability margins of a control system. By learning to identify the phase and gain crossover points on the plot, and by understanding how the distance to the critical point translates into gain margin and phase margin, you can quickly assess how much safety margin a design offers. Modern tools like MATLAB and Python’s control library automate the computation, but a solid grasp of the underlying concepts enables you to interpret results correctly and avoid common mistakes. Whether you design aircraft autopilots or robotic actuators, mastering Nyquist analysis is an essential skill for building robust, reliable closed‑loop systems. For further reading, consult the classic text Feedback Control of Dynamic Systems by Franklin, Powell, and Emami‑Naeini, or the online Control Tutorials for MATLAB which include interactive Nyquist examples.