State Space Representation - Petra Christian University

Download Report

Transcript State Space Representation - Petra Christian University

State Space Representation
Hany Ferdinando
Dept. of Electrical Engineering
Petra Christian University
Overview
Introduction
State variable
Signal Flow Graph (revisited)
State Space (SS) matrix
Transfer function from SS
SS in Matlab
State Space 1 - Hany Ferdinando
2
Introduction
State Space (SS) represents a dynamic
system in matrices
It is MIMO (multi input multi output)
system (transfer function is SISO –
single input single output)
With SS, one can get future condition of
a dynamic system
State Space 1 - Hany Ferdinando
3
Examples
On-off switch:
There are only two positions
The state of the switch can assume one of
two possible states
if the present state is ‘on’, then one can
know the future state
State Space 1 - Hany Ferdinando
4
State Variable
Definition: is a set of variables such that
the knowledge of these variables and
the input functions will, with the
equations describing the dynamics,
provide the future state and output
of the system
State Space 1 - Hany Ferdinando
5
Model of A Dynamic System
Model of a dynamic system is in nthorder differential equation
The order depends on the number of
storage element in that system
SS will change one nth-order
differential equation into n first-order
differential equations
State Space 1 - Hany Ferdinando
6
Example
i(t)
dvC
iC  C
 i (t )  iL
dt
diL
uL  L
 vC  RiL
dt
State Space 1 - Hany Ferdinando
7
Example
dvC
1
1
 i (t )  iL
dt
C
C
1
1
vC  i (t )  iL
C
C
diL 1
R
 vC  iL
dt
L
L
iL  1 vC  R iL
L
L
If x1 = vC and x2 = iL then
1
1
x1  i (t )  x2
C
C
1
R
x2  x1  x2
L
L
State Space 1 - Hany Ferdinando
8
Example

0

x

 1
 x    1
 2 
L
1
  x   1 
C 1   i(t )
R   x2   C 
 
0
L
Matrix A
State Space 1 - Hany Ferdinando
Matrix B
9
General Form of SS
x  Ax  Bu
y  C x  Du
State Space 1 - Hany Ferdinando
10
Signal Flow Graph (revisited)
Sum of the forward-path
factors
P

G ( s) 
1  L
k
k
N
q 1
q
Sum of the feedback loop
factors
State Space 1 - Hany Ferdinando
11
Signal Flow Graph State
From G(s) get the order of the equation
Make the denominator of G(s) in the
form of 1-(sum of the feedback loop) by
dividing G(s) with sn (n is the order of
G(s))
Draw the new SFG
State Space 1 - Hany Ferdinando
12
Example
b3 s  b2 s  b1 s  b0
G (s)  4
s  a3 s 3  a 2 s 2  a1 s  a 0
3
2
b3 s 1  b2 s  2  b1 s 3  b0 s  4
G (s) 
1
2
3
4
1  a3 s  a 2 s  a1 s  a 0 s
State Space 1 - Hany Ferdinando
13
Example
b3
1/s
U(s)
x4
-a3
1/s
-a2
b2
1/s
x3
b1
1/s
x2
x1
b0
Y(s)
-a1
-a0
Phase Variable Format
State Space 1 - Hany Ferdinando
14
Example
x2  x3
x1  x 2
x3  x4
x4  u  a3 x4  a2 x3  a1 x2  a0 x1
 x1   0
 x   0
 2  
 x 3   0
  
 x 4   a 0
1
0
0
1
0
0
 a1
 a2
0   x1  0
0   x 2  0
  u (t )
1   x 3  0 
   
 a3   x 4  1
State Space 1 - Hany Ferdinando
15
Example
b3
b2
b1
1/s
U(s)
x4
1/s
b0
1/s
x3
-a2
-a0
1/s
x2
-a3
x1
Y(s)
-a1
Input Feedforward Format
State Space 1 - Hany Ferdinando
16
Example
x1  a3 x1  x2  b3u
x 2  a2 x1  x3  b2 u
 x1    a3
 x   a
 2   2
 x 3    a1
  
 x 4   a 0
x 3  a1 x1  x4  b1u
x 4  a0 x1  b0 u
1 0 0  x1  b3 
0 1 0  x 2  b2 

u (t )
0 0 1  x3   b1 
   
0 0 0  x 4  b0 
State Space 1 - Hany Ferdinando
17
TF from SS
G( s)  C( s)B
1
(s) 
sI  A
CB
G (s) 
sI  A
State Space 1 - Hany Ferdinando
18
SS in Matlab (basic)
Use two functions:
tf2ss to convert transfer function model
into state space model
ss2tf to convert state space model into
transfer function model
State Space 1 - Hany Ferdinando
19