0% found this document useful (0 votes)
66 views8 pages

01 State Space Introduction

The document introduces state space models for modeling systems. It discusses representing systems using sets of first-order differential equations called state equations rather than higher-order equations. The state variables completely describe the system and are usually related to how energy is stored. Examples are provided to illustrate obtaining state equations from physical laws governing systems.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
66 views8 pages

01 State Space Introduction

The document introduces state space models for modeling systems. It discusses representing systems using sets of first-order differential equations called state equations rather than higher-order equations. The state variables completely describe the system and are usually related to how energy is stored. Examples are provided to illustrate obtaining state equations from physical laws governing systems.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

Introduction to State Space Models

The State Space Approach to Modeling Systems


A system model is necessary before any analysis or design of control system can be done. Mathematical models of systems can
be found by the application of one or more fundamental laws peculiar to the physical nature of the system or component.
Alternatively, experimental methods may be used. Two approaches can be used when modeling control systems. These are the
classical control theory and the modern control theory.

The classical theory of modeling systems involves representing a system using a differential equation that relates the system
output to the system input. The differential equation can be transformed into an algebraic expression in the s-domain (by
Laplace Transforms). This method is more applicable to SISO systems. The classical control theory was covered in the previous
Control Engineering course.

The modern control theory, which is also known as the state space or state variable approach, involves use of a set of first order
differential equations and matrix algebra. The system behavior is represented by several variables called states. The models are
then in the form of a set of first order differential equations. Each differential equation relates the first derivative of a state to
the states and the inputs to the system. To work on the models compactly, matrix algebra is exploited. Though the state space
approach is applicable to SISO systems, it finds important applications in multivariable systems. State space approach is the
subject of part of this course on Control Engineering.

Illustrative Examples
The following examples illustrate the concept of states as well as how state equations can be obtained from the Physical Laws
governing a system.

Example 1.1
Consider the system shown in figure 1.1.

θ l

Figure 1.1

Suppose the states for the system are chosen as the angular position, θ(t) and angular velocity of the pendulum 𝜃̇ (𝑡). Let the
states be denoted x1 and x2 respectively. Taking first derivatives of the states:
𝑥̇ 1 (𝑡) = 𝜃̇ (𝑡) = 𝑥2 (𝑡)
𝑔
𝑥̇ 2 (𝑡) = 𝑥̈ (𝑡) = − 𝑙 𝑥2 (𝑡)

Thus, basically state equations as they are known express relations between the first derivatives of the states with the states.

In the example, the first expression comes out from the fact that the first derivative of the first state is the angular velocity
which is the second state. The second expression is obtained by applying fundamental Laws governing the operation of the
pendulum so as to get the expression for the first derivative of the second state in terms of the states.

Example 1.2
Consider the circuit shown in figure 1.2.
1
L R2

v1(t) R1 C v2(t)
+

Figure 1.5

Let the states be x1 for current through inductor and x2 for voltage across the capacitor (reasons for this choice will be highlighted
in later topics). v1 and v2 are inputs to the circuit and y is the output which is voltage across R2. Using the fundamental laws of
circuit analysis, the state equations are derived as follows:
From loop 1,
𝑣𝑅1 − 𝑣𝐿 − 𝑣𝐶 = 0
𝑣1 − 𝑣𝐿 − 𝑣𝐶 = 0
𝑑𝑖
𝑣1 − 𝐿 𝑑𝑡𝐿 − 𝑣𝐶 = 0
𝑣1 − 𝐿𝑥̇ 1 − 𝑥2 = 0
𝑥2 𝑣1
Hence, 𝑥̇ 1 = − 𝐿
+ 𝐿

From loop 2,
𝑣𝐶 − 𝑣𝑅2 − 𝑣2 = 0
𝑣𝐶 − (𝑖𝐿 − 𝑖𝐶 )𝑅2 + 𝑣2 = 0
𝑑𝑣
𝑣𝐶 − (𝑖𝐿 − 𝐶 𝑑𝑡𝐶 )𝑅2 − 𝑣2 = 0
𝑥2 − (𝑥1 − 𝐶𝑥̇ 2 )𝑅2 − 𝑣2 = 0
𝑥 𝑥 𝑣
Hence, 𝑥̇ 2 = 𝑅 1𝐶 − 𝑅 2𝐶 + 𝑅 2𝐶
2 2 2

The output is given by


𝑣𝑅2 = 𝑣𝐶 − 𝑣2

Hence, 𝑦 = 𝑥2 − 𝑣2

The equations can be expressed in a compact form as matrices as follows:


