Review

Complex Numbers

  • \(a+bi = r\angle \phi\).
  • \(r = \sqrt{a^2+b^2}\) and \[\phi=\begin{cases}\tan^{-1}(b/a)&a > 0\\ \tan^{-1}(b/a) + 180^\circ &a <0\\ 90^\circ& a=0,\,b>0\\ -90^\circ &a=0,b<0 \\indeterminate &a=b=0\end{cases}.\]
  • \((a+bi)^n = r^n\angle n\phi\). (This is true even when \(n\) is negative.)
  • \[\frac{1}{a+bi} = \frac{a-bi}{a^2+b^2}.\]

Frequency Response

The frequency response of a system is defined as the steady-state response of the system to a sinusoidal input.

Sorry, your browser does not support SVG.

It is also a sinusoidal signal, where

  • The frequency is the same.
  • The amplitude is \(A\times |G(j\omega)|\).
  • The phase is \(\phi + \angle G(j\omega)\).

Bode Plots

  • Bode plots of a transfer function \(G(s)\) include two graphs:
    • Magnitude plot: \(20\log_{10}|G(j\omega)|\) (dB) in linear scale v.s. \(\omega\) in log scale.
    • Phase plot: \(\angle G(j\omega)\) (degree) in linear scale v.s. \(\omega\) in log-scale.

Basic Factors

  • A complex polynomial can always be factorized in to basic terms
    • \(K\)
    • \(s\)
    • \(\tau s + 1\)
    • \[\left(\frac{s}{\omega_n}\right)^2 + 2\zeta \left(\frac{s}{\omega_n}\right) + 1.\]

Constant K

Sorry, your browser does not support SVG.

Integrator \(1/s\)

Sorry, your browser does not support SVG.

First Order \(1/(\tau s+1)\)

Sorry, your browser does not support SVG.

Second Order \(1/((s/\omega_n)^2+2\zeta(s/\omega_n)+1)\)

Sorry, your browser does not support SVG.

Bode Plots of Complex Function

  • Decompose the Transfer Function into Basic Factors
  • Determine the Plot at the Low Frequency
  • Add First and Second Order Terms
  • Verify the results in Matlab

Frequency Domain Modeling

  • Determine an asymptotic magnitude plot by approximating the actual gain plot by a sequence of straight lines with slopes of \(20N\).
  • From the low frequency plot, determine the number of integrator \(1/s^N\) and the constant term \(K\).
  • Determine the corner frequency from the intersection of two consecutive lines.
  • From the change of slopes of the consecutive lines, determine the associated basic factor.
  • Determine the damping ratio for second order zeros and poles.
  • The phase plot can be used to verify your results.

Non-Minimum Phase System

Sorry, your browser does not support SVG.

Nyquist Contour and Plot

Sorry, your browser does not support SVG.

Nyquist Stability Criterion

A feedback system is stable if and only if \(N=-P\), i.e. the number of the counterclockwise encirclements of \(–1\) point by the Nyquist plot in the \(G\)-plane is equal to the number of the unstable poles of the open-loop transfer function.

Sketch Nyquist Plot (Segment 1)

  • We need to find 4 types of point from the Bode plots:
    • \(\omega = 0\);
    • Real intersection: Phase = \(180N^\circ\);
    • Imaginary intersection: Phase = \(180N+90^\circ\);
    • \(\omega = +\infty\);
  • We can also deduce the trend of the plot around those points:
    • If the phase is decreasing, the plot goes clockwise
    • If the phase is increasing, the plot goes counterclockwise
  • Plot those points on the \(G\)-plane and draw a smooth line to connect them.

Sketch Nyquist Plot (Segment 2&3)

  • Segment 2 is the origin point for strictly proper function. It is a constant for proper function.
  • Segment 3 is the mirror reflection of segment 1 around the real axis.

