Post on 29-Mar-2015
transcript
Unit 4 The Performance of Second Order System
中華技術學院電子系講師 蔡樸生
Open Loop & Close Loop
Open Loop:
Close Loop:
E Y
E YR
( )( ) ( )
1 ( ) ( )
G sY s R s
G s H s
( ) ( ) ( )Y s G s R s
2
( 2 )n
n
w
s s w
2
2 22n
n n
w
s w s w
The Performance of Second Order System
2:
1p
n
The Peak Time Tw
2: exp( )
1pThe Overshoot M
4 1.8
: , :s rn n
The Settling Time T Rise Time Tw w
2
2 2:
2n
n n
wSecond Order System
s w w
,: :nw natural frequency damping ratio
The Response of Second Order System
0 1 2 3 4 5 6 7 8 9 100
0.2
0.4
0.6
0.8
1
1.2
1.4
Time(s)
y(t)
ssepM
pt
Homework 1 2
3
2 4s s ( )U s ( )Y s
1. Steady State Error :
2 0
3( ) ( ) lim ( ) 0.75
( 2 4) sY s y t s Y s
s s s
2. Overshoot : 0.163
3. The Peak Time : 1.8138 s
4. The Rise Time : 0.9 s
5. The Setting Time : 4 s [Hint] : max
The Response of ( )y t
Homework2 : The effect of damping ratio
(1) 0 undamped
(2) 0 1 underdamped
(3) 1 critically damped
(4) 1 overdamped
P Controller This type of control action is formally known as
proportional control (Gain)
Homework3 : K=1, K=4 , K=8 , K=12 , K=36 Please explain the effect of P controller to the
second order system
1
( 4)s s E YR
K
0 5 10 15 200
0.2
0.4
0.6
0.8
1
1.2
1.4
Solution of Homework3
PD Controller
2
( 2 )n
n
w
s s wPK
DK s
( )R s ( )E s( )U s
( )Y s
( )c P DG s K K s ( )
( ) ( )P D
de tu t K e t K
dt
2 ( )( )( ) ( ) ( )
( ) ( 2 )n P D
c pn
w K K sY sG s G s G s
E s s s w
0 1 2 3 4 5 60
0.5
1
1.5
0 1 2 3 4 5 6-0.5
0
0.5
1
0 1 2 3 4 5 6-3
-2.5
-2
-1.5
-1
-0.5
0
0.5
1
1.5
( )y t
( )e t
( )de t
dt
1t 2t 3t 4t
The Performance of P Controller
: The error signal is positive, the torque
is positive and rising rapidly. The large overshoot
and oscillations in the output because lack of damping. : The error signal is negative, the torque
is negative and slow down causes the direction of the
output to reverse and undershoot. : The torque is again positive, thus tending
to reduce the undershoot, the error amplitude is
reduced with each oscillations.
10 t t
1 3t t t
3 4t t t
The contributing factors to the high overshoot
The positive correcting torque in the interval
is too large ( 抑制 ) Decrease the amount of positive torque The retarding torque in the interval
is inadequate ( 增強 ) Increase the retarding torque
10 t t
1 2t t t
The Effect of PD Controller
: is negative; this will reduce the original torque due to alone.
: both and is negative; the negative retarding torque will be greater than that with only P controller.
: and have opposite signs. Thus the negative torque that originally contributes to t
he undershoot is reduced also.
10 t t ( )de tdt
( )e t
1 2t t t ( )e t
2 3t t t
( )de tdt
( )e t ( )de tdt
Homework 4
1
( 4)s s PK
DK s
( )R s ( )E s( )U s
( )Y s
.
Design the PD Controller such that the
response of the original system is optimal
Solution of PD Controller clear; x1=0;x2=0;dt=0.01;r=1;step=2000; kp=36;kd=6;pe=r-x1; for k=1:step t(k)=k*dt; e=r-x1; de=(e-pe)/dt; u=kp*e+kd*de; x1=x2*dt+x1; x2=(u-4*x2)*dt+x2; pos(k)=x1;vel(k)=x2;pe=e; end
PI Controller
2
( 2 )n
n
w
s s wPK
IK
s
( )R s ( )E s ( )U s ( )Y s
( ) Ic P
KG s K
s
( ) ( ) ( )P Iu t K e t K e t dt 2
2
( )( )( ) ( ) ( )
( ) ( 2 )n P I
c pn
w K s KY sG s G s G s
E s s s w
HW5 : The Effect of PI Controller
Adds a zero at to the forward-path T.F.
Adds a pole at to the forward-path T.F. This means that the steady-state error of the
original system is improved by one order.
I
P
Ks
K
0s
2
k
s as b ( )R s ( )E s ( )Y s
2 2
( ) 1 1, ( )
( ) 1 ( ) ( ) ( ) ( )
E s k kE s
R s G s H s s as k b s s as k b
a=2,b=8,k=1
Program of PID Controller clear; x1=0;x2=0;dt=0.01;r=1;step=2000; kp=1;kd=6;ki=0.1;pe=r-x1;ie=(r-x1)*dt; for k=1:step t(k)=k*dt; e=r-x1; de=(e-pe)/dt; ie=ie+e*dt; u=kp*e+kd*de+ki*ie; x1=x2*dt+x1; x2=(u-2*x2-8*x1)*dt+x2; pos(k)=x1;vel(k)=x2;pe=e; end
PID Controller
2
( 2 )n
n
w
s s wPK
IK
s
( )R s( )E s
( )U s ( )Y s
( ) Ic P D
KG s K K s
s
( )( ) ( ) ( )P I D
de tu t K e t K e t dt K
dt
DK s
Homework6 針對以下系統 , 憑藉經驗值調諧 PID三個參數值 , 使得系統響應為最佳化
2
1
2 8s s PK
IK
s
( )E s ( )U s ( )Y s
DK s
( )R s
1 , ,P ss sK e t OS
cp cpK T Critical Stable
Homework7 : Ziegler-Nichols Tuning
1( ) (1 )I P
c P D P d P P di i
K KG s K K s K T s K K T s
s T s T s
Step 1 : Let until the occur of critical stableStep 2 : Optimal Parameter Tuning
, 0,i d PT T K
P
PI
PID
PKiT dT
0.5 cpK
0.45 cpK
0.6 cpK
1.2cpT
0.5 cpT 0.125 cpT
0
0
Homework8: Pendulum System
1
2
3
4
x x
x x
x
x
x
uM
1 2
2 3
3 4
4 3
1
1
x x
mx g x u
M Mx x
M mx g x u
M l M l
0(0) 0.2 , (0) 0.2x m
2
0.2
0.6
M Kg
m kg
l m
Feedback Controller Design
1 1
2 2
3 3
4 4
1
1 2
2 3
4
0 1 0 0 0
10 0 0
0 0 0 1 0
10 0 0
1 0 0 0
0 0 1 0
x xmgx xM M u
x x
x xM m
M l M l
x
y x
y x
x
[ 487 227 944 187]K State Feedback Controller