You are on page 1of 18

P

o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
1 4.1
Cosimo Greco
THE OVERALL DEVELOPMENT SYSTEM
Overall technological structure (13/14)
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
2 4.1
Cosimo Greco
| |
| |
n 1 n 1
1 i
1 i
b b a a
e ) n i ( u ) 1 i ( u ) n i ( y ) 1 i ( y
here w ) i ( y


= u
'
=
'
u
'
=

Model #1 can be rewritten as


n 2 m = is defined information set (m 1) with
u is the parameters vector (m 1).
The model tf is:
n
1 n
1
n
n
1 n
1
n
n
1
1
n
n
1
1
a z a z
b z b
z a z a 1
z b z b
) z ( G

+ +
=

+ +
=

ARX model (2/3)


#2
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
3 4.1
Cosimo Greco
i i
i i
||
1 i
2 i
N i
||
y A
wich from
A y
) i ( y
) 1 i ( y
) 1 N i ( y
= u
u
(
(
(
(

'

'

'
=
(
(
(
(

From #1 (or #2), by ordering N samples backward from i,


we can obtain:
#3
N
m 1
m N : condition Necessary >
ARX model (3/3)
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
4 4.1
Cosimo Greco
Problem: inversion of ; IMPORTANT: is it invertible?
A possible solution: use of the QR factorization:
it is possible to determine a matrix Q
NN
such that:
with R
i
upper triangular and Q ortonormal
LS estimation (2/4)
( )
i i
A A
'
(

=
0
R
QA
i
i
( )
1
Q Q , I Q Q

'
=
'
#5 Q
N
m
m
N-m
0
A
i
R
i
m
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
5 4.1
Cosimo Greco
IMPORTANT from #6: is it true that ??? 0 y
~
i
=
Premultiplying equation #3 by Q we obtain:
N.B: solution #6 can be also obtained from #4 by
substituing A
i
from #5 and remembering that Q is
ortonormal.
i
1
i i
i
i i
y

wich from
y
~
y

0
R

= u
(

= u
(

#6
1
m
LS estimation (3/4)
IMPORTANT: is R
i
invertible?
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
6 4.1
Cosimo Greco
Primary aspects:
1. estimation of n (or of m)
2. inversion of R
i
3. insertion of additional samples
4. real-time implementation
5. models of different structure
6. effect of the uncertainties
In the following, tools are provided only for items 14
LS estimation (4/4)
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
7 4.1
Cosimo Greco
RLS Solution KE
The solution KE is derived from the Kalman estimator.
It can be demonstrated
(+)
that an efficient solution for the
problem #8 is the following:
________________
*
see next slides
( )
( )
|
|
.
|

\
|

'
+

'

=
u
'
= +
+ + + u = u
+
+ +
i i i
2
i i i i
i
2
1 i
i i
i 1 i i 1 i
P
P P
P
1
P
and

i 1 i y

with ) i 1 i ( y

) 1 i ( y P

#9
m
1 m
proof
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
8 4.1
Cosimo Greco
Note: from the present generic instant k backward,
the forgetting factor acts by weighing the information
as follow:
at k by
0
at k1 by
1
at k2by
2
at k3by
3

at kN by
N
is therefore said exponential forgetting factor
Recursive Least Squares RLS (3/4)
k-40 k-35 k-30 k-25 k-20 k-15 k-10 k-5 k
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
9 4.1
Cosimo Greco
{ }
( )
L 1
P
P L 1
LP P
P P lim
c c
1
c
c c
1
c
c c
1
c
1
c
1
c
1
i
i

'

'
=

'
+ =
=




From the last result it is evident that the matrix P
c
is
not computable as
( )( )
1
c c c
L 1 P

'
=
because of the matrix is not invertible due to the
fact that its dimensions are mm but its rank is unitary;
this fact implies the covariance windup, that is:
( )
c c

'

Solution KE in steady state conditions (2/2)



c
P
accuracy and convergence problems for
u

P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
10 4.1
Cosimo Greco
Solution KE : initialization
IMPORTANT: the recursive solution #9 requires the
initial values P
0
and u
0
of P() and u() respectively
Three types of initialization are proposed in the following:
1.
2.
3. P
0
and u
0
from previous estimation experiments carried
out on the same system
( )
0 0 0 0
1
0 0 0
y A P

, A A P
'
= u
'
=

... 10000 or 1000 or 100 with = ( ) m rand

; I P
0 0
= u =
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
11 4.1
Cosimo Greco
The application of m Givens rotations to #10 leads to a
transformation matrix G
where G
j
is the one-step Givens rotation applied to the
j-th column of the system matrix
1 1 m m
G G G G

=
(

= u
(

'

) 1 i ( y
y

G
R
G
i
i
i
m 1
m+1
m 1
0 0 0
) 1 i ( y
~
+
m+1
#11
RLS Solution GR (2/8)
(

+
= u
(

+ +
) 1 i ( y
~
y

0
R
1 i 1 i
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
12 4.1
Cosimo Greco
To place poles and zeros we must change the control
structure
Working hypotesis: almost 2DoF closed loop structure
POLEZERO PLACEMENT (1/7)
u
d
T
+

e y
+
r
+
) z ( A
) z ( B
) z ( R
) z ( S
) z ( S
) z ( T
0 1
2
2
1 m
1 m
m
m
0 1
2
2
1 n
1 n
n
b z b z b z b z b B
and a z a z a z a z A
h wit
BS AR
TB
BS AR
SB
S
T
) z ( r
) z ( y
W
+ + + + + =
=
+
=
+
= =

P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
13 4.1
Cosimo Greco
m = n-1 (in general m< n)
Specifications:
closed loop poles: arbitrary placement
r
close loop zeros
system zeros to cancel ,
+
system zeros to maintain ,

zeros to add ,
a
closed loop DC gain K
DC
POLEZERO PLACEMENT (2/7)
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
14 4.1
Cosimo Greco
NB: ,
+
and ,

are roots of B(z), then we define:


Cancellation of B
+
:
Then, referring to the closed loop zeros: B
+
is
cancelled; B

in maintained; additional zeros are the


roots of T
POLEZERO PLACEMENT (3/7)
S B R A
TB
W
S B B B R A
B TB
S B B AR
B TB
BS AR
TB
W
B R R
B cancel want we if

+ +
+
' =
+
+
+
'
=
+
'
=
+
=
+
=
+
+
( ) ( )
m and B B B
with z b B ; z B
B
B B
1 j
j m
1 i
i
B B
= = + =
, = , =
+
+
+

=
+ +
[ [
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
15 4.1
Cosimo Greco
Note: the closed loop tf has the following form
POLEZERO PLACEMENT (4/7)

= +
'
=
+
'
= =
+
'
= + =
= =
= =
+
=

+
+ +
+
r
r
r
r
r
r r
r
r
r
r
r
A S B R A
B TB
S B R A
TB
A
B
W
then , B factor common the have B and A
; S B B B R A BS AR A
B TB TB B
with
A
B
W
BS AR
TB
W
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
16 4.1
Cosimo Greco
Without loss of generality, we can assume that the
polynomials A, B
+
and R are monic; T, B
-
and S are not
monic
The unknowns of the design problem are T, R and S
Given the n
a
zeros ,
a
to add, the not monic polynomial T,
of degree
T
, is given by
with K
T
to compute
POLEZERO PLACEMENT (5/7)
( )

, = =
=
[

=
T
1 i
i , a T
a T
z ) z ( T with ), z ( T K ) z ( T
n
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
17 4.1
Cosimo Greco
The unknown polynomials R and S are computed from
given the
Ar
desired closed loop poles
r
NB:
Ar
is still unknown
Nr. of eq.ns = n.r of unknowns we obtain
To ensure S/R causal
The n.r of not cancelled closed loop poles is
To ensure T/S causal
POLEZERO PLACEMENT (6/7)
r
A S B R A = +
'

( )
[

=
=
Ar
1 i
i , r r
z ) z ( A
1
A S
=
+
= >
'
B
R R S R

R A A
r
'
+ =
S T
s
P
o
l
i
t
e
c
n
i
c
o

d
i

T
o
r
i
n
o
18 4.1
Cosimo Greco
1. Given from the system model
2. given from the previous inequalities
3. we can fix the sets and then
4. compute
5. from is derived a system of equations
in unknowns, so R and S polynomials are computed
6. given the closed loop DC gain K
DC
, the coefficient K
T
of
T(z) is computed from
POLEZERO PLACEMENT (7/7)
r
A S B R A = +
'

+

B B
B A
, , ,
T A R S
and , ,
r

'
{ } { }
a r
and ,
( )
[

=
=
Ar
1 i
i , r r
z ) z ( A ( )
[

=
, =
T
1 i
i , a
z ) z ( T and
r
A

r
A

1 z
r
DC T
B T
A
K K
=

(
=

You might also like