0% found this document useful (0 votes)
11 views64 pages

Vut Notes Csy4701

The document discusses digital control systems, focusing on sampled data systems, including the processes of sampling and reconstruction of analog signals. It explains the use of difference equations to describe discrete systems and introduces elementary digital signals such as impulse and step functions, along with the z-transform. Additionally, it provides important z transforms and their properties relevant to digital signal processing.

Uploaded by

malvinrhangani
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views64 pages

Vut Notes Csy4701

The document discusses digital control systems, focusing on sampled data systems, including the processes of sampling and reconstruction of analog signals. It explains the use of difference equations to describe discrete systems and introduces elementary digital signals such as impulse and step functions, along with the z-transform. Additionally, it provides important z transforms and their properties relevant to digital signal processing.

Uploaded by

malvinrhangani
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 64

DIGITAL CONTROL SYSTEMS IV

MODULE CODE: EIDBS4

STUDY PROGRAM: UNIT 1 AND UNIT 2

VUT
Vaal University of Technology
EIDBS4 Chapter 1: Sampled Data Systems Page 1-1

1. SAMPLED DATA SYSTEMS


1.1 Sampling
In a digital control system, a digital computer is used to play the role of the controller.
This immediately necessitates that certain analog signals must be digitised. A typical
digital controller is shown in Figure 1-1.

Digital to analog
Computer Plant
converter
Desired Actual
output Output

Analog to digital
Transducer
converter

Figure 1-1

The sampling process implies that analog signals be sampled every T seconds and
converted into binary numbers. To ensure a good duplication of the analogue signal,
two aspects are important.
Firstly, the sampling rate must be chosen such that the frequencies contained in the
analog signals presented to the sampling unit, will be adequately reproduced, and
furthermore to ensure that the system remains stable. Secondly the number of binary
bits that are used to digitise the samples, should adequately represent the analogue
values.
For the reconstruction process, a zero order hold circuit is typically used. The raw
signal delivered by the zero order hold circuit still contains high frequencies as a
consequence of the spectrum repetition inherent to the original sampling process, and
these may be cancelled by a low pass filter.
A simplified illustration of the sampling and reconstruction process is given in
Figure 1-2. The signal x(t) is sampled and immediately reconstructed to produce the
signal xR(t).

x(t) xR (t)

T sek

0 T 2T 3T 4T 5T t Sample and hold 0 T 2T 3T 4T 5T t

Figure 1-2
EIDBS4 Chapter 1: Sampled Data Systems Page 1-2

1.2 Difference equations


Just as differential equations are used to describe the relationship between the output
and input of continuous systems, difference equations are used to describe the input-
output relationship of discrete systems. An everyday example of a discrete process that
can be described by a difference equation, is the following:
An amount of 10 rand is borrowed from the bank. The outstanding amount is
augmented by 10% interest at the end of each month while a payment of x rand is
made also at the end of each month to pay down the loan. The following iterative
process leads to a difference equation that describes the relationship between the
outstanding amount y and the instalment x.
y(0) = 10
y(1) = y(0) + 0.1y(0) – x(0)
y(2) = y(1) + 0.1y(1) – x(1)
y(k+1) = y(k) + 0.1y(k) – x(k)
y(k+1) = 1.1y(k) – x(k)

1.3 Elementary digital signals


1.3.1 Impulse function
(k)
The impulse function is defined as follows:
(k) = 1 k=0 1
(k) = 0, k0

k
k=0
1.3.2 Step function
u(k)
The step function u(k) is defined as follows:
u(k) = 0, k<0 1
u(k) = 1 k0

k
k=0

1.4 Z transform
Definition of the z-transform
The z transform X(z) = Z{x(k)} of a digital signal x(k), is defined as:

X(z) = Z{x(k)} = x(0) + x(1)z-1 + x(2)z-2 + x(3)z-3 +................


k 
X(z) =  x(k) z k Equation 1-1
k 0
EIDBS4 Chapter 1: Sampled Data Systems Page 1-3

Example 1-1 Determine the sum of the series: 1/2 + 1/4 + 1/8 + 1/16 + ...........
Let S = 1/2 + 1/4 + 1/8 + 1/16 + ...........
1/2S = 1/4 + 1/8 + 1/16 + .........
S - 1/2S = 1/2
1/2S = 1/2
S = 1
Example 1-2 Determine the z transform of the function x(k) = (kT):
X(z) = 1 + 0z –1 + 0z –2 +..... x(k)
1
X(z) = 1 + 0 + 0 + ….. k
X(z) = 1
Example 1-3 Determine the z transform of the function x(k) = u(kT) .
X(z) = 1 + 1z –1 + 1z –2 + 1z –3 +........
X(z) = 1 + 1/z + 1/z2 + 1/z3 +....... x(k)
(1/z)X(z) = 2 3
1/z + 1/z + 1/z +..... 1
X(z) – (1/z)X(z) = 1 k
z
X(z) =
z1
Example 1-4 Determine the z transform of the function x(k) = ak , for k  0.
X(z) = a0 + a1z –1 + a2z –2 + a3z –3 + .........
X(z) = 1 + (a/z) + (a/z)2 + (a/z)3 + ......
x(k)
(a/z)X(z) = (a/z) + (a/z)2 + (a/z)3 +......
X(z) – (a/z)X(z) = 1 1
X(z)[(1 – (a/z)] = 1
X(z) = 1/[1 – (a/z)]
z k
X(z) =
z a
Example 1-5 Determine the z transform of the function x(k) = sin(k), for k  0.
 jk  jk  Euler’s rule: x(k)
X(z) = Z{sin(k)} = Z  e  e 
jx -jx
sinx=(e – e )/j2 1
 j2  cosx=(ejx + e-jx)/2 k

    k  
= Z e jk  e  jk = Z e j    Z e  j   
1
j2
1
j2     
k  


 2 3
    
     z  e j  e  j  j2

1  z   z   z  ze
j
ze
j   
 
=      =   =
j2  z  e j   z  e  j  j2   z  e j  z  e  j    z  e jθ  z  e  jθ 
 
     
zsin a very important result as well as the corresponding
=
 jθ   jθ  result: Z{cos k} = (z2 – zcos)/(z – ej)(z – e–j)
 z  e  z  e 
   = (z2 – zcos)/(z – 1)(z – 1–)

= zsin
= zsin
= zsin
2 j   j  2
z  ze  ze 1 z 2  2z  e j  e  j  2  1 z  2zcos  1
  
EIDBS4 Chapter 1: Sampled Data Systems Page 1-4

1.5 Important z transforms


Important z transforms are given in Table 1-1. The corresponding continuous time
functions and associated Laplace transforms are also indicated.
Notes on using Table 1-1:
1. For all time sequences x(k), assume k  0
2. The second entry into the table, x(k) = 1, corresponds to x(k) = u(kT).
3. The number sequence generated by functions such as x(k) = (kT) or
x(k) = u(kT), is independent of the sampling period T and the z transform
of such functions does not involve the sampling period T.
4. The number sequence generated by a functions such as x(k) = kT is clearly
dependent on the sampling period and the value of T is needed to resolve X(z).
5. The z transform of a sequence such as x(k) = k, may be found from the table
by looking up the z transform of x(k) = kT and setting T = 1.
6. Some very useful transforms are given in the lower window of the table.
Table 1-1
 
X(z) =  x(k) z k
X(s)=  x(t)estdt x(t) x(k) = x(t)|t=kT
k0
1 (t) (kT) 1
1 z
1 1
s z1
1 Tz
t kT
s2 (z  1)2
2 T 2 z(z +1)
t2 (kT) 2
s3 (z  1)3
1 z
e at eakT
s a z  e  aT
1
teat Tze  aT
kTeakT
(s  a)2 (z  e aT ) 2
a
1  e at z(1  e  aT )
s(s  a) 1  e akT
(z 1)(z  e  aT )
 zsinT
sin t sin kT
s2  2 z 2  (2cosT)z  1
 ze  aTsinT
e at sin t e akTsin kT
(s + a)2   2 z 2  (2e  aT cosT)z  e  2aT
s
cos t cos kT z 2  zcosT
s2   2 z 2  (2cosT)z  1
 ze  aTsinT
e at sin t e akTsin kT
(s + a)2   2 z 2  (2e  aT cosT)z  e  2aT
EIDBS4 Chapter 1: Sampled Data Systems Page 1-5

Table 1-1 (continued)


e – sTX(s) x(t–T) x[(k–1)T] z – 1X(z)
e – 2sTX(s) x(t–2T) x[(k–2)T] z – 2X(z)
x[(k+1)T] zX(z) – zx(0)
x[(k+2)T] z2X(z) – z2x(0) – zx(1)
X(s+a) eat x(t) eakTx(kT) X(zeaT)
1  e  sT  X(s) 
(1  z 1)Z 
X(s)
s  s 
ak z/(z – a)
k
ka az/(z – a)2
(az (a  z
2ab k cos(k  ) 
z  b z  b  

1.6 Properties of the z transform


1. Z{x(k) + y(k)} = X(z) + Y(z)
2. Z{ax(k)} = aX(z)
3. Z{x(k – n)} = z –nX(z)
4. Z{x(k + n)} = znX(z) – zn x(0) – z n –1 x(1) – ....... – zx(n – 1)
5. Z{e –akTx(k)} = X(zeaT)
6. Z{x(k)y(k)} = X(z)Y(z)
7. lim x(k)  lim X(z)
k0 z

8. lim x(k)  lim (1  z 1)X(z) if (1–z-1)X(z) has no poles on or outside |z| = 1.


k z 1

Example 1-6 Determine the z transform of x(k) = 3u(k) + (0.5)ku(k).


X(z) = Z{3u(k) + (0.5)ku(k)} = Z{3u(k)} + Z{(0.5)ku(k)} = 3Z{u(k)} + z/(z – 0.5)
= 3[z/(z – 1)] + z/(z – 0.5) = 3z/(z – 1) + z/(z – 0.5)
= [3z(z – 0.5)+z(z – 1)]/(z – 1)(z – 0.5) = z(4z –2.5)/(z2 – 1.5z +0.5).

Example 1-7 Determine the z transform of a) x(k) = u(k – 3) and b) x(k) = u(k + 3).
a) X(z) = Z{u(k – 3)} = z –3 Z{u(k)} = z –3 [z/(z – 1)] = z –2 /(z – 1).
b) X(z) = Z{u(k + 3)} = z3{Z[u(k)] – [x(0) + x(1) z –1 + x(2) z –2 ]}
= z3{z/(z–1) – [1 + z –1 + z –2 ]} = z4/(z – 1) – z3 – z2 – z

Example 1-8 Find the final value of y(kT) if Y(z)=0.792z2/(z–1)(z2– 0.416z+0.208).

 1
 z 1
 0.792z 2 

lim y(kT)  lim (1  z )Y(z) = lim 
k z 1 z 1  z 2
(z 1)(z  0.416z + 0.208) 
 
2
= lim [0.792z/(z – 0.416z + 0.208)] = 0.792/(1 – 0.416 + 0.208) = 1
z1
EIDBS4 Chapter 1: Sampled Data Systems Page 1-6

1.7 Inverse z transform


Method of partial fractions
1. This method assumes that the function on which this method is applied, is a proper
fraction, that is the order of the numerator is smaller than the order of the
denominator.
2. If the inverse transform of X(z) must be found, then it is preferred that X(z)/z is
expanded.
Three possible situations may arise and these will be illustrated with the following
three examples.
Example 1-9 (Case 1 - different real factors)
Determine the inverse z transform of X(z) = 1/(z – 1)(z – 0.5)
X(z)/z = 1/z(z – 1)(z – 0.5)
= A/z +B/(z – 1) + C/(z – 0.5)
A = 1/(0 – 1)(0 – 0.5) = 2
B = 1/(1 – 0.5) = 2
C = 1/0.5(0.5 – 1) = – 4
X(z)/z = 2/z + 2/(z – 1) – 4/(z – 0.5)
X(z) = 2 +2z/(z – 1) – 4z/(z – 0.5)
x(k) = 2(k) + 2u(k) – 4(0.5)k u(k)
Example 1-10 (Case 2 - complex factors)
Determine y(k) if x(k) = u(k) for the difference equation:
y(k) = x(k) + y(k–1) – 0.5y(k–2)
Z{y(k)} = Z{x(k) + y(k–1) – 0.5y(k–2)}
Z{y(k)} = Z{x(k)} + Z{y(k–1)} – 0.5Z{y(k–2)}
Y(z) = X(z) + z-1Y(z) – 0.5z-2Y(z)
with x(k) = u(k) is X(z) = z/(z – 1)
Y(z) = z/(z – 1) + Y(z)/z – 0.5Y(z)/z2
z2Y(z) = z3/(z – 1) + zY(z) – 0.5Y(z)
Y(z)(z2 – z + 0.5) = z3/(z – 1)
Y(z) = z3/(z – 1)(z2 – z + 0.5)
Y(z)/z = z2/(z – 1)(z2 – z + 0.5)
z2 – z + 0.5 = 0  z = 0.5  j0.5 = 0.7071 0.7854r
z2 – z+0.5 = (z – 0.70710.7854r)(z – 0.7071– 0.7854r)
Y(z)/z = z2/(z – 1)(z – 0.70710.7854r)(z – 0.7071– 0.7854r)
= A/(z – 1) + B/(z – 0.70710.7854r) + B*/(z – 0.7071– 0.7854r)
A = z2/(z2 – z + 0.5)|z=1 = 2
B = z2/(z – 1)(z – 0.7071– 0.7854r)|z=0.70710.7854r
= (0.70710.7854r)2/(0.70710.7854r – 1)(0.70710.7854r – 0.7071– 0.7854r)
= 0.51.5708r /(0.70712.356r)(11.5708r ) = 0.7071–2.356r
EIDBS4 Chapter 1: Sampled Data Systems Page 1-7

and B* = 0.70712.356r
(note: we will never calculate B* as B* is just the conjugate of B).
Y(z)/z = 2/(z – 1) + 0.7071– 2.356/(z – 0.70710.7854)
+ 0.70712.356/(z – 0.7071– 0.7854)
Y(z)=2z/(z – 1) + (0.7071– 2.356)z/(z – 0.70710.7854)
+ (0.70712.356)z/(z – 0.7071– 0.7854)
k
y(k) = 2 + 20.7071(0.7071) cos(0.7854k – 2.356)
(az (a  z
using   2ab k cos(k  ) (Table 1-1)
z  b z  b  

Example 1-11 (Case 3 - repeated factors)


Determine x(k) if X(z) = z/(z – 0.5)(z – 1)2
X(z)/z = 1/(z – 0.5)(z – 1)2 = A/(z – 0.5) + B/(z – 1)2 + C/(z – 1)
A = 1/(z – 1)2|z = 0.5 = 4
B = 1/(z – 0.5)|z = 1 = 2
C = d/dz[1/(z-0.5)]|z = 1 = d/dz[(z – 0.5)-1]|z = 1 = [– (z – 0.5)-2]|z = 1
= [–1/(z-0.5)2]|z = 1 = – 4
X(z) = 4z/(z – 0.5) + 2z/(z – 1)2 – 4z/(z – 1)
x(k) = 4(0.5)k + 2k – 4

Exercise
1-1 Determine the z transform of the following functions:
a) f(k) = ke – 3k b) f(k) = ksin2k c) f(k) = e – 2k sin3k
Ans: a) f(k) = k(e – 3)k  F(z) = ze – 3/(z – e – 3)2 using kak  z/(z–a)2 table 1-1
b) F(z) = 1/j2Z{ke j2k – ke – j2k} = z/j2[ej2/(z – ej2)2 – e – j2 /(z – e – j2 )2]
= [z(z2 – 1)sin2]/(z2 – 2zcos2 + 1)2
c) F(z) = ze – 2 sin3/(z2 – 2ze – 2 cos3 + e – 4) from table 1-1 with T=1
1-2 Find the z transform of the following sequence:
f(k) = 1 for k even (0, 2, 4...) and f(k) = –1 for k odd (1, 3, 5..).
Ans: F(z) = 1 – z –1 + z –2 – z –3 + z –4 – z –5 + .....= z/(z+1)
(interestingly, when z = 1 then 1 – 1 + 1 – 1 + 1 – 1 + ........ = ½ )
1-3 Determine the z transform of the following functions:
a) F(s) = 1/(s+1)(s+2) b) F(s) = 1/s2(s+1)
c) F(s) = 10/s(s+5)2 d) F(s) = 5/s(s2+2)
Ans: a) F(s) = 1/(s+1)(s+2) = 1/(s+1) – 1/(s+2)
F(z) = z/(z – e –1) – z/(z – e –2) = z/(z – 0.3679) – z/(z – 0.1353)
b) F(s) = 1/s2(s+1) = A/s2 + B/s + C/(s+1)
A = 1 B = d/ds[1/(s+1)]|s=0 = [– 1/(s+1)2]|s=0 = –1 C = 1
F(s) = 1/s2 – 1/s + 1/(s+1)  F(z) = Tz/(z – 1)2 – z/(z – 1) + z/(z – e-T)
c) F(s) = A/s + B/(s+5)2 + C/(s+5) = 0.4/s – 2/(s+5)2 – 0.4/(s+5)
F(z) = 0.4z/(z – 1) – 2Tze-5T/(z – e-5T)2 – 0.4z/(z – e-5T)
EIDBS4 Chapter 1: Sampled Data Systems Page 1-8

