Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
R
S
T
t
t
and the initial condition is x(0) |1 0 2|
T
.
B.10 Lxcm(| .2 rr///4
Linearized equations governing the inverted pendulum system oI Fig. 5.16 are
x Ax bu
x q q
: :
T
A
0 1 0 0
4 4537 0 0 0
0 0 0 1
0 5809 0 0 0
.
. -
L
N
M
M
M
M
M
O
Q
P
P
P
P
P
; b
0
0 3947
0
0 9211
-
L
N
M
M
M
M
M
O
Q
P
P
P
P
P
.
.
(a) Show that the open-loop system is unstable.
(b) Design state Ieedback u kx that results in closed-loop poles at
1, 1, 1, 1.
(c) Simulate the Ieedback system. Given initial state
x(0) |0.1 0 0 0|
T
B.11 Lxcm(| . rr///4
The plant model oI a satellite attitude control system (ReIer Figs 7.37.4) is
x Ax bu
v cx
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 87
with A
0 1
0 0
L
N
M
O
Q
P
; b
0
1
L
N
M
O
Q
P
; c |1 0|
(a) Design state Ieedback u kx that results in closed-loop poles at
4 + f4.
(b) Assuming that the state vector x(t) is measurable, simulate the Ieedback
system Ior x(0) |1 0|
T
.
(c) Consider now that state measurements are not practical. Design a state
observer that yields estimated states
~
x (J). Place the observer poles at
10, 10.
(d) Obtain state variable model oI the compensator by cascading the state
Ieedback control law and the state observer. Find the transIer Iunction
oI the compensator.
(e) Set up state model oI the Iorm (7.57) Ior the observer-based regulator
system and simulate the model (Note that x(0) |1 0|
T
leads to
~
x (0) |1 0|
T
when
x(0) 0).
B.12 Lxcm(| .13 rr///4
The plant model oI a satellite attitude control system (ReIer Figs 7.37.4) is
x(k 1) Fx(k) gu(k)
v(k) cx(k)
with
F
1
0 1
T
L
N
M
O
Q
P
; g
T
T
2
2 / L
N
M
O
Q
P
; T 0.1 sec
c |1 0|
The reIerence input q
r
is a step Iunction.
Design state Ieedback u k
1
(x
1
(k) q
r
) k
2
x
2
(k) that results is deadbeat
response.
Simulate the Ieedback system Ior a unit-step input q
r
.
B.13 Reconsider the inverted pendulum regulator problem raised in Problem
B.10, wherein you designed state Ieedback control based on pole-placement.
Now design a state-Ieedback control law that minimizes the perIormance
index
J
1
2
0
z
(x
T
Qx u
T
Ru)dt
with
Q
100 0 0 0
0 1 0 0
0 0 1 0
0 0 0 1
L
N
M
M
M
M
M
O
Q
P
P
P
P
P
; R 0.01
igiral Conrrol and Srarc \ariallc Mcrhods 88
Simulate the Ieedback system Ior initial state x(0) |0.1 0 0 0|
T
.
B.1+ Reconsider the inverted pendulum system oI problem B.10.
(a) Discretize the plant model (sampling interval T 0.1 sec).
(b) Introduce integral state in the plant equations (ReIer Eqn. (7.109)) and
show that the augmented system is controllable.
(c) Design state Ieedback with integral control that minimizes the perIor-
mance index
J
1
2
0 k =
|x
T
(k)Qx(k) u
T
(k)Ru(k)|
with
Q
10 0 0 0 0
0 1 0 0 0
0 0 100 0 0
0 0 0 1 0
0 0 0 0 1
L
N
M
M
M
M
M
M
M
O
Q
P
P
P
P
P
P
P
; R 1
(d) Simulate the digital servo (ReIer Fig. 7.17) Ior a step input.
B.15 Br/o Lxcm(| 10.3 rr///4
Figure 10.40a shows the block diagram oI a nonlinear system with saturation
nonlinearity.
(a) Sketch the Nyquist plot Ior the linear transIer Iunction
G(s)
1
1 2 1 s s s ( )( ) + +
(b) Superimpose on this plot, the plot oI describing Iunction oI saturation
nonlinearity.
(c) Show the existence oI a stable limit cycle and determine its amplitude
and Irequency.
(d) Drag the Iollowing blocks Irom SIMULINK block libraries:
(i) 'Sum Irom Math subnode oI Simulink node;
(ii) 'Saturation Irom Nonlinear subnode oI Simulink node;
(iii) 'LTI system Irom Control System Toolbox node: and
(iv) 'Scope Irom Sinks subnode oI Simulink node.
Setup a simulation block diagram as per the Ieedback structure given in
Fig. 10.40a. Simulate the system Ior an initial condition oI x0 |5 0 0|
T
.
The SIMULINK response shows a limit cycle. Determine the amplitude and
Irequency oI the limit cycle and compare these parameters with the ones
obtained in part (c).
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 8
Script PB.1
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 3.1')
Lffects of sampT1nq on response
AnaToq system
0tf{1,|1 1 0|),
Mfeedback{0,1),
1rans1ent response
f1qure{1)
step{M),
Steady-state response
Kpdcqa1n{0)
0vtf{|1 0|,1)*0,
Kvdcqa1n{0v)
0atf{|1 0|,1)*0v,
Kadcqa1n{0a)
hoTd on
SampTed system
1s1nput{'Lnter sampT1nq t1me .')
0zc2d{0,1s),
Mzfeedback{0z,1),
1rans1ent response
Step{Mz),
Steady-state response
Kpzdcqa1n{0z)
0vztf{|1 -1|,1,1s)*0z]1s,
Kvzdcqa1n{0vz)
0aztf{|1 -1|,1,1s)*0vz]1s,
Kazdcqa1n{0az)
hoTd off
DeTay approx1mat1on of ZON.
kefer LxampTe 2.10.
f1qure{2)
step{M),
hoTd on
0dtf{1,|1 1 0|,'1nputDeTay',1s]2),
0d1pade{0d,2),
M1feedback{0d1,1),
step{M1),
hoTd off
Us1nq L11 V1ewer,determ1ne peak overshoot
igiral Conrrol and Srarc \ariallc Mcrhods 00
& settT1nq t1me of anaToq & sampTed systems.
Tt1v1ew{'step',M,M1)
Script PB.2
cTear aTT,cTose aTT
d1sp{'kefer LxampTe 3.2')
Lffect of sampT1nq on stab1T1ty
0tf{1,|1 2 0|),
f1qure{1)
rTocus{0),sqr1d
ax1s equaT
pause
Wa1ts for user to str1ke any key.
1s1nput{'Lnter sampT1nq t1me.')
0zc2d{0,1s),
f1qure{2)
rTocus{0z),zqr1d,
ax1s equaT
|K1,p1|rTocf1nd{0z)
Script PB.3
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 3.3')
D1scret1zat1on of system w1th dead-t1me
11,N1,deTta0.5,
0tf{1,|1 1|,'1nputDeTay',deTta*1),
0z1c2d{0,1),
0z2tf{1,|1 0|,1),
0z0z1*0z2,
zpk{0z)
Script PB.1
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 2.10')
D1q1taT 1mpTementat1on of AnaToq Des1qn
Approx1mat1on of sampTed-data system
1s0.04,
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 01
denconv{conv{|0.5 1|,|0.1 1|),|0.05 1|),
0tf{10,den,'1nputDeTay',1s]2),
01pade{0,2),
AnaToq Des1qn
f1qure{1)
Dtf{|0.61 1|,|2 1|),
marq1n{D*01)
f1qure{2)
L11 V1ewer funct1ons are ava1TabTe
1n f1qure w1ndow.Zoom 1n req1on of -3db
contour & read bandw1dth.
0cD*01,
nqr1d,
n1choTs{0c),
D1scret1zat1on of Des1qn
Dzc2d{D,1s,'tust1n')
00tf{10,den),
0zc2d{00,1s),
Mzfeedback{Dz*0z,1),
Tt1v1ew{'step',Mz)
Script PB.5
cTear aTT,
cTose aTT,
d1sp{'kefer LxampTe 4.3')
D1rect D1q1taT Des1qn{Taq compensat1on)
Uncompensated system
0tf{50,|1 5 0|),
D1scret1zat1on
0zc2d{0,0.1),0z1zpk{0z),
Des1qn 1n w-doma1n
0wd2c{0z,'tust1n'),
f1qure{1),
marq1n{0w),
kead uncompensated phase marq1n from f1qure 1.
wToqspace{-1,1,100),
|maq,ph|bode{0w,w),
maq & ph are arrays,MA1LAb funct1on 1nterp1
does not accept these arrays.keshape the
arrays 1nto coTumn vectors.
maqreshape{maq,100,1),
phreshape{ph,100,1),
igiral Conrrol and Srarc \ariallc Mcrhods 02
h1-180+spec1f1ed phase marq1n+eps1Ton-130
h11nput{'Lnter phase anqTe h1.')
SeTect frequency ranqe properTy,funct1on 1nterp1
requ1res monoton1c data.
wc21nterp1{ph,w,h1)
wc2 1s the des1red qa1n crossover .
beta1nterp1{ph,maq,h1),
Upper corner frequency at wc2]4.
wcu1nput{'Lnter upper corner frequency.')
tau1]wcu,
Dwtf{|tau 1|,|beta*tau 1|)
D1q1taT controTTer
Dc2d{Dw,0.1,'tust1n'),
Dzzpk{D)
f1qure{2)
kead phase marq1n of compensated system
from f1qure 2.
marq1n{Dw*0w),
bandw1dth{uncompensated &compensated)
w|5.0.1.15|,
|maq,ph,w|bode{feedback{0w,1)),
maqdb20*Toq10{maq),
wb1nterp1q{-maqdb,w,3)
|maq1,ph1,w|bode{feedback{Dw*0w,1)),
maq1db20*Toq10{maq1),
wb11nterp1q{-maq1db,w,3)
AnaTys1s on N1choTs chart
f1qure{3),
0wcDw*0w,
nqr1d,
n1choTs{0w,0wc),
Step-response anaTys1s us1nq L11 V1ewer
Mzfeedback{D*0z,1),
Tt1v1ew{'step',Mz)
Carry out des1qn on 0U1
Script PB.6
cTear aTT,
cTose aTT,
d1sp{'kefer LxampTe 4.4')
D1rect D1q1taT Des1qn{Tead Compensat1on)
Uncompensated system
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 03
0tf{50,|1 5 0|),
D1scret1zat1on
0zc2d{0,0.1),
Des1qn 1n w-doma1n
0wd2c{0z,'tust1n'),
f1qure{1)
marq1n{0w),
kead uncompensated phase marq1n from f1qure 1.
h1Mspec1f1ed phase marq1n-uncompensated
phase marq1n+eps1Ton35
h1M1nput{'Lnter requ1red phase Tead .')
aTpha{1-s1n{h1M*p1]180))]{1+s1n{h1M*p1]180)),
wToqspace{0,2,100),
|maq,ph|bode{0w,w),
maqdb20*Toq10{maq),
maqdbreshape{maqdb,100,1),
wm1nterp1{maqdb,w,-20*Toq10{1]sqrt{aTpha))),
tau1]{wm*sqrt{aTpha)),
Dwtf{|tau,1|,|aTpha*tau,1|)
D1q1taT controTTer
Dc2d{Dw,0.1,'tust1n'),
Dzzpk{D)
f1qure{2),
kead compensated phase marq1n from f1qure 2.
marq1n{Dw*0w),
bandw1dth{uncompensated & compensated)
w|5.0.1.25|,
|maq,ph,w|bode{feedback{0w,1)),
maqdb20*Toq10{maq),
wb1nterp1q{-maqdb,w,3)
|maq1,ph1,w|bode{feedback{Dw*0w,1)),
maq1db20*Toq10{maq1),
wb11nterp1q{-maq1db,w,3)
AnaTys1s on N1choTs chart
f1qure{3)
0wcDw*0w,
nqr1d,
n1choTs{0w,0wc)
Step-response anaTys1s us1nq L11 V1ewer
Mzfeedback{D*0z,1),
Tt1v1ew{'step',Mz)
Carry out the des1qn on 0U1
igiral Conrrol and Srarc \ariallc Mcrhods 04
Script PB.7
cTose aTT
cTear aTT
d1sp{'kefer LxampTe 4.1')
D1q1taT ControTTer Des1qn on kootTocus pTots
Tant modeT
0tf{1,|1 2 0|),
10.2,
0zc2d{0,1),0z1zpk{0z),
zeta0.5,wn4,
thetawn*1*sqrt{1-zeta2),
f1qure{1)
Uncompensated root Toc1
rTocus{0z),
1ake near-zero vaTue for wn 1n zpchart funt1on
1f you are not us1nq wn Tocus 1n your des1qn procedure.
zpchart{qca,0.5,.01),
kepTace zpchart command by zqr1d{zeta,wn) 1f work1nq w1th
MA1LAb 5.3 vers1on.
ax1s equaT,
hoTd on
Locate des1red dom1nant roots.
poTar{theta*|1 1|,|0 1|,'k'),
0a1n ad]ustment does not sat1sfy specs.
Lead compensator zero to canceT open-Toop
poTe at z0.61.1ake poTe at zaTpha.
aTpha1nput{'Lnter tr1aT vaTue of aTpha.')
Dztf{|1 -0.61|,|1 -aTpha|,1),
f1qure{2)
rTocus{Dz*0z),
zpchart{qca,zeta,0.01),
ax1s equaT,
hoTd on
poTar{theta*|1 1|,|0 1|,'k'),
|KK,poTesCL|rTocf1nd{Dz*0z)
Tace the crossha1r cursor at des1red root & cT1ck.
0vztf{|1 -1|,1,1)*Dz*KK*0z]1,
Kvzdcqa1n{0vz)
erform s1muTat1on study on compensated system
us1nq L11 V1ewer.
Mzfeedback{KK*Dz*0z,1),
Tt1v1ew{'step',Mz)
Carry out the des1qn on 0U1.
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 05
Script PB.9
cTear aTT
cTose aTT
d1sp{'State Space AnaTys1s')
01ven transfer funct1on
num|1 0|,
den|1 2 2.5 0.5|,
0tf{num,den)
Construct state var1abTe modeT
sysss{0),
|A,b,c,d|ssdata{sys)
D1scret1zat1on
10.1,
sysdc2d{sys,1),
|l,q,c,d|ssdata{sysd)
S1muTat1on
t|0.0.1.20|',
x0|1,0,2|',
1nput for 0<t<2.
u{1.20)2*ones{20,1),
1nput for t2.
u{21.201)0.5*ones{181,1),
|y,t,X|Ts1m{sys,u,t,x0),
|y1,t,X1|Ts1m{sysd,u,t,x0),
f1qure{1)
pTot{t,X{.,1),t,X1{.,1),'o'),qr1d,
Teqend{'x_1'),
f1qure{2)
pTot{t,X{.,2),t,X1{.,2),'o'),qr1d,
Teqend{'x_2'),
f1qure{3)
pTot{t,X{.,3),t,X1{.,3),'o'),qr1d,
Teqend{'x_3'),
Script PB.10
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 1.2')
kequTator Des1qn{oTe-pTacement) for 1nverted enduTum
Tant ModeT
A|0,1,0,0,4.4531,0,0,0,0,0,0,1,-0.5809,0,0,0|,
b|0,-0.3941,0,0.9211|,
igiral Conrrol and Srarc \ariallc Mcrhods 0
c|0 0 1 0|,d0,
sysss{A,b,c,d),
Uctrb{A,b),
ControTTabTeoTesrank{U)
kequTator Des1qn
poTesOLpoTe{sys)
poTesCL|-1,-1,-1,-1|,
kacker{A,b,poTesCL)
kequTatoroTese1q{A-b*k)
S1muTat1on
x0|0.1,0,0,0|',
t|0.0.1.20|,
sysCLss{A-b*k,|0,0,0,0|,c,0),
|y,t,X|Ts1m{sysCL,0*t,t,x0),
f1qure{1)
subpTot{2,2,1),pTot{t,X{.,1)),qr1d,Teqend{'x_1'),
subpTot{2,2,2),pTot{t,X{.,2)),qr1d,Teqend{'x_2'),
subpTot{2,2,3),pTot{t,X{.,3)),qr1d,Teqend{'x_3'),
subpTot{2,2,4),pTot{t,X{.,4)),qr1d,Teqend{'x_4')
Script PB.11
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 1.1')
Observer-based kequTator for SateTT1te Att1tude ControT
Tant ModeT
A|0 1,0 0|,b|0,1|,c|1 0|,
kequTator Des1qn
poTesCL|-4+41,-4-41|,
kpTace{A,b,poTesCL)
kequTatorpoTese1q{A-b*k)
sysss{A-b*k,|0,0|,c,0),
S1muTat1on
t|0.0.01.1|,
x0|1 0|',
|y,t,X|1n1t1aT{sys,x0,t),
f1qure{1)
pTot{t,y),
hoTd on
Observer Des1qn
poTesOb|-10 -10|,
kkacker{A',c',poTesOb),
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 07
mkk'
ObserverpoTese1q{A-m*c)
kefer Lqns.{1.58)&{1.59)
sys_compss{A-b*k-m*c,m,k,0),
Dtf{sys_comp)
S1muTat1on
kefer Lqn.{1.51)
A1A-b*k,A2b*k,A3zeros{s1ze{A)),A4A-m*c,
A_cT|A1{1,.),A2{1,.),A1{2,.),A2{2,.),A3{1,.),A4{1,.),A3{2,.),A4{2,.)|,
sysCLss{A_cT,|0,0,0,0|,|1 0 0 0|,0),
x0|1 0 1 0|',
|y1 t X1|1n1t1aT{sysCL,x0,t),
pTot{t,y1,'r'),qr1d,
Teqend{'Output w1th no observer','Output w1th observer')
hoTd off
f1qure{2)
pTot{t,X1{.,3),t,X1{.,4)),qr1d,
Teqend{'xt1Tde_1','xt1Tde_2')
Script PB.12
cTear aTT,
cTose aTT,
d1sp{'kefer LxampTe 1.13')
Deadbeat controTTer for SateTT1te Att1tude ControT
Tant ModeT
10.1,
l|1,1,0,1|,q|12]2,1|,c|1,0|,
sysdss{l,q,c,0,1),
oTe pTacement
poTesCL|0,0|,
kacker{l,q,poTesCL)
Step response
sysdCLss{l-q*k,100*q,c,0,'1s',1),
step{sysdCL)
Script PB.13
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 1.2')
L1near Quadrat1c kequTator for 1nverted enduTum
Tant ModeT
igiral Conrrol and Srarc \ariallc Mcrhods 08
A|0,1,0,0,4.4531,0,0,0,0,0,0,1,-0.5809,0,0,0|,
b|0,-0.3941,0,0.9211|,
c|1,0,0,0|,
sysss{A,b,c,0),
Uctrb{A,b),
ControTTabTeoTesrank{U)
erformance 1ndex
Q|100,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1|,k0.01,
State leedback
|k L|Tqr{A,b,Q,k),
oTesCLL
0a1nMatr1xk
sysCLss{A-b*k,|0,0,0,0|,c,0),
S1muTat1on
x0|0.1,0,0,0|',
t|0.0.1.20|,
|y,t,X|1n1t1aT{sysCL,x0,t),
subpTot{2,2,1),pTot{t,X{.,1)),qr1d,Teqend{'x_1'),
subpTot{2,2,2),pTot{t,X{.,2)),qr1d,Teqend{'x_2'),
subpTot{2,2,3),pTot{t,X{.,3)),qr1d,Teqend{'x_3'),
subpTot{2,2,4),pTot{t,X{.,4)),qr1d,Teqend{'x_4'),
Script PB.11
cTear aTT
cTose aTT
d1sp{'kefer LxampTe 1.2')
D1q1taT Servo for 1nverted enduTum
Tant ModeT
A|0,1,0,0,4.4531,0,0,0,,0,0,0,1,-0.5809,0,0,0|,
b|0,-0.3941,0,0.9211|,
c|0,0,1,0|,
sysss{A,b,c,0),
10.1,
sysdc2d{sys,1),
|l,q,c,d|ssdata{sysd),
Tant ModeT w1th 1nteqraT state
kefer Lqn.{1.109)
l1|l{1,.),0,l{2,.),0,l{3,.),0,l{4,.),0,c*l,1|,
q1|q{1),q{2),q{3),q{4),c*q|,
c1|c,0|,
Uctrb{l1,q1),
Appcndix B. MA1AB Aidcd Conrrol Sysrcm csign. Convcnrional 0
rankUrank{U)
erformance 1ndex
Q|10,0,0,0,0,0,1,0,0,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,1|,
k1,
State leedback w1th 1nteqraT ControT
KdTqr{l1,q1,Q,k),
Kp|K{1),K{2),K{3),K{4)|
K1K{5)
S1muTat1on{step response)
kefer Lqns.{1.110)&{1.108)
l1_cTl1-q1*K,
sysCLss{l1_cT,|0,0,0,0,-1|,c1,0,'1s',1),
t|0.0.1.20|,
|y,t,X|step{sysCL,t),
pTot{t,y),qr1d
Script PB.15
cTear aTT,
cTose aTT,
d1sp{'kefer kev1ew LxampTe 10.3')
Descr1b1nq lunct1on AnaTys1s
Nyqu1st pTot for 0{s)
0tf{3,conv{conv{|2 1|,|1 1|),|1 0|)),
w|1.0.1.100|,
|re 1m w|nyqu1st{0),
rereshape{re,Tenqth{w),1),
1mreshape{1m,Tenqth{w),1),
pTot{re,1m),
ax1s{|-5 2 -5 2|),
hoTd on
Descr1b1nq lunct1on pTot for saturat1on
kefer Lqns.{10.51)-{10.53)
S1,
L|1.0.5.10|',
N|1.0,0.181,0.609,0.495,0.416,0.359,0.315,0.281,0.253,...
0.230,0.211,0.195,0.181,0.169,0.159,0.149,0.141,0.134,0.121|',
N1-1.]N,
re1N1,
1m10*Tenqth{N1),
pTot{re1,1m1,'ro'),qr1d,
Move the po1nter to the 1ntersect1on po1nt & cT1ck.
|X,Y|q1nput{1)
igiral Conrrol and Srarc \ariallc Mcrhods 10
L01nterp1{N1,L,X)
|maq ph w|bode{0),
phreshape{ph,Tenqth{w),1),
w01nterp1{ph,w,-180)
Fig. PB.15