ω —r − yK = 41 / (s + 1)³yN ? · P 0 · Z ?—
−2−101234−3−2−10123real partimaginary partNYQUIST PLANE L(jω)ω > 0ω < 0turns 0.00−1L(j0) = 12 →00.511.52−101time (cycles of the input)valueONE SINE TEST: IN AND OUTsine insine out
Lit wire with moving dashes: a signal is flowing along itBlocks: sine source, comparator, gain dial K, plant G(s), output, feedback switch, the count and the closed-loop polesPlots: the Nyquist plane and one sine test, both computed from the modelThe needle pinned at −1 points at the dot; its net clockwise turns are NA unity-feedback loop: a sine source, comparator, gain K, plant G(s) = 1/(s + 1)³ and output, with a switch that cuts or closes the feedback path. The Nyquist plane and the sine test are computed from the model: the dot is L(jω), and the needle pinned at −1 counts the encirclements N in Z = N + P. Sign conventions differ between books. Here the contour runs clockwise round the right half plane and N counts clockwise encirclements, so Z = N + P, as in Ogata §7-5. Nise counts anticlockwise turns and writes N = P − Z: the same rule with the sign of N flipped.

The question

  1. A gain K = 4 drives the plant G(s) = 1/(s + 1)³, and the output is fed back and subtracted. Stable means every root of 1 + K·G(s) = 0 has a negative real part. Can we tell without solving?

Draw the curve

Count the turns

Change the gain

The working

# step 1/11 · loop
# about: Sine source, Compare r − y, Gain K, Plant G(s), Output y, Feedback switch

plant      G(s) = 1 / (s + 1)³
open loop  L(s) = K·G(s),  K = 4
closed loop T(s) = L / (1 + L)

closed-loop poles: roots of 1 + L(s) = 0
stable  ⇔  all of them have real part < 0

Nyquist: decide this from L(jω) alone,
the open loop's response to sines.

Every point on the Nyquist plane is L(jω) = K / (1 + jω)³ computed exactly; the sines are the exact steady-state output, |L|·cos(ωt + ∠L). Turn counts come from adding the needle's angle changes along the sampled contour. The Python uses only the standard library. With python-control installed, ct.nyquist_response(ct.tf([12], [1, 3, 3, 1])).count returns the number of encirclements of −1.