d) F(s) = 5/s(s2 + 2) = 5/s(s + j2)(s – j2) = A/s + B/(s + j2) + B*/(s – j2)
=2.5/s – 1.25/(s + j2) – 1.25/(s – j2) = 2.5/s – 1.252s/(s2 + 2)
=2.5/s – 2.5s/[s2+(2)2]
F(z) = 2.5z/(z – 1) – 2.5(z2 – zcos2T)/(z2– 2zcos2T + 1)

1-4 Determine the inverse z transform, f(k), of the following functions:


a) F(z) = 10z/(z – 1)(z – 0.2) b) F(z) = z/(z – 1)(z2 + z + 1)
c) F(z) = z/(z – 1)(z – 0.85) d) F(z) = 10/(z – 1)(z – 0.5)
Ans a) F(z)/z = 10/(z-1)(z-0.2) = 12.5/(z-1) - 12.5/(z-0.2)
F(z) = 12.5z/(z-1) - 12.5z/(z-0.2)
f(k) = 12.5 - 12.5(0.2)k k  0
b) F(z)/z=1/(z-1)(z2+z+1)=1/(z-1)(z-1120)(z-1-120)
=A/(z-1) +B/(z-1120) +B*/(z-1-120)
= 0.3333/(z-1)+0.3333120/(z-1120) + 0.3333-120/(z-1-120)
F(z)=0.3333z/(z-1)+0.3333120z/(z-1120)+0.3333-120z/(z+1-120)
f(k) = 0.3333 + 20.3333(1)kcos(k120+120)
=0.3333 + 0.6667cos(k120+120) k0
c) F(z)/z = 1/(z-1)(z-0.85) = A/(z-1)+B/(z-0.85)=6.667/(z-1)-6.667/(z-0.85)
F(z) = 6.667z/(z-1)-6.667z/(z-0.85)
f(k) = 6.667 - 6.667(0.85)k ……k=0, 1, 2, ....
d) F(z)/z=10/z(z-1)(z-0.5)=A/z+B/(z-1)+C/(z-0.5)=20/z+20/(z-1)-40/(z-0.5)
F(z) = 20 + 20z/(z-1)-40z/(z-0.5)
f(k) = 20(k) +20 - 40(0.5)k

1-5 Solve the following difference equations with the aid of the z transform.
a) x(k+2) – x(k+1) + 0.1x(k) = u(k), x(0) = x(1) = 0.
b) x(k+2) – x(k) = 0, x(0) = 1, x(1) = 0.
Ans a) Z{x(k+2) – x(k+1) + 0.1x(k)} = Z{u(k)}
[z2X(z) – z2x(0) – zx(1)] – [zX(z) – zx(0)] + 0.1X(z) = z/(z–1)
X(z)(z2 – z +0.1] = z/(z–1)
X(z) = z/(z-1)(z-0.8873)(z-0.1127)
X(z)/z = 1/(z-1)(z-0.8873)(z-0.1127)=A/(z-1)+B/(z-0.8873)+C/(z-0.1127)
= 10/(z-1) - 11.46/(z-0.8873) + 1.455/(z-0.1127)
X(z) = 10z/(z-1) - 11.46z/(z-0.8873) + 1.455z/(z-0.1127)
x(k) = 10 - 11.46(0.8873)k + 1.455(0.1127)k
b) Z{x(k+2) – x(k)} = 0
z2X(z) - z2x(0) - zx(1) - X(z) = 0
z2X(z)-z2-X(z)=0
X(z)(z2 - 1) = z2
X(z)/z=z/(z+1)(z-1)=A/(z+1)+B/(z-1)
= 0.5/(z+1) + 0.5/(z-1)
X(z) = 0.5z/(z+1) +0.5z/(z-1)
x(k) = 0.5(-1)k +0.5, note that z/(z+1) = z/[z-(-1)] and use Z-1{z/(z-a)}=ak
EIDBS4 Chapter 1: Sampled Data Systems Page 1-9

1-6 A car is bought with a loan of Po rand. The interest is r percent per month and
the loan is paid down at u rand per month over a period of N months.
a) Write down a difference equation for the outstanding amount p(k).
b) Solve for p(k) by means of the z transform.
c) Solve for the monthly instalment u, if the bond must be settled in N months.
d) Take P0 as R15000, r=0.01(1 percent per month) en N=48 months. Find
the monthly payment.
Ans: a) p(0) = Po
p(1) = p(0) + rp(0) – u
p(2) = p(1) + rp(1) – u
p(k+1) = p(k) + rp(k) – u
p(k+1) = (1 + r)p(k) – u
b) Z{p(k+1)} = Z{(1 + r)p(k) – u}
zP(z) – zp(0) = (1 + r)P(z) – uz/(z–1)
P(z)[z – (1+r)] = zPo – uz/(z–1) where p(0) = initial loan = P0
= z[P0 – u/(z–1)]
= z[P0(z–1) – u]/(z–1)
z[Po (z  1)  u]
P(z) =
(z  1)[z  (1  r)]
P(z) Po (z  1)  u
 =
z (z  1)[z  (1  r)]
A B
= 
z  1 z  (1  r)
P (z  1)  u
where A = o = u/r
z  (1  r) z  1
P (z 1)  u
and B = o = (rP0 – u)/r
z 1 z 1 r
P(z) (u/r) (rPo  u)/r
 = 
z z  1 z  (1  r)
 u z  rP  u  z
P(z) =     o 

 r  z 1  r  z  (1  r)
p(k) = (u/r) + [(rPo – u)/r](1+r)k k0
N
c) p(N) = (u/r) + [(rPo – u)/r](1+r) = 0
u+(rPo–u)(1+r)N = 0
u[1 – (1+r)N] = – rPo(1+r)N
u = – rPo(1+r)N/[1 – (1+r)N]
= rPo(1+r)N/[(1+r)N – 1]
d) u = 0.0115000(1.01)48/[(1.01)48 – 1] = R395
EIDBS4 Chapter 2: Transfer Functions Page 2-1

2. TRANSFER FUNCTIONS
2.1 Transfer function of a zero order hold circuit
Consider again the simplified representation of a zero order hold system of Figure 1-2,
repeated here in Figure 2-1.
xR(t) Figure 2-1
x(t)
x(2T)
x(T)
x(3T)

x(5T)
T sec x(0)
x(4T)

0 T 2T 3T 4T 5T t Sample and hold 0 T 2T 3T 4T 5T t


The reconstructed version xR(t) of the original analogue signal x(t), can be expressed as:
xR(t) = x(0)[u(t) – u(t – T)] + x(T)[u(t – T) – u(t – 2T)] + x(2T)[u(t – 2T) – u(t – 3T)] + ..
0 , for t < 0
where u(t) =  Equation 2-1
1 , for t  0

x(0)u(t) – x(0)u(t–T) = x(0)u(t) – x(0)u(t–T)


x(0)[u(t) – u(t–T)]
+x(T)[ u(t–T) – u(t–2T)]
x(0) x(0) x(0)
x(T)
0 T 2T 0 T 2T 0 T 2T
= x(0)
x(T)u(t–T) – x(T)u(t–2T) = x(T)u(t–T) – x(T)u(t–2T)
0 T 2T
x(T) x(T) x(T)

1
L{u(t – a)} = e  as
0 T 2T 0 T 2T 0 T 2T s
L{(t – a)} = e  as

We may find the Laplace transform of the stepwise reconstructed signal xR(t), in
Equation 2-1, by using the transform pair u(t – a)  e  as .
1
s
1 e  sT   e  sT e  2sT   e  2sT e  3sT 
XR(s) = x(0) 
  + x(T)    + x(2T)    + ....
s s   s s   s s 
     
1  e  sT  1  e  sT  1  e  sT 
= x(0)   + x(T)e  sT   + x(2T)e  2sT   + ........
 s   s   s 
     
1  e  sT 
= [x(0) + x(T)e sT + x(2T)e 2sT + ......... ]   
 s 
 
EIDBS4 Chapter 2: Transfer Functions Page 2-2

1  e  sT 
XR(s) = X*(s)   Equation 2-2

s 
where we have defined X(s) = x(0) + x(T)e
– sT – 2sT
+ x(2T)e + .... Equation 2-3
Equation 2-2 suggests that we may visualize the sample and hold process to consist of
two separate processes as depicted in Figure 2-2.

X(s) X*(s) XR(s)


1  esT
s
x(t) T x*(t) xR(t)

Ideal sampling Hold action Figure 2-2

Firstly, producing X*(s) from X(s) (the first block in Figure 2-2), could be viewed as
ideal sampling, because when we take the inverse Laplace transform of X*(s), using
the transform pair (t – a)  e – as, we find from Equation 2-3,

x*(t) = x(0)(t) + x(T)(t – T) + x(2T)(t – 2T) + ..……... Equation 2-4

The output x*(t) of the ideal sampler is a sequence of impulses, as shown in Figure 2-3.

x*(t)
x(2T)
x(T)
x(3T)

x(4T)
x(0) x(5T)

Figure 2-3
0 T 2T 3T 4T 5T t

Although the impulse sequence x*(t) is never physically present in the A/D or D/A
circuitry, it does offer a valuable model of the ideal sampling process. If we accept the
equivalence of the impulse function (t) in the continuous domain and the impulse
function (kT) in the discrete domain, we could also express the output of the sampler
as,
x(kT) = x(0)(kT) + x(T)(kT – T) + x(2T)(kT – 2T) + ............ Equation 2-5

In a sense then, the ideal sampler has a dual interpretation, on the one hand delivering
a sequence of impulses with strength x(0), x(T), x(2T),..., which may be the input to a
continuous time system or the sampler may deliver the sequence of numbers x(0),
x(T), x(2t), ......, which may be the input to a computational device.
EIDBS4 Chapter 2: Transfer Functions Page 2-3

Secondly, the second block in Figure 2-2 is clearly responsible for transforming the
impulses into steps and must represent the zero order hold action of the sample and
hold process, and we conclude that the transfer function of the zero order hold section
is given by:

1  e sT
GH(s) = Equation 2-6
s

Equations 2-4 and 2-5, provide a very important connection between the continuous
time Laplace domain and the discrete time z domain. We already know that the
Laplace transform of x*(t) is given by Equation 2-3. The z transform of the number
sequence in Equation 2-5, is given by:
X(z) = x(0) + x(T)z – 1 + x(2T)z – 2 + .... Equation 2-7
Comparing Equation 2-7 with Equation 2-3, it becomes clear that X*(s) = X(z), if we
allow for,
z = esT Equation 2-8

2.2 Pulse transfer function


In Figure 2-4, a system G(s) is shown which is driven by an ideally sampled version
x(t) of a continuous signal x(t).

x(t) x(t) y(t) y(t)


G(s)
T T
Figure 2-4

The response y(t) can then be determined from the relationship Y(s) = G(s)X(s).
Typically, however, we are only interested in the values of y(t) at the sampling instants
and for that purpose, a perfect sampler is introduced at the output, in synchronism with
the input sampler, to produce the impulse sequence y*(t). In Example 2-1, we will
illustrate the relation between the analog output y*(t) and the digital output y(kT), for a
simple system. In general however, it can be shown that the z transforms of y*(t) and
x*(t), are related by:

Y(z) = G(z)X(z) Equation 2-9


where G(z) = Z{G(s)} Equation 2-10

So, Equation 2-9 will allow us to describe a continuous time system G(s), as a digital
system G(z), with G(z) calculated as per Equation 2-10. G(z) is called the
pulse transfer function of the system G(s).
EIDBS4 Chapter 2: Transfer Functions Page 2-4

Example 2-1 (Only an illustration) The input signal to the system shown in Figure 2-5,
is x(t) = u(t) and the impulse response of the system is g(t) = e – t u(t). Assume T = 1.
x(t) = u(t) x*(t) y(t) y(t)
–t
g(t) = e u(t)
T=1 T=1 Figure 2-5
a) Determine y*(t) using s transform methods and the relationship Y(s) = G(s)X(s)
b) Determine y(k), using the relationship Y(z) = G(z)X(z).
c) Using the sum of an infinite geometric series, determine X*(s) and G*(s) in closed
form and compare with X(z) and G(z).
a) We will find y(t) = L – 1 {G(s)X(s)}and then synthesize y*(t) from y(0), y(1), y(2), ..
y(t)
x(t) = u(t) x (t) = (t) + (t–1) + (t–2) + ...
*
–t
g(t) = e u(t) y(t)
Y(s)
1
X*(s) = 1 + e – s + e – 2s + ... G(s) = T=1
T=1 s 1

1 1 e  s e  2s
Y(s) = G(s)X*(s) = (1 + e – s + e – 2s + ....) = + + + .....
s 1 s 1 s 1 s 1
y(t) = e – tu(t) + e – (t – 1) u(t – 1) + e – (t – 2) u(t – 2) + ......
y(0) = 1, y(1) = e – 1 + 1, y(2) = e – 2 + e – 1 + 1, .....
y*(t) = (t) + (e – 1 + 1)(t – 1) + (e – 2 + e – 1 + 1)(t – 2) + .....
b) Now, let us calculate y(k) using z transform methods.
1 y(k)
G(s) =
x(t) = u(t) x(k) = (k) + (k–1) + (k–2) + ... s 1 y(t) Y(z)
z z
X(z) = 1 + z – 1 + z – 2 + ... = G(z) =
z  e1
T=1 z 1 T=1

z z Y(z) z e (e 1) 1 (e 1)


Y(z) = X(z)G(z) =   = = –
z  1 z  e1 z (z 1)(z  e  1) z 1 z  e 1
 e  z  1  z e 1 1 k
Y(z) = +   –    y(k) = u(k) – (e ) u(k)
 e 1  z 1  e 1  z  e 1 e 1 e 1
y(0) = [e/(e – 1)] – [1/(e – 1)](e – 1)0 = [e/(e – 1)] – [1/(e – 1)] = (e – 1)/(e – 1) = 1
y(1) = [e/(e – 1)] – [1/(e – 1)](e – 1)1 = [e/(e – 1)] – [(e – 1)/(e – 1)] = (e – e – 1)/(e – 1)
= [(e – 1)(1 + e – 1)]/(e – 1) = 1 + e – 1
y(2) = [e/(e – 1)] – [1/(e – 1)](e – 1)2 = [e/(e – 1)] – [(e – 2)/(e – 1)] = (e – e – 2)/(e – 1)
= [(e – 1)(1 + e – 1 + e – 2)]/(e – 1) = 1 + e – 1 + e – 2
y(k) = (k) + (e – 1 + 1)(k – 1) + (e – 2 + e – 1 + 1)(k – 2) + ......
c) X*(s) = 1 + e – s + e – 2s + ....  e – s X*(s) = e – s + e – 2s + ....  X*(s) – e – s X*(s) = 1
X*(s) = 1/(1 – e – s) = es/(es – 1) (compare with X(z) = z/(z – 1)
g(t) = e – t u(t)  g*(t) = (t) + e – 1(t – 1) + e – 2(t – 2) + ....  G*(s) = 1 + e –1e – s + e – 2e – 2s ....
e – 1e – sG*(s) = e – 1e – s + e – 2e – 2s ......  G*(s) – e – 1e – sG*(s) = 1  G*(s) = 1/(1 – e – 1e – s)
G*(s) = es/(es – e – 1) (compare with G(z) = z/(z – e – 1)
The strong relation between the starred transform and the z transform is evident.
EIDBS4 Chapter 2: Transfer Functions Page 2-5

2.3 Transfer function of systems in cascade


When two systems are connected in cascade, it is important to know whether sampling
occurs between the two systems.
X(z) Y(z)
G1(s) G2(s)
T T T
Figure 2-6 a

X(z) Y(z)
G1(s) G2(s)
T T Figure 2-6 b
For the system in Figure 2-6 a) the transfer function G(z) = Y(z)/X(z), is given by:
G(z) = Z{G1(s)}Z{G2(s)} Equation 2-11
= G1(z)G2(z).
For the system in Figure 2-6 b) the transfer function G(z) = Y(z)/X(z), is given by:
G(z) = Z{G1(s)G2(s)} Equation 2-12
= G1G2(z).
It is important to understand the meaning of the notation G1G2(z) and also to realise
that G1G2(z)  G1(z)G2(z).

