Module 5: Design of Sampled Data Control Systems: Lecture Note 3
Module 5: Design of Sampled Data Control Systems: Lecture Note 3
Consider the closed loop discrete control system as shown in Figure 1. Design a digital controller
such that the closed loop system has zero steady state error to step input with a reasonable
dynamic performance. Velocity error constant of the system should at least be 5.
r(t) e(t)
+
− G∗D (s) ZOH Gp (s) c(t)
T
Controller Plant
10
Gp (s) = , T = 0.1 sec
(s + 1)(s + 2)
1 − e−0.1s 10
Gh0 Gp (z) = Z
s (s + 1)(s + 2)
−1 10
= (1 − z )Z
s(s + 1)(s + 2)
∼ 0.04528(z + 0.9048)
=
(z − 0.9048)(z − 0.8187)
>> s=tf(’s’);
>> Gp=10/((s+1)*(s+2));
>> GhGp=c2d(Gp,0.1,’zoh’);
I. Kar 1
Digital Control Module 5 Lecture 3
Root Locus
2
1.5
Imaginary Axis 1
0.5
−0.5
−1
−1.5
−2
−6 −5 −4 −3 −2 −1 0 1 2
Real Axis
The root locus of the uncompensated system (without controller) is shown in Figure 2 for
which the MATLAB command is
>> rlocus(GhGp)
Pole−Zero Map
1
0.8
0.6
0.4
Imaginary Axis
0.2
−0.2
−0.4
−0.6
−0.8
−1
−1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1
Real Axis
Pole zero map of the uncompensated system is shown in Figure 3 which can be generated
using the MATLAB command
>> pzplot(GhGp)
I. Kar 2
Digital Control Module 5 Lecture 3
One of the design criteria is that the closed loop system should have a zero steady state error
for unit step input. Thus a PI controller is required which has the following transfer function
in z-domain when backward rectangular integration is used.
Ki T Kp z − (Kp − Ki T )
GD (z) = Kp +
=
z−1 z−1
The parameter Ki can be designed using the velocity error constant requirement.
1
kv = lim (z − 1)GD (z)Gh0 Gp (z) = 5Ki ≥ 5
T z→1
Above condition will be satisfied if Ki ≥ 1. Let us take Ki = 1. With Ki = 1, the characteristic
equation becomes
>> z=tf(’z’,0.1);
>> Gcomp=0.04528*(z-1)*(z+0.9048)/(z^3 - 2.724*z^2 + 2.469*z - 0.7367);
>> zero(Gcomp);
>> pole(Gcomp);
>> rlocus(Gcomp)
The zeros of the system are 1 and −0.9048 and the poles of the system are 1.0114 ± 0.1663i and
0.7013 respectively. The root locus plot is shown in Figure 4.
Root Locus
2
1.5
1
Imaginary Axis
0.5
−0.5
−1
−1.5
−2
−6 −5 −4 −3 −2 −1 0 1 2
Real Axis
I. Kar 3
Digital Control Module 5 Lecture 3
Root Locus
System: Gcomp
0.6 Gain: 6.31
Pole: 0.721 + 0.692i
Damping: 0.000781 System: Gcomp
Overshoot (%): 99.8 Gain: 0.239
0.4 Frequency (rad/sec): 7.65 Pole: 0.983 + 0.181i
Damping: 0.00369
Overshoot (%): 98.8
Imaginary Axis
System: Gcomp
0 Gain: 1
Pole: 0.888 − 0.271i
Damping: 0.243
Overshoot (%): 45.5
−0.2 Frequency (rad/sec): 3.05
−0.4
−0.6
−0.8
0.7 0.75 0.8 0.85 0.9 0.95 1
Real Axis
It is clear from the figure that the system is stable for a very small range of Kp . The stable
portion of the root locus is zoomed in Figure 5. The figure shows that the stable range of Kp is
0.239 < Kp < 6.31. The best achievable overshoot is 45.5%, for Kp = 1, which is very high for
any practical system. To improve the relative stability, we need to introduce D action. Let us
modify the controller to a PID controller for which the transfer function in z-domain is given
as below.
(Kp T + Kd )z 2 + (Ki T 2 − Kp T − 2Kd )z + Kd
GD (z) =
T z(z − 1)
To satisfy velocity error constant, Ki ≥ 1. If we assume 15% overshoot (corresponding to
ξ∼= 0.5) and 2 sec settling time (corresponding to ωn ∼
= 4), the desired dominant poles can be
calculated as,
p
s1,2 = −ξωn ± jωn 1 − ξ2
= −2 ± j3.46
The pole zero map including the poles of the PID controller is shown in Figure 6 where the red
cross denotes the desired poles.
I. Kar 4
Digital Control Module 5 Lecture 3
Pole−Zero Map
1
0.8
0.6
0.4
Imaginary Axis
0.2
θ θ
1 2
0
−0.2
−0.4
−0.6
−0.8
−1
−1 −0.5 0 0.5 1 1.5
Real Axis
Let us denote the angle contribution starting from the zero to the right most pole as θ1 ,
θ2 , θ3 , θ4 and θ5 respectively. The angles can be calculated as θ1 = 9.5o , θ2 = 20o , θ3 = 99.9o ,
θ4 = 115.7o and θ5 = 129.4o .
Net angle contribution is A = 9.5o − 20o − 99.9o − 115.7o − 129.4o = −355.5o . Angle defi-
ciency is −355.5o + 180o = −175.5o
Thus the two zeros of PID controller must provide an angle of 175.5o . Let us place the two
zeros at the same location, zpid .
Since the required angle by individual zero is 87.75o , we can easily say that the zeros must
lie on the left of the desired closed loop pole.
0.28
tan−1 = 87.75o
0.77 − zpid
0.28
or, = tan(87.75o ) = 25.45
0.77 − zpid
0.28
or, 0.77 − zpid = = 0.011
25.45
or, zpid = 0.77 − 0.011 = 0.759
(z − 0.759)2
The controller is then written as GD (z) = K . The root locus of the compensated
z(z − 1)
system (with PID controller) is shown in Figure 7. This figure shows that the desired closed
loop pole corresponds to K = 4.33.
z 2 − 1.518z + 0.5761
Thus the required controller is GD (z) = 4.33 . If we compare the above
z(z − 1)
I. Kar 5
Digital Control Module 5 Lecture 3
Root Locus
1.5
1
System: untitled1
Gain: 4.33
Pole: 0.77 + 0.279i
Damping: 0.497
0.5 Overshoot (%): 16.6
Imaginary Axis
−0.5
−1
−1.5
−5 −4 −3 −2 −1 0 1 2
Real Axis
transfer function with the general PID controller, Kp and Kd can be computed as follows.
Note that the above Ki satisfies the constraint Ki ≥ 1. One should keep in mind that the
design is based on second order dominant pole pair approximation. But, in practice, there will
be other poles and zeros of the closed loop system which might not be insignificant compared
to the desired poles. Thus the actual overshoot of the system may differ from the designed one.
I. Kar 6