Gain Margin

  • Define \(\omega_{\phi}\) to be the smallest frequency, where the phase of the open-loop transfer function is \(-180^\circ\).
  • \(\omega_{\phi}\) is called the phase crossover frequency.
  • For most minimum phase system, the gain margin for the system is given by \[K_g = \frac{1}{|G(j\omega_\phi)H(\omega_\phi)|}.\]
  • In terms of decibles,\[K_g(dB) = -20\log|G(j\omega_\phi)H(\omega_\phi)|.\]

Phase Margin

  • Define \(\omega_{g}\) to be the smallest frequency, where the magnitude of the open-loop transfer function is \(1\) or \(0dB\).
  • \(\omega_{g}\) is called the gain crossover frequency.
  • For most minimum phase system, the phase margin for the system is given by \[\phi_m = 180^\circ+\angle G(j\omega_g)H(\omega_g).\]

Stable System

Sorry, your browser does not support SVG.

Unstable System

Sorry, your browser does not support SVG.

Loop Shaping

  • In the low frequency, the gain should be high to have good steady state accuracy.
  • Around the gain crossover frequency, the slope of the magnitude plot should be about \(-20\) and extend over a sufficient range of frequency
  • In the high frequency, the gain must be small in order to have good noise attenuation and robustness against model uncertainty.

Desirable Magnitude Plot Shape

Sorry, your browser does not support SVG.

Lead and Lag Compensator

  • The transfer function of a lead compensator is \[C(s) = K\frac{Ts+1}{\alpha Ts+1},\,0<\alpha<1.\]
  • The transfer function of a lag compensator is \[C(s) = K\frac{Ts+1}{\beta Ts+1},\,\beta > 1.\]

Lead and Lag Compensator

Sorry, your browser does not support SVG.

Lead Compensator Design Procedure

  • Determine the gain \(K\) to satisfy the steady state error requirement.
  • Draw the Bode plots of \(KG(s)\), derive the phase margin \(\phi_0\)
  • From \(\phi_0\) and the required phase margin \(PM\), determine the phase lead \(\phi\): \[\phi = PM - \phi_0 + 5^\circ\sim 10^\circ.\]
  • Derive \[\alpha = \frac{1-\sin \phi}{1+\sin \phi}.\]

Lead Compensator Design Procedure

  • To achieve the maximum phase lead, place the gain crossover frequency \(\omega_g\) at \(1/\sqrt{\alpha}T\). Therefore, \[20\log|G(j\omega_g)| + 20\log K = 10\log \alpha,\] and we can derive \(\omega_g\).
  • Choose \[T = \frac{1}{\sqrt{\alpha}\omega_g}.\]
  • Verify the result using Matlab.

Lead Compensator Example

Sorry, your browser does not support SVG.

Lag Compensator Design Procedure

  • Determine the compensator gain \(K\) to meet the steady state error requirement.
  • Draw the Bode plots of \(KG(s)\).
  • From the Bode plots, find the frequency \(\omega_g\) at which the phase of \(KG(s)\) is \[\angle KG(\omega_g) = PM -180^\circ + 5^\circ\sim 10^\circ.\]
  • Calculate \(\beta\) to make \(\omega_g\) the gain crossover frequency, \[20\log\beta = 20\log K + 20\log |G(j\omega_g)|.\]
  • Choose \(T\) to be much greater than \(1/\omega_g\), for example, \(T = 10/\omega_g\).
  • Verify the results using matlab.

Lag Compensator Example

Sorry, your browser does not support SVG.

PID Controller

Sorry, your browser does not support SVG.

The standard form of PID controller is \[C(s) = K_p\left(1+\frac{1}{T_is}+T_ds\right) = K_p+\frac{K_I}{s}+K_Ds.\]

Step Response Method

  • Find the maximum slop tangent line
  • Read \(K\), \(T\) and \(L\) from the plot
  • Compute \(K_p\), \(T_i\) and \(T_d\) from the table

Sorry, your browser does not support SVG.

Self-Oscillation Method

  • The critical gain \(K_{cr}\) is the gain margin
  • The critical period \(P_{cr} = 2\pi/\omega_\phi\)
  • Compute \(K_p\), \(T_i\) and \(T_d\) from the table