Example 2-2 Determine the transfer function G(z) = Y(z)/X(z) for the system shown
in Figure 2-7.
X(z) Y(z)
1/s 1/(s+1)
T T T
G1(s) G2(s) Figure 2-7
From Equation 2-11: G(z) = Z{G1(s)}Z{G2(s)}
= Z{1/s}Z{1/(s + 1)}
= [z/(z – 1)][z/(z – e–T)]
= z2/(z – 1)(z – e–T)

Example 2-3 Determine the transfer function of the system in Figure 2-8.
X(z) Y(z)
1/s 1/(s+1)
T T
G1(s) G2(s) Figure 2-8
From Equation 2-12: G(z) = Z{G1(s)G2(s)}
= Z{[1/s][1/(s+1)]}
= Z{1/s(s+1)}
= z(1 – e-T)/(z – 1)(z – e-T) from Table 1-1.
EIDBS4 Chapter 2: Transfer Functions Page 2-6

2.4 Feedback systems


Consider the unity feedback system in Figure 2-9.

R(z) E(z) C(z)


G(s)
T T

Figure 2-9

The overall transfer function T(z) = C(z)/R(z), will now be derived.


C(z) = G(z)E(z) ........................…….………............. (1)
and E(z) = R(z) – C(z) ……..........……………............... (2)
(2) in (1): C(z) = G(z)[R(z) – C(z)]
C(z) = G(z)R(z) – G(z)C(z)
C(z) + G(z)C(z) = G(z)R(z)
:C(z)[1 + G(z)] = G(z)R(z)

C(z) G(z)
 = T (z)  Equation 2-13
R(z) 1  G(z)

Consider now the more general feedback system shown in Figure 2-10.

R(z) E(z) C(z)


G(s)
T T

H(s)

Figure 2-10

C(z) = G(z)E(z) ........................………….…............ (1)


and E(z) = R(z) – GH(z)E(z) ........……………............... (2)
From (1): E(z) = C(z)/G(z) ..............……………...................... (3)
(3) in (2): C(z)/G(z) = R(z) – GH(z)C(z)/G(z)
C(z) = R(z)G(z) – GH(z)C(z)
C(z) + GH(z)C(z) = G(z)R(z)
C(z)[1 + GH(z)] = G(z)R(z)

C(z) G(z)
 = T (z)  Equation 2-14
R(z) 1  GH(z)
EIDBS4 Chapter 2: Transfer Functions Page 2-7

Example 2-4
Determine the transfer function T(z) = C(z)/R(z) for the control system in Figure 2-11.

R(z) C(z)
G(s)=1/s
T T

H(s)=1/(s+1)

Figure 2-11
G(z) = Z{G(s)}
= Z{1/s)}
= z/(z – 1)
GH(z) = Z{G(s)H(s)}
= Z{[1/s][1/(s + 1)]}
= Z{1/s(s + 1)}
z(1  e T )
=
(z  1)(z  e T )
G(z)
From Equation 2-14: T(z) =
1  GH(z)
z
= z 1
z(1  e T )
1
(z 1)(z  e T )
z
= z 1
(z 1)(z  e T ) + z(1  e T )
(z  1)(z  e T )
z
= z 1
z 2  z  ze T + e T + z  ze T
(z 1)(z  e T )
z (z 1)(z  e T )
= 
z 1 z 2  z  ze T + e T + z  ze T
z(z  e T )
=
z 2  2ze T + e T
EIDBS4 Chapter 2: Transfer Functions Page 2-8

2.5 Transfer function of systems preceded by a zero order hold device


In Figure 2-12, a plant with transfer function P(s), is shown with a zero order hold
device GH(s) at the input. From Equation 2-6, the transfer function of a zero order hold
device is given by GH(s) = (1 – e – sT)/s. The transfer function G(z) = Y(z)/X(z) of this
configuration will now be obtained.
X(z) Y(z)
1  e sT
GH(s) = P(s)
s
T T
Figure 2-12
G(z)
1  e sT 
G(z) = Z  P(s)
 s 
 P(s) P(s) 
= Z   e sT 
 s s 
 P(s)   sT P(s) 
= Z    Ze 
 s   s 
 P(s)  1 Z  P(s) 
= Z  z   {e–sTX(s)  z-1X(z) Table 1-1}
 s   s 
 P(s)   1 
= Z    1 z 
 s   

 P(s) 
 G(z) = (1  z 1 ) Z  Equation 2-15
 s 

Example 2-5 Refer to the system in Figure 2-13.


a) Determine the transfer function G(z) = Y(z)/X(z).
b) Determine y(k) if x(k) = u(kT)
X(z)
Y(z)
1  e sT P(s) =
1
GH(s) = s
T s
T
Figure 2-13
–1  P(s) 
a) G(z) = (1 – z ) Z 
 s 
1s 
= (1 – z – 1) Z  (do not forget the 1/s)
 s 
 1 
= (1 – z – 1) Z 
 s2 
EIDBS4 Chapter 2: Transfer Functions Page 2-9
Tz
G(z) = (1 – z – 1)  Table 1-1
2
(z 1)
1 z 1
Now 1 – z – 1 = 1   (please take note)
z z
z 1 Tz
G(z) =  y(k)
z (z 1) 2
3T
= T/(z-1)
2T
b) Y(z) = G(z)X(z)
= T/(z – 1)z/(z – 1) T
= Tz/(z – 1)2
y(k) = kT k
{typical integrator (1/s) response} 0 1 2 3

Example 2-6 Refer to the system in Figure 2-14 and assume that T = ln2 sec.
a) Determine the transfer function G(z) = Y(z)/X(z).
b) Determine y(k), if x(k) = u(kT).
c) Calculate the final value of y(k) with the aid of the final value theorem (property 8).
X(z) Y(z)
1  e sT 1
GH(s) = P(s) =
s s +1
T T
Figure 2-14
a) G(z) = (1 – z – 1) Z{P(s)/s}
= (1 – z – 1) Z{1/s(s + 1)}
= (1 – z – 1) [z(1 – e-T)/(z – 1)(z – e-T)] table 1-1 (caution when a  1)
But T = ln2  e = 2  e = ½
T –T

G(z) = [(z – 1)/z][z(1 – 0.5)/(z – 1)(z – 0.5)]


= 0.5/(z – 0.5)
b) Y(z) = G(z)X(z)
y(k)
= 0.5/(z – 0.5)z/(z – 1) 1
Y(z)/z = 0.5/(z – 1)(z – 0.5)
= A/(z – 1) + B(z – 0.5) 1/2
where A = 1 and B= –1
Y(z)/z = 1/(z – 1) – 1/(z – 0.5)
Y(z) = z/(z – 1) – z/(z – 0.5) k
0 1 2 3 4
y(k) = 1 – (0.5)k
c) lim y(k)  lim (1  z 1)Y(z) (z transform property 8)
k z 1
= lim [(z 1)/z][0.5z/(z  1)(z  0.5)]
z 1
= lim [0.5/(z  0.5)]
z 1
=1
EIDBS4 Chapter 2: Transfer Functions Page 2-10

Example 2-7
Refer to the control system in Figure 2-15. Determine the output c(k) if r(k) = u(kT)
and T=1/2 sec.

R(z) C(z)
Zero order hold 1
GH(s) P(s)=
s
T T

G(z)

Figure 2-15
G(z) = (1 – z-1)Z{P(s)/s}
= (1 – z-1)Z{1/s2}
= (1 – z-1)[Tz/(z – 1)2]
= [(z – 1)/z][Tz/(z – 1)2]
= T/(z – 1)
According to Equation 2-13 for a unity feedback system:
G(z)
T(z) =
1  G(z)
= [T/(z – 1)]/[1+T/(z – 1)]
= [T/(z – 1)]/[(z – 1+T)/(z – 1)]
= T/(z – 1 + T)
With T = 0.5: T(z) = 0.5/(z – 0.5)

Now T (z) = C(z)/R(z)


C(z) = T(z)R(z)
With r(k) = u(kT), R(z) = z/(z-1)
C(z) = [0.5/(z – 0.5)][z/(z – 1)]
= 0.5z/(z – 0.5)(z – 1)
C(z)/z = 0.5/(z – 0.5)(z – 1)
= – 1/(z – 0.5) + 1/(z – 1)
C(z) = – z/(z – 0.5) + z/(z – 1)
c(k) = – (0.5)k + 1 k0
c(k)
1
¾
½

k
0 1 2 3 4
EIDBS4 Chapter 2: Transfer Functions Page 2-11

Exercise

2-1 The output of a linear time-invariant discrete system is given by the following time
sequence:
c(k) = 1 – e-2kT , k = 0, 1, 2, 3, .....,
when a signal is applied to the input of the system that is described by:
r(k) = 1 for all k  1.
Find the transfer function T(z) = C(z)/R(z).
Ans: C(z) = Z{c(k)} = Z{1 – e-2kT}
= z/(z – 1) – z/(z – e-2T) = [z(z – e-2T) – z(z – 1)]/(z – 1)(z – e-2T)
= z(1-e-2T)/(z-1)(z-e-2T)
and R(z) = Z{1} = z/(z-1)
T(z) = C(z)/R(z) = [z(1-e-2T)/(z-1)(z-e-2T)](z-1)/z
= (1-e-2T)/(z-e-2T)

2-2 Determine C(z)/R(z) for the systems in Figure P 2-1 a) - f). Take T=0.5 sec.

a)
r(t) 1 c(t)
s(s + 2)
T
Figure P 2-1 a)
b)
r(t) c(t)
1 10
s +1 s+ 2
T

Figure P 2-1 b)
c)
r(t) c(t)
1 10
s +1 s+ 2
T T

Figure P 2-1 c)
d)
r(t)
1  e sT 5 c(t)
GH(s)= s(s + 2)
s
T

Figure P 2-1 d)
EIDBS4 Chapter 2: Transfer Functions Page 2-12

e)
r(t) c(t)
1  e sT 5
GH(s)= s(s + 2)
s
T

Figure P 2-1 e)
f)

r(t) c(t)
1  e sT 5
GH(s)= s(s + 1)(s + 2)
s
T

Figure P 2-1 f)

Ans:
a) T(z) = Z{1/s(s+2)} = (1/2)Z{2/s(s+2)} = 0.5z(1 – e–1)/(z – 1)(z – e–1)
= 0.316z/(z – 1)(z – 0.3679)
b) T(z) = Z{[1/(s+1)][10/(s+2)]} = Z{10/(s+1)(s+2)}
= Z{10/(s+1) – 10/(s+2)} = 10z/(z – e–0..5) – 10z/(z – e–1)
= [10z(z – e–1) – 10z(z – e–0.5)]/(z – e–0.5)(z – e–1) = 10z(e–0.5 – e–1)/(z – e–0.5)(z – e–1)
= 2.387z/(z – 0.6065)(z – 0.3679)
c) T(z) = Z{1/(s+1)}Z{10/(s+2)} = z/(z – e–0.5)10z/(z – e–1) = 10z2/(z – e–0.5)(z – e–1)
= 10z2/(z – 0.6065)(z – 0.3679)
d) T(z) = (1 – z–1)Z{(1/s)5/s(s+2)} = [(z – 1)/z]Z{5/s2(s+2)} = [(z – 1)/z]Z{5/s2(s+2)}
= [(z – 1)/z]Z{A/s2 + B/s + C/(s+2)} = [(z – 1)/z]Z{2.5/s2 – 1.25/s + 1.25/(s+2)}
= [(z – 1)/z][2.50.5z/(z – 1)2 – 1.25z/(z–1) + 1.25z/(z – e–1)]
= [(z – 1)/z]{[1.25z(z – e–1) – 1.25z(z – 1)(z – e–1)+1.25z(z – 1)2]/(z – 1)2(z – e–1)}
= [(z – 1)/z]{1.25z[z–e–1 – (z2 – z – ze–1 + e–1)+(z2 – 2z + 1)]/(z–1)2(z–e–1)}
= 1.25z[(z – 1)/z]{[z – e–1 – z2 + z + ze–1 – e–1 + z2 – 2z + 1]/(z – 1)2(z – e–1)}
= 1.25z[(z – 1)/z]{[ze–1 – 2e–1 + 1]/(z – 1)2(z – e–1)}
= 1.25(ze–1 – 2e–1 + 1)/(z – 1)(z – e–1)}
= (0.4598z + 0.3303)/(z – 1)(z – 0.3679)
e) G(z) = (1 – z–1)Z{(1/s)5/s(s+2)} = (0.4598z + 0.3303)/(z – 1)(z – 0.3679)
Prob 2-2d
T(z) = G(z)/[1+G(z)] unity feedback system Equation 2-8
= (0.4598z+0.3303)/(z – 1)(z – 0.3679)/[1+(0.4598z+0.3303)/(z – 1)(z – 0.3679)]
= (0.4598z+0.3303)/(z – 1)(z – 0.3679)/
{[(z – 1)(z – 0.3679)+(0.4598z+0.3303)]/(z – 1)(z – 0.3679)}
= (0.4598z + 0.3303)/[(z – 1)(z – 0.3679) + (0.4598z + 0.3303)]
= (0.4598z + 0.3303)/(z2 – 1.3679z + 0.3679 + 0.4598z + 0.3303)]
EIDBS4 Chapter 2: Transfer Functions Page 2-13

= (0.4598z + 0.3303)/(z2 – 0.9081z + 0.6982)


f) G(z) = (1–z–1)Z{(1/s)[5/s(s+1)(s+2)]} = (1–z–1)Z{5/s2(s+1)(s+2)}
= (1–z–1)Z{A/s2 + B/s + C/(s+1) + D/(s+2)}
A = 5/(s+1)(s+2)|s=0 = 2.5
B = d/ds{5/(s+1)(s+2)}|s=0 = 5d/ds[(s2+3s+2)–1]|s=0
= –5[(s2+3s+2)–2(2s+3)]|s=0 = –5[(2s+3)/(s2+3s+2)2]|s=0 = –5[3/4]
= –3.75
C = 5/s2(s+2)|s=–1 = 5
D = 5/s2(s+1)|s=–2 = –1.25
G(z) = (1–z–1)Z{2.5/s2 – 3.75/s + 5/(s+1) – 1.25/(s+2)}
= [(z–1)/z][1.25z/(z–1)2 – 3.75z/(z–1) + 5z/(z–e–0.5) – 1.25z/(z–e–1)]
= [(z–1)/z]
1.25z[(z–e–0.5)(z–e–1)–3(z–1)(z–e–0.5)(z–e–1)+4(z–1)2(z–e–1)–(z–1)2(z–e–0.5)]/
(z–1)2(z–e–0.5)(z–e–1)
= 1.25[z2–e–0.5z–e–1z+e–1..5 –3(z–1)(z2–e–0.5z–e–1z+e–1.5)
+4(z2–2z+1)(z–e–1) –(z2–2z+1)(z–e–0.5)]/(z–1)(z–e–0.5)(z–e–1)
= 1.25[z2–e–0.5z–e–1z+e–1.5 –3(z3–e–0.5z2–e–1z2+e–1.5z–z2+e–0.5z+e–1z–e–1.5)
+4(z3–2z2+z–e–1z2+2e–1z–e–1)–(z3–2z2+z–e–0.5z2+2e–0.5z–e–0.5)]/
(z–1)(z–e–0.5)(z–e–1)
= 1.25[z2–e–0.5z–e–1z+e–1.5–3z3+3e–0.5z2+3e–1z2–3e–1.5z+3z2–3e–0.5z–3e–1z+3e–1.5)
+4z3–8z2+4z–4e–1z2+8e–1z–4e–1–z3+2z2–z+e–0.5z2–2e–0.5z+e–0.5)]/
(z–1)(z–e–0.5)(z–e–1)
= 1.25[(1+3e–0.5+3e–1+3–8–4e–1+2+e–0.5)z2
+ (–e–0.5–e–1–3e–1.5–3e–0.5–3e–1+4+8e–1–1–2e–0.5)z
+ (e–1.5+3e–1.5–4e–1+e–0.5)]/(z–1)(z–e–0.5)(z–e–1)
= 1.25[(–2 +4e–0.5–e–1)z2 + (3 – 6e–0.5 + 4e–1 – 3e–1.5)z
+ (4e–1.5 – 4e–1 + e–0.5)]/(z–1)(z–e–0.5)(z–e–1)
= 1.25(0.05824z2 + 0.1629z + 0.02753)/(z–1)(z–e–0.5)(z–e–1)
= (0.0728z2 + 0.2036z + 0.03441)/(z–1)(z–0.6065)(z–0.3679)

