Course materials · Control Engineering II

Frequency-Domain Stability

English translation

Execution setup

The Python option uses python-control. If the module is missing, run %pip install control==0.10.2 in a Colab or Jupyter code cell.

Learning objectives

Before simulating all time responses, try assessing stability from the frequency response and open-loop poles.

Unstable open-loop and closed-loop poles

Starting conditions

G(s)=s2+10s+24s2−8s+15G(s)=\frac{s^2+10s+24}{s^2-8s+15}, K=.5K=.5,1. Use negative unity feedback.

Procedure

  1. Count P, the number of open-loop right-half-plane poles.
  2. Plot the Nyquist plot for each K, and directly calculate Z, the number of closed-loop poles in the right half-plane.
  3. State your sign convention for the direction of encirclements of -1, and check the relationship among P, the encirclement count, and Z.

Results to retain

import numpy as np
import matplotlib.pyplot as plt
import control as ctl
s = ctl.tf('s')
G=(s*s+10*s+24)/(s*s-8*s+15)
print('open-loop',ctl.poles(G))
for k in [.5,1.]:print(k,ctl.poles(ctl.feedback(k*G,1)))
# TODO: Record the Nyquist plot and number of encirclements.

Record results and self-check

K:

P:

Number and direction of encirclements:

Z:

Closed-loop stability:

Points to check

Stability margins and gain changes

Starting conditions

Compare G(s)=50s3+9s2+30s+40G(s)=\frac{50}{s^3+9s^2+30s+40} and K∈{1,3,5}K\in\{1,3,5\}.

Procedure

  1. Find the gain margin, phase margin, and corresponding crossover frequencies using margin(K*G).
  2. Report gain margin separately as a linear ratio and in dB using 20log10.
  3. Examine each set of closed-loop poles and time response, and explain the relationship between margins and stability.

Results to retain

import numpy as np
import matplotlib.pyplot as plt
import control as ctl
s = ctl.tf('s')
G=50/(s**3+9*s*s+30*s+40)
for k in [1,3,5]:
 gm,pm,wcg,wcp=ctl.margin(k*G)
 print(k,gm,pm,wcg,wcp)
# TODO: Distinguish the ratio and dB columns, and check the poles and responses.

Record results and self-check

K:

GM [ratio]:

GM [dB]:

PM [deg]:

Crossover ω [rad/s]:

Stability:

Points to check

Changing the frequency range

Starting conditions

For the same G, compare examining only ω=[.1,1,10] with examining logspace(-2,3,1000).

Procedure

  1. Compare gain and phase on both grids.
  2. Describe the information missed when assessing crossover points and stability margins using only three sparse points.
  3. Record both calculated values and visual evidence to distinguish assessment results from plot resolution.

Results to retain

import numpy as np
import matplotlib.pyplot as plt
import control as ctl
s = ctl.tf('s')
G=50/(s**3+9*s*s+30*s+40)
coarse=np.array([.1,1,10]);fine=np.logspace(-2,3,1000)
# TODO: Compare frequency_response on the two grids.

Record results and self-check

Frequency grid:

Observed crossover:

Calculated GM and PM:

Limits of the assessment:

Points to check