Documente Academic
Documente Profesional
Documente Cultură
1
Basics
• Vector matrix format generally is given by:
2
PARTS OF A STATE SPACE
REPRESENTATION
• State Variables: a subset of system variables which if
known at an initial time t0 along with subsequent inputs are
determined for all time t>t0+
• State Equations: n linearly independent first order
differential equations relating the first derivatives of the
state variables to functions of the state variables and the
inputs.
• Output equations: algebraic equations relating the state
variables to the system outputs.
3
d
x(t ) Ax (t ) Bu (t ) State equation
Dynamic equation dt
y (t ) Cx(t ) Du(t ) Output equation
State variable
x1 (t ) u1 (t ) y1 (t ) x1 (0)
x (t ) u (t ) y (t ) x (0)
x(t ) 2 u (t ) 2 y (t ) x(0) 2
2
x n (t ) n1 ur (t ) r1 p p1
y (t ) n n1
x ( 0 )
A nn
B nr
C pn
D pr
u1 (t ) y1 (t )
u2 (t ) Inner state variables y2 (t )
x1 , x2 , xn
ur (t ) y p (t )
u (t ) + x (t ) 1 x(t ) + y (t )
B C
s +
-
A
Motivation of state space approach
Example 1
u (t ) e(t ) s 1 y (t )
+ - ( s 1)
2
s 1 +
n(t ) noise
Y ( s) s 1
Transfer function
U ( s) s 3 BIBO stable
E ( s) 2( s 1)
u 0
N ( s) ( s 1)( s 3)
unstable
Example 2
u (t ) s 1 1 y (t )
s 1 s 1
y 1
BIBO stable, pole-zero cancellation
u s 1
+
+ x1 1 x1 + v(t ) x 2 1 x2
-2
u (t ) - s + s y (t )
+
v s 1 2
1
u s 1 s 1
2
vu u
s 1 7
x1 x1 2u x1 (0) x10
x2 x1 x2 u x 2 (0) x 20
y x2
x(t ) L1[(sI A) 1 ]x(0) L1[(sI A) 1 BU (s)]
x1 (t ) e t x10 2e t u (t )
1 1 t
y (t ) x 2 (t ) ( x 20 x10 )e e x10 e t u (t )
t
2 2
1. if x10 x 20 0
2. if x10 2 x 20 then system stable
8
Example : Capacitor electric
energy
1 t0 1 t
v(t ) i ( )d i ( )d
c c t0 i[, t0 ] Input
1 t
v(t 0 ) i ( )d
c t0
Example : Inductor
1 t0 1 t
i (t ) v( )d v( )d
L L t0
1 t
i(t 0 ) v( )d
L t0 Magnetic
energy
9
Example y2 y1
K
M2 M1 f (t )
B3 B2 B1
x1 y1 y 2 x1 0
1 1 x1 0
x K ( B B2 ) B2 x 1 f (t )
x 2 y1 2 M 1
let M1 M1 2 M1
x3
( B2 B3 ) x3 0
1
x3 y 2
K B2
M 2 M2 M 2
10
Example La Rf
Ra
ea t ia e t Lf e f t
b
Armature circuit m Field circuit
TL
Jm
di Tm k i ia
ea (t ) Raia eb La a
dt d 2 m d m
Jm B TL
eb kbm dt 2 m
dt
dia Ra kb 1 d m k B d m 1
ia m ea i ia m TL
dt La La La dt Jm J m dt Jm
d m
m
dt
11
Ra Kb 1
L La
0 L 0
ia a ia a e
Ki Bm 1 a
m J Jm
0 m 0
J m TL
m m
0 m 0 0
0 1
ia
y1 (t ) m (t ) 0 0 1
y (t ) (t ) 0 1 0 m
2 m
m
12
Dynamical equation Transfer function
x (t ) Ax (t ) Bu (t )
y (t ) Cx(t ) Du(t )
Laplace transform
sX ( s) x(0) AX ( s) BU ( s)
Y ( s) CX ( s) DU ( s)
assume x(0) 0
X ( s) ( sI A) 1 BU ( s)
Y ( s) [C ( sI A) 1 B D]U ( s)
matrix
Transfer function
13
Example By Newton’s Law
F My My by ky r
r ky by My let x1 y, x2 y
k
b
x1 y x2
M
b k 1
x2 y y y r
y (t ), y (t ) M M M
r (t ) b
x2
k 1
x1 u u r
M M M
x1 x 2
k b 1
x 2 x1 x2 u
M M M
x1 0 1 x 0
x
k b 1 1 u y 1 0 1 0 u
x2 M x2
M M x2
C
A B
14
State Space Equation
x1 0 1 x 0
x Ax Bu For example : k b 1 1 u
x2 M x2
M M
y Cx Du
x1
y 1 0 0 u
x2
Transfer Function
Y ( s) b1s b0
G( s) For example : G( s)
U ( s) a2 s 2 a1s a0
15
x1 0 1 0 x1 0 0
Example x 0 4 3 x 1 0 u1
2 2 u
x3 1 1 2 x3 0 1 2
MIMO system x1
y1 (t ) 1 0 0
y (t ) 0 0 1 x2
2 x
3
adj ( sI A)
( sI A) 1
sI A
s 2 6s 11 s 2 3
1
3 s 2
2 3s
s ( s 4)( s 2) 3 3s
s4 s 1 s 4s
2
G ( s) [C ( sI A) 1 B D]
1 s2 3
Transfer function
s 3 6s 2 11s 3 ( s 1) s( s 4)
16
Remark : the choice of states is not unique.
+ R L +
di(t ) 1 t
ei (t ) c ec (t ) Ri (t ) L i(t )dt ei (t )
i (t )
dt c 0
- -
x1 (t ) i (t ) x1 R
1 x 1
x L LC L ei (t )
1
let 2 1 0 x2 0
x2 (t ) i (t )dt
x
y(t ) i(t ) y (t ) 1 0 1
x2
R R
xˆ1 (t ) i (t ) xˆ1 L
ˆ
x 1
ˆ L ei (t )
L
1
1
let xˆ2 0 x2 0
xˆ2 (t ) ec (t ) L
exist a mapping
y(t ) i(t ) xˆ1
y (t ) 1 0
xˆ2
17
Question
The transition matrix
For a given continuous system,
d
X (t ) AX (t ) Bu (t )
dt
y CX (t )
we can obtain the solution as the follow.
First, we can re-write the equation as:
d
X (t ) AX (t ) Bu (t )
dt
35
The transition matrix
Pre-multiplying both sides of the above equation by
e-At, we obtain
At d d At At
e ( X (t ) AX (t )) (e X (t )) e Bu (t )
dt dt
Integrating the preceding equation between 0 and t
gives t d
0 dt
At At
( e 1
X (t1 )) dt1 e 1
X (t )
1 0|t
t
e At X (t ) X (0) e At1 Bu (t1 )dt1
0
36
The transition matrix
t
e At
X (t ) X (0) e At1 Bu (t1 )dt1
Or 0
t
e At X (t ) X (0) e At1 Bu (t1 )dt1
0
Pre-multiplying both sides by eAt, we have
t
X (t ) e At X (0) e At e At1 Bu (t1 )dt1
0
t
e X (0) e At e At1 Bu (t1 )dt1
At
0
t
e At X (0) e A(t t1 ) Bu (t1 )dt1
0
37
The transition matrix
e At 0 X (0)
X (0) e At 0 X (t 0 )
38
The transition matrix
• e A(t t ) e At e At e At e At I
N
Ak t k
• (t ) e At lim
N k!
k 0
41
Calculation of the transition matrix
N
Ak t k
As (t ) e
At
lim
N k!
k 0
apply Laplace transform to the above equations, we
have L[ (t )] L[ I At 21! A 2 t 2 k1! A k t k ]
I A A2 Ak
2 3 k
s s s s
1 A A2 Ak
I 2 k
s s s s
1 I I
( sI A) 1
s A sI A
I
s
42
Calculation of the transition matrix
Finally we have
(t ) L (sI A)
1 1
That means we can use inverse Laplace
transform to calculate the transition matrix.
43
Examples of the transition matrix
calculation
44
Examples of the transition matrix
calculation
46
Examples of the transition matrix
calculation (cont’)
Finally, calculate the transition matrix,
s6 1
2
2
(t ) L1[( sI A) 1 ] L1 s 6 s 109 s 6 s 109
109 s
2
s 6s 109 s 2 6s 109
s 33 1
2
-1 (s 3) 10
2 2
(s 3) 10 11(t ) 2 (t )
2
L
109 s 3-3
21(t ) 22 (t )
(s 3) 10 (s 3) 2 10 2
2 2
3t 3 3t 1 3t
e cos 10t e sin 10t e sin 10t
10 10
109 3t 3
e sin 10t e 3t cos 10t e 3t sin 10t
10 10 47
General State Representation
x Ax Bu State equation
y Cx Du output equation
x = state vector
x = derivative of the state vector with
y = output vectorrespect to time
u= input or control vector
A = system matrix
B
= input matrix
C = output matrix
D = feedforward matrix
48
Some definitions
• System variable : any variable that responds to an input or initial
conditions in a system
• State variables : the smallest set of linearly independent system
variables such that the values of the members of the set at time t0
along with known forcing functions completely determine the
value of all system variables for all t ≥ t0
• State vector : a vector whose elements are the state variables
• State space : the n-dimensional space whose axes are the state
variables
• State equations : a set of first-order differential equations with b
variables, where the n variables to be solved are the state variables
• Output equation : the algebraic equation that expresses the output
variables of a system as linear combination of the state variables
and the inputs.
49
Graphic
representation
of state space
and a state
vector
Application
Electrical network
51
1. Select state variablesvC iL
dvC diL
C iC L vL (1)
dt dt
Express (1) using vC iL vt
3. dvC 1 vc 1 iL
dt RC C
vC vt
diL 1 1 (3)
dt L L
4. 1
Output iR vC
equation R
Convert a transfer function
dny d n 1 y dy
n
a n 1 n 1
a1 a0 y b0u
dt dt dt
choose
d n 1 y
x1 y x2
dy
dt
d2y
x3 2
dt xn n 1
dt
diferensiasikan
dy
x1 x1 x2
dt
d2y
x2 2
x 2 x3
dt
d3y
x3 3 x n 1 xn
dt
n
xn a0 x1 a1 x2 an1 xn b0u
d y
xn
dt n
53
x1 0 1 0 0 0 0 0 x1 0
x 0 0 1 0 0 0 0 x2 0
2
x3 0 0 0 1 0 0 0 x3 0
u
xn 1 0 0 0 0 0 0 1 xn 1 0
xn a0 a1 a2 a3 a4 a5 an 1 xn b0
x1
x
2
x3
y 1 0 0 0
xn 1
xn
Example : TF to State Space
1. Inverse Laplace
c 9c 26c 24c 24r
x1 x2
x2 x3
N s
G s
x3 24 x1 26 x2 9 x3 24r Ds
N s numerator
y c x1 Ds denominator
55
x1 0 1 0 x1 0
x 0 x 0 r x1
y 1 0 0 x2
2 0 1 2
x3 24 26 9 x3 24
x3
56
Decomposing a transfer function
57
Y s C s b2 s 2 b1s b0 X1 s
d 2 x1
yt b2 2 b1 1 b0 x1
dx
dt dt
yt b0 x1 b1 x2 b2 x3
58
Example
59
yt 2 x1 7 x2 x3
x1
y 2 7 1 x2
x3
60
State Space to TF
x Ax Bu
y Cx Du
Laplace Transform
sX s AX s BU s
Y s CX s DU s
X s sI A BU s
1
Y s C sI A B D U s
1
Y s
T s C sI A B D
1
U s
61
0 1 0 10
x 0 0 1 x 0 u
1 2 3 0
y 1 0 0x
s 1 0
sI A 0 s 1
1 2 s 3
( s 2 3s 2) s3 1
1 s ( s 3) s
s (2s 1) s
2
s 3 3s 2 2s 1
T s C sI A B D
1
10( s 2 3s 2)
T s 3
s 3s 2 2s 1
Design of state observer
State Observer , or pole placement, is a method employed in feedback control system
theory to place the closed-loop poles of a plant in pre-determined locations in the s-
plane.
Placing poles is desirable because the location of the poles corresponds directly to the
eigenvalues of the system, which control the characteristics of the response of the
system. The system must be considered controllable in order to implement this method.
If the closed-loop input-output transfer function can be represented by a state space
equation,
then the poles of the system are the roots of the characteristic equation given by
70
Example
Consider a control system given by the following state space
equations
71
Upon setting this characteristic equation equal to the desired
characteristic equation, we find
72