Professional Documents
Culture Documents
PCE6101 Linear Systems Theory: (Controllability and Observability)
PCE6101 Linear Systems Theory: (Controllability and Observability)
PCE6101 Linear Systems Theory: (Controllability and Observability)
University
ASTU
School of EEC
1
Cont…
State feedback control
d
r Feedforward + u + + y
Plant
gain matrix -
Feedback x
gain matrix
Plant
x Ax Bu, x (t0 ) x0
y Cx Du
State variables are used for feedback.
One of the state variables may be the output.
2. Controllable/Uncontrollable
2
Cont…
3. Controllability
Controllability concept
Situations:
We want to design a feedback system with the
desired performance.
We want to control unstable systems.
Questions:
Is it possible to move the initial state x(t0) to the
desired state x(t1) after a finite time by applying
the appropriate input u(t)?
3
Cont…
Observability concept
Situations:
Some variables are difficult to measure for
feedback.
Some sensors are too expensive. So they can not
be used.
Questions:
Is it possible to know the initial state x(t0) or the
state x(t) from both the input u(t) and the output
y(t) observed for a finite time?
Cont…
Why do we check it?
Necessary to know the existence
of uncontrollable state variables
because the feedback of the state
variables is used.
If a system is uncontrolable, no
state controller can be designed.
Firstly introduced by R.E. Kalman. R.E. Kalman
(1930-2016)
4
Cont…
(Definition) Controllability
A system is said to be controllable at t= t0 if there is a
control input u(t), t0<tt1 that can move the initial
state x(t0) to the desired state x(t1) at t= t1.
Cont…
Single input LTI system:
The controllability is closely related to matrices A and
B. For example
0 1
x x u, x (t0 ) 0
0 1
At
1 -1+et
Φ (t ) e
0 et
5
Cont…
The solution is 0
t
e A(t ) Bu ( )d
A ( t t0 )
x (t ) e x (t0 )
0
t 1 -1+e(t )
0
0
u ( )d
e(t )
t
0
[ e(t ) ]u ( )d
t
(t )
e u ( )d
0
Cont…
Letting t= t1
t1 t1
x1 (t1 ) ( ) 0
u ( )d 0
e(t1 ) u ( )d
t1
x2 (t1 ) 0
e(t1 ) u ( )d
When 0, = 0
t1
x1 (t1 ) 0
u ( )d
x2 (t1 ) 0
x1(t1) can be moved to any state via u(t), but x2(t1) is
always fixed to 0.
6
Cont…
(Definition) Controllability of a LTI system
A LTI system is said to be controllable at t= t0 if u(t),
t0< t t1 exists to move x(t0) to the desired state x(t1)
at t= t1. Especially if one of the following conditions
is true, then it is controllable:
Cont…
3. The controllable Gramian matrix WC is
nonsingular.
t
e A BBT e A d , t 0
T
Wc
0
For example, given a system
0 1 1 0
x x 0 1 u, x (t0 ) x0
1 2
Controllability matrix is given by
1 0 0 1 Since U= 2 = n,
U [ B AB ]
0 1 1 2 controllable.
7
Cont…
Consider a system
1 1 0 1
x 0 1 0 x 2 u, x (t0 ) x0
0 0 0 1
Cont…
1 1 3 -2E1+E2 E2
U [ B AB A2 B ] 2 2 2 -E1+E3 E3
1 0 0
1 1 3 1
0 4 8 -4E2+E3 E3 1 1 3
0 4 8
0 1 3
0 0 1
Since U= 3= n, controllable.
8
Cont…
Consider a LTI system
1 1 1
x x u, x (t0 ) x0
0 2 1
1
1 s 1 1 1
( sI A) B
0 s 2 1
s3
1 s 2 1 1 ( s 1)( s 2)
( s 1)( s 2) 0 s 1 1 1
( s 2)
To check the linear independence of two rows
s3 1
1 2 0
( s 1)( s 2) ( s 2)
Cont…
Multiplying both sides by (s-1)(s+2) gives
9
Cont…
For example, given a system
1 0 1
x x 1 u, x (t0 ) x0
0 2
At
et 0
Φ (t ) e
2t
0 e
t
e A BBT e A d , t 0
T
Wc
0
Cont…
e 0 1 e 0 e 2 e3
1 1
A T AT
e BB e
0 e2 1 0 e2 e 3 e4
t t e 2
e3
e A BBT e A d
T
Wc 3 4
d
0 0 e
e
1 2t 1 3t
2 (1 e ) 3 (1 e )
1 (1 e 3t ) 1 (1 e 4t )
3 4
Since Wc is
1 1
Wc (1 e2t )(1 e 4t ) (1 e3t ) 2 0 nonsingular,
8 9
controllable.
10
Cont…
For example, check the controllability using the
Matlab functions.
1 1 0 1
x 0 1 0 x 2 u, x (t0 ) x0
0 0 0 1
Program:
>>A= [-1 1 0;0 -1 0;0 0 0];
>> B= [1;2;1];
>> U= ctrb(A,B); % Controllability matrix
>> r= rank(U) % Rank
r= 3
4. Observability
Why do we need to check it?
Designing and implementing state feedback control
require the feedback of all state variables.
When some state variables are unmeasurable, we
need to check whether they can be estimated from the
model.
If the system is unobservable, state observer design is
impossible
Firstly introduced by R.E. Kalman
11
Cont…
LTI system:
The observability is closely related to matrices A
and C.
x Ax Bu, x (t0 ) x0
y Cx Du
x Ax Bu, x (t0 ) x0
y Cx
Cont…
(Definition) Observability
A LTI system is said to be observable if there is
enough t= t1>0 that u and y determine x0 uniquely.
Especially it is observable if one of the following
conditions is true:
1. The rank of the npm observability matrix V is n.
C
CA
V
n-1
CA
12
Cont…
2. All columns of the transfer matrix are linearly
independent.
C(sI-A)-1
Cont…
For example, consider a SISO LTI system
0 1 0
x x u, x (t0 ) x0
1 2 1
y 1 0 x
Observability matrix yields
C 1 0
V
CA 0 1
Since V= 2 = n, the system is observable.
13
Cont…
For example, consider a LTI system
0 1 1
x x 0 u, x (t0 ) x0
0 0
y 1 0 x
1
s 1
C ( sI A) 1 1 0
0 s
1 s 1 1 1
2 1 0
s 0 s s s2
Cont…
To check the linear independence of two columns
1 1
1 2 0
s s2
Multiplying both sides by s2 gives
1s+2= 0s+0s0
Comparing the left and right sides gives
14
Cont…
Program:
>> A= [0 1;0 0]; B= [1;0]; C= [1 0];
>> U= ctrb(A,B); % Controllability matrix
>> ru= rank(U) % Rank
>> V= obsv(A,C); % Observability matrix
>> rv= rank(V) % Rank
ru= 1
0 1 1
rv= 2 x x u, x (t0 ) x0
0 0 0
y 1 0 x
The system is observable but not controllable.
5. Similarity Transformation
A LTI system can be represented as a combination of
subsystems with appropriate similarity transformation
Controllable and
observable system
Controllable but
unobservable system
Observable but
uncontrollable system
Uncontrollable and
unobservable system
15
Cont…
Controllable subsystem
x Ax Bu, x (t0 ) x0
y Cx Du
If U= n1< n, via the following similarity
transformation
x Qx
The original system can be represented by a
combination of controllable subsystems and
uncontrollable subsystems.
Cont…
16
Cont…
Original system
x Ax Bu, x (t0 ) x0
y Cx Du
Similarity transformation x Qx
x Ax Bu
y Cx Du
where A Q 1 AQ, B Q 1 B, C = CQ, D D
Cont…
Transformed system
x c Ac A12 xc Bc
u
xc 0 Ac xc 0
x
y Cc Cc c Du
xc
Controllable subsystem
x c Ac xc Bc u
y Cc xc Du
17
Cont…
Consider a LTI system.
0 1 0 0
x 1 2 0 x 1 u, x (t0 ) x0
0 0 3 0
y 1 1 0 x
The controllability matrix U gives
0 1 2
U [ B AB A2 B] 1 2 3
0 0 0
Cont…
Since U= 2 < n= 3, it is uncontrollable. n1= 3-2= 1.
Choosing one vector randomly such that Q is
nonsingular yields
0 1 2 0 1 0
U 1 2 3 Q 1 2 0
0 0 0 0 0 1
2 1 0
Q 1 1 0 0 Randomly choose
0 0 1 such that Q-1 exists
18
Cont…
Thus
0 - 1 0
A Q AQ 1 -2 0 ,
1
0 0 -3
1
B Q 1 B 0 ,
0
C CQ 1 1 0 ,
DD0
Cont…
The transformed system is given by
0 - 1 0 1
x c xc
1 -2 0 0 u
xc xc 0
0 0 -3
x
y 1 1 0 c
xc
0 1 1
Thus, controllable x c x
c 0 u
subsystem is given by 1 2
y 1 1 xc
19
Cont…
Observable subsystem
x Ax Bu, x (t0 ) x0
y Cx Du
If V= n2 < n, via the similarity transformation
x Q 1 x
the original system can be represented by a
combination of observable subsystems and
unobservable subsystems.
Cont…
q1
q n2 independent vectors
2
selected from V
where Q qn2
q
2
n 1 (n-n2) vectors randomly
chosen such that Q is
nonsingular
n
q
20
Cont…
Original system
x Ax Bu, x (t0 ) x0
y Cx Du
Similarity transformation x Q 1 x
x Ax Bu
y Cx Du
where A QAQ 1 , B QB, C CQ 1 , D D
Cont…
Transformed system
x o Ao A12 xo Bo
u
Ao xo 0
xo 0
x
y Co Co o Du
xo
Observable subsystem
x o Ao xo Bo u
y Co xo Du
21
Cont…
Consider a LTI system.
0 1 0 0
x 1 2 0 x 1 u, x (t0 ) x0
0 0 3 0
y 1 1 0 x
The observability matrix V gives
C 1 1 0
V CA 1 1 0
2 1 1 0
CA
Cont…
Since V= 1 < n= 3, it is unobservable. Selecting Q as
1 1 0 1 1 0
Q 0 1 0 Q 1
0 1 0
0 0 1 0 0 1
Randomly choose
Thus such that Q-1 exists
-1 0 0 1
A QAQ 1
-1 -1 0 , B QB 1
0 0 -3 0
C CQ 1 1 0 0 , D D 0
22
Cont…
The transformed system is given by
-1 0 0 1
x o
o x
-1 -1 0 xc 1 u
xo 0 0 -3 xo 0
x
y 1 0 0 o
xo
Thus, observable 1 0 1
x o x
o 1 u
subsystem is given by 1 1
y 1 0 xo
23
Cont…
Controller Plant
r u y
u Kx Fr D/A
A/D A/D
x1 x2
Cont…
Plant
x Ax Bu, x (t0 ) x0
y Cx Du
where A nn , B n1 , C 1n ,D
Assumption
The plant is a SISO LTI system(u and y are scalars)
It is controllable & observable(U= n, V= n)
24
Cont…
Similarity transformation
Before
x Ax Bu, x (t0 ) x0
y Cx Du
x Qx
After
Q is
x Ax Bu, x (t0 ) x0 nonsingular
y Cx Du
where A Q 1 AQ, B Q 1 B, C CQ, D =D
Cont…
Controllability
Before U [ B AB An 1 B ], U n
After U [ B AB Ai 1 B An 1 B ]
The ith term in the above equation
Ai 1 B (Q 1 AQ )(Q 1 AQ ) (Q 1 AQ )Q 1 B Q 1 Ai 1 B
25
Cont…
Observability
C C
CA
CA
Before V , V n After V
n 1
CA CAn1
As the previous case
(i-1) times
Cont…
After transformation
C C
V CAi 1 CAi 1 Q VQ
n 1 n 1
CA CA
Thus V n
Observability is kept after transformation.
26
Cont…
Conversion to controllable canonical form
System
x Ax Bu, x (t0 ) x0
y Cx Du
Controllable canonical form
x Ax Bu, x (t ) x 0 0
y Cx Du
where A Q 1 AQ, B Q 1 B, C CQ, D =D
Cont…
Controllable canonical form(SISO)
0 1 0 0 0
0
0 0 1 0
x x u, x (t0 ) x0
0 0 0 1 0
a a 1
n n 1 an 2 a1
Transfer function
27
Cont…
Conversion procedure
Step 1: Check the controllability of the system (U= n).
U [ B AB An1 B ]
Step 2: Find the characteristic polynomial from A.
( ) | I A | n a1 n 1 an 1 an
Step 3: Obtain Q= [q1 q2 … qn]
qn B
qn 1 AB a1 B
qn 2 A2 B a1 AB a2 B
q1 An 1 B a1 An 2 B an 1 B
Cont…
Step 4: Obtain matrices
A Q 1 AQ, B Q 1 B, C CQ, D =D
For example, consider a dynamic system.
1 0 1
x x 1 u
1 2
y 2 1 x
Check the controllability.
Convertible to the
1 1 controllable
U [ B AB ] , U 2
1 3 canonical form.
28
Cont…
Getting the characteristic polynomial of A
1 0
( ) I A 2 2
1 2
a1= 1, a2= -2 1 0 1
x x 1 u
1 2
1 y 2 1 x
q2 B
1
1 1 2
q1 AB a1 B 1 Q= [q1 q2]
3 1 2
Cont…
2 1 1 1 1
Q Q 1
2 1 4 2 2
Obtain matrices
1 1 1 1 0 2 1 0 1
A Q 1 AQ =
4 2 2 1 2 2 1 2 1
1 1 1 1 0
B Q 1 B =
4 2 2 1 1
2 1
C CQ = 2 1 2 3 , D D =0
2 1
29
Cont…
Before
1 0 1 G ( s ) C ( sI A) 1 B D
x x u
1 2 1 3s 2
2
y 2 1 x s s2
TFs before and after the
After
transformation are the same.
0 1 0 G ( s ) C ( sI A) 1 B D
x x u
2 1 1 3s 2
2
y 2 3 x s s2
Cont…
Example 1: Code to obtain the controllable canonical
form of the system.
2 1 0 4
x 0 0 1 x 0 u
1 0 0 1
y 1 0 0 x
Program:
30
Cont…
MATLAB program
A= [-2 1 0;0 0 1;-1 0 0]; B= [4;0;1]; C= [1 0 0];
D= 0;
3 2
p= poly(A); % ( ) a1 a 2 a 3
Q(:,3)= B;
Q(:,2)= A*Q(:,3)+p(2)*B;
Q(:,1)= A*Q(:,2)+p(3)*B;
IQ= inv(Q);
A1= IQ*A*Q, B1= IQ*B, C1= C*Q, D1= D
[ns,ds]= ss2tf(A,B,C,D) % TF of original
[ns1,ds1]= ss2tf(A1,B1,C1,D1) % TF after
Cont…
Example 2: Obtain the TF of the system.
0 1 0 0
x 0 0 1 x 0 u
2 0 1 1
y 2 3 0 x
Solution:
G ( s) C ( sI A) 1 B D
b1s 2 b2 s b3 3s 2
s3 a1s 2 a2 s a3 s3 s 2 2
31
Cont…
Example 3: Write the TF in the controllable
canonical form.
2 s 3 3s 2 6 s 2
G (s)
s 3 6 s 2 5s 1
Solution:
a1= 6, a2= 5, a3= 1, b0=2, b1= 3, b2= 6, b3= 2
0 1 0 0 0 1 0 0
x 0 0 1 x 0 u 0 0 1 x 0 u
a3 a2 a1 1 1 5 6 1
y (b3 b0 a3 ) (b2 b0 a2 ) (b1 b0 a1 ) x 0 4 9 x
Cont…
Observable canonical form
0 0 0 an (bn b0 an )
1 0 0 an 1 (bn 1 b0 an 1 )
x 0 1 0 an 2 x (bn 2 b0 an 2 ) u, x (t0 ) x0
0 0 1 a1 (b b a )
1 0 1
y 0 0 0 1 x b0 u
32
Q&A
33