T(z) = G(z)/[1 + G(z)]


= (0.0728z2 + 0.2036z + 0.03441)/(z–1)(z–0.6065)(z–0.3679)/
[1 + (0.0728z2 + 0.2036z + 0.03441)/(z–1)(z–0.6065)(z–0.3679)]
= (0.0728z2 + 0.2036z + 0.03441)/(z–1)(z–0.6065)(z–0.3679)/
[(z–1)(z–0.6065)(z–0.3679)+(0.0728z2 + 0.2036z + 0.03441)]/
(z–1)(z–0.6065)(z–0.3679)
= (0.0728z2 + 0.2036z + 0.03441)/
[(z–1)(z–0.6065)(z–0.3679)+(0.0728z2 + 0.2036z + 0.03441)]
= (0.0728z2 + 0.2036z + 0.03441)/
[(z–1)(z2–0.9744z+0.2231)+(0.0728z2+0.2036z+0.03441)]
= (0.0728z2 + 0.2036z + 0.03441)/
(z3 –0.9744z2+0.2231z–z2+0.9744z–0.2231+0.0728z2+0.2036z+0.03441)
= (0.0728z2 + 0.2036z + 0.03441)/(z3 – 1.902z2 + 1.401z – 0.1887)
EIDBS4 Chapter 3: Time Domain Analysis Page 3-1

3. TIME DOMAIN ANALYSIS


3.1 Transient response of a second order continuous-time control system
It is necessary at this stage to consider the response of the prototype second order
continuous-time control system in Figure 3-1.

R(s) C(s)
 2n
G(s) =
s(s + 2)

Figure 3-1

The overall transfer function is given by:


C(s) G(s)
T(s) = =
R(s) 1  G(s)
2n s(s + 2 2n
= =
  2n s(s + 2 s(s + 2  2n
2
T(s) = n
Equation 3-1
s 2 + 2s + 2n

The character of the natural response of the system depends on the roots of the
characteristic equation (denominator of T(s)). For the case when n > , the roots will

be two conjugate complex numbers p = – + j 2n   2 and p = – – j 2n   2 , as
shown in Figure 3-2.
Im{s}

p Complex s plane
d = 2
n 
2
n
d
–

Definition of the
damping ratio  Re{s}
–
 = cos
= – cos( – )
= – (– /n)  Figure 3-2
p
= /n
EIDBS4 Chapter 3: Time Domain Analysis Page 3-2

It is clear from Figure 3-2 that the parameters , d, n,  and  are interrelated and
two equations that will be useful, are given below.

n =  2   2
d Equation 3-2

and  = cos = Equation 3-3
n

The parameters , n, d and  have the following meaning:


: damping factor of the system, representing the real part of the roots
d: damped frequency - the imaginary part of the roots
n: natural undamped frequency of the system, equal to the magnitude of the roots
: damping ratio
For the case where the characteristic equation has two complex roots, as illustrated in
Figure 3-2, the system will exhibit a damped sinusoidal natural response and the
system's step response, will demonstrate this clearly. We may find the step response
by substituting R(s) = 1/s (r(t) = u(t)), into Equation 3-1:
C(s)  2n  2n  2n
= 2  C(s) = R(s) =
R(s) s + 2s +  2 n s2 + 2s +  2 n s(s2 + 2s +  2 ) n
We will now determine the inverse Laplace transform of C(s), to find c(t).
C(s) = n2/[s(s2 + 2s + n2)] = n2/[s(s +  – jd)(s +  + jd]
= n2/{s[s – n ( – )][s – n– ( – )]}
s1 = –  + jd  s1 +  – jd = 0
A B Β s1 = n( – )  s1 – n( – ) = 0
=  
s s  n 1(  ) s  n   (  )]}
s1 Im{s}
A = n2/(s2 + 2s + n2)|s = 0 = 1 n
d
 2
B= n  –
s (s     (  ) –
n s   (  ) Re{s}
n –d
 
= n s2
 n (  )][n (  )  n   (  )]
s2 = –  – jd  s2 +  + jd = 0
  s2 = n– ( – )  s2 – n– ( – ) = 0
= n
n [1(  )]{n [1(  )  1  (  )]}
 
= n

 (  )]{[cos(  )  jsin(   )]  [cos((  ))  jsin( (  ))]}
n
 cos(–x) = cos x
= sin(–x) = – sinx
[1(  )]{[cos(  )  jsin(   )]  [cos(  )  jsin(   )]
= 1/{[1( – )][j2sin( – )]}
sin( – ) = sincos – cossin = sin
= 1/{[1( – )](j2sin )}
= 1/{[1( – )](2sin /2)} j = 1/2
EIDBS4 Chapter 3: Time Domain Analysis Page 3-3

B = 1/{2 sin  [(3/2) – )]}


1/(r) = (1/r)– 
= (1/2sin)[ – (3/2)]
C(s) = (1/s) + {(1/2sin)[ – (3/2)]}/[s – n( – )]
+ {(1/2sin)– [ – (3/2)]}/[s – n– (– )]
= (1/s) + {(1/2sin)[ – (3/2)]}/(s +  – jd)
+ {[(1/2sin)– [ + (3/2)]}/(s +  + jnd)
Now using the the Laplace transform pairs: L{u(t)} = 1/s and
L{2Ae – t cos(t+)u(t)} = (A)/(s +  – j) + (A– )(s +  + j)
1   
c(t) = u(t) + 2 e  t cos   t     u(t)
2sin  d 2 
cos(x– 3/2) = cosxcos(3/2) + sinxsin(3/2) = – sinx
e  t
c(t) = 1 – sin   t    , t  0 Equation 3-4
sin  d 

A typical step response is shown in Figure 3-3 with overshoot D, rise time tr and
settling time ts, indicated (the three important attributes of the step response).
c(t)
tr Figure 3-3
D
1

t
ts

The maximum overshoot may be found by setting the derivative of c(t) equal to zero.
 e  t e  t
c’(t) = – d cos   t    + sin   t   
sin  d  sin  d 
 e  t e  t
Thus c’(t) = 0  – d  
cos   t    + sin   t    = 0
sin  d  sin  d 
sin(dt+) = dcos(dt+)  tan(dt+) = d/  dt +  = tan-1(d/)
Now, tan = d/  tan-1(d/) =   dt +  = 
t = 0 (not what we are looking for)
Next possibility: tan( + ) = d/  tan-1(d/) =  +   dt +  =  + 
t = /d (this must be the first time that c(t) reaches a maximum)
The corresponding maximum value of c(t) is,
   
e d    e d
c(/d) = 1 – sin     = 1 – sin   
sin   d  sin 
 d 
EIDBS4 Chapter 3: Time Domain Analysis Page 3-4

sin( + ) = sincos + cossin = – sin


 d
e d
 c(/d) = c(t)|MAX = 1 + sin  = 1 + e =1+D
sin 


D= e d Equation 3-5

The rise time can be found by setting c(t) = 1. From Equation 3-4,
e  t   e  t
c(t) = 1 – sin   t    = 1  sin   t    = 0
sin  d  sin  d 
-t
sin(dt + ) = 0 {because e can never be zero}
Now, sin(dt + ) = 0  dt +  = 0  t = – /d (not the t we are looking for)
Next angle where sin(dt + ) = 0, occurs when dt +  = 
t = ( – )/d  t = [ – tan – 1(d/)]/d (this must be the first time c(t) reaches 1)

 
  tan 1 d 
  
tr = Equation 3-6
d

The settling time is normally defined as the time it takes for the decaying function e - t
(and the corresponding oscillations) to settle down to 2% of the initial value. This
occurs, from equation 3-4, when e-t = 0.02 or – t = ln(0.02)  – 4.
4
ts = Equation 3-7

3.2 Mapping between the s plane and the z plane


The relation between the s plane and the z plane is specified by Equation 2-8:
z = esT .
If a point on the s plane is given by, s = –  + jd ,
(  j )T
then the corresponding point z in the z plane will be given by, z = e d

z = e – TdT Equation 3-8

j Im s j Im z
s z | z | = e – T
e – T
d z = dT
dT
– Re s Re z
EIDBS4 Chapter 3: Time Domain Analysis Page 3-5

3.3 Time response of discrete data control systems


Example 3-1 Consider the system in Figure 3-4 and estimate the overshoot D, the rise
time tr and the settling time ts.

c(t)
r(t) 1  e sT 1
GH(s) =
s s(s +1)
T=0.5

G(z)

Figure 3-4
1 1 
For this system, G(z) = (1 – z-1)Z   
 s s(s  1) 
 1 
= (1 – z-1)Z  2 
 s (s  1) 
1 1 1 
= (1 – z-1)Z  2   
s s (s  1) 
z 1  Tz z z 
=   
z  (z  1)2 z 1 (z  e T ) 
 
z  1 z[T(z  e T )  (z  1)(z  e T )  (z  1) 2 ]
= 
z (z  1) 2 (z  e T )
Tz  Te T  (z 2  z  e T z + e T )  z 2  2z  1
=
(z 1)(z  e T )
(T -1+ eT )z + (1-eT -TeT )
=
(z  1)(z  eT )
G(z)
T(z) =
1  G(z)

(T 1 + e T )z + (1  e T  Te T )
(z 1)(z  e T )
=
(T 1 + e T )z + (1  e T  Te T )
1
(z 1)(z  e T )

(T  1 + e T )z + (1  e T  Te T )
=
(z  1)(z  e T ) + (T  1 + e T )z + (1  e T  Te T )
EIDBS4 Chapter 3: Time Domain Analysis Page 3-6

(T  1 + e T )z + (1  e T  Te T )
T(z) =
z 2  z  e T z + e T + (T 1 + e T )z + (1  e T  Te T )
(T 1 + e T )z + (1  e T  Te T )
T(z) = Equation 3-9
z 2  (T  2)z + (1  Te T )
Analogously to continuous systems, the denominator of T(z) is called the
characteristic equation of the system. The roots of the characteristic equation, also
called the poles of T(z), completely determines the transient behaviour of the system.
It is always possible to distinguish between two components of a system's response.
One component is associated with the driving force, r(t) in this case, and the natural
component which is governed by the poles of the system.
The roots of the characteristic equation can also be determined without calculating the
total transfer function first. For a unity feedback system the appropriate equation will be:
G(z) + 1 = 0 Equation 3-10
and for the general feedback system:
GH(z) + 1 = 0 Equation 3-11
For example, for the system under consideration:
(T  1 + e T )z + (1  e T  Te T )
G(z) + 1 = +1=0
(z  1)(z  e T )
(T – 1 + e – T)z + (1 – e – T – Te – T + (z – 1)(z – e – T) = 0
z2 + (T – 2)z + (1 – Te – T) = 0,
which is the desired equation according to the transfer function Equation 3-9.
Now with T = 0.5 sec. the transfer function becomes:
0.1065z  0.0902
T(z) = 2 Equation 3-12
z  15
. z + 0.6967
The characteristic equation is:
z2 – 1.5z + 0.6967 = 0 ,
with roots (poles):

z = 0.83470.4543rad and 0.8347– 0.4543rad .

T(z) becomes zero when z = – 0.8469 and this value is called a zero of T(z). If a zero
is between –1 and 0, it has a small effect on the step response while a zero moving
towards z = +1 greatly increases the overshoot. We should therefore be able to specify
a continuous second order system that behaves similarly to the present discrete second
order system and apply Equations 3-5 to 3-7 to estimate the overshoot, the rise time
and the settling time.
EIDBS4 Chapter 3: Time Domain Analysis Page 3-7

From Equation 3-8: z = e – TdT  |z| = e – T and z = dT


e – T = | z | = 0.8347
– T = ln(0.8347) = – 0.180683  –  = – 0.180683/T = – 0.180683/0.5
 = 0.36137 (the damping factor  is a dimensionless quantity)
and dT = z = 0.4543  d = 0.4543/T = 0.4543/0.5
d = 0.9086 rad/sec
The overshoot for the corresponding continuous system is from Equation 3-5:
D = e – /d
= e –  (0.36137)/(0.9086)
= 0.28665 or 28.665%.
The rise time using Equation 3-6:
tr = [– tan-1(d/)]/d
= [ – tan-1(0.9086/0.3614)]/0.9086
= 2.145 sec.
Finally the settling time from Equation 3-7:
ts = 4/
= 4/0.36137
= 11.07 sec

We could confirm these findings by applying a step input u(kT) to the system:
0.1065z  0.0902 z
C(z) = T(z)R(z) = 
z 2 1.5z + 0.6967 z 1
C(z) = z(0.1065z + 0.0902)/[(z – 1)(z – 0.83470.4544)(z – 0.8347– 0.4544)]
C(z)/z = (0.1065z + 0.0902)/[(z – 1)(z – 0.83470.4544)(z – 0.8347– 0.4544)]
= A/(z – 1) + B/(z – 0.83470.4544) + B*/(z – 0.8347– 0.4544)
A = (0.1065z + 0.0902)/(z2 – 1.5z + 0.6967)|z = 1 = 1
B = (0.1065z + 0.0902)/(z – 1)(z – 0.8347– 0.4544)|z = 0.83470.4544
= [0.1065(0.83470.4544) + 0.0902]/[(0.83470.4544) – 1)
(0.83470.4544) – 0.8347– 0.4544)]
= [0.1744920.22552]/[0.443542.16960.732741.5708]
= 0.53692.7683
C(z)/z = 1/(z – 1) + 0.53692.7683/(z – 0.83470.4544)
+ 0.5369–2.7683/(z – 0.8347– 0.4544)
C(z) = z/(z – 1) + [(0.53692.7683)z]/(z – 0.83470.4544)
+ [(0.5369–2.7683)z]/(z – 0.8347– 0.4544)
c(k) = 1 + 20.5369(0.8347)kcos(0.4544k + 2.7683)
= 1 + 1.0738(0.8347)kcos(0.4544k + 2.7683)
With MATLAB a graph of c(k) can be created with the following statements:
a=[0.1065 0.0902]; b=[1 -1.5 0.6967]; dstep(a,b,30)
The result is shown in Figure 3-5.
EIDBS4 Chapter 3: Time Domain Analysis Page 3-8

From the graph the overshoot, rise time and settling time may now be determined.
The overshoot is approximately 0.3 or 30% - estimated value 28.66%. The rise time
from the graph is 5 samples corresponding to 50.5 = 2.5 sec - estimated value is
2.145 sec. The settling time is difficult to read off from the graph but it should be
approximately 25 sample times which is 250.5 = 12.5 sec. - estimated at 11.07 sec.

c(7) = 1.286

c(14) = 0.9181

Figure 3-5

3.4 Relationship between the roots of the characteristic equation and


transient response
For real roots z = a in the characteristic equation, the transient response is of the
form ak. This is illustrated in Figure 3-6.

Figure 3-6
EIDBS4 Chapter 3: Time Domain Analysis Page 3-9

In the case of complex roots, z = b and b = 1 (roots lie on the unit circle), the
transient response is of the form cos(k), illustrated in Figure 3-7.

=T=/2

=T=3/4
=T=/4

Figure 3-7

In the case of complex roots of the form, z=b and b  1 (roots inside or outside the
unit circle), the transient response is of the form bkcos(k), illustrated in Figure 3-8.

b>1

b<1

Figure 3-8
EIDBS4 Chapter 3: Time Domain Analysis Page 3-10

It is very clear that if any roots of the characteristic equation fall outside the unit circle
on the z plane, the transient response does not decay but rather continue to grow. We
therefore come to the conclusion that a stable discrete system cannot have any
poles outside the unit circle.

3.5 Steady state analysis


Consider the system in Figure 3-9.

R(s) E(s) C(s)


G(s)
T

H(s)

Figure 3-9

E(z) = R(z) – GH(z)E(z)


E(z)[1 + GH(z)] = R(z)
 R(z) 
E(z) =  
1  GH(z) 
The final error signal ess is therefore given by (property 8):
 (1  z 1)R(z) 
ess = lim  
z1  1  GH(z) 
Rz
For a step input r(t) = Ru(t), R(z) = , and
(z 1)
 (z  1) Rz 
ess = lim   
z1  z[1  GH(z)] (z 1) 
 R 
= lim 
z1 1  GH(z) 
R
=
1  lim GH(z)
  z1  
The position error constant is now defined as :
EP = lim GH(z) ,
z1
R
so that ess =
1 E
P
EIDBS4 Chapter 3: Time Domain Analysis Page 3-11

RTz
In the case of a ramp function r(t) = Rtu(t), R(z) = , and
(z 1)2
 (z 1) RTz 
ess = lim  
z1  z[1  GH(z)] (z 1) 2 
 
 RT 
= lim 
z1  (z  1)[1  GH(z)]
 RT 
= lim 
z1 [(z 1)  (z 1)GH(z)]
 RT 
= lim 
z1  ( z  1)GH(z) 
R
=
1 lim (z  1)GH(z)
T
z 1
The velocity error constant Ev is now defined as:
Ev = lim (z  1)GH(z)
1
T z 1
R
and the steady state error: ess = .
Ev

For the quadratic function r(t) = ½Rt2u(t) the acceleration error constant Ea is defined
as:
 1 
Ea =   lim (z  1)2 GH(z)
 2  z 1  
T 
R
and the steady state error: ess = .
Ea
The derivation of Ea is left as an exercise.

Example 3-2
Determine the position, velocity and acceleration steady state errors for the system in
Figure 3-10, for r(t)=u(t), r(t)=tu(t) and r(t)= ½t2u(t), respectively.

R(s) C(s)
1
ZOH G(s)=
s(s  0.5)
T=0.1

G(z)

Figure 3-10
EIDBS4 Chapter 3: Time Domain Analysis Page 3-12

-11 1  -1
 1 
G(z) = (1 - z )Z    = (1 – z )Z  
 s s(s  0.5)   s 2 (s  0.5) 
2 4 4 
= (1 – z-1)Z    
 s2 s (s  0.5) 
z 1  2Tz 4z 4z 
=   
z  (z  1)2 z 1 (z  e  0.5T ) 
 
z 1  0.2z 4z 4z 
=   
z  (z  1)2 z  1 (z  e  0.05 ) 
 
z  1 z[0.2(z  e0.05 )  4(z  1)(z  e0.05 )  4(z  1)2 ]
= 
z (z  1)2 (z  e0.05 )
0.2z  0.2e  0.05  4(z 2  z  e  0.05z + e  0.05 )  4z 2  8z  4
=
(z 1)(z  e  0.05 )
(0.2  4 + 4e  0.05  8)z + (4  4e  0.05  0.2e  0.05 )
=
(z 1)(z  e  0.05 )
0.0049177z + 0.0048364
=
(z  1)(z  0.95123)
EP = lim G(z) = 
z1
R 1
ess = = =0
1 E 1 
P
1
Ev = lim (z  1)G(z)
T z1
1 z  1 0.0049177z + 0.0048364
= lim 
0.1 z1 1 (z  1)(z  0.95123)
1 0.0049177z + 0.0048364
= lim
0.1 z1 (z  0.95123)
= 100.2 = 2
R
ess = .= ½ = 0.5
Ev
1
Ea = lim (z  1)2 G(z)
2
T z1  

1 (z  1) 2 0.0049177z + 0.0048364
= lim 
0.01 z1 1 (z  1)(z  0.95123)
1 (z  1)(0.0049177z + 0.0048364)
= lim = 1000 = 0
0.01 z1 (z  0.95123)
R
ess = .= 1/0 = 
Ea
EIDBS4 Chapter 3: Time Domain Analysis Page 3-13

Exercise
3-1 Refer to the system discussed in Example 3-1 and select a few values for k and
calculate c(k). Compare your answers with Figure 3-5.
3-2 The block diagram of a discrete control system is given in Figure P 3-1.
a) Determine the transfer function T(z) of the system if the sampling period
T = 0.1 sec.
b) Calculate the unit step response c(k) for k = 0 to 20.

