K. Liu, R. Skelton ...... [Skelton. 1988] and Phase Variable. Coordinates, are also given in TABLE. 2. The fact that ...... System Control;" John Wiley & Son. [9]. [10].
/ /
b
Optimal
Controllers
for Finite Wordlength
o
Implementation
K. Liu, R. Skelton Purdue
University
West Lafayette,
IN 47907
ABSTRACT When
a controller
is implemented
the numerical
errors
system.
exists realizations
effects have
There
of the computation
from computational a systematic
which
way
take account
precision
to the standard the separation
Since, in general,
of reducing
these round-off
These results LQG controller principle
computer,
can drastically
of a given controller
errors.
of the digital
A/D and D/A converters. reduce
in a diNtal
effects. errors
provide
affect
transfer
Optimum
function
yielding
controller
in the controller extension
when infinite precision
9J
the performance
there is no upper
a natural
does not hold.
with A/D and D/A
bound,
conversion,
of the control arbitrarily
large
it is important
designs
are
to
developed
implementation
and in the
to the LQG theory
since they
computation
is used.
But for finite
I.
LQG controllers will
be perfect
(this
However,
real control
round-off
errors
errors
are normally
should
on the control
subjects
designed
is the infinite systems
INTRODUCTION
wordlength
are subject
not be ignored
system
under the assumption assumption
to the effects in the design
and the optimum
that computer
for
state
variable
of finite wordiength of the controller.
controller
design
implemention computation).
computation.
These
The influence
considering
of these
their effects
are the
of this paper.
We consider of digital
the problems
computers.
that arise with fixed-point
This paper
[1989].
Mulhs
revealed
the fact that the influence
the realization suggest
and
Roberts
was motivated
chosen
a special
by the
and Hwang
[1977]
of round-off
errors
for the filter implementation.
coordinate
This is in stark irrelevant
[1976]
(and hence
transformation
contrast
work
and the finite word length
of Kladiman
in the field on digital
ignored)
round-off
approaches
the state space
Williamson
processing
filter performance
To minimize
domain
and
of signal
T prior to filter (or controller)
to frequency
is completely
arithmetic
first
depends
errors
on
these papers
synthesis.
to control,
realization
which
regard
of the controller
as
transfer
function. The idea applied
of applying
to Kalman [1989].
degradation
in the performance
by Sripad
for LQG controIler by a coordinate controllers transformation optimal
from round-off
Kalman [1981]
design.
T.
to indicate
In these papers to reduce a standard
because
Williamson
without
the effects LQG
to insure
round-off
Riccati
equations
of round-off followed
on the control
errors.
LQG gain is not the optimal
92
percentage error.
of the ideal This approach et. al [1983]
are solved,
followed
We shall call
hence,
and
that the resulting
by an "optimal"
gains,
has been
Kladiman
filters, and later by Moroney,
controller
depends
synthesis [1985],
error is less than a certain
the standard
the standard
to controller
of the computer
filter or LQG controller
This transformation
above in quotes,
prior
problems,
in the design of Kalman
transformation
LQGT
design
One may select the wordlength
of the standard
was adapted
transformation
filter and LQG controller
Williamson
behavior
a coordinate
these
coordinate
we put the word
gain for the round-off
error
problem.
account
The
optimum
the round-off
merely
performing
errors
state estimation
Kalman
filter.
results
with a finite
word
transformation
and Williamson
conditions
algorithm
to reduce
the possibility
of overflow.
shall use is the variance off errors
are additive.
quantization
in the presence
the controller
effects. arbitrarily controller described.
work,
solution.
rather
than
after it is designed.
The
to a modified
in the presence
of round-off
worked
with upper
but their
This paper
for the solution
It is shown large
bounds
algorithm
provides
of this problem.
of the paper
is as follows.
of round-off
errors
does
the
not
necessary
We shall call this
that the portion
of the choice
In Section
conditions
are derived of the optimal in Section
bound
controller.
5. Some conclusions
coordinate
problem.
An
LQG
appear in Section
6.
93
roundwhereas
of LQG
the needed
results
of finite
of the
achieving in terms
controller
of the coordinates
by these errors
from
will range
the lower of chosing The
is then presented
and the LQGFw
of
wordlength
realization
simultaneously.
algorithm
The standard
we
1985].
variation
is discussed
The method
on state quantization,
on upperbounds
the
scaled
We assume
2, the problem
The coordinate
problem
1977].
3 summarizes
with
are properly
available.
The importance
results
the realization
for the optimization LQGv-w
In Section
of coordinates).
and
[-Hwang
of the LQG cost contributed
4, the optimization matrices
criteria
errors [Williamson
3. Section
and our new
lower
controller
by the literature
is formulated.
in Section
1989],
scaling
12-norm scaling
leads to multiplicative
to an achievable
(variation
There are many
This tends to be supported
and Williamson
parameter
compared
earlier
into
This leads
This paper
the states of the LQGFw
procedure,
will be discussed
controller
designs
oriented
of coefficients
The organization
[Kadiman
over
design
takes
LQGFw.
With a fixed point implementation,
design
[1989].
directly
implementation,
[1985].
controller
for an optimal
design
which
length
by Williamson
LQG
improvement
controller
T on the LQG controller
was solved
of optimum
showed
and a controller
controller
associated
by Kadiman
the necessary
conditions
the
problem
The problem
error was studied
provide
is to design
a coordinate
optimal
and numerical
solution
from of the
bound both
is the
necessary for the
controller
are
II. Round-Off
In this section, present.
we formulate
The formulation
and the ideas
be controlled.
the LQG controller
procedure
of Williamson
study of round-off
Error and LQG Controller
error,
follows
Design
design problem
the original
ideas
[1985],
Kadiman
and Williamson
the discrete
controller
is designed
We then introduce
a model
Problem
when round-off
of Mullis
[1976],
[1989].
effects
Hwang
model
are
[1977]
Let us assume,
from a discrete
for finite wordlength
errors
for the
of the plant
into the discrete
to
design
problem. Considering
the following
discrete-time
model of a time-invariant
xp (k + 1) = Apxp(k)
measurement white
state
np-vector,
nz-vector,
Gaussian
noises
The controller
(1)
= C_xp (k)
yp (k)
Xp is the
+ Dpwp(k)
= Mp Xp(k) + Vp(k)
zp(k)
where
+ Bpu(k)
plant:
u, yp and Zp are
vp and Wp are assumed with covariance
matrices
the
control
to be mutually
nu-vector, independent,
output
ny-vector,
zero mean,
discrete
Vp and Wp, respectively.
that one might desire to implement
is described
by following
equations:
(2)
xc(k + 1) = Acxc(k) + Bcz_(k) u(k) Ccxc(k) + Dczp(k)
where
Xc is the controller
described
in the plant model.
measurement quantization is described
state
variable process,
no-vector,
In a finite
z.p will computation
u and zp are the control
wordlength
be quantized
digital computer,
at each
(1) and (2) cannot
by
94
time
and measurement the controller
of computation.
be accomplished.
Instead
vectors
state x c and
Considering
the
the computation
(3a)
zp(k) = Mpxp(k) + vp(k) xp(k + l) = Apxp(k) + BpQ[u(k)] yp(k) = Cpxp(k)
xc(k + 1) = AcQ[xc(k)] u(k) = CcQ[xc(k)]
where
Q[-] stands
for the quantization
error, we can model the quantization
Q[u(k)]
where
assumption
respect
to coefficient numerical
controller
structures
= u(k) + eu(k)
errors.
from D/A conversion,
There
to coefficient
be modeled
covariance
matrix Ex,
errors
are many
ex (k) is the error
All such
resulting
We do not claim in this paper,
One can only evaluate in filter theory,
evidence
points
to state quantization
from
that this since one
designs
with
and we shall add
to a conclusion
tend to also be good
that with
quantization.
_ is the worctlength eu(k)
directly.
(4b) (4c)
assumption
such evaluations
with respect
1977] that, under sufficient
as a zero
mean,
white
Ex = qI,
error
this common
in this paper.
that are good
computer
from A/D conversion.
but we invoke
evaluation
can
where
(4a)
A/D
to coefficient
of the round-off
D/A
= zp(k) + ez(k)
justified,
property
by:
Q[zp(k)]
It was shown [Sripad ex(k)
an additive
control
with respect
own
respect
process
Assuming
= xc(k) + ex (k)
is always
optimize
our
process.
error resulting
(3b)
+ Dc Q[zp(k)]
and ez(k) is the error resulting
cannot
+ Bc Q[zp(k)]
Q[xc(k)]
eu is the round-off
quantization
+ Dpwp(k)
of the control
and the A/D conversion
error
excitation
noise
independent
q _ @2-2 2-2_
computer. ez(k)
conditions, wp(k)
and
vp(k),
,
Similarly,
error with
(5a)
we assume
to be zero mean,
95-
of
the round-off
mutually
the D/A conversion independent
white
noise and also independent
where
13uand 13z are the
obtain
a closed-loop
of wp(k),
vp(k) and ex(k) with covariance
model
Eu and Ez,
Eu = %1,
qu 6__.12_2-21_
(5b)
Ez=qzI,
qz '_ 1 = -_- 2 -213_
(5c)
wordlengths
system
matrices
of D/A
including
and A/D
Substitute
converters.
finite wordlength
(4) into (3) to
effects,
zp(k) = Mpxp(k) + vp(k) xp(k + 1) = Apxp(k) + Bpu(k) + Dpwp(k) yp(k)= Cpxp(k)
(6a)
+ Bpeu(k)
xc(k+ I)= Acxc(k) + Bczp(k)+ Acex(k) + Bcez(k) u(k)= Ccxc(k)+ Dczp(k) + Ccex(k)+ Dcez(k)
(6b)
We seek thecontroller tominimize thefollowingcostfunction
J = lira
E {yp(k)Qpyp(k)
+ u*(k)Ru(k)}
(7)
k ---_ **
where
u and yp are again control After
combining
(6a)
and output vectors,
and
(6b),
and
using
and Qp and R are the weighting the
following
notation
for the
matrices:
[x=(k)J ; y(k)
D=
the closed-loop
;G=
system
= Lu(k) J
Bc
is compactly
Ac
;I°=
described
;II=
by
96
;I2=
;
matrices. vectors
and
x(k+ 1)= [A + BGM]x(k) + Dwp(k)+ BOIl vp(k)+ BGI2ex(k) + BOIl ez(k)+ BI1eu(k) y(k)= [C + IoGM]x(k) + IoGI1vp(k)+ IoGI2ex(k)+ IoGI1ez(k) (9) andthecostfunction(7) maybewritten J= lim E
{y* (k)Qy(k)
}.
(10)
k --._*_
Now,
substitute
(9)
into
(10),
since
eu(k),
ex(k),
ez(k),
wp(k),
and
are
vp(k)
mutually
independent,
J = tr{X[C
+ IoGM]*Q[C
+ loOM]}
+ tr{Ex(IoGI2)*QIoGI2)}
where X is the state covariance
satisfying:
X = [A + BGM]X[A
+ DWpD"
+ BGM]"
+ tr{Ez(IoGI1
(lla)
)" Q(IoGI1 )}
+ (BGI1)Vp(BGI1)*
+ (BGI2)Ex(BGI2)"
We can decomposite
+ tr{Vp(IoGI1)'Q(IoGI1)}
+ (BGI1)Ez('BGI1)*
+ BI1F_,u(BI1)*
(llb)
Jill e,qn. (1 la) into two terms:
J = Jw_ + Je
(12a)
where
Jw-¢ _ tr{ Xl [C + IoGM]* Q[C + loOM] } + tr{ (Vp + Ez)(IoOI1 )* Q(IoOI1 ) } X 1 = [A + BGM]X_ [A + BGM]*
+ DWpD*
+ (BGI1)(Vp
+ Ez)(BGI1)*
(12b)
+ BI1Eu(BI
1)*
(12c)
and
Je _=tr{Xe[C
+ IoOM]*Q[C
Xe = [A + BGM]Xe[A
where
X = X 1 + Xe.
J_
%(k),
ez(k), wp(k) and vp(k).
+IoGM]
+ BGM]*
is the portion
} + tr{Ex (IoGI2)'Q(IoGI2)
}
+ ('BGI2)ExfBGI2)*
of the performance
Je is the portion contributed
97
index
(12d) (12e)
contributed
solely by round-off
by disturbances error ex(k).
To prevent
the overflow
the state variables.
in controller
X1 (2, 2) is the (2.2)
stands for the ith diagonal variables
have
disturbance
variance
subblock
element equal
and measurement
Therefore,
computation,
We use the 12-norm scaling procedure
[X1(2,2)]ii
where
state variable
matrix
i=l,
noise.
""
Equation
(the
the closed-loop
as:
controller
system
subblock),
and [']ii
that the controller
is excited
only
state
by outside
constraint.
is
min J = rain (Jwv + Je) , G G
subject
scale
(13)
(13) requires
We call (13) the scaling
problem
is written
,nc
of X 1 matrix
of the matrix.
to s when
the optimization
=s
which
we must properly
to (12-13).
9B
(ld)
HI.
Contribution
In this section, portion
of the LQG
function large),
of Round-Off
we discuss cost
is coordinate
The lower 1989].
bound
result
G is some given matrix
Given
lower
bound,
any n x n matrix
by eqn. (12d)
errors.
above,
is discussed
which
This portion
(that
can be achieved et_ al. 1983]
Index
is the
of the
cost
is, it can
be arbitm_rily
in an optimal
coordinate.
and [Kadiman in this section,
and Williamson where
we assume
G later).
three key lemmas, 1976, Hwang
M, there
which
coordinate
(we shall optimize
and Roberts
from
by [Moroney
of this optimal
and defined
by round-off
It is unbounded
was obtained
We will first present 1. [Mullis
contributed
dependent.
The consn'uction
Lemma
the Je term in (12a)
function
but it has an achievable
Error to the LQG Performance
which form the basis for the results
of this section.
1977].
exist a (non-unique)
unitary
matrix
U such that (UMU*)jj
=
S
for all j, if and only if tr(M) = sn []
Lemma
2. [well known]
For any two positive
definite
matrices
P and Q, let Li ['] denote
the i th eigenvalue
of matrix
['].
Then,
a)
)_i[QP] >0
for alli
b)
The Li[QP] are invariant
under
the transformation
P = TPT* and 0 = T-*Q T-1 where
T is
nonsingular. []
Lemma
3.
Let a scalar J be defined
by
99
J Atr{rr'pl where
the np x np nonsingular
matrix T is constrained
(TlT-*)ii
and P is a positive
definite
(15a)
matrix.
= s
by
for all i
Then over the set of all nonsingular
(15b)
matrices
T constrained
by (15b),
a)
J is not bounded
b)
J is bounded
from
from above.
below
(J > _ by l r'_J_="--:--[tr('qP)] 2 Snp
(16a)
where
P= _- _-
and "_
is symmetric.
c) J_in (16a) is achievable
by the matrix
T."
T = T A_Wti-ltVt
where
(16b)
Ut, Vt are unitary,
I-It diagonal,
(17a)
satisfying
UtI_It2U_
[VtFlt2Vt]ii
= Snp_-
= s for all i .
(17b)
(17c)
[]
Statementsb) and c) are minor modificationsof the resultsobtainedby [Mullis and Roberts1976]and[Hwang,1977].The proof of a) appearsin AppendixA. An algorithmfor solving(17b),(17c)is givenin AppendixB.
The contributionof finite wordiengtherrorin the costfunctionis describedby equations (12d)and(12e). ThisJetermcanalsobewrittenas: Je= tr{Ke(BGI2)Ex(BGI2)*} + tr{Ex(IoGI2)*Q(IoGI2)} Ke = [A + BGM]*Ke[A
+ BGM] + [C + IoGM]*Q[C
(18a)
+ IoGM]
(18b)
.
Since Ex = qI, we then have:
(19)
Je = q tr{ (BGI2)* Ke (BGI2) + (IoGI2)* Q(IoGI2 ) } •
We can easily
check
that the (2, 2)th subblock
matrix
of Ke (the controller
subblock
Ke(2,
2))
satisfies:
I_(2,
Substituting
2) = (BGI2)*Ke(BGI;)+
(20) into (19) reduces
(IoGI2)*Q(IoGI2)
the minimization
of Je reduces
to (18b), (13) and (12c).
2)]
.
to the problem:
minJe,
subject
Je=qtr{Ke(
From the singular
2,2)1
_h
*
Zx Ux Ke (2, 2)UxZx
Zx, Zk are diagonal
(21)
value decompositions
X 1(2, 2) = UxZxUx
then Ux, Uk are unitary,
(20)
(19) to
J_ = qtr[I_(2,
Hence,
.
aA
and
I01
= U_Z, kUk
(22a) (22b)
Zk. _=diag {... _[Ke(2,
Suppose
we begin our study with the closed-loop
after this coordinate
X l(2,2)=(Uxx --
Ke(2,
If we take equations,
one more
as suggested
*
½
* -1-
tit
1
*
xUk)
2) = (UxX_Uk)
controller
(after we substitute
(22c)
transformation
T as:
, _ , UxZx Uk
transformation
--
2)] ... } .
coordinate
T=
Then,
2)X1(2,
coordinate
*
by Kadiman
Xl(2,2)(UxX
I_(2,
(23)
*
½
xUk
-*
and Williamson
)
-*
[ 1989]:
=I
(24)
* ½ Uk) * = Y--'k• 2)(UxZx
transformation
Tc, the index
(25)
Je and its constraint
(24) and (25) into (13) and (21)), become
Je = qtr[TeT_Zk] [T_lT_*]ii=s,
Since,
from
calculations equation
i=l,
Lemma (18b)
"-"
2, _
,nc.
and (12c)
1. The round-off
constrained unbounded
and concentrate
error
by the scaling from above
(26b)
in (22c) is coordinate
(26), we have following
Theorem
bounded
(26a)
on Tc in (26).
term Je in the LQG eqn. (12c),
the
Then,
performance
by applying
index
(13), is controller
realization
from below by the following
Lemma
coordinate
j- - _ q
by the following
T
(12d)
coordinate varies
and
(12e), and
dependent.
arbitrarily.
Ux, Uk, Ut, Vt are
unitary
It is It
is
tr Z t
(27)
sn c
controller
½
= UxZ x
coordinate
transformation:
*
(28a)
UkUtIitVt
--'C
where
3 on
lower bound:
--e
The lower bound is achieved
we may i_mnore the Ke and X 1
theorem.
constraint when
independent,
matrices,
Zx,
102
I-It are
diagonal
matrices,
subject
to the
constraints.
X 1 (2,
2_UxKe(2
(28b)
2) = Ux2xUx
(28c)
' 2)UxZx " _,_= U_Y--kUk
snc 2k U_FI72U_
-
2
[VtI"lt
Vt
]ii
=
(28d)
tr2k
i = 1, • • • , nc
s,
(28e)
[]
To find the optimal obtain
Ut, Flu Vt. The equations
P is the diagonal needed
coordinate
matrix
transformation
(28d),
T --C
in (28a),
(28e) are, however,
Zk. An algorithm
is given
special
in Appendix
we must
solve
cases
of (17b),
B to compute
(28d), (17c),
(28e)
where
the Ut, I-It, Vt
for (28a). The
conclusion
transformation
of this section
given by (28a).
is that
the problem
min Je is solved Tc
to
by the
coordinate
IV.
LQG Controller
As discussed can
in Section
be decomposed
measurement
into
noise,
not influenced
two
by the coordinate An
requirement
of
optimization
problem
optimal the
without
round-off
terms.
One
coordinate
term
4. Suppose
errors.
design
influence
errors.
the second
prevent
comparing
of disturbance
Although
term is critically
is given
to
Errors
the LQG performance
the
by round-off
variables
now for controller
round-off
contains
transformation
state
of Round-Off
error is present,
of the controller,
controller
Let us first present Lemma
17, when
in the Presence
the other term is conn'ibuted
coordinate.
problem
Design
by
(28a).
overflow,
to the original
In this section, we will discuss
we
and
the first term is dependent
With
the
have
optimal
the controller
index
on the scaling
a different
control
design
design.
a useful result.
Jkx _=_ _ki[Kii,
i)X(j, j)] where K(i, i) and X(j, j) are the (i, i)th subblock
l=1
of K and (j, j)th subblock
of X respectively.
VkJkx
Define
A _ j --"_'_" kx ,
then:
a) VkJ_(p,q)
= 0
when p _ i or q _ i [E -1 (i, j)]]th-row[E(i,
(29a)
VkJkx(P'q)
b)
where
"_[K(i,
q)=0
VxJkx(P,
1 l_ K(i, i)[E -1 (i, j)] _th-row[E(i, j)] q) = _- _ _/_.t[-K(i, i)X(j, j)]
,
of matrix
when p = i and q = i
when p¢jorqcj
q) and VxJkx(p,
matrix
j)
i)X(j, j)]
VxJ_(p,
_TkJkx(P
eigenvector
= 2t_ -
j)]_--colX(j,
(29b)
(29c)
q) are the (p, q)th subblock
l*th---¢o]
of
when
VkJkx
p = j and q = j
(29d)
and VxJkx, E(i, j) is the
K(i, i)X(j, j)
104
[]
The proof of the lemma The account,
LQG
controller
are described
However,
the
coordinates optimal
is given in Appendix
scaling
design
coordinate
we can therefore
problem,
by the equations constraint
of the controUer,
A. when
(12-14).
(13)
can
so the problem
transformation
finite This
be
wordlength is denoted
always
since Jw_ is constant
G,T,
G
in terms of the variation
properly Finding
taking
into
controller.
choosing
the
G and finding
On the strength
of Section
Assume
J _ min Je is given "_
problem
(Jwv + Je)]
of Tc, we have
G
by (27), from Theorem
the equivalent
LQGzw
design
becomes
subject
,
(30a)
to (12c) and (18b) where
Jw_ = trX1 (C + IoGM)*Q(C =
1. Hence,
Tc
G
J
(30)
T,
min[Jw_ + J]
---e
3,
T,
min J = min [Jw,, + rnin Je] G,T,
its
as
rain J = rnin (Jwv + Je) = rain[rain G,T,
by
breaks up into two parts:
problem
are
as the LQGFw
satisfied
Tc to satisfy (12), (13) and (14).
write the optimization
effects
q
(tr
_k)
+ IoGM)
+ tr(Vp + Ez)(IoGI1)*Qfl0GI1)
(30b) (30c)
2
sn¢
where
Zk is defined
algorithm
in Appendix
The following Theorem Necessary
theorem
by (22c),
and the
transformation
B, and may be computed
Tc which
yields
only after the optimal
states the necessary, conditions
J
is given
G is obtained
of the optimization
problem
by
the
from (30).
(30).
2: conditions
for G to be the solution
of the optimal
loft
controller
design problem
(30) are."
[A + BGM]X1
[A + BGM]*
[A + BGM]* I_[A
+ DWpD*
+ BGM]
+ (BGI1)(Vp
+ [C + IoGM]*Q[C
+ IoGM]
[A + BGM]" K2[A + BGM] + [C + IoGM]*Q[C [A + BGM]K3
[A + BGM]*
(I_QIo + B*K2B)G(MX1
where
- X1 = 0 (31a) (31b)
- Ke = 0
(31c) (31d)
- K3 + Vk = 0
+ KeAK3)M*
Vx has 4 subblocks
+ BI1Eu(BI1)"
+ IoGM] - K2 + Vx = 0
M* + I1 (Vp + Ez)I_)
+ B* (K2AX1
+ Ez)(BGI1)*
+ (I_QIo + B*KeB)GMK3M*
+ (31e)
= 0
as
Vx(i, j)=0
i_e2
or j,2
Vx (2, 2) = q--fl-tr 2k
2, 2)[E-11 o rZl ol }
Snc
and V k also has 4 subblocks
as
Vk(i, j)=0
i.2
q
Vk(2, 2)=
or j*2
I-E-1 ] _ow I-E]_colXl (2, 2) tr £k _:g-.
sn---7-
where
E is the matrix
of eigenvectors
1 J
l'=1
of the matrix Ke(2,2)
X1 (2,2). []
The proof of theorem
2 is given in Appendix
Remark
1: The only terms
denoted
by Vx, Vk. Hence
eqs. (31) reduce reduces Riccati
setting
to the standard
to the Kalman equation.
in (31) which
are affected
by q are the two terms
in (31c)
and (31d)
13= *_ gives q = 0, Vk = 0, Vx = 0, K3 = 0, K2 = K_. Hence,
LQG design
filter Riccati
A.
equation,
by setting [3= _.
In this case, the 11 block of (31a)
and the 22 block ] 0
of (31c) reduces
to the control
Remark
2: We shall denote
that the LQGFw
controller
Now, we have following
The LQGFw
the controller requires
LQGFw
an additional controller
(31) as the LQ_w
step; the computation
controUer
to indicate
of T from Appendix me
B.
design algorithm:
Algorithm
Step 1:
Solve G from equations
Step 2:
Compute
(31a)-(31e).
T c = UxZx UkUtI-ltVt
using the G obtained
Step 3:
satisfying
This gives the LQG_
by solving
controller.
Ux,_x,gk,Ut,IIt,V
t
from
(28b)-(28e),
in Step 1.
G =
is the optimal
LQGvw
controller
for implementation.
[]
Remark:
A natural
algorithm
LQGFw
controller
(i)
Solve (31a)-(31e)
(ii)
On the next
to suggest in Step 1 is as follows.
Suppose
one desires
to design
a
for 10 bit arithmetic.
for
iteration
_i =
set
_:,o(hence,
_i
=
the standard
32 (or whatever
LQG controller).
gives
a reasonably
small
number
for
Vx, Vk.
(iii)
Iterate
by indexing
an "answer" guaranteed This is a "natural"
_i. Change
in 32-10
= 22 iterations
to be sufficient homotopy
_i by no more than one bit on each iteration. (but this manner
to yield the optimal
method,
since [3 is a natural
/07
of choosing
This gives
step sizes
answer). choice
for a homotopy
parameter.
in not
V.
We consider
an Euler
Bernoulli
modal
frequencies
and 2 outputs.
The
discrete
is represented
These
model matrices
cost function
are given is given
Computation
beam modeled appear
by the
of the control
A/D conversion
errors
and
measurement
controller
and the LQGFw
we
1. In discrete
C for a uniform
sample
computer
ignore
controller
R = 0.01I
is assumed system
controller
design,
in equation
time At = 0.018
sec.
the (1).
The LQG
these
errors
are computed
.
to be 4 bits.
simply
Frequency
modify
in the
Since
the effects
the effects
of system
example.
Damping
Factor
1
3.4987e+00
9.9994e-03
Mode
2
1.3995e+01
2.1301e-02
Mode
3
3.1488e+01
4.5600e-02
Mode 4
5.5979e+01
8.0400e-02
Mode 5
8.7468e+01
1.2530e-01
1. Frequencies Euler-Bernoulli
Both
for the system.
Mode
TABLE
with 2 inputs
(7) with
on the control
noise,
modes
{Ap,Bp,Cp,Dp,Mp,Wp,Vp}
Qp = 0.991
The wordlength
by its first 5 bending
in TABLE
matrices
in Appendix
by equation
Examples
and Damping
Factors
Beam Example
of the
the
of D/A and disturbance
standard
LQG
The standardLQG controllerof coursewasdesignedwithoutconsiderationof round-off errors(_ = _) andis labeledcontroller"LQG" in the TABLES. Controllersdenoted"LQGTi" i = 1, • ••, 4 arethesameastheLQG, butfor a coordinatetransformation on thecontrollerafter G is computed.The matrices{Ac,Bc,Cc,Dc in Appendix
C. In different
Je in the closed-loop T 1 (controller coordinate wore[length
LQGT1) design of the
computational Coordinates
errors
synthesis
the cost
control
Je is about LQG).
by
Je in two commonly 1988]
Variable
and Phase
Coordinates
[Williamson
in TABLE
unbounded
for some coordinates. or discussed
further.
smaller
improvement
about
5 bits
used coordinates,
Variable
The
2 serves
is
than
the cost
equivalent
increasing
only
to demonstrate
of
Hessenberg 2. The
with other findings
the cost
"1"4was rather
the
effect
in TABLE
of the controller that
The
Observable
is consistent
coordinate
in the original
to
are also given
high costs
of coordinate
In the optimal
Normalized
Coordinates,
are shown contribution
1 (5 = _-- log2500).
extreme
The choice
controller
the finite wordlength
LQG controller.
are bad for computation
1990].
(LQGT4)
with the LQGT1
2 shows
500 times
This
computer
coordinate
be described
Ti, TABLE
cost, using the standard
(controller
[Skelton
fact that Phase filter
system
coordinates
] associated
in
in a particular Je can
arbitrary
become
and will not
Controller ControllerCoordinates
CostJ¢
LQGT1
Optimal
LQGT2
NormalizedObs.Hess. 2.692x 102
LQG
9.793
PlantCoordinates
4.862× 103
LQGT3
PhaseVariable
9.486x 103
LQGT4
Coordinate"X"
1.472x 108
TABLE2. StandardLQGControllerin DifferentCoordinates The LQGFwcontrollerwasdesignedby the LQGFwalgorithmgiven in Section4. The controllermatrices{Ac,Bc,Cc,Dc} of this controlleralsoappearin AppendixC. TABLE 3 showsthe computedcostsof the standardLQG controller,the transformedLQG controller (LQGT1),and the LQGFwcontroller(The "LQGFwwith coefficienterror" will be discussed later). The costsfor three different applicable
disturbances
wordlength
for J,
Jy,
groups
and Ju include
plant
disturbance
for Je,
error e. The applicable
are only wp and vp (no finite wordlength decompositions; Jy + Ju.
and
Jwvy
Jy
effects).
are computed
disturbance Jey,
Hence,
Jeu
J = Jwv + Je.
Jwvu
(the contribution is the control
noise
case.
these sums apply
of vp and wp in J), Ju = Jwvu
The
v, and finite
is only e, and for Jw,¢,
term of J_¢ and
jlO
in each
w, sensor
is the output term of J (the total cost), Ju is the control
is the output term of J_
Je = Jey + Jcu,
of excitations
Jwvy,
Jwvu
to the various
cost
term in J, hence where + Jeu.
Jy =
Jwvy
J = + Jey
As we can
Disturbances
LQG
LQGT1
LQGFw
LQGFw
Controller
Controller
Controller
with coeff,
4.8827e+03
3.0589e+01
2.1207e+01
2.4695e+01
Jy
2.8053e+03
2.3458e+01
2.0798e+01
2.4232e+01
Ju
2.0774e+03
7.1303e+00
4.0941e-01
4.631e-01
Je
4.8621e+03
9.9302e+00
2.0067e-01
1.4071e-01
Jey
2.7850e+03
3.1790e+00
1.3841e-01
1.0275e-01
J_u
2.0771e+03
6.7512e+00
6.2267e-02
3.7961e-02
J,,,,,
2.0659e+01
2.0659e+01
2.1006e+01
2.4554e+01
J,,,,,y
2.0279e+01
2.0279e+01
2.0659e+01
2.0279e+01
Jwvu
3.7912e-01
3.7912e-01
3.4715e-01
4.2514e-01
Costs
Applied
All v, w,
errors
and e
e only
v and w only
TABLE
3. Evaluation
of LQG Controllers
Coordinate
see in the TABLE (LQGT1), 30.589). cost
the Je portion
computer arithmetic
when
compared
In the latter by about
the
standard
to the case,
controller LQGT1
LQG
using
by a reduction
design
this is equivalent
11 bits.
I/)
algorithm, 24,110
to increasing
is in its optimal
we reduce times the
the Je portion
compared
wordlength
this improvement
RMS = _
vs.
coordinate compared
to
of the
to the LQG of the
will give the same performance
Furthermore effort
Controller
controller
and
LQGFw
in control
Optimal
33% of the total cost (9.9302
controller
7 bits, That is, controller
that LQG gives
is accompanied
and of the LQGFw
of the cost is still about
By using the new LQGFw
50 times,
controller.
3, even
in Plant Coordinates,
in output RMS = _.
control
using 4 bit performance To
conclude
this point,
we see that if both
performance
is an order
of magnitude
performance
can
the
mean
difference
controllers
use 4 bits,
('_"6.798
vs. _).
between
feasibility
the difference This
and
in RMS
output
kind of improvement
infeasibility
of some
in
control
missions. With the new controller, as opposed
to 33% for LQG.
the closed-loop suppose
the round-off
system
the LQG_v
are the conditions
Now let us discuss
was only excited
controller
controller
LQGFw
controller
compromise
is a little higher
TABLE
3, that the quantifies
vp and disturbance
than that of standard
and the control
performance
be the total cost if
allows
robustness
that are optimized
These
standard
(under
These
in the evaluation. The output
indicate
that the
LQG controller.
to computational
by the theory
bits.
LQG controller.
term a little lower.
than the designed
wp. That is,
using infinite
since there are no disturbances
is a little more conservative
in nominal
noise
would
for 4 bits, but evaluated
LQG design,
term of the cost is also a little higher
the cost Jw,,, which
by measurement
was designed
of the standard
Jw_ of the LQGFw
portion J_ of the cost is only 0.85% of the total cost
errors.
the given
This
Note
conditions
in are
shaded. In the design by a gradient as the
the
method.
initial
convergence the
process
output
iterative
design
played
input
for
starting
the
algorithm,
role in reducing
as shown
in Fig. 2. problem.
but note from Figs.
(31a) to (31e) were solved
in its optimal iterative
plotting
Ju performances,
a crucial
in the optimization computations,
the equations
LQG controller
for the LQGFw
Jy and
of magnitude)
formulated
The standard
controller
transformation orders
of the LQG_-w controller,
versus
coordinate
process.
Figs.
iteration. errors
This was expected The LQG_-w controller
The
1-3
was used
illustrate
optimal
(reducing
because
the
cost J_, coordinate
the error by 3-4
the transformation
was obtained
1-3 that after 120 iterations
]12
(LQGT1)
the total cost J, the wordlength
the round-off
with little loss.
iteratively
after
was
about
one might have
300
stopped
Coefficient
Errors
In the introduction argued
that
performs errors
even
we promised
though
coefficients.
TABLEs
loop pole locations as marked
arithmatic,
poles
5
transformation
the
before
compared
transformation coefficients
are improved
Finally, quantization
consider
to 4 bits).
all modes is multiplied prior
discussion.
demonstrating
The improved
plant and controller
LQG
closed
only
4 bits.
The
coefficient
controller
4 shows
precision).
in
the closed
The using
system
is
only 4 bit
the unit circle.
by
its
The poles is still
the LQG_v system errors,
errors"
performance,
that all controllers
are implemented
state computation.
with coefficient
coefficient
Hence
the
computer.
loop system
Fig. 6 shows
it
in the controller
Figure
infinite
This is the LQGT1 controller.
optimal (o's)
are in improved
unstable.
The
coordinate
controller
when
controller
is stable, even
confirming
though
for
the controller
The performance
in TABLE
coordinate
3 is about
this has
degradation
in
15% (compared
to
3).
errors
in
both
the
These results
are summarized
by parameter
p. Hence
range
destabilize.
coefficients
in the
in controller
in TABLE
(note
We
quantization
in the state degrades
(using
using a 4 bit control
to controller
"LQGFw
precision
by the o's in Fig. 4, are outside
using
only for errors
we
the controller
but not enough.
robustness
performance
LQG regulator
for state
errors.
this we introduced
of infinite
errors
errors can easily
4, but the
implemented
To show
instead
of coefficient
only
of e is just a disturbance
improvement
to Fig.
J, listed in the column nominal
When
synthesis.
helped
been optimized
the standard
is unstable
shows
as well.
Quantization
Coefficient
as indicated
LQG controller
Fig.
example
using
of the effects
is optimized
4 bit precision
since the effect
by the x's.
some
locations
controller
The key issue here is this.
1 and 2 are stable).
evaluation
quantization
by using
but does not destabilize,
standard
LQGFw
well with coefficient
in the controller
stable
the
some
for
robustness
stability over
plant
and
in TABLE
p=l corresponds
using standard
the LQGFw
controller 4, where
1J3
the modal
to the nominal controller
LQG controllers
coefficients.
coefficients
(due
to
damping
in
plant in all of the
is .729
in the presence
< p < 1.23, of errors
in
Damping
Error Factor
p
LQO
LQGT1
LQGFw
Controller
Controller
Controller
1.5242e+00
unstable
unstable
unstable
1.3717e+00
unstable
unstable
unstable
1.2346e+00
unstable
unstable
STABLE
1.1111 e+00
unstable
unstable
STABLE
1.0000e+00
unstable
9.0000e-01
unstable
unstable
STABLE
8.1000e-01
unstable
unstable
STABLE
7.2900e-01
unstable
unstable
STABLE
6.5610e-01
unstable
unstable
unstable
5.9049e-01
unstable
unstable
unstable
TABLE
4. Robustness
(Fig 4)
Controllers
(4-Bit Wordlength
unstable
with respect Controllers)
(Fig 5)
STABLE
to modal damping
(Fig 6)
VI. Conclusion This papersolvesthe problemof designingan LQG controller to be optimal in the presenceof finite word.lengtheffects(modeledas white noisesourceswhosevariancesare a functionof computerwordlength).Thisnewcontroller,denotedLQG_¢, hastwo computational steps.First the gains are optimized,and then a specialcoordinatetransformationmust be applied to the controller. This transformationdependson the controller gains, so the transformation cannotbeperformeda priori.
(Hence,
LQGvw
to the standard
controller
word.length It was
exists
both
a closed
algorithm achieved
theoretically
influences
an optimal
obtained
requires
reduces
Acknowledgement:
synthesis, and
the effects
form solution significant
by example
in which
for the LQGvw computation.
We gratefully
importance acknowledge
of
that
the
errors
problem,
theorem.)
controller extension
choice
The new an infinite
of the LQG theory. coordinates
system
computations.
design
when
of controller
on the control
to do these
Hence,
of extra computational
The
LQG
so this is a natural
of computational
set of coordinates
at the expense
Williamson.
algorithm
is used for the controller
shown
significantly
design
there is no separation
and that there
Since
we have
of the LQG_-w controller
the improvement
of the new
not
by this
controller
is
effort in design.
this many
this work by NASA grant NAG 1-857, Technical
problem
was
pointed
helpful discussions Monitor
out
to
us by
Darrell
with him, and the support
E.S. Armstrong.
of
Appendix
1.
a)
Proof of Lemma
Using
A
3
the singular
value decomposition
of T = UtFltVt,
then the constraint
equation
(15b)
becomes
(Wtl-lt2V;)ii
from Lemma
1, above equation
= s
is equivalent
for
(32)
all i
to
tr(Ylt 2) = Snp .
Now, let us study the cost '},of (15a).
Using
tr(AA') >
(33)
the inequality
[tr(AB')]2 tr(BB*)
we have a lower
bound on 3'
_= {u, nt ut P} = =(fit, u; _/b-)(ntu; _-)" } 2
*
m
k tr {(Ut [_._]_1 )(Ut [.__]_1 ), }
Now, to prove that 7 is unbounded
tr{p_l }
(34)
from above, we prove that for any large scalar m > 0, we
have y('I') -> m for some '_. Let us choose
a 'r having the following
Irlt = diag (lrli)
such that -
fil =fi2= "'" = nr -2= and
/16
1
1=it:
mtrCP -1 ) ,
I'In- 1 =
lrlr_ = _m
tr(F-I)
%/2mstr(P -1 ) - 1
where
m is so chosen
that 1 m>
2str(P -1 )
Then
2mtr(P -1) - 1 + 1 mtr(P -1 ) mtr(P -1 )
Hence
the chosen
_" satisfies
the constraint
-- Snp.
(33). Now, we have:
nP
_
(End) 2 (tr{M t1) 2
T>
we then conclude
tr{p-1}
the proof
(Mrb)2
-m tr{P -1)
a). The proof of b) and c) follows
of part
bound and the matrix T are found
i=l
---> tr{P -1}
by using following
next.
(35)
holds above when Q*Q = )v2I.
Let us assume are unitary
matrices.
T = UtlitVt, Assume
P
=
UpIIpU;,
where
lit and lip are diagonal,
for the R and Q matrices
Q*Q
(36)
* --IA*- --2* " _IA = U t UpIIp UpUtll t u I Upllp
-*UpU
t
(37)
,
then
(Q*Q)-I
we have:
- *-
--
= tot Upll_"
Ut, Vt, Up
in (35),
R = U;Upli U;U
Hence,
lower
inequality:
(trR) 2 < tr(QRQ* )tr(Q-* RQ -1 )
the equality
The
14-
*-
---2
UpUtllt
//7
"*
" ---1/4"
Ut Opllp
*"
UpU t
.
tr(QRQ*)
= tr(RQ*Q)
* --- tr[UpXlpUpUtl']
tr(Q-*RQ
UpI-[p
* UpUt)(W
2 * tU t] =
tr[PTY*]
= tr[(Ut
*
½
-t) = tr[R(Q* Q)-a] = tr[(Ut *
= tr[-UpUtrlt
From equation
2
*
ty(R)
equalities
¼
* UpUt)
]
* -IA * t Up_"_p UpUtl-]
-2 * -_,4 * t U t UpIIp UpUt)
]
* l
Ut Up] = tr[rlt z]
(33), and the above equation
= tr(g
2 * t U t Uplip
= T
a,6 * UpUt)(U
Upl"lp
tr(Q-*RQ
Now,
* ¼ * t UpIXp UpWtIl
* ½ * t UpIlp UpUt)
back into inequality
we have the following:
-1 ) = tr[Ht 2] = Snp
= tr(I'[_)
(35).
1A * Up)
-- tr(Upllp
We then have:
-- trNlV-.
[tr('_-)]
Substitute
the
2 < Snp3', that is
[tr(',,_)]_
y>
above
(38)
Snp D*
Now, suppose
the matrix
T
= utritV
t
yields the equality
in (38).
Since
the equality
in (35)
holds when Q*Q = )_2I, then we have: *
2
-1A *---U t UpX'ip UpUtl-I
*
__ t U t Uplip
1A * UpU
t
=_.2I
that is
--2-.tUt
Ut/-I
=..
_2-Upllp- .,-* Up
_
_tg72U?--- _.-2Upl'_p ., Up •
(39)
Hence
_= = u, u,,n_v;U, _.2
Substitute
_2
this Fl
into equation
(32) to obtain
*
rio
,_n
_,
(v,ut up-_u;,u#_)_
Then tr [-_)=
Snp, hence X2 = l'_tr(rI_)=snp
i/8
= s.
l"-_tr('_)'Snp
N°w'
substitute
the ab°ve)'2
into (39), to obtain
-- ---2--* snpUpI]p UtFit Ut =
Hence
(38) yields
(40), must satisfy
the lower (17b).
1//2
Up
SnpN/P-
(40)
bound in (16a), and the matrix
(17c) can be easily deduced
achieving
from (15b).
this bound,
This concludes
shown
by
the proof. []
2.
Proof of Lemma
a)
Proof of (29a):
4
Since Jkx does not depend
on K(p,q)
for p ;e i or q ¢ i, we have:
O VkJrx(P'
Proof
of (29b):
We need following
q) -
_K(p, q) Jk,x = 0
equality
(e.g. Page 444 of Skelton
[1988])
to prove
the
we have
by
equation:
_.i[A] = [E -1 ]ith_rowA[E]ith--eol
where
_-i is the ith eigenvalue
taking
A = K(i, i)X(j, j)
Xi[K(i,
of A, and E the eigenvector
i)X(j,j)]
= tr{K(i,
Hence
from the differentiation
rule
= [E-1 ]lth-rowK(i,
i)X(j, j)[E]lth--col
]i9
of A.
i)X(j, j)[-E]tth--col
[E-1]lth-row
OtrAB _ AT we get
OB
matrix
}
Now,
_X/
-: T
OK(i, i)
Then,
T
- FE
•
j)
we have: 8 8Jk.x
1 n OK(i, i) _a[K(i,
0K(i, i) - _t_
-
5/kt[K(i,
i)X(j, j)]
rib--colX(j,• j) [E-1T] it)v-row[E] T
=I_ -
The proof of part b) follows
i)X(j, j)]
_/_a[K(i, i)X(j,j)]
in a similar manner []
3. Proof
of Theorem
minimization
2:
Apply
Lagrangian
Multipliers
K2, K3,
then
(30a)-(30c)
leads
of
= tr{Q([C
+ IoGM]X 1[C + IoGM]* + (IoGI1)(V p + Ez)OoGI:
+ tr{ K 2([A + BGM]X1 [A + BGM]* - X:)} + tr{K3([A
+ DWpD*
+ (BGI:)(Vp
+ BGM]*Ke[A
[C + IoGM]-
I_)}
/20
1)" + (BI1)Eu (BI1)*
+ BGM] + [C + IoGM]* Q + _ snc
Then
+ Ez)(BGI
)* )] }
(trZk) 2
to
g
- [A + BGM]X1
[A + BGM]*
+ DWpD"
+ (BGI1)(Vp
+ Ez)(BGI1)"
+ BI1Eu(BI1
)* - X1 = 0
3K2 - [A + BGM]* Ke[A + BGM] + [C + IoGM]*Q[C
+ IoGM]
- Ke = 0
0K3 - [C + IoGM]*Q[C
+ IoGM] + [A + BGM]'K2[A
+ BGM] - K2 + Vx_ = 0
3X1 - [A + BGM]K3
[A + BGM] ° - K3 + Vk I = 0
_Ke
Applying
Lemma
theorem.
This verifies
_G
4 on the above (31a)-(31d).
- 2I;QCX1M"
two equations,
we can obtain
Vx, and Vkl as stated
in the
Now
+ 2I;QIoGMX
1M" + 2I;QIoGI2(Vp
+ 2B'K2BGMX1M*
+ 2B*K2BGI
+ 2B*K1BGMK3M*
+ 2I_QCK3M*
+ Ez)I_ + 2B'K2AX1
1(Vp + Ez)I_ + 2B'K1AK3 + 2I_QIoGMK;M*
M*
M°
= 0 ,
but since I_QC = O, then,
_G
- 2[I_QIoG(MX + (B'K1B
1M ° + 11('Vp + Ez)I_)
+ IoQIo)GMK3M*
= 2[(I_QI 0 + B'K2B)G(MX1 + (B'K1B
This verifies
+ I;QIo)GMK3M*]
+ B* (K2AX1
+ B*K2BG(MX1 M° + Ii(Vp
+ K2AK 3)M*
M" + I1 (Vp + Ez)I _)]
+ Ez)I_) + B*(K2AX
1 + K1AK3)M*
= 0 .
(31e). []
12I
Appendix
We now present and (17c) Let _
an algorithm
for one set of solutions
in (17b) be written
(originally
B
developed
by Hwang
of Ut, I-It, Vt (The solutions
in terms of its singular
Up unitary,
Algorithm
for solving
(17b)
for Ut, I-It, Vt are not unique).
value decomposition
"_" = UpY-1:,U _
where
[1977])
(4])
Zp diagonal.
(Solving
Ut, I-It, Vt in (17b) and (17c))
I. Take:
(42a)
U t = Up
!
tr(_,p)
n, =
(42b) Snp
Vt = Vn-lVn.-2
where
Vi, i = 1, • • • , n - 1 is computed li.
Compute
" " " Vi " " ' V2V1
as follows:
V 1" Let
Z 1 _FIt 2=diag(.-.
Assume
(42c)
_11 and ch_ are two numbers
clj'")
such that one of them is bigger
than s. Then take V1 as:
122
(43a)
than s, the other is smaller
column fl
0
...
0 gl
0
...
O"
0
1
...
0
0
0
...
0
1
0
0
fl
0
...
0
g 1 =
0 -ga row
0
...
(43b)
--_
0
......
1
............
1
where
fl
:to,0-11 L'G_ll
I
1 - Cll
gl =
'
(_1_ -- (Yll
Compute
1
(43d)
Vi" Let
2i = Vi-I
where
(43c)
Zi
_]R
satisfies
(i-1)x(i-1)
and Zi_ can be written
"_-_-1V_-I
the property
[2il]j
=
j = S, Ei2
_-'i3
cIR (i-1)x(n-i+l)
is a nonzero
matrix,
as
_-43 =
Assume
(Jii and cYia are numbers
than s. Then take V i as
such that one of them is bigger
than s and the other
is smaller
i column "1
o_ column
0
0 0
0
i row
...
fi 0 0
0
...
0 gi
1
0 0
0
tz row -4
0
0
0
Wi =
...
...
(44b)
1 0
gi 0
...
0
0 fi
...
0
0 0
0
Computefi andgi as:
fi =
gi =
I
(_ia
--
(44C)
1 1 la
_ia -