1 1
𝑥̇ 1 0 − 𝐿 𝑥1 0 𝑣1
𝐿
[ ]=[ 1
𝑥̇ 2 1 ] [𝑥 ] − [ 1 ] [𝑣 ]
− 2 0 2
𝑅2 𝐶 𝑅2 𝐶 𝑅2 𝐶

𝑥1 𝑣1
𝑦 = [0 1] [𝑥 ] + [0 1] [𝑣 ]
2 2

Choice of states
The procedure of formulating the state variable system begins with the selection of a set of state variables. This set of variables
must completely describe the effect of the past history of the system and its response in the future. Although the choice of state
variables is not unique, the state variables of a dynamic system are usually related to the energy stored in each of the system’s
energy-storing elements. Since any energy that is initially stored in these elements can affect the response of the system at a
later time, one state variable is normally associated with each of the independent energy storing elements.

For example, the potential and kinetic energy are stored in position and velocity, respectively. Consequently, position and
velocity make appropriate choices for state variables in translational and rotational mechanical systems. For electrical circuits
energy is stored in inductors and capacitors, thus capacitor voltage and inductor current are usually chosen as the state variables
in such systems.

2
Notes
1. Choice of state variables is not always straightforward.
2. In most situations more than one set of valid state variables are possible.

Deriving State Equations from Differential Equations


The process of converting differential equations to state space equations is illustrated using Example 1.3.

Example 1.3
Consider the following differential equation (DE):
𝑑3 𝑦 𝑑2 𝑦 𝑑𝑦
+ 𝑎2 𝑑𝑡 2 + 𝑎1 𝑑𝑡 + 𝑎0 𝑦 = 𝑢
𝑑𝑡 3

This has a transfer function (TF):


𝑌(𝑠) 1
𝐺 (𝑠) = 𝑈(𝑠) = 𝑠 3+𝑎 𝑠 2+𝑎
2 1 𝑠+𝑎0

If the following states are chosen:


𝑑𝑦 𝑑2 𝑦
𝑥1 = 𝑦, 𝑥2 = 𝑦̇ , 𝑥3 = 𝑦̈ , where 𝑦̇ = and 𝑦̈ =
𝑑𝑡 𝑑𝑡 2

For a translational mechanical system, these states may represent the position, velocity and acceleration of a body.

Using these states and relating the first derivatives to the states, the following first order equations can be written:
𝑥̇ 1 = 𝑥2
𝑥̇ 2 = 𝑥3
𝑥̇ 3 = −𝑎0 𝑥1 − 𝑎1 𝑥2 − 𝑎2 𝑥3 + 𝑢

The DE can, thus, be represented in the following matrix form:


𝑥̇ 1 0 1 0 𝑥1 0
[𝑥̇ 2 ] = [ 0 0 𝑥
1 ] [ 2 ] + [0 ] 𝑢
𝑥̇ 3 −𝑎0 −𝑎1 −𝑎2 𝑥3 1
𝑥1 0
𝑦 = [1 0 0 ] [𝑥 2 ] + [0 ] 𝑢
𝑥3 1

The state space approach to modelling, thus, can be said to work by replacing high order differential equations with a set of
simultaneous first order differential equations.

General format of State Space Equations


The general form of the state-space equations is as follows:
𝑥̇ ̅ (𝑡) = 𝐴̅𝑥̅ (𝑡) + 𝐵̅𝑢̅(𝑡) (1)
𝑦̅(𝑡) = 𝐶̅ 𝑥̅ (𝑡) + 𝐷 ̅ 𝑢̅(𝑡) (2)

where
𝑥̅ (𝑡)𝑇 = [𝑥̅1 (𝑡) 𝑥̅ 2 (𝑡) ⋯ 𝑥̅ 𝑛 (𝑡)] is the state vector
𝑢̅(𝑡)𝑇 = [𝑢̅1 (𝑡) 𝑢̅2 (𝑡) ⋯ 𝑢̅𝑝 (𝑡)] is the input vector
𝑦̅(𝑡)𝑇 = [𝑦̅1 (𝑡) 𝑦̅2 (𝑡) ⋯ 𝑦̅𝑞 (𝑡)] is the output vector

𝐴̅ is a 𝑛 × 𝑛 matrix
𝐵̅ is a 𝑛 × 𝑝 matrix
𝐶̅ is a 𝑞 × 𝑛 matrix
𝐷̅ is a 𝑞 × 𝑝 matrix

The above two matrix equations are known as the state-space equations or the state-variable equations.