r(t) c(t)
5
ZOH
s(s + 2)
T

Figure P 3-1
Ans:
G(z) = (1-z-1)Z{(1/s)5/s(s+2)} = [(z-1)/z]Z{5/s2(s+2)}
= [(z-1)/z]Z{5/s2(s+2)} = [(z-1)/z]Z{A/s2 + B/s + C/(s+2)}
= [(z-1)/z]Z{2.5/s2 - 1.25/s + 1.25/(s+2)}
= [(z-1)/z][0.25z/(z-1)2 - 1.25z/(z-1) + 1.25z/(z-e-0.2)]
= [(z-1)/z]0.25z{[(z-e-0.2) - 5(z-1)(z-e-0.2) + 5(z-1)2]/(z-1)2(z-e-0.2)}
= 0.25[z-e-0.2 - 5(z2 - z - ze-0.2 + e-0.2)+5(z2 - 2z + 1)]/(z-1)(z-e-0.2)}
= 0.25[z - e-0.2 - 5z2 + 5z + 5ze-2 - 5e-0.2 + 5z2 - 10z + 5]/(z-1)(z-e-0.2)}
= 0.25[-4z + 5ze-0.2 - 6e-0.2 + 5]/(z-1)(z-e-0.2)}
= 0.25[z(-4 + 5e-0.2) - 6e-0.2 + 5)/(z - 1)(z - e-0.2)}
= 0.25(0.09365z + 0.08762)/(z - 1)(z - 0.8187)
= (0.02341z + 0.02191)/(z - 1)(z - 0.8187)
T(z) = G(z)/[1 + G(z)]
= [(0.02341z + 0.02191)/(z - 1)(z - 0.8187)]/
[1+(0.02341z + 0.02191)/(z - 1)(z - 0.8187)]
= [(0.02341z + 0.02191)/(z - 1)(z - 0.8187)]/
[(z - 1)(z - 0.8187)+(0.02341z + 0.02191)/(z - 1)(z - 0.8187)]
= (0.02341z + 0.02191)/(z2 - 1.8187z + 0.8187 + 0.02341z + 0.02191)
= (0.02341z + 0.02191)/(z2 - 1.795z + 0.8406)
b) C(z) = (0.02341z + 0.02191)/(z2 - 1.795z + 0.8406)R(z)
= (0.02341z + 0.02191)/(z2 - 1.795z + 0.8406)z/(z-1)
= z(0.02341z + 0.02191)/(z-1)(z2 - 1.795z + 0.8406)
Now, {z2 – 1.795z + 0.8406
= (z – 0.91680.2058r )(z – 0.9168– 0.2058r )}
C(z)/z = (0.02341z + 0.02191)/(z – 1)(z – 0.91680.2058r)(z – 0.9168– 0.2058r)
= A/(z – 1) + B/(z – 0.91680.2058r) + B*/(z – 0.9168– 0.2058r)
EIDBS4 Chapter 3: Time Domain Analysis Page 3-14

A = [(0.02341z + 0.02191)/z2 – 1.795z + 0.8406)]|z = 1 = 0.9939


B = [(0.02341z + 0.02191)/(z – 1)(z-0.9168– 0.2058r)]|z = 0.91680.2058
=0.53912.743r
C(z)/z = 0.9939/(z-1) + 0.53912.743r/(z – 0.91680.2058r)
+ 0.5391– 2.743r/(z – 0.9168– 0.2058r)
C(z) = 0.9939z/(z-1) + 0.53912.743rz/(z – 0.91680.2058r)
+ 0.5391– 2.743rz/(z – 0.9168– 0.2058r)
c(k) = 0.9939 + 20.5391(0.9168)kcos(0.2058k + 2.743)
= 0.9939 + 1.078(0.9168)kcos(0.2058k + 2.743)
In the table below the values of c(k) were calculated with Excel for k = 0 to 59.
k 0 1 2 3 4 5 6 7 8 9
y(k) 0.0004 0.024 0.088 0.183 0.3 0.43 0.565 0.698 0.823 0.936
k 10 11 12 13 14 15 16 17 18 19
y(k) 1.034 1.114 1.176 1.22 1.247 1.257 1.254 1.24 1.217 1.187
k 20 21 22 23 24 25 26 27 28 29
y(k) 1.153 1.117 1.082 1.048 1.017 0.99 0.967 0.949 0.937 0.928
k 30 31 32 33 34 35 36 37 38 39
y(k) 0.924 0.924 0.927 0.933 0.94 0.949 0.959 0.968 0.977 0.986
k 40 41 42 43 44 45 46 47 48 49
y(k) 0.993 1 1.005 1.008 1.011 1.012 1.013 1.012 1.011 1.009
k 50 51 52 53 54 55 56 57 58 59
y(k) 1.006 1.004 1.001 0.999 0.997 0.995 0.993 0.991 0.99 0.99

With the aid of MATLAB for T(z) = (0.02341z + 0.02191)/(z2 - 1.795z + 0.8406):
a=[0 0.02341 0.02191]; b=[1 -1.795 0.8406]; dstep(a,b,100);
EIDBS4 Chapter 4: Stability Analysis Page 4-1

4. STABILITY ANALYSIS
4.1 The Jury stability test
A discrete control system is stable if all the roots of the characteristic equation fall
inside the unit circle on the z plane. The Jury test may be used to confirm stability.
Assume the characteristic equation of a discrete system is given by:

Q(z) = anzn + an-1zn-1 + ......+ a1z + a0 = 0, an > 0. (if an < 0, multiply Q(z) by –1)

We now form the following structure (Jury table) with the coefficients of Q(z)
inverted to form the first row:

a0 a1 ..... an – 1 an A B  A B
det   = = AD – CB
an an – 1 ..... a1 a0  C D C D
b0 b1 ..... bn – 1 ao an
b0 = = a 0 a0 – an an
bn – 1 bn – 1 ..... b0 an a0
..... ..... ..... ..... ao a n 1
l0 l1 l2 l3 b1 = = a 0 a1 – an an – 1
an a1
l3 l2 l1 l0
m0 m1 m2 ao a1
bn – 1 = = a 0 an – 1 – an a1
an a n 1
ao a n k bo b n k
where bk = , ck = , .. The next b row (bn – 1 to b0) is formed by
an ak bn bk inverting the first b row b0 to bn – 1 Then
the first c row may be calculated from the
two previous b rows, in the same way the
The necessary and sufficient conditions
first b row was determined from the two
for the roots of Q(z), to fall inside or on previous a rows.
the unit circle, are:

1) Q(1) > 0
 Q(1)  0 n even
2) (–1)nQ(–1) > 0, which implies 
 Q(1)  0 n odd

3) | a0 | < an
4) If n > 2, construct the Jury table and determine whether the following
conditions are satisfied:
| b0 | > | bn-1 |, | c0 | > | cn-2 |, ....... | l0 | > | l3 |, |m0| > |m2|

4.2 Application to digital control systems


Example 4-1 The characteristic equation of a system is given by:
Q(z) = z3 + z2 + 0.5z + 0.25.
Use the Jury test to investigate the stability of the system.
EIDBS4 Chapter 4: Stability Analysis Page 4-2

Q(1) = 1 + 1 + 0.5 + 0.25 = 2.75 > 0 


Q(–1) = – 1 +1 – 0.5 + 0.25 = – 0.25 < 0 for n = 3 (uneven) 
| a0 | = 0.25 < a3 = 1 
Now form the Jury table:
0.25 0.5 1 1
1 1 0.5 0.25
– 0.9375 – 0.875 – 0.25
(0.250.25 – 11) (0.250.5 – 11) (0.251 – 10.5)
= – 0.9375 = – 0.875 = – 0.25
| m0 | = 0.9375 > | m2 | = 0.25. 
The system is therefore unconditionally stable.
Stability may also be tested with Matlab: a=[1 1 0.5 0.25] roots(a); z1 = – 0.7718
* *
(|z1| = 0.7718), z2 = – 0.1141 + 0.5576i (|z2| = 0.5692), z2 = – 0.1141 – 0.5576i (|z2 | = 0.5692)

Example 4-2 Use the Jury test to determine values for K that will ensure stability for
the system in Figure 4-1. Assume T = ln2 sec.
B(z) A(z)

R(z) C(z)
1  e sT 1
K
s (s +1)(s + 2)
T T

ZOH

G(z)

Figure 4-1
1  e sT   
B(z) = K and A(z) = Z 
1 –1 1
.  = (1 – z )Z  
 s (s +1)(s  2)   s(s  1)(s + 2) 
 0.5 1 0.5  z 1  0.5z z 0.5z 
A(z) = (1 – z – 1)Z     =    
 s s 1 s  2  z  (z 1) z  e  T z - e- 2T 

For T=ln2 sek:


z 1  0.5z z 0.5z 
A(z) =  
z  (z 1) z  0.5 z - 0.25 

 z  1  0.5z z 0.5z 
G(z) = B(z)A(z) = K    (z  1)   
 z  z  0.5 z - 0.25 
 z  1   z[0.5(z  0.5)(z  0.25) - (z  1)(z  0.25)  0.5(z -1)(z  0.5)] 
= K  (z  1)(z  0.5)(z  0.25) 
 z  
EIDBS4 Chapter 4: Stability Analysis Page 4-3

0.5(z  0.5)(z  0.25)  (z  1)(z  0.25)  0.5(z -1)(z  05


.)
G(z) = K
(z  05
. )(z  0.25)
0.5z2  0375
. z + 0.0625  (z2  0.75z + 0.25)  05
. z2 - 0.75z + 0.25
=K
(z  05. )(z  0.25)
0.125z + 0.0625 0.125K(z + 0.5)
=K =
(z  05
. )(z  0.25) (z  05
. )(z  0.25)

The characteristic equation may be determined by calculating T(z).


 0.125K(z + 0.5)   0.125K(z + 0.5) 
T(z) = G(z)/[1 + G(z)] =  1
 (z  05
 
. )(z  0.25)   (z  0.5)(z  0.25) 
 0.125K(z + 0.5)   (z - 0.5)(z - 0.25) + 0.125K(z + 0.5) 
=   
 (z  0.5)(z  0.25)   (z  0.5)(z  0.25) 
0.125K(z + 0.5)
=
(z  0.5)(z  0.25) + 0.125K(z + 0.5)
0.125K(z + 0.5)
=
z 2  0.75z + 0.125 + 0.125Kz + 0.0625K
Q(z) = z2 + (0.125K – 0.75)z + (0.0625K + 0.125)
or alternatively from 1 + G(z) = 0
0.125K(z + 0.5)
1+ = 0  (z – 0.5)(z – 0.25) + 0.125K(z+0.5) = 0
(z  05
. )(z  0.25)
z2 – 0.75z + 0.125 + 0.125Kz + 0.0625K = 0
z2 + (0.125K – 0.75)z + (0.0625K + 0.125) = 0
Q(z) = z2 + (0.125K – 0.75)z + (0.0625K + 0.125)

Jury test:
Q(1) = 1 + 0.125K – 0.75 + 0.0625K + 0.125 > 0  0.1875K > – 0.375  K > – 2
Q(–1) = 1 – 0.125K +0.75 + 0.0625K + 0.125 > 0 for n even (2)
 – 0.0625K > –1.875  0.0625K < 1.875  K < 30
and | 0.0625K + 0.125 | < 1 ( | a0 | < an )
0.0625K + 0.125 < 1 and 0.0625K + 0.125 > –1
 K < 14 and K > –18
Because this is a second order system (n = 2), the Jury table is not involved.
We therefore conclude that for stability: –2 < K < 14.

Exercise
4-1 A digital control system is described by the following difference equation:
x(k+1) = (0.368 – 0.632K)x(k) + Kr(k),
where r(k) is the input and y(k) is the output. Calculate values for K so that the
system is stable.
EIDBS4 Chapter 4: Stability Analysis Page 4-4

Ans: zX(z) = (0.368 – 0.632K)X(z) + KR(z) assume x(0) = 0


X(z)[z – 0.368 + 0.632K] = KR(z)
X(z)/R(z) = K/(z – 0.368 + 0.632K)
The characteristic equation is therefore: Q(z) = z – 0.368 + 0.632K
Q(1) = 1 – 0.368 + 0.632K > 0  0.632K > 0.368 – 1 = – 0.376  K > –1
and Q(–1) = –1 – 0.368 + 0.632K < 0  K < 2.165
and | 0.632K – 0.368 | < 1  0.632K – 0.368 < 1  K < 2.165
or – (0.632K – 0.368) < 1  0.632K > 0.368 –1  K > –1
Final conclusion: –1 < K < 2.165

4-2 The block diagram of a sampled data control system is given in figure P 4-1.
r(t) e(t) e*(t) c(t)
Nul orde houbaan K
Zero order hold s(s + 1.5)
T

