You are on page 1of 7

c

MUSYN
Inc. 2009

HIMAT: H Control Design


PURPOSE:
Design of H controllers.

H Controller Synthesis: hinfsyn


[k,cl,gam,info] = hinfsyn(p,nmeas,ncon,key1,value1,key2,value2)
KEY
GMAX
GMIN
TOLGAM
METHOD

VALUE
real
real
real

S0

ric
lmi
maxe
real

DISPLAY

on/off

z
e
y

MEANING
initial upper bound on GAM (Inf default)
initial lower bound on GAM (0 default)
relative error tolerance for GAM (.01 default)
H-infinity solution method:
- (default) standard 2-Riccati solution, DGKF1989
- LMI solution, Packard 1992, Gahinet 1994
- maximum entropy, HINFSYNE, Glover-Doyle 1988
(default=Inf) frequency S0 at which entropy is
evaluated, only applies to METHOD maxe
display synthesis information to screen,
(default = off)




-

w
d
u

z
e

g = Fl (p, k)

hinfsyn calculates a H control law which achieves the infinity norm gfin for the interconnection structure p. The control law, k, stablizes the SYSTEM matrix p and has the
same number of states as p. The SYSTEM p is partitioned

A B1 B2

p = C1 D11 D12
C2 D21 D22

where B1 are the disturbance inputs, B2 are the control inputs, C1 are the errors to be
kept small and C2 are the output measurements provided to the controller. B2 has column
size (ncon) and C2 has row size (nmeas).
The closed-loop system is returned in clp. The program provides a iteration using
the bisection method. Given a high and low value of , GMAX and GMIN, the bisection

c
MUSYN
Inc. 2009

method is used to iterate on the value of in an effort to approach the optimal H


control design. If GMAX = GMIN, only one value is tested. The stopping criterion for the
bisection algorithm, require the relative difference between test value and the prior
value be less than TOLGAM.
The algorithm employed requires tests to determine whether a solution exists for a given
value. The following assumptions are made in the implementation of the hinfsyn
algorithm and must be satisfied:
(i)
(ii)
(iii)
(iv)

(A, B2 ) is stabilizable and (C2 , A) detectable


D
" 12 and D21 have# full rank
A I B2
has full column rank for all .
C1
D12 #
"
A I B1
has full row rank for all .
C2
D21

where denotes the frequency variable. If condition (ii) is violated, hinfsyn automatically adds a small random matrix of size size(p) to p.d to satisfy this condition.
If the display flag is set, (DISPLAY,on), the hinfsyn program displays several variables
which can be checked to ensure that the above conditions are being satisfied. For each
value being tested, the minimum magnitude, real part of the eigenvalues of the X and Y
Hamiltonian matrices are displayed along with the minimum eigenvalue of X and Y
which are the solutions to the X and Y Riccati equations, respectively. The maximum
eigenvalue of X Y , scaled by 2 , is also displayed. This addition information can aid
you in the control design process.

Example: H Controller Synthesis for HIMAT


An H control law will be synthesized for the HIMAT interconnection structure shown
below. The controller is designed to minimize the infinity norm between the set of inputs,
in this example they are w and d, and the system outputs, z and e.
This is better illustrated by the interconnection structure for the above block diagram.
The idea of H control
design,
is to synthesize a controller k which minimizes the infinity

z1
w1
"
#
"
#
z
w
y1
u1
2
2
, while measuring
and feeding back
.
, and
norm between
e1
d1
y2
u2
e2
d2

You will make up the interconnection structure himatic during the HIMAT exercise by
working through previously. This will construct the HIMAT interconnection structure

c
MUSYN
Inc. 2009
"

z1
z2

wdel
6

"

w1
w2

"

?- g
himat

d1
d2

#
"

e1
- wp - e
2

- ?
g

"

u1
u2

"

y1
y2

Figure 1: HIMAT Open-loop Interconnection Structure


z1 , z2 
e1 , e2 
y1 , y2 

himatic 


w1 , w2
d1 , d2
u1 , u2

Figure 2: HIMAT Open-loop Interconnection System


himatic.

Control Design
Design a H (sub)optimal control law for a LTI system, himatic, with two sensor measurements, two error signals, two actuator inputs, and eight states. The range of is
selected to be between 1.0 and 5.0 with a tolerance, tolgam, on the relative closeness of
the final solution of 0.1.
Initially, we will not make use of the iteration portion of the hinfsyn program. An H
suboptimal control law will be designed and analyzed for different levels to help us gain
an understanding of what the H controller is minimizing. Input the initial information
about the system himatic:
ex5data;
aa = [

-2.2600e-02 -3.6600e+01 -1.8900e+01


0 -1.9000e+00
9.8300e-01
1.2300e-02 -1.1700e+01 -2.6300e+00

-3.2100e+01;
0;
0;

c
MUSYN
Inc. 2009

1.0000e+00

bb = [
0
0;
-4.1400e-01
0;
-7.7800e+01
2.2400e+01;
0
0];
cc = [
0
5.7300e+01
0
0
himat = ss(aa,bb,cc,0);
wdel = tf([50 5000],[1 10000]);
wp = tf([0.5 1.5],[1 0.03]);
wdel = blkdiag(wdel,wdel);
wp = blkdiag(wp,wp);

0
0

0];

0;
5.7300e+01];