Notes on SS equations
1. If the system is discrete-time the equations are basically the same but based on first order difference equations rather than
first order differential equations.
3
2. If the dynamic system is time-varying then 𝐴̅, 𝐵̅, 𝐶̅ and 𝐷̅ are time varying and are denoted by 𝐴̅(𝑡), 𝐵̅(𝑡), 𝐶̅ (𝑡) and 𝐷
̅ (𝑡).
3. The equations can be modified to represent non-linear systems.
4. The equations include all types of multivariable systems:
SISO (single-input single-output) 𝑝 = 𝑞 = 1
MISO (multi-input single-output) 𝑞 = 1
SIMO (single-input multi-output) 𝑝 = 1
MIMO (multi-input multi-output)
5. If 𝑛 is 1, 2 or 3 then the state can be represented (and visualised) geometrically in 1, 2 or 3-dimensional Cartesian space.

Transfer Function from State Space representation

Laplace domain equivalent of State Space equations


Taking the Laplace transform of the SS equations (1) and (2) above gives:
𝑠𝑋̅ (𝑠) − 𝑥̅ (0) = 𝐴̅𝑋̅ (𝑠) + 𝐵̅𝑈
̅ (𝑠 ) (3)
𝑌̅(𝑠) = 𝐶̅ 𝑋̅ (𝑠) + 𝐷
̅𝑈̅ (𝑠 ) (4)

Equation (3) can be rearranged to give:


(𝑠𝐼 ̅ − 𝐴̅)𝑋̅(𝑠) = 𝑥̅ (0) + 𝐵̅𝑈
̅ (𝑠 )

thus:
𝑋̅(𝑠) = (𝑠𝐼 ̅ − 𝐴̅)−1 𝑥̅ (0) + (𝑠𝐼 ̅ − 𝐴̅)−1 𝐵̅ 𝑈
̅ (𝑠 ) (5)
zero input response zero state response

and substituting this into equation 4 gives:


𝑌̅(𝑠) = 𝐶̅ (𝑠𝐼 ̅ − 𝐴̅)−1 𝑥̅ (0) + [𝐶̅ (𝑠𝐼 ̅ − 𝐴̅)−1 𝐵̅ + 𝐷
̅ ]𝑈
̅ (𝑠 ) (6)
zero input response zero state response

In equations (5) and (6), the first terms represent the zero input response and the second terms represents the zero state response.

Transfer Function
Using equation (6) and ignoring zero input response, the transfer function matrix 𝐺(𝑠) can be obtained as follows:
𝑌̅ (𝑠)
𝐺 (𝑠 ) = = 𝐶̅ (𝑠𝐼 ̅ − 𝐴̅)−1 𝐵̅ + 𝐷
̅ (𝑠)
̅ (9)
𝑈