Determine stability conditions for K, if T = 1.0 sek. Figure 4-1

Ans:
G(z) = (1–z-1)Z{(1/s)K/s(s+1.5)} = (1–z-1)Z{K/s2(s+1.5)} = K(1–z-1)Z{1/s2(s+1.5)}
= K(1–z-1)Z{0.6667/s2 – 0.4444/s + 0.4444/(s+1.5)}
= K[(z–1)/z]{0.6667Tz/(z – 1)2 – 0.4444z/(z – 1) + 0.4444z/(z – e – 1.5T)}
= Kz[(z–1)/z]{[0.6667T(z–e–1.5T) – 0.4444(z–1)(z–e–1.5T) + 0.4444(z–1)2]/(z–1)2(z–e–1.5T)}
= K{[0.6667Tz–0.6667Te–1.5T–0.4444(z2–(1+e–1.5T)z+e–1.5T)+0.4444(z2–2z+1)]/(z–1)(z–e–1.5T)}
= K[(0.6667T+0.4444(1+e–1.5T)–0.8888)z+(–0.6667Te–1.5T–0.4444e–1.5T+0.4444)]/(z–1)(z–e–1.5T)
With T = 1:
G(z) = K[(0.6667+0.4444(1+e – 1.5) – 0.8888)z+(– 0.6667e–1.5–0.4444e–1.5+0.4444)]/(z–1)(z–e–1.5)
= K[(0.6667+0.44441.223–0.8888)z+(–0.66670.2231–0.44440.2231+0.4444)]/(z–1)(z–0.2231)
= K[(0.6667 + 0.5435– 0.8888)z+ (– 0.1487 – 0.0991+ 0.4444)]/(z – 1)(z – 0.2231)
= K(0.3213z + 0.1966)/(z – 1)(z – 0.2231)
1 + G(z) = 0  1 + K(0.3213z + 0.1966)/(z – 1)(z – 0.2231) = 0
(z – 1)(z – 0.2231) + K(0.3213z + 0.1966) = 0
2
Thus Q(z) = z – 1.223z + 0.2231 + 0.3213Kz + 0.1966K
= z2 + (0.3213K – 1.223)z + (0.1966K + 0.2231)
For stability:
Q(1) = 1 + 0.3213K - 1.223 + 0.1966K + 0.2231 > 0
0.5179K > 0  K > 0
Q(–1) = 1 – 0.321K + 1.223 + 0.1966K + 0.2231 > 0
0.1244K < 2.446  K < 19.66
and |0.1966K + 0.2231| < 1
0.1966K + 0.2231 < 1 K < 3.952
and – 0.1966K – 0.2231 < 1 K > – 6.221
Final requirement: 0 < K < 3.952
EIDBS4 Chapter 5: Root Locus Techniques Page 5-1

5. ROOT LOCUS TECHNIQUES


Many discrete control systems may be represented by the block diagram in Figure 5-1.
R(s) C(s)
G(s)
T

H(s)
Figure 5-1

C(z) G(z)
The closed loop transfer function is given by:  .
R(z) 1  GH(z)

The characteristic equation is given by: 1 + GH(z) = 0.


The open loop transfer function GH(z), normally include the system gain K (or
perhaps other parameters, such as the sampling period T). The root locus describes the
movement of the roots of the characteristic equation across the z plane, for variations
in these parameters, typically the system gain K.

5.1 General rules for the construction of root loci


1. The locus sections start (K=0) at the poles of GH(z) and ends (K= ) in the zeros
of GH(z).
2. The locus on the real axis, lies on a section of the real axis, to the left of an uneven
number of poles and zeros on the real axis.
3. The root locus is symmetrical with respect to the real axis.
4. The number of asymptotes along which locus sections go to infinity, are equal to
the number of poles of GH(z), p, minus the number of “visible” zeros of GH(z), n.
The asymptotes cut the real axis at the point (sum of poles – sum of zeros)/(p – n)
with (p – n) angles, /(p – n), 3/(p – n), 5/(p – n), ......
dK
5. The breakaway points from the real axis are given by the roots of  0.
dz

Examples of root loci are given in Figure 5-2 a) - k).

One real pole One real pole and One real pole and Two real poles
one real zero one real zero

Fig 5-2 a) Fig 5-2 b) Fig 5-2 c) Fig 5-2 d)


EIDBS4 Chapter 5: Root Locus Techniques Page 5-2

Two equal Two complex Two real poles Two real poles
real poles poles and one real zero and one real zero

Fig 5-2 e) Fig 5-2 f) Fig 5-2 g) Fig 5-2 h)

Two real poles Two complex poles Three real poles


and one real zero and one real zero

Fig 5-2 i) Fig 5-2 j) Fig 5-2 k)

Just to illuminate some of R(s) C(s)


0.693147
the rules given to construct + 2K ZOH s  0.693147

the root loci, consider the T=1 T=1
digital control system shown
in Figure 5-3. Figure 5-3

 z  1  0.693147   z 1  z(1  e


0.693147 ) 
GH(z) = 2K   Z   = 2K  z   
 z   s(s  0.693147)     (z  1)(z  e 0.693147 ) 
 z  1  0.5z  K
= 2K     =
 z   (z  1)(z  0.5)  z  0.5
K
The open loop transfer function GH(z) = becomes infinite when z = 0.5 and
z  0.5
this value of z is called a pole of GH(z). GH(z) tends to zero when z tends to infinity
and this is called an “invisible” zero of GH(z). A value of z that causes GH(z) to
become zero and also appear explicitly in the numerator of GH(z), is called a “visible”
zero of GH(z). For example, z = –1 would be a “visible” zero if it was given that
GH(z) = K(z + 1)/(z – 0.5).
Now, the characteristic equation Q(z) = 0, is given by z + (K – 0.5) = 0. When K = 0,
the solution of the characteristic equation is z = 0.5, which is the pole of GH(z). When
K = , then z = 0.5 – K = –, which is the zero of GH(z). The path of the root locus,
is shown in Figure 5-4,
EIDBS4 Chapter 5: Root Locus Techniques Page 5-3

Im{z} Root of the characteristic


Root of the characteristic
equation (when K = 0),
equation (when K  ),
located at z = 0.5 (the
is located at z = –  (the K=0
K= K = 1.5 pole of GH(z). This is
zero of GH(z). This is
also where the root locus
also where the root locus 0.5 Re{z}
ends its journey. – starts its journey across
|z|=1 the z plane.

Figure 5-4
We have confirmed rule 1 for this particular GH(z) and also rule two, as we can see
that the root locus section on the real axis, lies to the left of an uneven number of poles
and zero’s (in this case the pole at z = 0.5). Rule 2 is also evident when we inspect
Figure 5-2. Rule 3 is a consequence of the complex conjugate root theorem from
algebra, which states that if a polynomial has real coefficients, any complex roots will
occur in conjugate pairs. Rule 4 will not be important to us, but it is useful to
determine the asymptotes of root locus sections that branches off to infinity (see for
example Figure 5-2 k). We will make extensive use of rule 5, however, the current
example does not exhibit any breakaway points. We will have the opportunity to
calculate breakaway values in Example 5-1.
Finally, the critical value of K when the root locus crosses the unit circle (this is the
value of K that will cause the system in Figure 5-3 to become unstable) will be
important. For the current system, this will happen when z = – 1 and from the
characteristic equation, z + (K – 0.5) = 0, it follows that the marginal value is K = 1.5

5.2 System Analysis with Root Locus Techniques


0.125K(z + 0.5)
Example 5-1 Draw the root locus for the system GH(z) = , from
(z  05
. )(z  0.25)
Example 4-2, and determine the values of K that will ensure system stability.
According to rule 1, two root locus sections start at z = 0.5 en z = 0.25, and end in the
zeros z = – 0.5 and z = . (See figure 5-2 i).. To find the breakaway points, we must
solve for K from the characteristic equation. The characteristic equation is given by:
0.125K(z + 0.5)
GH(z) + 1 = 0  +1=0
(z  05
. )(z  0.25)
0.125K(z + 0.5) + (z – 0.5)(z – 0.25) = 0
0.125K(z + 0.5) = – (z2 – 0.75z + 0.125) d  u  (du dx )v  u(dv dx )
 
dx  v  v2
2
 (z  0.75z  0.125)
K =
0.125(z + 0.5)
dK  [(2z  0.75)  0.125(z  0.5)  (z 2  0.75z  0.125)  0.125]
 
dz [0.125(z + 0.5)]2
dK/dz = 0  (2z – 0.75)(z + 0.5) – (z2 – 0.75z + 0.125) = 0
2z2 + 0.25z – 0.375 – z2 + 0.75z – 0.125 = 0  z2 + z – 0.5 = 0
The breakaway points are therefore at z = 0.366 and z = – 1.366
EIDBS4 Chapter 5: Root Locus Techniques Page 5-4

The root locus diagram (corresponding to Figure 5-2 i), is shown in Figure 5-5. The
distance between the zero (–0.5) and any breakpoint (say 0.366), is the radius
0.366– (– 0.5)] = 0.866, of a circle with centre at – 0.5 (the zero). Refer to the Appendix
at the end of Chapter 5 for a proof of the circularity of the root locus. The radius is
also given by [(– 0.5 – 0.5)(– 0.5 – 0.25)] = 0.866
Im z
P
unit circle
|z|=1
– 1.366
– 0.5 0.25 0.5

Re z

0.366

Figure 5-5
P’
The system becomes unstable when the root locus cuts the unit circle at P and P’.
Three methods to calculate K at P or P’:
Method 1:
0.125K(z + 0.5)
The root locus equation is: +1=0
(z  05
. )(z  0.25)
0.125K(z+ 0.5) + (z– 0.5)(z– 0.25) = 0  0.125Kz + 0.0625K + z2 – 0.75z + 0.125 = 0
z2 + (0.125K – 0.75)z + (0.125 + 0.0625K) = 0
We now call the two (complex) roots of this quadratic equation z1,2
 (0.125K  0.75)  (0.125K  0.75)2  4(0.125  0.0625K)
z1,2 =
2
 (0.125K  0.75)  j 4(0.125  0.0625K)  (0.125K  0.75) 2
=
2
 (0.125K  0.75) 4(0.125  0.0625K)  (0.125K  0.75) 2
= ±j
2 2
1
| z1,2 | =
1 (0.125K  0.75) 2  [4(0.125  0.0625K)  (0.125K  0.75) 2 ] 2
2  
1
=
1 (0.125K  0.75) 2  (0.125K  0.75) 2  4(0.125  0.0625K) 2
2  

= 4(0.125  0.0625K)2 =
1 1 1
0.5  0.25K
2 2
1
But at P and P’ | z1,2 | = 1, and therefore 0.5  0.25K = 1 which implies that K = 14
2
Thus for stability, K must be smaller than 14 (and larger than zero).
EIDBS4 Chapter 5: Root Locus Techniques Page 5-5

Method 2:
From the characteristic equation: z2 + (0.125K – 0.75)z + (0.125 + 0.0625K) = 0.
Using the fact that for z2 + bz + c = 0, | z | = c (this is ONLY true if the roots
are complex):
| z | = 0.125  0.0625K = 1
0.125 + 0.0625K = 1  K = 14 P
unit circle
Method 3: root locus
1
The radius of the root locus circle is: .866 -
1.366 – 0.5 = 0.866 
Cosine rule:
0.866 0.5
(0.866)2 = (0.52 + 12 – 20.51cos
cos = (0.52 + 12 – 0.8662)/20.51
cos = 0.5   = 1.0472r
Thus at P, z = 1( – 1.0472) = 12.0944 1.366
and K = – (z – 0.5)(z – 0.25)/0.125(z + 0.5)
= – (12.0944 – 0.5)(12.0944 – 0.25)/0.125(12.0944 + 0.5) = 14 + j0

Root Locus
The root locus may also be drawn with 1
Matlab. The characteristic equation must
be of the form: q(z) = 1+ ka(z)/b(z). For the 0.5
q(z) under discussion, a(z) = z + 0.5, and
Imaginary Axis

b(z) = (z– 0.5)(z– 0.25) = z2– 0.75z+0.125.


0
The following instructions are needed:
a=[1 0.5], b=[1 -0.75 0.125], zgrid([],[]),
-0.5
(to add the unit circle) and rlocus(a,b).
k may now be determined with
-1
k=rlocfind(a,b), and the answer given -2 -1.5 -1 -0.5 0 0.5 1
Real Axis
was k = 1.7538. We must realize that
k represents 0.125K in our transfer Lines were made more visible with MATLAB
function, so K=1.7538/0.125 = 14.03. statement: set(gca,'DefaultLineLineWidth',4).

Example 5-2 (Problem 8-23, Automatic Control Systems, B.C. Kuo, 7’th edition,
Chapter 8.). The bock diagram of a discrete control system is shown in Figure 5-6.
a) Construct the root loci for the system in the z plane for K  0, without the zero
order hold when T = 0.5 sec. and then when T = 0.1 sec. Find the marginal values
for K for stability.
b) Repeat part a) when the system has a zero-order hold.

R(s) E(s) E*(s) Y(s)


K
Zero order hold
s(s + 5)
T
Figure 5-6
EIDBS4 Chapter 5: Root Locus Techniques Page 5-6

a) G(z) = Z{K/s(s+5)} = Z{(K/5)[5/s(s+5)]} = (K/5)z(1 – e –T)/(z – 1)(z – e –2.5T)


No zero hold
i) T = 0.5 sec:
G(z) = (K/5)z(1 – e –2.5)/(z – 1)(z – e –2.5) = 0.1836Kz/(z – 1)(z – 0.08209)
Root locus starts at z = 1 and z = 0.08209, and ends in z = 0 and z = 
0.1836Kz
The characteristic equation is given by: +1=0
(z  1)(z  0.08209)
K = – (z – 1)(z – 0.08209)/0.1836z = – (z2 – 1.082z + 0.08209)/0.1836z
= – 5.447z + 5.893 – 0.4471/z
dK/dz = – 5.447 + 0.4471/z2 = 0  – 5.447z2 + 0.4471 = 0  z2 = 0.08208
Breakaway points at z =  0.2865
It is clear that for stability, K > 0 (P1). Furthermore, the system will
become unstable when the root locus intersects the unit circle at P2, or in
other words, when z = – 1. Now let z = – 1 in the characteristic equation:
0.1836K(– 1)/(– 1 – 1)(– 1 – 0.08209) = – 1
– 0.1836K = – (– 2)( – 1.082)  0.1836K = 2.164  K = 11.79
For stability: 0 < K < 11.79 Im z
Unit circle
| z |=1
0.08209

K P2 K= K=0 1

K=0 P1 Re z
– 0.2865 0.2865

ii) T = 0.1 sec:


G(z) = Kz(1 – e –0.5)/5(z – 1)(z – e –0.5)
= 0.07869Kz/(z – 1)(z – 0.6065)
Root locus starts at z = 1 and z = 0.6065 and ends in z = 0 and z = 
0.07869Kz
The characteristic equation is given by: +1=0
(z  1)(z  0.6065)
K = – (z – 1)(z – 0.6065)/0.07869z = – (z2 – 1.607z + 0.6065)/0.07869z
= – 12.71z + 20.42 – 7.707/z
dK/dz = – 12.71 + 20.42 + 7.707/z2 = 0  – 12.71z2 + 7.707 = 0  z2 = 0.6064
Breakaway points at z =  0.7787
The system becomes unstable when the root locus traverses the unit circle
at P2, that is when z = – 1. Now set z = – 1 in the characteristic equation:
0.07869K(– 1)/(– 1 – 1)( – 1 – 0.6065) = – 1
– 0.07869K = – (– 2)( – 1.607)  0.07869K = 3.214  K = 40.84
For stability 0 < K < 40.84
EIDBS4 Chapter 5: Root Locus Techniques Page 5-7

Im z
unit circle
| z |=1
0.6065
K P2 K= 1 K=0

K=0 P1 Re z
– 0.7787
0.7787

b) G(z) = (1 – z –1)Z{(1/s)[K/s(s + 5)]} = K(1 – z –1)Z{1/s2(s + 5)}