systemnames = wp wdel himat;


inputvar = [ z(2) ; d(2); u(2) ];
outputvar = [ wdel; wp ; d + himat ];
input_to_himat = [ u + z ];
input_to_wp = [ d + himat ];
input_to_wdel = [ u ];
sysoutname = himatic;
sysic;
nmeas = 2;
% number of sensor measurements
ncon = 2;
% number of control inputs
gmin = 5;
% gamma value to be tested
gmax = 5;
% gamma value to be tested
tolgam = .1; % tolerance on the gamma stopping value
size(himatic) % SYSTEM interconnection structure}
State-space model with 6 outputs, 6 inputs, and 8 states.
We are setting gmin and gmax equal to one another. This will lead to a single controller
being designed at a level of gmax. Once the controller is synthesized, we want to analyze
the results. Do a frequency response of the closed-loop system and plot its -norm as a
function of frequency.
[k5,g5] = hinfsyn(himatic,nmeas,ncon,...
DISPLAY,on,GMIN,gmin,GMAX,gmax,TOLGAM,tolgam);
Test bounds:
5.0000 < gamma <=
5.0000
gamma
5.000

hamx_eig
2.3e-002

xinf_eig
4.4e-008

Gamma value achieved:

hamy_eig
2.3e-002

5.0000

yinf_eig
0.0e+000

nrho_xy
0.3422

p/f
p

c
MUSYN
Inc. 2009

omega = logspace(-1,4,50);
g5g = frd(g5,omega);
g5gs = fnorm(g5g);
semilogx(g5gs)
Singular value plot of g5 with k5 implemented
4.5

3.5

2.5

1.5

0.5
1
10

10

10

10

10

10

What is the -norm achieved by this controller?


What does the singular value plot look like across frequency?
Is the closed-loop system stable and does it satisfy ||g5|| gfin?
Rerun the above commands for gmin = gmax = 4, 3, 2 and 1.8. Name the closed-loop
systems g4, g3, g2 and g1p8 respectively.
What is the -norm achieved by these controllers?
What does the singular value plot look like across frequency for each controller?
Do the closed-loop systems with controllers synthesized at different levels have
different -norms?
What is the trend in these results?
Now design an H controller using the iteration part of the program. hinfsyn outputs
at each iteration the current value being tested, and eigenvalue information about the
X and Y Hamiltionian matrices and X and Y Riccati solutions. At the end of each
iteration a (p) denoting the tested value past or a (f) denoting a failure is displayed.
Upon finishing, hinfsyn prints out the value achieved.

c
MUSYN
Inc. 2009

[k,g] = hinfsyn(himatic,nmeas,ncon,DISPLAY,on);
Resetting value of Gamma min based on D_11, D_12, D_21 terms
Test bounds:
gamma
5.386
2.943
4.164
3.554
3.248
3.096
3.019
3.057
3.076
3.067

0.5000 <

hamx_eig
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002

gamma

xinf_eig
4.4e-008
4.5e-008
4.5e-008
4.5e-008
4.5e-008
4.5e-008
4.5e-008
4.5e-008
4.5e-008
4.5e-008

<=

5.3857

hamy_eig
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002
2.3e-002

yinf_eig
0.0e+000
0.0e+000
0.0e+000
-3.0e-014
0.0e+000
0.0e+000
0.0e+000
0.0e+000
0.0e+000
0.0e+000

nrho_xy
0.2926
1.1073#
0.5063
0.7181
0.8801
0.9835
1.0425#
1.0124#
0.9978
1.0050#

Gamma value achieved:


3.0764
norm(g,inf)
ans =
3.0764
omega = logspace(-1,4,50);
gg = frd(g,omega);
ggs = fnorm(gg);
semilogx(ggs)
Singular value plot of optimal Hinfinity controller
3.08

3.075

3.07

3.065

3.06

3.055

3.05

3.045

3.04

3.035

3.03
1
10

10

10

10

10

10

p/f
p
f
p
p
p
p
f
f
p
f

c
MUSYN
Inc. 2009

H Loop-shaping and Comparison of Designs


For the given HIMAT model, himat, using the H Loop-shaping control design technique
to synthesis the controller for HIMAT.
1. Implement the HIMAT H Loop-shaping in the open-loop interconnection structure, figure 1, and analyse the nominal closed-loop stability using himatic (figure 2).
2. Set up a robust performance problem based on the interconnection in figure 1.
Calculate the robust performance of the signal based H controller and loop-shaping
based H controller.
3. Use the same interconnection structure as constructed for the robust performance
anlaysis to calculate the worst-case performance for the two controllers.o
4. Remove the weighting functions from the open-loop interconnection in figure 1 to
investigate the nominal time responses of the two controllers.
5. Compare and discuss the results of the two control designs.

You might also like