𝑎𝑑𝑗[𝑠𝐼 ̅−𝐴̅]
It can be observed that [𝑠𝐼 ̅ − 𝐴̅]−1 = ̅ ̅]
. The TF can therefore, be represented by:
𝑑𝑒𝑡[𝑠𝐼 −𝐴
𝐶̅ 𝑎𝑑𝑗[𝑠𝐼 ̅−𝐴̅]𝐵̅
𝐺 (𝑠 ) = ̅
+𝐷 (10)
̅ 𝐴̅]
𝑑𝑒𝑡[𝑠𝐼 −

Characteristic Equation and Eigenvalues


The characteristic polynomial of the system is given by 𝒅𝒆𝒕[𝒔𝑰̅ − 𝑨
̅ ] and the characteristic equation is given 𝒅𝒆𝒕[𝒔𝑰̅ − 𝑨
̅ ] = 𝟎.
The roots of the characteristic equation are known as the eigenvalues of the system.

Example 1.4
0 1 0
Suppose in a system, 𝐴̅ = [ 0 0 1 ], find the TF and the eigenvalues of the system.
−15 −23 −9

SOLUTION
𝑠 −1 0
[𝑠𝐼 ̅ − 𝐴̅] = [ 0 𝑠 −1 ]
15 23 𝑠+9

𝑑𝑒𝑡[𝑠𝐼 ̅ − 𝐴̅] = 𝑠(𝑠(𝑠 + 9) + 23) + 1(0(𝑠 + 9) + 15)


= 𝑠 3 + 9𝑠 2 + 23𝑠 + 15

The characteristic equation is: 𝑠 3 + 9𝑠 2 + 23𝑠 + 15 = 0

4
From solution of the characteristic equation, the eigenvalues are: 𝜆1 = −1, 𝜆2 = −3 and 𝜆3 = −5.

Minimal and Non-minimal Systems


A state variable equation is minimal if the number of its eigenvalues equals the number of poles in its transfer function. Every
eigenvalue of a minimal state variable equation will appear as a pole of its transfer function and there is no essential difference
between using the state variable equation or its transfer function for studying the system. In such a system the state variable
equations are said to be completely characterized by its transfer function.

If a state variable equation is not minimal then some of the eigenvalues will not appear as poles of its transfer function and the
transfer function is said to have missing poles. In such systems the state variable equations cannot be completely characterized
by the transfer function and consequently the system cannot be fully analyzed using the transfer function approach.

Eigenvectors
Associated with each eigenvalue 𝜆𝑖 , there is an associated eigenvector 𝑥̅ 𝑖 given by:
[𝜆𝑖 𝐼 ̅ − 𝐴̅]𝑥̅ 𝑖 = 0̅ (11)

No eigenvector is unique as it can always be multiplied by a scalar and still satisfy equation (11). The following example shows
the determination of the eigenvectors of a simple two state system.

Example 1.5
−1 0
𝐴̅ = [ ]
1 −2

Characteristic equation: |𝑠𝐼 ̅ − 𝐴̅| = 0


𝑠+1 0
| |=0
−1 𝑠 + 2
(𝑠 + 1)(𝑠 + 2) = 0

Eigenvalues: 𝜆1 = −1, 𝜆2 = −2

Eigenvector 1:
1 0 −1 0
[(−1) [ ]−[ ]] 𝑥̅ = 0
0 1 1 −2 1

0 0 𝑥11
[ ][ ] = 0
−1 1 𝑥21

Equating elements of matrices gives:


𝑥11 + 𝑥21 = 0
𝑥11 = 𝑥21
1 2 3 1
One eigenvector for 𝜆1 = −1 would be[ ] but[ ], [ ] or any vector 𝜌 [ ] where 𝜌 is a real scalar would also be valid.
1 2 3 1

Eigenvector 2:
1 0 −1 0
[(−2) [ ]−[ ]] 𝑥̅ = 0
0 1 1 −2 2

−1 0 𝑥12
[ ][ ] = 0
−1 0 𝑥22

Equating elements of matrices gives:


−𝑥12 = 0
−𝑥22 = 𝜌 {non-zero 𝑥̅ 𝑖 normally used}

0 0 0 0
One eigenvector for 𝜆1 = −2 would be[ ] but[ ], [ ] or any vector 𝜌 [ ] where 𝜌 is a real scalar would also be valid.
1 2 −3 1

5
Notes
Eigenvectors are essentially vectors that specify the direction of something. One use of eigenvectors in state space analysis is
to transform state space representations from one form to another and this will become apparent in future topics as will the
reason for the subscript notation used above.

Eigenvectors also provide a useful visual insight into the state trajectory determined from the state transition matrix. The
eigenvalues give the exponential modes of the system and the eigenvectors specify the distribution of the modes between the
states.

Diagrammatic representations
SS systems are often represented diagrammatically using a notation based on the now largely redundant analogue computer.
These diagrams consist of a combination of three components: an integrator, a summer and a coefficient multiplier. This
notation is useful as it enables the dynamic system to be represented by what is essentially an analogue circuit. The three
components are shown in figures 1.6 (a) to 1.6 (c).

f2(0)
𝑇
𝑓𝑜 (𝑡) = න 𝑓1 (𝑡)𝑑𝑡 + 𝑓2 (0)
f2(t) fo(t)
∫ 0

(b) integrator - the initial condition, f2(0) is often omitted if it is zero

f1(t)
f2(t)

+
+
f3(t) fo(t) 𝑓𝑜 (𝑡) = 𝑓1 (𝑡) + 𝑓2 (𝑡) − 𝑓3 (𝑡)
-

(b) summer

f1(t) fo(t) 𝑓𝑜 (𝑡) = 𝐾𝑓1 (𝑡)


K

(c) coefficient multiplier

𝑓1̅ (𝑡) ̅
𝑲 𝑓𝑜̅ (𝑡) 𝑓𝑜̅ (𝑡) = 𝐾𝑓1̅ (𝑡)

(d) vector coefficient multiplier

Figure 1.6 Block diagram symbols

Example 1.6
𝑑3 𝑦 𝑑2 𝑦 𝑑𝑦
Figure 1.7 shows a block diagram representing the 3rd order (3 state) DE with the TF: 𝑑𝑡 3 + 9 𝑑𝑡 2 + 8 𝑑𝑡 + 5𝑦 = 𝑢.
𝑑3 𝑦 𝑑2 𝑦 𝑑𝑦
The equation can be rewritten as: = 𝑢 − 9 𝑑𝑡 2 − 8 𝑑𝑡 − 5𝑦 = 𝑢 − 9𝑥3 − 8𝑥2 − 5𝑥1 .
𝑑𝑡 3

6
𝑢 𝑥̇ 3 𝑥3 = 𝑥̇ 2 𝑥2 = 𝑥̇1
+ ∫ ∫ ∫
-
- -
𝑥3
9 𝑥2
𝑥1
8

Figure 1.7

The above notation is based on fn(t) being a scalar. A similar notation however can be used for vector signals, i.e. 𝑓𝑜̅ (𝑡). The
principle change to the notation is the coefficient multiplier which becomes as shown in figure 1.7 (c), where
̅ is a vector of real numbers.
𝑲

Using the vector-based diagram notation the SS equations (equations 1 and 2) can be represented by the diagram shown in
figure 1.8.

̅
𝐷

+
𝑢̅(𝑡) + 𝑥̇ ̅ (𝑡) 𝑥̅ (𝑡) + 𝑦̅(𝑡)
𝐵̅ ∫ 𝐶̅
+

𝐴̅

Figure 1.8

Major differences between LTF and state-space models


1. A LTF model relates only the system output and input. Any internal structure and behavior of the system is lost. State-
space representations can preserve such internal information, if the state variables are appropriately chosen.
2. When working with LTFs, one may have to solve high order equations. In the state space approach, only first order
equations appear in the model.
3. The LTF approach only easily applicable to SISO systems, though more recent techniques (e.g. inverse Nyquist arrays)
are now available for MIMO systems. In the state space approach, the system model is arranged in a vector-matrix
form. It therefore matters little how many inputs or outputs a system has, the matrices just change in size.
4. A LTF model is only defined for zero initial conditions. The initial conditions may be represented as disturbance
inputs. The state space approach uses the differential equations directly, so all initial conditions are automatically
included and are simply set to zero if not required.
5. The state space model may handle time-varying models whereas a LTF model is only for stationary systems.

But there are drawbacks to state-space models, some of which can be serious:

1. Many processes involve pure time delays which are difficult to handle using continuous-time state-space models.
2. The methods of control system design based on frequency-domain models are true design methods. A controller is
designed, its effects investigated and is then refined until the results appear acceptable. Good results can be obtained
with poorly modelled plants and unexpected disturbances. Control system design using state-space models, on the
other hand, tends to use synthesis methods. That is to say, an algorithm will exist for designing a certain kind of
controller (these will be studied later). The designer simply plugs the system model (𝐴̅, 𝐵̅, 𝐶̅ and 𝐷
̅ ) into the algorithm,
and out comes the design of the controller – it is synthesized from the model parameters; hence a very good plant
model is required. In practice, it is hard to get good models of many industrial plants.

These factors, together with the observation that frequency-domain control seems able to cope with the majority of real control
problems have led to a generally slow rate of introduction of state-space techniques.

7
Chapter 1 Tutorial Questions
1. Derive the state matrices for the following electrical circuit.

x1 x2 x3 Vo x4

L R R R
V1 q C C C V2

where
x  x1 x4  u  V1 0 0 V2 
T
x2 x3
and
x1 is a current; x2, x3 and x4 are voltages.

If the output quantities are the voltage vo and q, determine the output matrix C in the output equation:
v o 
 q   Cx
 

  0 1 0 0   1 
  L  0 0 0
  L 
 1 C  1 CR 1 CR 0   0 0 0 
0 0 0 1  1
A    B 
 1 2 1   C  0 C 0 0 
 0 CR   
0 0 0 0
  
 
CR CR
 0 0 1  2   0 0 0 1 
CR 
  CR CR  

2. The system with:


0 1  1 2 
A B
  5  2 
0 1 

is to be held at x1 = x2 = 1. Determine the required values of u1 and u2. Make a block diagram of the system and check
that the results are correct in the diagram. (u1 = -15; u2 = 7)

3. For the system:


x  Ax  B u
y  Cx
 1 1 0 0 
  1 1  B  1
where A 0 C  1 0 1
 6  11  7 1

obtain the characteristic equation and thus determine the eigenvalues. Draw the state block diagram.

Ans : s 3  9s 2  26s  24  0; 1  2;  2  3; 3  4 
4. Find the characteristic equation for the following:
  a1 1 0  0 0  a 3 
(a) A   a 2 0 1 (b) A  1 0  a 2 
  a 3 0 0 0 1  a1 

s 3
 a1 s 2  a 2 s  a3  s 3
 a1 s 2  a 2 s  a3 
5. For the following A matrices determine the eigenvalues and suggest suitable eigenvectors:
0 1  1 4  1 2  3 0 
(a)   (b)   (c)   (d)  
 6  5  4  1 0 3  1  2
8

You might also like