= K(1 – z –1)Z{0.2/s2 – 0.04/s + 0.04/(s + 5)}
= K[(z – )/z][0.2Tz/(z – 1)2 – 0.04z/(z – 1) + 0.04z/(z – e –5T)]
= K[(z – 1)/z]z{[0.2T(z – e –5T) – 0.04(z – 1)(z – e –5T) + 0.04(z – 1)2]/(z – 1)2(z – e –5T)}
= K[0.2Tz – 0.2Te –5T – 0.04(z2 – (1 + e –5T)z + e –5T) + 0.04(z2 – 2z + 1)]/(z – 1)(z – e –5T)
= K[(0.2T + 0.04 + 0.04e –5T – 0.08)z + (– 0.2Te –5T – 0.04e –5T + 0.04)]/(z – 1)(z – e –5)
i) T=0.5 sek:
G(z) = K[(0.1 + 0.04 + 0.003283 – 0.08)z + (– 0.008209 – 0.003283 + 0.04)]/(z – 1)(z – 0.08209)
= K[0.06328z + 0.02851)/(z – 1)(z – 0.08209) = 0.06328K(z + 0.4505)/(z – 1)(z – 0.08209)
Root locus starts at z = 1 and z = 0.08209 and ends in z = – 0.4505 and z = 
0.06328K(z + 0.4505)
The characteristic equation is given by: +1=0
(z  1)(z  0.08209)
K = – (z – 1)(z – 0.08209)/0.06328(z + 0.4505)
= – (1/0.06328)(z2 – 1.082z + 0.08209)/(z + 0.4505)
= – 15.8(z2 – 1.082z + 0.08209)/(z + 0.4505)
Im z

P2 unit circlel
|z|=1

K  K= .08209 P1 1

K=0 K=0 Re z
– 0.4505 0.4285
-1.33
P3
EIDBS4 Chapter 5: Root Locus Techniques Page 5-8

dK/dz = – 15.8[(2z – 1.082)(z + 0.4505) – (z2 – 1.082z + 0.08209)]/(z + 0.4505)2


= – 15.8(2z2 – 0.181z – 0.4874 – z2 + 1.082z – 0.08209)/(z + 0.4505)2
= 15.8(z2 + 0.901z - 0.5695)/(z + 0.4505)2
dK/dz = 0  z2 + 0.901z – 0.5695 = 0
z = [– 0.901  (0.9012 – 4(– 0.5695))]/2
= [– 0.901  (3.09)]/2 = [– 0.901  1.758]/2 = 0.4285 en –1.330
Breakaway points at z = 0.4285 en z = – 1.330
P2
The system becomes unstable when the root
locus cuts the unit circle at P2 and P3. 1
cos = (12 + 0.45052 – 0.87932)/(210.4505 = 0.477 .8793
At P2,  = 61.51  z = 1118.5 
and K = – 15.8(z – 1)(z – 0.08209)/(z + 0.4505)
.4505
= – 15.8(1118.5 – 1)(1118.5 – 0.08209)/
(1118.5 + 0.4505) = 32.18
0 < K < 32.18

ii) T = 0.1 sec:


G(z) = K[(0.2T + 0.04 + 0.04e –5T – 0.08)z + (– 0.2Te –5T – 0.04e –5T + 0.04)]/(z – 1)(z – e –5T)
G(z) = K[(0.02 + 0.04 + 0.02426 – 0.08)z + (– 0.01213 – 0.02426 + 0.04)]/(z – 1)(z – 0.6065)
= K(0.00426z + 0.00361)/(z – 1)(z – 0.6065)
= 0.00426K(z + 0.8474)/(z – 1)(z – 0.6065)
The root locus starts at z = 1 and z = 0.6065 and ends at z = – 0.8474 and z = 
0.00426K(z + 0.8474)
The characteristic equation is given by: +1=0
(z  1)(z  0.6065)
Im z

P1
unit circle

0.6065
K  K= 1

K=0 K=0 Re z
– 0.8474
–2.487

0.792

P2
EIDBS4 Chapter 5: Root Locus Techniques Page 5-9

K = – [(z –1)(z– 0.6065)]/0.00426(z+ 0.8474) = – 234.7(z2 –1.607z + 0.6065)/(z + 0.8474)


dK/dz = – 234.7[(2z – 1.607)(z + 0.8474) – (z2 – 1.607z + 0.6065)]/(z + 0.8474)2
= – 234.7[2z2 +0.0878z – 1.362 - z2 + 1.607z – 0.6065]/(z + 0.8474)2
= – 234.7[z2 + 1.695z – 1.969]/(z + 0.8474)2
dK/dz = 0  z2 + 1.695z – 1.969 = 0  z = [ – 1.695  (1.6952 – 4(– 1.969))]/2
z = [– 1.695  (10.75)]/2 = [– 1.695  3.279]/2
P1
Breakaway points: z = 0.792 and z = – 2.487
The system becomes unstable when the root 1.639
locus crosses the unit circle at P1 and P2. 1

cos = (12 + 0.84742 – 1.6392)/(210.8474) = – 0.5713
.8474
At P1,  = 2.1789r  z = 10.96269
and K = –234.7(z – 1)(z – 0.6065)/(z + 0.8474)
= – 234.7(10.96269 – 1)(10.96269 – 0.6065)/
(10.96269 + 0.8474) = 108.92–0.0002734
K < 109

Exercise: For example 5-1, find the value of K when the root locus cuts the imaginary
axis. (Ans: let z = ja and from char eq: (0.125 + 0.0625K– a2) + ja(0.125K – 0.75) = 0. Now,
x + jy = 0 implies both x = 0 and y = 0 and therefore 0.125K – 0.75 = 0 and so K = 6)

Appendix: Confirmation of the circular root locus for an open loop transfer function
K(z  N)
of the form: G(z) = ,
(z  P1)(z  P2 )
where N is a real zero, and P1, P2 are real poles of G(z).
The characteristic equation may be found from G(z) + 1 = 0
K(z  N)
+ 1 = 0  K(z – N) + (z – P1)(z – P2) = 0
(z  P1)(z  P2 )
z2 – P1z – P2z + P1P2 + Kz – KN = 0  z2 + (K – P1 – P2)z + (P1P2 – KN) = 0
 (K  P1  P2 )  (K  P1  P2 ) 2  4(P1P2  KN)
z =
2
2
When [(K – P1 – P2) – 4(P1P2 – KN)] < 0, the roots are complex, and are given by:

 (K  P1  P2 ) 4 (P P  KN)  (K  P  P ) 2
z= j 1 2 1 2
2 2
Now let x = Re{z} and y = Im{z}  z = x  jy,
 (K  P1  P2 )
x = ………….................………………………………..…… (1)
2
and

4 (P P  KN)  (K  P  P ) 2
y= 1 2 1 2 ……....…….................………............. (2)
2
EIDBS4 Chapter 5: Root Locus Techniques Page 5-10

For each value of K, x and y may be calculated from equations 1 and 2, and the
resulting (x,y) pairs could then be plotted in the x-y plane. This curve would
correspond to the root locus in the complex plane. In order to find the relationship
between x and y, the parameter K, must be eliminated from equations 1 and 2.
2
(K  P1  P2 ) 2
From (1): x = ……………………....….……….………… (3)
4
and also from (1): 2x = – K + P1 + P2
K = P1 + P2 – 2x …………………………………....…....…....……..…….. (4)
2 4(P1P2  KN)  (K  P1  P2 ) 2
From (2): y =
4
(K  P1  P2 ) 2
y = (P1P2 – KN) –
2
…………………….....………………. (5)
4
Using equations (3) and (4) in equation (5):
y2 = [P1P2 – (P1 + P2 – 2x)N] – x2 = P1P2 – P1N – P2N + 2Nx – x2
y2 + x2 – 2Nx = P1P2 – P1N – P2N
Completing the square in x:
y + x – 2Nx + N2 = P1P2 – P1N – P2N + N2
2 2

y2 + (x – N)2 = (N – P1)(N – P2) ……............…..........…………………..…… (6)


Equation (6) is the equation of a circle centred at x = N and y = 0, with a radius,
r = ( N  P )( N  P )
1 2 y
r = ( N  P )( N  P )
1 2

x
N
EIDBS4 Chapter 6: Digital Controller Design Page 6-1

6. DIGITAL CONTROLLER DESIGN


6.1 Sample rate selection
It is very difficult to formulate a uniform method for the selection of an appropriate
sampling rate. The sampling theorem which states that sampling must be at least twice
as fast as the highest frequency contained in the signal is not always applicable for
digital control systems. From a cost perspective the designer would like to choose the
sampling period as large as possible while a too large sampling period may cause the
system to become unstable.
A rough guide is to sample eight to ten times during a cycle of the damped sinusoidal
oscillations of the output of the closed loop system if it is underdamped. For
overdamped systems, sample eight to ten times during the rise time in the step
response.
Another rule of thumb is to use one-tenth the major time constant as the sampling
interval.

6.2 Design specification in the time domain


The approach in the time domain is to consider transient response specifications in the
continuous s plane and then to translate this specification to the z plane using z = esT .

Example 6-1
Consider the digital control system shown in Figure 6-1.

R(z) C(z)
Digital 1
ZOH P(s) 
controller s(s + 2)
T T

B(z) A(z)

Figure 6-1
Design a digital controller such that the dominant closed loop poles have a damping
ratio  of 0.5 and a settling time of 2 sec. The sampling period is T = 0.2 sec. Obtain
the response of the designed digital control system to a unit step input. Also obtain the
static velocity error constant Kv of the system. Assume a first order controller device
with transfer function of the form:
z a
B(z) = K Equation 6-1
z b

By specifying  and ts, we have specified the transient response completely, that is d ,
n ,  and D are also fixed.
EIDBS4 Chapter 6: Digital Controller Design Page 6-2

From Equation 3-7: ts = 4/  2 = 4/   = 2


From Equation 3-3:  = /n  0.5 = 2/n  n = 4
From Equation 3-2: n =  2   2  d =  2n   2 = 4 2  2 2 = 3.464
d
The damped frequency is d = 3.464 r/s while the sampling frequency is
s = 2/T = 31.42 r/s which is more than 9 times larger than d and therefore
adequate.
We may now calculate the position of the dominant poles in the z plane. From
Equation 3-8: z = e – TdT = e – 20.23.4640.2 = 0.67030.6928 (= 0.670339.69)
A question that could be asked at this stage is why we need compensation of the form
Equation 6-1 and could the system not be forced to obey the specification by simply
adjusting the loop gain. To answer this question, we will construct the root locus of the
uncompensated system. For this purpose we calculate A(z).
  1  = (1  z 1)Z 0.5  0.25  0.25
A(z) = (1  z 1)Z
s2 (s2)   s2 s s2 
 
= (1  z 1)  0.1z  0.25z  0.25z 
 (z  1)
2 z  1 z  0.6703
 z  1  1 2.5 
= 0.1z     2.5 
 z   (z  1)2 z  1 z  0.6703
 2
= 0.1(z  1)  (z  0.6703)  2.5(z  1)(z  0.6703) + 2.5(z  1) 
 (z  1)2 (z  0.6703) 
  0.01758(z + 0.876)
= 0.1  0.1758z + 0.154  =
 (z  1)(z  0.6703)  (z  1)(z  0.6703)

The root locus for A(z) is shown in Figure 6-2.


Im z
dT = 0.6928r = 39.69

=2

P
0.8272

–2.579 1 Re z
– 0.876
0.6703

Figure 6-2
EIDBS4 Chapter 6: Digital Controller Design Page 6-3

On the root locus, the loci of  = 2 ( | z | = e – T = 0.6703 ) and d = 3.464


( z = dT = 39.69 ) in the z plane, were added. It is very clear from Figure 6-2 that
the root locus can never simultaneously satisfy both the requirements  = 2 and
d = 3.464, whatever gain is selected. The essential problem lies with the position of
the two poles at z = 1 and z = 0.6703. They must be shifted to the left if the root locus
ever wishes to pass through the point P ( = 2 and d = 3.464).
It will be our strategy to leave the valuable pole at z = 1 alone, to cancel the pole at
z = 0.6703 and to position a new pole nearer to the origin. Cancelling the pole at
z = 0.6703, require the controller transfer function to have a zero at z = 0.6703:
z  0.6703
B(z) = K .
zb
The characteristic equation of the final system will be given by:
B(z)A(z) + 1 = 0
z  0.6703 0.01758(z + 0.876)
K  +1=0
zb (z  1)(z  0.6703)
K 0.01758(z + 0.876) + 1 = 0
(z  1)(z + b)
0.01758K(z + 0.876) + (z – 1)(z + b) = 0
z + (0.01758K + b – 1)z + (0.0154K – b) = 0
2

Values for K and b must now be determined to satisfy the requirement that the roots of
the characteristic equation are z = 0.6703±0.6928r.
We now remember that the roots of the quadratic equation z2 – 2rcosz + r2 = 0,
are z = r±, as (z – r)(z – r– ) = z2 – r(1 + 1– )z + r2 = z2 – 2rcosz + r2.
Applying this result to the equation under consideration, we arrive at the following
two equations:
0.01758K + b – 1 = – 20.6703cos0.6928r
0.01758K + b – 1 = – 2×0.6703×0.76946
0.01758K + b – 1 = – 1.03154
0.01758K + b = – 0.03154 .......….………….......………… (1)
and 0.0154K – b = (0.6703)2 = 0.4493.
0.0154K – b = 0.4493…….....…………...........…………. (2)
Solving the two equations (1) and (2) renders K = 12.667 and b = – 0.2542.
The desired transfer function for the controller is therefore:
z  0.6703
B(z) = 12.667
z  0.2542
The open loop transfer function for the system is:
z  0.6703 0.01758(z + 0.876) 0.2227(z + 0.876)
G(z) = B(z)A(z) = 12.667  = ,
z  0.2542 (z  1)(z  0.6703) (z  1)(z  0.2542)
EIDBS4 Chapter 6: Digital Controller Design Page 6-4

and the final transfer function is:


G(z)
T(z) =
G(z)  1
0.2227z  0.1951
=
z 2 1.0315z  0.4493
The step response (obtained with MATLAB a=[0.2227 0.1951] b=[1 -1.0315 0.4493]
dstep (a,b,20), is shown in Figure 6-3.

Figure 6-3

The velocity error constant is given by:


1 1 lim  0.2227(z + 0.876) 
Kv = lim  (z  1)G(z)  = (z  1) 
T z1 0.2 z1  (z  1)(z  0.2542 
 0.2227(z + 0.876) 
= 5 lim   = 2.801
z1  z  0.2542 

6.3 Digital realization of a PID controller


An analog PID controller is modelled by the following differential equation:
t
0
de
u(t)  K Pe(t)  K I e(t)dt  K D Equation 6-2
dt
or the model in the s domain by using the Laplace transform of Equation 6-2.
 KI 
U(s)   K P   K Ds E(s) Equation 6-3
 s 

e(t) is the error signal input to the controller and u(t) the output control signal to the
plant. KP is the proportional gain, KI is the integral gain and KD is the derivative gain.
The integral gain may also be expressed as KI = KP/TI where TI is called the reset time,
while the derivative gain is expressed as KD = KPTD where TD is called the rate time.
EIDBS4 Chapter 6: Digital Controller Design Page 6-5

The typical influence that an increase in the values of KP, KI and KD, have on the
response characteristics of a control system, is summarised in Table 6-1
Rise Time Overshoot Settling time S-S Error
KP Decrease Increase Small change Decrease
KI Decrease Increase Increase Eliminate
KD Small Change Decrease Decrease Small Change
Table 6-1
The discrete transfer function of the PID controller may be obtained by assuming a
de
sampling period of T seconds and using approximate expressions for and  e(t)dt .
dt
There are many possible discrete time approximations to integration and differentiation
but for this development we will use the forward difference rule for numerical
differentiation (Figure 6-4 a) and the backward difference rule for numerical
integration (Figure 6-4 b).

e[(k  1)T]  e(kT)


0 0
e(t) de(t) e(t) kT (k - 1)T
 e(t)dt  e(t)dt + Te[(k–1)T]
dt t  kT T
e[(k+1)T] Te[(k–1)T]

0
e[(k+1)T]– e(kT) (k - 1)T
e(t)dt
e(kT)
e[(k–1)T]
e[(k–1)T]
T T
0 (k–1)T kT (k+1)T t (k–1)T kT t

Figure 6-4 a) Figure 6=4 b)

Let us now denote the approximation for de(t) as d(kT) and the approximation
dt t  kT
kT
for 0
e(t)dt as i(kT).
de(t) e[(k  1)T]  e(kT)
So,  d(kT) = Equation 6-4
dt t  kT T
kT
and 0
e(t)dt  i(kT) = i[(k–1)T] + Te[(k–1)T] Equation 6-5

