r = 1K = 4.001/(s(s+2))PM ?y 0.00011.163ζ ?OS ?
0.1110100-40-20020ω (rad/s)dBBODE MAGNITUDE |L(jω)|ωc0 dB0.1110100-180-135-90ω (rad/s)degBODE PHASE ∠L(jω)−180°PM012345600.511.5t (s)yCLOSED-LOOP STEP y(t)predictedK 4K 25K 2K 2.86
Lit wire with moving dashes: a signal is flowing along itBack row: the loop (step, compare, gain dial, plant, output). Front row: phase margin → ζ → overshootPlots: Bode magnitude and phase of the open loop, and the closed-loop step responses, all computedThe puck's height above the output block is y(t); the dashed tick is the predicted peakA unity-feedback loop with a gain dial K and the plant 1/(s(s+2)). The phase margin read off the open-loop Bode plot passes through the damping ratio to the overshoot of the closed-loop step, and the puck above the output shows the real swing. The phase-margin formula PM = atan(2ζ/√(√(1+4ζ⁴)−2ζ²)) holds for an open loop of the form ωn²/(s(s+2ζωn)), whose closed loop is the standard second-order system (Nise, ch. 10). For this loop the phase only approaches −180° as the frequency goes to infinity, so the gain margin is infinite at every gain. That is why the phase margin, not the gain margin, predicts the overshoot here.

Read the margin

  1. A gain K = 4 drives a plant 1/(s(s+2)), and the output is fed back and compared with the input. We will apply a step of 1. How far past 1 will the output swing? We answer from the open-loop Bode plot, before running anything.

Margin to overshoot

Turn the gain

Design with it

What is happening

# step 1/12 · loop
# about: Step input, Compare, Gain dial, Plant, Output

open loop    L(s) = K / (s (s + 2)),  K = 4
closed loop  T(s) = L / (1 + L)
input        r = unit step (0 → 1 at t = 0)

question: the peak of y(t), read from
the plot of L(jω) alone

The plant 1/(s(s+2)) is an illustrative motor-like model (an integrator and one pole at 2 rad/s). Every curve and number in the figure is computed from it: the Bode curves from L(jω), the step curves from the exact second-order step response. The Python on each step is plain Python 3 (math and cmath). python-control's margin(L) returns the same phase margin and crossover frequency.