Copyrighl © I FAC Compuler Aided Design in Control Syslems. Beij ing. PRC. 1988
A CSCAD SOFTWARE FOR OPTIMAL OUTPUT FEEDBACK REGULATORS Luo Zongqian* and Fang Huajing** *Departmnlt of Automatioll , Hua z.hollg Ulliversit), of Sciellce alld Techn%g)', Wuitall, PRC **Departmellt of Electrollic Ellgilleerillg, WlIhall Institute of Techllolog)', Wuhall , PRC
Abstract. rh~ optimal output feedback control problem concerns the problem of generating the cont rol variaoles directly by using line~r combination of the available ou t put variables.This pap er present a CSCAD soft..... are in detail.lli th this CSCAD soft .... are,the designer of control systems can obtain an optimal output feedback regulators s.ubject to; t .... elve kinds of performance indices(six kinds of indices for continuous system,six kinds of indices for discret.e system).First,the gradient formulae for th e i nd ices and an algor.itrua based on g radient minimization technique are g iven. The n~t h e program flo .... -chart and examples are given. Keywords. Computer-aided system. design; optimal control; multi variable control systems; linear systems; computational methods.
INTRODUCTION The linear quadratic reg.u lator problem is one of the typical prDblems in the modern control theor}l'. I't is .... ell kno wn that an optimal control is obtained by feeding back all the state variables and an optimal feedback mat.rix.. does not. depend on the initial states. However if some states are unavailable for feedback, it is impossiole to use the results of the usual regulator theory. The optimal output feedback control problem concerns the problem of generating the control variables directly by taking th.e linear combination of the available output variables instead of first reconstructing the states via a Kalman fiter or a state reconstructor. Th e most difficult point in the design of the linear regulator by directly using output variables is that an optimal feedback matrix subject to usual quadratic performance index.. depends en the initial states which are unavailable. In order to overcome this difficulty, many works have be&n done since the end of 1960's. In 1970 , Levine(1970,1971)
145
proposed a method which assumes the initial state x(O) to be a random variables uniformly distributed on the surface of the n-dimensional unit sphere, and uses mathematical expection value of the quadratic performance index as a ne .... cri teriom. An optimal feedback control gain matrix F which is independent of X(O) can be en found. In 1976, Yahagi(1976,1981) propose~ another method which is quite different from Levien's method. Yahagi used a minimax performance index for obtaining an optimal output feedback regulator. In this method feedback matrix is determined by minimizing the effects of the ....orst value. of the initial state on system. performanc:e measure.. In 1986, the desig~ method of optimal output feedback regulator subject to minimax per~ormance indices .... as further diacusse~Luo,1986), and this design method has been extended to linear discrete-time system. This paper presents a CSCAD soft .... are in detail. With t his CSCAD software, the designer of control systems can obtain an
Luo Zongqian and Fang Huajing
146
optimal output feedbadk regulator subject to twelve kimds. of performance indices, (three ktinda of mathematical expect ion indices and three kinds of minimax performance indices for linear mutivariable continuous system,three kinds of mathematical expectio~ indices and three kinds of minimax indices for linear mutivariable discrete-time system). This CSCAD softwara is written in FORTRON. The use of this interactive software does not, requirli thli knowladge of programming languages or computer science.
Find a F* which minimizes one of the following indices (chosen by the designer) TQX+UTRU) ( 13) J7.(F)= max ,2::(X X ERn UXJ-1
/(-0
- lOk (.r J 8 ( F ) = max ,~e X Q~+U T RU) X € Rn /(-0
( 1 4)
IX.l-1
=.
rr
T
J (F)= max ,2-(k X QX+U RU) 9 X ERn "-0 X =1 J 1O( F) aEa
f: CXTQX+UTRU) )
"-D
( 1 5)
( 16.)
J 11 (F)=E(tf elo'k(XTQX+UTRU»
(17 )
r T T J 12(F)=E(tf.(k X QX+U RU »
(18 )
/t-.
PROBLEM STATEMENT ALGORITHM
The output feedback problem can be briefly describe& as follow: Consider a linear continuous systea described. by X(t)=AX(t)+BU(t), X(O)=X o
(1)
y(t)=cx(t)
( 2)
U(t)=FY(t)
(3)
where X(t.)€Ro" U(t.)ERm" Y(t)ER1 . Fi~ a F* which minimizes one of the followi~ indLces (choaen by the designer) J 1 (.F)= max *J]xfQx+uTIW)dt , X ERn
(4)
JlXJ-1
J 2CF)a max ~Xe.zCJ\xTQx+uTRU)dt (5) XE Rn UXJ=1
J (F)= max 'i:(t.rXTQX+UTRU)dt. 3 XE Rn
(6)
(1)
JS(F)-E(,r~2<1t (XTQX+UTRU)dt)
(8)
J 6 (F)-E( '[(t.rXTQX+UTRU)'d.t)'
(9)
where Ql0, R70 are nxo, and. lILJ(m symmlitrLc matricea respectively.~70 is a real number r70 is a integer. ~.) denotes mathematical expectation.
wh.ara X(k.)€Ro, .. U(k)€R
"
( 1 2)
Y(k)€R
(20)
L(A+BFC)T+(A+BFC)L+Vm(P)Vm(p)T aO
(21)
PV (p)=)\ (P)V (p), v:~T(p)Yl'L(P)=1
(22)
m
IlL
~
If all the eigenvalues of (A+c1I+BFC) have negative real part, then ( 23)
P(A+CJI+BFC)+(A+dI+BFC)Tp+Q+CTF~FC =0
(24)
L(A+CJI+BFC)T+(A+dI+BEC)L
PV (p) =" (p) V (p), V T ( p) V (p) = 1 m m IlL m m (10) ( 11)
l
1
P(A+BFC)+(A+BFC)Tp+Q+cTFTRFC=O
+~m.(p )VmT(p)=O
Consider a linear discrete system describled, by
IIL
If all the e.ig~valu.es of (A+BFC) have negative real part, then oJ ( F) /a F =(RFC+BTp)LC T (19)
[DJ
J4(F)-E('~(XTQX+UTRll)di)
X(O)=X~
These optimal regulators design problems can. be considered as parameter optimization problems •. If the gradient fOI'Tioulae of the indices are given, an iterativ.e algorithm can be obtained easily . The ci..erivation. proced.u.re of the gradient. is prealinted in another paper(Luo,1986). only the. results are gLven nere.
where]\. (p) is maximum. eigenvalue of P, m, and vm(p) La the corresponding eigenvactor
UX;l-1
X.(k.+1)-AX(K)+BU(k), y (k) .. CX.(K) U(k.)'-FY(K)
C,radient Form;u,l ae
If all thli eLgenvalues of (A+BFC) have negativli real part .. then
(25) ( 26.)
147
A CSCAD Software for Optimal Output Feedback Regulators
Lr-(A+BFC)Lr(A+BFC)T=vm(Pr)Vm(Pr)T
oJ (F)laF. -«RFC+ST.Pr)lr+
3
..
T r! (BTfpi , Li ) )C
( 27)
(r!P r _ 1+C TPTRFC)-O
( 28)
T
(46 )
Li-(A+BFC)Li(A+BFC)T i -( A+9FC ).~" CjL j (A+BFC) J-'" i-r-1,r-2 •..... 0
( 41)
P V (p )-)\. (p )V (p ), rm r m rill r
Pi(A+BPC)+(A+BFC) Pi +P i _ 1 O izr-1,r-2 ••••.• 1
(29 )
Po(A+BPC)+(A+BPC)Tpo+Q-O
( 3D)
It can be proved that if we substitute
(31)
E(X o XT) for Vm(P)VIlL(p)T in the gradie~t of 0 minimax indices, they become the gradie~t of mathmatical expectio~ indices. T.he derivation procedure is similar to the one for minimax indices.
z
V.~(Pr)VIlL(Pr)=1
Lr(A+BFC)T+(A+BPC)L r + V!IlJ(P r) Vm (p r)T- O
Li(A+BPC)T+(A+BP~Li+Li+1-0
(32)
(48)
i-r-1,r-2 ...... 0 Pr VmCP r)-"m (p r)Vm(Pr)'
Algpori thm.
V (p )TV (p )'-1 !IlJ r m r
(33)
If all th~ eigenvalues of (A+BPC) have the modulus smallar than o~e,the~ eJ (F)laF _(RFC+BTp(A+BFC) )LC T (34) 7 P_(A+BFC)Tp(A+BPC)-Q+CTpTRPC
(35)
L_(A+BFC)L(A+BPC)T_V~(p)V~(p)T
(36)
PV (p)_A (P)V (p), V (P,TVmCP}-1 m m m m
(37)
u
If all the eigenvalues of (A+BPC)e modulus S!llJaller than: ona., then
have
eJ 8 (F)la F _(RPC+e'ct'BTp(A+BPC) )LCT
(38)
p_e~(A+BFC)Tp(A+BFC)_Q+CTFTRFC
(39)
L-tt"'(A+BFC )L(A+BFC) T_ vm .< p) Vm( p) T
(40)
PVIIIJ(p)'_A (p) Vm(P) , VlIl!( p) TVm(p) -1 m
(4.1 )
If. all t.he: e.igenvaluea. of (A+BPC) hava modulus smaller t.han o~e, then
eJ 9 (F)laF -(RFCLr+BT.t.i.crp j(A+ T BPC)Li)C ; CC~-1)
(42)
Pr-(A+BPC)Tpr(A+BPC) T" r j T T ~ C - P j(A+BPC)+C F RFC ( 43) -(A+BFC) JOt r rPi-(A+BFC)TPi(A+BPC) -(A+BPC)
r.,
T'
i
.
Ci -J Pi _ (A+BPC) 1 i-r-1,r-2 •.•... 1
Po-(A+BFC)TPo(A+BFC)-Q
Based o~ gradient minimizatio~ technique, the algorithm for optimal solution can be obtained. The procedure for optimal output matrix subject to J 1 (F) is g iven below as an example. The others are same and not repeated... step 1: Set F 1-Fo (A+BFoC is stable), Let i=1. By stable we llLean t hat all the eigenvalues ,of (A+BFoC) hava ~egative real parts. This Fo can be obta~ from another . stablizi~ pro grant. S1tep 2: Calculat.e Gei ~aJ,( F) Id F F=F L
I
where J(F) is the one of Ji(F) i,.1 ,2 ..••.• 1 2. In this step, the Liapunov matrix
equat ions must be solved:.. MWl,Y methods can be obtained from the literature. We adopted the method of expanding this matrix equation to a set ~(n+1)/2th order linear algebra equations. (Chen, 1968j Fang, 1986). Pratice has proved that this methods are reliable. Step 3: If IG (£;.0), let F*,.P i , stop, i else goto step 4. Step 4: Calculate col(Si)=-Hicol(G i )
,,£
where Hi -H i _ 1+ (f1_1 col (.oF i-1 ( 44)
( 45)
( col (.4 Fi-1 ) ) T-H i-1 col(.j) Gi ,..1 ) ( col (AF i _ 1 ) )T-col(AFi_1) (C01(.oG i _ 1 ))T
Luo Zongqian and Fang Huajing
148
0.0 1.0 0.00.0] 0.0 0.0 1. 0 0.0 [ 0.0; 0.0 0.0 1. 0
Hi _ 1 ) / ( ( col (A F i-1 ) ) Tco I (AG i-1 ) ) II F i-1 =F C F i-1 ,1lGi-1 =G i -G i _ 1 • I'i _ 1 =1+ ( ( co I (A Gi _ 1 ) ) TH i _ 1 ( co I (A Gi-1 ) ) ) / ( (col(.d Fi -1 ) ) Tcol (A Gi-1 ) ) Step 5: Find optimal stepsize' ti by one dimensional searc h , which satisfies J (F.+t.S. )=min J(F . +t s.) 1 lllt"O 1 1 Because the derivative of J(t) can be obtained easily,
I
dJ ( t) * aJ T dt t=t =trar Gi
I
F=Fi+t*Gi
a modified bisection ~ethod has been use~ f or finding the optimal stepsize t . The procedure is i given in Fig. 3. With this modified.. bisection m.ethod, that J(t) converges to a local minimum value J(t*), where J(t*)7J(0) can be prevented. Step 6: Let Fi+1=Fi+tiSi' i+1-ri, go to step 2.
The weight matrices are QsI4 4' RzI
x 2x2 • The optimal solutions are presented iD Table 1.
TABLE 1 The Optimal Solutions of Example Index
Optimal solution . F*
m.i.nimax 0.53189 1.73630 8.65511 -, r=O,cr,.O -1.55505 -3.75399 -6.74453 1.1x10 mi.n.imax 5.54600 7.51994 10.9612 -1 r=1,(1"=0 -20 •.2120 -24.2980 -12.1321 1. 6x1 0 expo
0.39.7.52 . 1.59255
THis program. is intended for use in an interativ~ mode and was developed on IMS-8000 microcomputer. The program language is FORTRAN-IV. The function of this software is illustrated in Fig. 1. Figure 2. is the main program flow-chart of continuous system output feedback regulators design . The one for discrete system is similar and omitted . The figure 3. is the program flow- chart for one- dimenaiorual search.
-I
expo
0.40619 2.46986 7.80666 r=1,<1=0 -3.23927. -11.6312 -7..88115 1.67
X(t)= (-0.01 -1.0 )x(t)+(1.0 O.O)-U(t) 50.0 -0.01 . 0.0 1.0)' y(t)=(0.50.5)X(t) ChoQse Q=I 2x2 ' RaO.1 I • 2x2 The poles of the open loop system. are ~,2= -0.01:7.07i The optim.al solutions are presented.. in Table 2. TABLE 2 The Optimal Solutions of Example 2 Index
F*
EXAMPLES Example 1. Consider the control system descrioed by X(t ) =AX(t ) +BU(t) y(t)=CX(t) where
1
0 . 0123 0 . 00') 55 -1. 0 1. 0 0. 0 0. 0 0 . 23 0 . 06 18 0. 0 0.016 0 . 0457 0. 0 '1'
B=
7.85225
r=O,C1=O -1.25753 -3.48232 -5.00401 2.2x10
Example 2. Consider the system. described by
PROGRAM FLOW_CHART
- 0 . 037 0 .0 A= [ -6.37 1.25
~/aF.
0.00084 0 . 00 0 .08 - 0 .0862)( 0 . 00023& 0 . 0 0 .804 - 0 .0665
Cloa.e loop system poles
minimax r=O,cr .. O
-13.73678 -6.734547
-5.1278:19.075i
P"ninimax r=1,6 .. 0
-7.240538 -3.654980
-2.7338:14.8911
P1inimax. r=O,c1,. 30
-149.3592 -91.59914
- 60. 239:10. 45ai
P1inimax lr-1"O'''30
-149.0172 -91.49734
-60.138:10.6871
expo 1r=0,6 =0
-12.28192 -6.269456
-4.647.8:18. 232i
A CSCAD Software for Optimal Output Feedback Regulators
149
expo r=1,.,sO
-6.083548-~. 367611
-2 .. 3728~13. 957i
expo r-1 ,,ds 1
-0.267 276 0. 0 24639
0. 0 141!0 .11 52i 1"1=0 .11 6 1
expo r=O,O"-30
-177.1373 -78.35383
-6.3.883~18.791i
expo r-2,c1=1
- 0 .269115 0 .026386
0 . 0 112:0 . 0883i 1"1=0. 0889
expo r-1,6-30
-177.0222 -7.8.33949
-63.850~18.994i C.ONCLUSION
Example 3. Consider the discrete system described by X(k+1)= [0.1 -0.8.,) X(k..)+[0_36B O~O Iu(k) 1.0 0.10 0 •. 0 0.361'j Y(kJ-(1.0 -8.1)X(k}
•
Choose Qs O.0001I 2x2 '· R-0.0001I 2x2
A CSCAD software for optimal outp~t feedback re~~ators has been developed and f~ly teste~. The co~p~tation example~ have shown that t h is CSCAD software is useful for obtaining the output fee dback regulators and further studying the optimal output fee db ack pro bl ems.
The poles of the open loop system are
~1,2=0.1:0.9~'IA1,21=0.9055 The optimal Table 3.
sol~tioAS
are presented in
TABLE 3 The Optimal Solutions of Example 3 Il!Ildex
F*
Close loop system poles
minimax -0.083998 r-O,d- O -0.000964
0.0859~0.?478i
minimax r=1,c1-0
-0.149289 -0.00036.1
0.0731~0.6034i
minimax r=2,d-0
-0.197763 0.005529
0.0554:0.4692i 1,,1-0 . 4725
minimax
r s O,d-1
-0.265788 0.0236.53
O. 0158~0. 13311 1,,1 =0.1340
minimax rs1,6 s1
-0.267.319 0.024516
0.0143~0.1146i
minimax r-2,cf-1
-0.269?21 0.026443
0.0111:0 •.0864i IAI sO. 0872
expo r-O,6-0
-0.092228 -0.000196
0.0833+0. 731 3i I" 1sO: 7359
1~1=0.7526
1,,1_0.6078
1~1_0.11S4
0.0715+0.6218
expo rs1 ,If-O
-0.141921
expo r_2,cf s O
-0.187537 0.003659
0.0600~0.500 5i
-0.265768 0.023380
0.0163~0.1332i
expo r-O,d-1
0.001573
IAI =0.6259 1,,1 =0. 5041
IAI =0.1342
REFERENCES Chen, C.F. ,aru:l. L.S.Shich(1968).Note on expanding PA+API.-Q. IEEE Trans. Automatic Control, AC-13,1,1 22-123. Fang~H.J.(1986 ) .Methods f or solving discrete Lyapunove equation.J.Wuhan Institute of Technology,1,88-93. Levine,W.S.,an~ M.Athans(1970 ) .On the det~rmination of the optimal constant output feed back gains for linear multi variable syst~.IEEE Trans. Automatic Control,AC-15~l,44-48 . Levine,W.S.,T.L.Johnson,and M.Athans(1971 ) . Optimal limited state variable feedback controllers for linear systems. IEEE Trans.Automatic C ontrol, AC-16,~, 785-739. Luo,Z.Q,and H.J.Fang(1 986 ) . The design method of minimax performance ind ex optimal constant output feedback regulator~.Control Tneory anJ Applications,l,l,77-88. Yahagi,T.(1976).Minimax out put f eedback regulators. Trans.of ASME Series G,~. Dynamic Systems Measurement and Control,98,~,270-276.
Yahagi.T.,and J.G. Balche~1 9 81 ) . O pt~mal design of linear regulator by minimax performance index.Preceeding of the 8th LFAC, 487-493.
150
Luo Zongqian and Fang Huajing
continuous system.
Optimal output feedback regulator F*with stability margin f7
Fig. 1.
discrete system
opt i;nal output feedoack regulator F* subject to time multiplie index
Optimal output feedback. regulator F * subject
yes
to time'
multiplier index and with stabili ty margin. 0'
Th.e fun.c:t.ion of thEl CSCAD software
Fig . ?
The rma ill program.
flow-chart
yes
yes
yes
Fig,. 3.
Tha program flow-chart of on.e-dimensional search