Using the approximations from Equation 6-4 and Equation 6-5 in Equation 6-2 then,
u(kT) = KPe(kT) + KIi(kT) + KDd(kT) Equation 6-6
z transform applied to Equation 6-6:
U(z) = KPE(z) + KII(z) + KDD(z) Equation 6-7
e[(k  1)T])  e(kT)
Now, from Equation 6-4: d(kT) =
T
zE(z)  E(z)
D(z) = Z{d(kT)} =
T
EIDBS4 Chapter 6: Digital Controller Design Page 6-6

z 1
D(z) = E(z) Equation 6-8
T
and from Equation 6-5: i(kT) = i[(k – 1)T] + Te[(k – 1)T]
I(z) = Z{i(kT)} = z – 1I(z) + T z – 1 E(z)  I(z) – z – 1I(z) = T z – 1 E(z)
Tz  1
I(z)(1 – z ) = T z E(z)  I(z) =
–1 –1
E(z)
1 z1
T
I(z) = E(z) Equation 6-9
z 1
Substituting D(z) from Equation 6-8 and I(z) from Equation 6-9 in Equation 6-7:
T z 1
U(z) = KPE(z) + KI E(z) + KD E(z)
z 1 T
1 K
U(z) = [KP + KIT + D (z 1) ]E(z)
z 1 T
The transfer function B(z) of a digital PID controller is therefore given by,
U(z) 1 K
B(z) = = KP + KIT + D (z 1) Equation 6-10
E(z) z 1 T
The block diagram of the digital PID controller is shown in Figure 6-5.
A digital PID
KP controller
E(z) U(z)
1
K IT
z 1

KD
(z 1) Figure 6-5
T

Example 6-2 An analog PI controller is shown in Figure 6-6. Show that the discrete
1 R 1
equivalent is given by B(z) = KP + KIT where KP = 2 and KI = . We use –E(s)
z 1 R1 R1C
as the input as the typical input to this circuit is the measured value minus desired
value, which is the negative of the error value (e = desired value – measured value)

– E(s) (controller output)


–E(z) R1 R2
(error value) –E*(s) –E’(s) 1/sC U(z)
ZOH U(s) U*(s)
T
T

Figure 6-6
EIDBS4 Chapter 6: Digital Controller Design Page 6-7

E' (s) U(s) E' (s) sCU(s) sCR 2  1


– =–  =  E' (s) = sCU(s)
R1 1 R1 sCR 2  1 R1
R2 
sC
 sCR 
sCU(s) =  2  1  E’(s)  U(s) =  R 2  1  1  E’(s) ....................... (1)
 
 R1 R1   R1 CR1  s 
R 1  K 
From Equation (1) with KP = 2 and KI = : U(s) =  K P  I  E’(s) .......... (2)
R1 R1C  s 
1  e  sT 1  e  sT
and –E’(s) = – E*(s)  E’(s) = E*(s) ...................................... (3)
s s
 K  1  e  sT K K 
(3) in (2): U(s) =  K P  I  E*(s)  U(s) = (1  e  sT ) P  I  E*(s)
 s  s  s s2 
 z Tz  z 1  z z 
U(z) = (1 – z –1 
) KP  KI E(z) = K  K IT E(z)
 2  P z 1 2
 z 1 (z  1)  z  (z  1) 
U(z) 1
 = B(z) = KP + KIT (compare with Equation 6-10)
E(z) z 1

Example 6-3 Consider the system in Figure 6-7. The controller is a PI device and the
sampling period is T = 1 sec.

R(z) C(z)
PI 1
ZOH P(s) 
controller s 1
T=1 T=1
B(z) A(z)
G(z)

Figure 6-7
a) Determine the step response of the system with proportional control (B(z) = KP = 1).
b) Determine the step response of the system with integral control B(z) = KIT/(z – 1)
c) Design a PI controller B(z) = KP + KIT/(z – 1) such that the dominant closed loop
poles have a damping ratio  of 0.5 and a settling time of 10 sec.

  z(1  e  1) 

a) A(z) = (1  z 1 )Z P(s)  1)Z 1  = z  1  0.63212
= (1 z   =
s s(s  1) 1
 (z  1)(z  e )  (z  0.36788)
  z 
0.63212 G(z) [0.63212 (z  0.36788)]
G(z) = B(z)A(z) = 1  T(z) = =
(z  0.36788) 1  G(z) 1  [0.63212 (z  0.36788)]
0.63212 z 0.63212z
T(z) = and with step input R(z) = , C(z) =
z  0.26424 z 1 (z 1)(z  0.26424)
EIDBS4 Chapter 6: Digital Controller Design Page 6-8

C(z)/z = 0.63212/(z – 1)(z – 0.26424) = 0.85914/(z – 1) – 0.85914/(z – 0.26424)


C(z) = 0.85914z/(z – 1) – 0.85914z/(z – 0.26424)
c(k) = 0.85914u(k) – 0.85914(0.25424)ku(k)
The step response c(k) is shown in Figure 6-8, plotted with the aid of MATLAB
a=[0.63212] b=[1 -0.26424] dstep(a,b,10)
Step Response
0.9

0.8

0.7

0.6
Amplitude

0.5

0.4

0.3

0.2

0.1

0
0 2 4 6 8 10
No of samples (sec)
Figure 6-8
The step response demonstrates clearly the typical deficiency of proportional
control alone - not being able to drive the system to setpoint (which was 1, while
the system only settled on 0.85914, offset = 0.14086). This happened because G(z)
does not contain a pole at z = 1 (or no pole at s = 0 in P(s)). Integral control has the
ability to remedy this situation by forcing the system to setpoint with a pole at z = 1.

K IT
0.63212 0.63212K I
b) G(z) = B(z)A(z) = = (T = 1)
(z 1) (z  0.36788) (z 1)(z  0.36788)
The root locus of Q(z) = 1 + G(z) = z2 – 1.36788z + (0.63212KI + 0.36788) = 0, is
shown in Figure 6-9. Breakaway point: KI = – (z2 – 1.36788z + 0.36788)/0.63212
Thus dKI/dz = 0 which gives z = 0.68394. The root locus intersects the unit circle
at P when 0.63212K I  0.36788 = 1 so that (KI)MAX = 1
Im z

KI = 1
P
0.68394

0.36788 1 Re z

Figure 6-9

So let us choose KI = 0.5 and determine the step response.


0.63212  0.5 G(z) [0.31606 (z  1)(z  0.36788)]
G(z) = T(z) = =
(z 1)(z  0.36788) 1  G(z) 1  [0.31606 (z  1)(z  0.36788)]
EIDBS4 Chapter 6: Digital Controller Design Page 6-9

0.31606 0.31606
T(z) = =
(z 1)(z  0.36788)  0.31606 z 2 1.36788z  0.68394
z z 0.31606
With step input R(z) = , C(z) = 
z 1 z 1 z 2 1.36788z  0.68394
C(z) 0.31606
 =
z (z 1)(z  0.827010.59704)(z  0.82701  0.59704)
C(z) 1 0.6045772.54457 0.604577  2.54457
 = + +
z z 1 z  0.827010.59704 z  0.82701  0.59704
z 0.6045772.54457z 0.604577  2.54457 z
C(z) = + +
z  1 z  0.827010.59704 z  0.82701  0.59704
c(k) = u(k) + 20.604577(0.82701)kcos(0.58704k + 2.54457)u(k)
= u(k) + 1.2092(0.82701)kcos(0.58704k + 2.54457)u(k)
The step response is shown in Figure 6-10, plotted with MATLAB (a=[0.31606]
b=[1 -1.36788 0.68394] dstep(a,b,20)).
Step Response
1.4

1.2

1
Amplitude

0.8

0.6

0.4

0.2

0
0 5 10 15 20 25 30
Figure 6-10
No of samples Time (sec)

As expected, the controller drives the system to setpoint (offset = 0) but with rather
large overshoot and long settling time.

c) From Equation 3-7: ts = 4/  10 = 4/   = 0.4


From Equation 3-3:  = /n  0.5 = 0.4/n  n = 0.8 r/s
From Equation 3-2: n =  2   2  d =  2n   2 = 0.82  0.4 2 = 0.6928 r/s
d
The damped frequency is d = 0.6928 r/s while the sampling frequency is
s = 2/T = 2/1 = 6.3662 r/s which is more than 9 times larger than d and
therefore adequate.
We may now calculate the position of the dominant poles in the z plane. From
Equation 3-8: z = e – TdT = e – 0.410.69281 = 0.67030.6928.
1 K (z 1)  K I K z  (K I  K P )
Now (with T = 1), B(z) = KP + KIT = P = P
z 1 z 1 z 1
EIDBS4 Chapter 6: Digital Controller Design Page 6-10

az  b
For convenience, let us define a = KP and b = (KI – KP) so that B(z) =
z 1
az  b 0.63212 0.63212az  0.63212b
G(z) = B(z)A(z) = =
(z  1) (z  0.36788) (z  1)(z  0.36788)
G(z) + 1 = 0  0.63212az + 0.63212b + (z – 1)(z – 0.36788) = 0
0.63212az + 0.63212b + z2 – 1.36788z + 0.36788 = 0
z2 + (0.63212a – 1.36788)z + (0.63212b + 0.36788) = 0
0.63212a – 1.36788 = – 20.6703cos0.6928  0.63212a = – 1.03154 + 1.36788
a = 0.53208
and 0.63212b + 0.36788 = (0.6703)2 = 0.4493  0.63212b = 0.08142
b = 0.1288
0.53208z  0.1288
B(z) =
(z 1)
0.53208z  0.1288 0.63212 0.33634z  0.081417
G(z) = =
(z 1) (z  0.36788) (z 1)(z  0.36788)
G(z) [(0.33634z  0.081417) (z  1)(z  0.36788)]
T(z) = =
1  G(z) 1  [(0.33634z  0.081417) (z  1)(z  0.36788)]
0.33634z  0.081417 0.33634z  0.081417
= =
0.33634z  0.081417  (z 1)(z  0.36788) z 2 1.03154z  0.4493
The step response is shown in Figure 6-11, plotted with MATLAB
(a=[0.33634 0.081417] b=[1 -1.03154 0.4493] dstep(a,b,20)).
The overshoot should be D = e-/d = e-0.4/0.6928 = 0.163 (seems to be a bit higher)
and the rise time tr = [-tan-1(d/)]/d = [-tan-1(0.6928/0.4)]/0.6928 = 3.023 sec.
Step Response
1.4

1.2

1
Amplitude

0.8

0.6

0.4

0.2

0
0 5 10 15 20 Figure 6-11
No of samples Time (sec)

KP = 0.53208 and (KI – KP) = b  KI = 0.1288 + 0.53208 = 0.6609


We were fortunate in the sense that the controller zero at z = – 0.2421 (caused by
the numerator az+b of the PI controller transfer function), falls between – 1 and 0.
If the sampling period T or the open loop transfer function G(z), is of such a nature
that KP must become larger than KI, the controller zero will then fall between 0
and 1, which will have an adverse effect on the design.
EIDBS4 Chapter 6: Digital Controller Design Page 6-11

Exercise

6-1 Design a controller B(z) = [(z+a)/(z+b)] for the plant P(s)=1/(s+1) if it is required
that the damping ratio and the settling time of the final system's step response
should be 0.8 and 1 sec respectively. The sampling period is 0.2 sec.

Ans:  = 4/ts = 4 and  = /n  n = 4/0.8 = 5 and d = 2n   2 = 3 rad/sec.


z = e-T±dT = 0.4493±0.6
A(z) = (1-z-1)Z{1/s(s+1)} = 0.18127/(z-0.81873)
G(z) = B(z)A(z) = 0.18127(z + a)/(z + b)(z – 0.81873)
Characteristic equation: 0.18127z + 0.18127a + z2 + bz – 0.81873z – 0.81873b = 0
z2 + (b – 0.63746)z + (0.18127a – 0.81873b) = 0
0.18127a – 0.81873b = 0.20187 and b – 0.63746 = – 0.74165
b = – 0.1042 and a = 0.643
B(z)=(z + 0.643)/(z – 0.1042)

6-2 Design a controller B(z) = K[(z+a)/(z+b)] for the system P(s) = 1/s(s+1) if it is
required that the compensated system should exhibit an overshoot of no more than
20.788% (D=0.20788) and have a settling time of 4 sec. The sampling period is
0.2 sec. Plot the step response of the final system with Matlab.

Ans:  = 4/4 = 1 and 0.20788 = e-/d  d = 2 r/s


z = 0.81873±0.4
A(z)=(1 – z-1)Z{1/s2(s + 1)} = (1 – z-1)Z{1/s2 – 1/s + 1/(s + 1)}
= [(z – 1)/z][0.2z/(z – 1)2 – z/(z – 1) + z/(z – e-0.2)]
= [0.2z – 0.16375 – z2 + 1.81873z – 0.81873 + z2 – 2z + 1]/(z – 1)(z – 0.81873)
= (0.01873z + 0.01752)/(z – 1)(z – 0.81873)
We will now cancel the pole at z=0.81873 and position a new pole to satisfy the
design criteria.
B(z) = K(z – 0.1873)/(z + b)
and G(z) = K(0.01873z + 0.01752)/(z – 1)(z + b)
Characteristic equation: K(0.01873z + 0.01752) + (z – 1)(z + b) = 0
z2 + (0.01873K – 1 + b)z + (0.01752K – b) = 0
0.01752K – b = (0.81873)2 = 0.67032
and 0.01873K – 1 + b = – 20.81873cos(0.4) = – 1.5082
K = 4.472 and b = – 0.592
B(z) = 4.472(z – 0.1873)/(z – 0.592)
and G(z) = (0.08376z + 0.07835)/(z – 1)(z – 0.592)
T(z) = (0.08376z + 0.07835)/(z2 – 1.5082z + 0.6704)

With Matlab, the step response may be plotted.


a=[0.0837 0.07835] b=[1 -1.5082 0.6704] dstep(a,b,50)
Result shown in Figure P 6-1.
EIDBS4 Chapter 6: Digital Controller Design Page 6-12

Figure P6-1 Step response of compensated system

K T (z  1)
6-3 Design a PI controller B(z) = K  I (another form for I(z) using
P 2 (z  1)
the trapezium rule for numerical integration) for the plant P(s)=1/(s+1) if it
is required that the damping ratio and the settling time of the final system's
step response should be 0.31623 and 4 sec respectively. The sampling period
is T = 0.2 sec.
Ans:  = 4/ts = 1
and  = /n  n = 1/0.31623 = 3.1623  d = 2n   2 = 3 rad/sec.
z = e-T±dT = 0.81873±0.6r
and A(z) = (1 – z-1)Z{1/s(s + 1)} = 0.18127/(z – 0.81873)
B(z) = KP + 0.1KI(z + 1)/(z – 1) = [KP(z – 1) + 0.1KI(z + 1)]/(z – 1)
= [(KP + 0.1KI)z + (0.1KI – KP)]/(z – 1)
G(z) = B(z)A(z) = [(KP + 0.1KI)z + (0.1KI – KP)]/(z – 1)[0.18127/(z – 0.81873)]
= [0.18127(KP + 0.1KI) + 0.18127(0.1KI – KP)]/(z – 1)(z – 0.81873)
T(z) = G/(G+1)
= [0.18127(KP + 0.1KI)z + 0.18127(0.1KI – KP)]/
{z2 + [0.18127(KP + 0.1KI) – 1.81873]z + [0.18127(0.1KI – KP) + 0.81873]}
Q(z) = z2 + [0.18127(KP + 0.1KI) – 1.81873]z + [0.18127(0.1KI – KP) + 0.81873]
With the roots of the characteristic equation required to be 0.81873±0.6r
0.18127(KP + 0.1KI) – 1.81873 = – 20.81873cos0.6
0.18127(KP+ 0.1KI) – 1.81873 = – 1.3515
EIDBS4 Chapter 6: Digital Controller Design Page 6-13

0.18127KP + 0.018127KI = 0.46723


KI = 25.775 – 10KP ...........................................(1)
and 0.18127(0.1KI – KP) + 0.81873 = 0.818732
0.18127(0.1KI – KP) + 0.81873 = 0.67032
0.18127(0.1KI – KP) = – 0.14841
0.1KI – KP = – 0.81872
KP = 0.1KI + 0.81872 = 2.5775 – KP + 0.81872 from (1)
2KP = 3.3962  KP = 1.6981
and KI = 25.775 – 16.981 = 8.794
T(z) = (0.46723z – 0.14841)/(z2 – 1.3515z + 0.67032)
The step response is shown in Figure P 6-2

Figure P 6-2

Note: Because T(z) has a zero at z = 0.31764, the overshoot is approximately 40%
while it should be D = e-/d = e-1/3 = 0.3509, or 35%.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy