Digital Controls & Digital Filters Lectures 1 & 2, Professor Department of Electrical and Computer Engineering Colorado State University Spring 2017
Digital versus Analog Control Systems Block diagrams of typical analog and digital (sampled-data) control systems are shown below. As can be seen the plant is still analog while the controller is replaced by a sampler (A/D converter), a digital controller (filter), and a hold device (D/A converter).
Why Digital Control? Benefits: Reduced Sensitivity and Robustness: Unlike analog controllers digital ones are not sensitive to environmental variations and aging. Better Adaptability: Parameters of digital controllers can more easily be adapted to the changes in a changing plant i.e. adaptive control strategies are more suited for digital control systems. Form Factor: Digital devices are more compact and lightweight comparing to their analog counterparts. Cost Effectiveness: Digital controllers are generally cheaper. More Reliable: Digital controllers are more reliable as their characteristics don t drift with time. Drawback: Quantization Effects: In designing digital systems one must be aware of the quantization effects (e.g., roundoff and truncation) due to finite word length of the processors.
Example Examples below show block diagrams of an autopilot system with position and rate feedback for: (a) analog control, (b) digital control, and digital control with multirate sampling for situations where the signals have different bandwidths.
Review of z-transform The role of z-transform to digital systems is similar to that of Laplace transform to continuous-time systems. Definition 1: The z-transform of a two-sided sequence {x(n)} is defined by X(z) = n= x(n)z n If {x(n)} is a right-sided sequence, i.e. x(n) = 0, X(z) = n=0 x(n)z n n < 0 then Example 1: Let x(n) = a n u s(n), where u s(n) is the unit step function defined as, { 1 n 0 u s(n) = 0 n < 0 Find X(z). Using n=0 an = 1 for a < 1, we have 1 a X(z) = n=0 an z n = n=0 ( a z )n = 1 1 a z if z > a
z-transform Thus the region of convergence (ROC) for this example extends from circle with radius a to. Example 2: Let x(n) = A sin(ω 0nT ), n 0. Find X(z). Using Euler formula, X(z) = n=0 Asin(Ω0nT )z n = A e jω 0 nt e jωnt n=0 z n 2j [ = A 2j [ n=0 ( ejω 0 T ) n ] z n=0 ( e jω 0 T ) n = A z 2j 2Az 1 sin(ω 0 T ) 1 2z 1 cos(ω 0 T )+z 2 1 1 e jω 0 T z 1 ] 1 = 1 e jω 0 T z 1 exists when ejω 0 T z < 1 or z > 1 (since e jω 0T = 1) Thus, ROC extends from circle with radius 1 to similar to that of Example 1.
z-transform Remarks: 1 For a right-sided sequence ROC is outside a circle bounded on the inside by largest magnitude pole and on the outside by. 2 For a left-sided sequence ROC is inside a circle bounded on the outside by smallest magnitude pole and on the inside by 0. 3 For a two-sided sequence ROC is within a ring (between two circles) bounded on the inside by the pole with largest magnitude for n 0 (i.e. right-sided part) and on the outside by the pole with smallest magnitude for n < 0. 4 Note: ROC should NOT enclose a pole. a N >... > a 2 > a 1 b 1 < b 2 <... < b M
Properties 1. Linearity Let x 1 (n) z X 1 (z) ROC R 1 < z < R 2 x 2 (n) z X 2 (z) ROC R 3 < z < R 4 Then ax 1 (n) + bx 2 (n) Z ax 1 (z) + bx 2 (z) ROC R 5 < z < R 6 where R 5 = max(r 1, R 3 ) R 6 = min(r 2, R 4 ) Remark: If linear combination leads to pole-zero cancellation, ROC may be larger. For example, both x 1 (n) = a n u s (n) and x 2 (n) = a n u s (n 1) have ROCs z > a but x 1 (n) x 2 (n) = δ(n) has a ROC which is the entire z-plane because X 1 (z) = z z a and X 2(z) = a z a hence X 1(z) X 2 (z) = z a z a = 1, i.e. ROC is everywhere.
z-transform Properties-Cont. 2. Shift-in-Time Let x(n) z X(z) ROC R 1 < z < R 2 Then x(n n 0 ) z z n0 X(z) ROC R 1 < z < R 2 Thus, ROCs are the same except possibly at z = 0 or z =. To see this, consider example, x 1 (n) = δ(n) z X 1 (z) = 1 ROC is everywhere on z-plane x 2 (n) = δ(n 1) z X 2 (z) = 1 z ROC is everywhere except at z = 0 x 3 (n) = δ(n + 1) Z X 3 (z) = z ROC is everywhere except at z = Generalizations: [ x(n n 0 ) z z n0 X(z) ] 1 k= n 0 x(k)z k with IC s x( 1),.., x( n 0 ). [ x(n + n 0 ) z z n0 X(z) n 0 1 k=0 ]. x(k)z k
z-transform Properties-Cont. 3. Multiplication by an Exponential Sequence Let x(n) z X(z) ROC R 1 < z < R 2 Then a n x(n) z X(z/a) ROC a R 1 < z < a R 2 Thus, ROC is scaled by a. 4. Differentiation Let x(n) z X(z) ROC R 1 < z < R 2 Then nx(n) z z dx(z) dz ROC R 1 < z < R 2 i.e. ROC is unchanged. 5. Conjugate (Complex Signals) Let x(n) Z X(z) ROC R 1 < z < R 2 Then x (n) Z X (z ) ROC R 1 < z < R 2 i.e. ROC is unchanged.
z-transform Properties-Cont. 6. Initial Value Theorem If x(n) = 0 n < 0 (right-sided) Then x(0) = lim z X(z) 7. Final Value Theorem (FVT) If x(n) = 0 n < 0 Then lim n x(n) = lim z 1 (1 z 1 )X(z) = lim z 1 (z 1)X(z) Condition: As long as (1 z 1 )X(z) does not have a pole on or outside the unit circle. Note: FVT is very useful for steady-state error analysis in control systems. Example: For x(n) = sin(ωn) from Table 2.3, we have X(z) = Now, if we use FVT lim z 1 (1 z 1 )X(z) = lim z 1 z sin(ω) z 2 2zcos(Ω)+1. (z 1)(zsin(Ω) z(z 2 2zcos(Ω)+1) = 0.
z-transform Properties-Cont. This result contradicts with lim n = sin(ωn) =? due to the fact that the above condition for using FVT is not satisfied since (1 z 1 )X(z) has poles on the unit circle z 1,2 = e ±jω. 8. Linear Convolution If y(n) = x(n) h(n) where stands for linear convolution operation i.e. y(n) = x(n) h(n) = k= x(k)h(n k) = and x(n) z X(z) ROC R 1 < z < R 2 h(n) z H(z) ROC R 3 < z < R 4 k= x(n k)h(k) Then Y (z) = X(z)H(z) ROC max[r 1, R 3 ] < z < min[r 2, R 4 ] Note: If a pole that borders on the ROC of one of the z-transforms is cancelled by a zero of the other, then the ROC of Y (z) will be larger.