Solution 4.6.4.12
The closed loop transfer function is
K
s(s+1)
1+
K
s(s+1)(s+20)
=
K
s
3
+21s
2
+20s + K
:
The characteristic equation is
s
3
+21s
2
+(20+K)s + K =0:
The MATLAB program
K=2
p=[1 21 20 K]
roots(p)
K=4.87
p=[1 21 20 K]
roots(p)
K=10
p=[1 21 20 K]
roots(p)
K=50
p=[1 21 20 K]
roots(p)
K=[2 4.87 10 50]
gh = zpk([],[0 -1 -20],1)
[R,K] = rlocus(gh,K)
plot(R,'kd')
print -deps rl46412.eps
produces the output
EDU>sm46412
K=
2
p=
1
1 21 20 2
ans =
-20.0053
-0.8813
-0.1134
K=
4.8700
p=
1.0000 21.0000 20.0000 4.8700
ans =
-20.0128
-0.5108
-0.4764
K=
10
p=
1 21 20 10
ans =
-20.0262
2
-0.4869+ 0.5121i
-0.4869- 0.5121i
K=
50
p=
1 21 20 50
ans =
-20.1298
-0.4351+ 1.5148i
-0.4351- 1.5148i
K=
2.0000 4.8700 10.0000 50.0000
Zero/pole/gain:
1
--------------
s(s+1) (s+20)
R=
-20.0053 -20.0128 -20.0262 -20.1298
-0.8813 -0.5108 -0.4869- 0.5121i -0.4351- 1.5148i
-0.1134 -0.4764 -0.4869+ 0.5121i -0.4351+ 1.5148i
K=
3
-25 -20 -15 -10 -5 0
-2
-1.5
-1
-0.5
0
0.5
1
1.5
2
Figure 1: Plot of solutions
2.0000
4.8700
10.0000
50.0000
EDU>
The plot of the points is shown in Figure 1
For K =2,the MATLAB dialogue
EDU>g = zpk([],[0 -1 -20],2)
Zero/pole/gain:
2
--------------
s(s+1) (s+20)
EDU>h = 1
4
Time (sec.)
A
mp
li
tu
d
e
Step Response
0 5 10 15 20 25 30 35 40 45 50
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
Figure 2: Step Response for K =2
h=
1
EDU>tc = feedback(g,h)
Zero/pole/gain:
2
-------------------------------
(s+20.01) (s+0.8813) (s+0.1134)
EDU>step(tc)
EDU>print -deps sr46412a.eps
EDU>
produces the step response shown in Figure 2.
For K =4:87, the MATLAB dialogue
EDU>g = zpk([],[0 -1 -20],4.87)
5
Zero/pole/gain:
4.87
--------------
s(s+1) (s+20)
EDU>h = 1
h=
1
EDU>tc = feedback(g,h)
Zero/pole/gain:
4.87
-------------------------------
(s+20.01) (s+0.5108) (s+0.4764)
EDU>step(tc)
EDU>print -deps sr46412b.eps
EDU>
produces the step response shown in Figure 3.
For K = 10, the MATLAB dialogue
EDU>g = zpk([],[0 -1 -20],10)
Zero/pole/gain:
10
--------------
s(s+1) (s+20)
EDU>h = 1
h=
1
EDU>tc = feedback(g,h)
6
Time (sec.)
A
mp
li
tu
d
e
Step Response
0 2 4 6 8 10 12
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
Figure 3: Step Response for K =4:87
7
Time (sec.)
A
mp
li
tu
d
e
Step Response
0 2 4 6 8 10 12
0
0.2
0.4
0.6
0.8
1
1.2
1.4
Figure 4: Step Response for K =10
Zero/pole/gain:
10
----------------------------------
(s+20.03) (s^2 + 0.9738s + 0.4993)
EDU>step(tc)
EDU>print -deps sr46412c.eps
EDU>
produces the step response shown in Figure 4.
For K = 50, the MATLAB dialogue
EDU>g = zpk([],[0 -1 -20],50)
Zero/pole/gain:
50
--------------
s(s+1) (s+20)
8
Time (sec.)
A
mp
li
tu
d
e
Step Response
0 2 4 6 8 10 12 14
0
0.5
1
1.5
Figure 5: Step Response for K =50
EDU>h =1
h=
1
EDU>tc = feedback(g,h)
Zero/pole/gain:
50
---------------------------------
(s+20.13) (s^2 + 0.8702s + 2.484)
EDU>step(tc)
EDU>print -deps sr46412d.eps
EDU>
produces the step response shown in Figure 5.
9