System Analysis and Design Overview
System Analysis and Design Overview
Chapter 1
Introduction
Design procedure
Control problem 1
Assume that you are given a robot car. You are asked to design an automatic
controller for driving the car at a constant speed regardless of the road condition.
How many steps do you think to solve this problem?
Design procedure
Control problem 1
Design procedure
Control problem 1
Design procedure
Control problem 1
Design procedure
Control problem 1
Design procedure
Control problem 1
Inputs Outputs
Design procedure
Plant
Design procedure
Control without measurement
???
???
???
Design procedure
Control with measurements
Speed
sensor
???
???
???
Design procedure
Control with measurements
Speed
sensor
???
???
???
Design procedure
Control problem 1
What you should do? How many steps? Which ones?
Design procedure
Control problem 1
Step 1. ...
Step 2. ...
...
Step n. ...
Design procedure
Control problem 2
Assume that you are a CEO of a new company. It is required that your company
must produce at least 1000 products each month.
What you should do before running the company if you know nothing about the
company in advance?
Design procedure
Control problem 2
???
Design procedure
Control problem 2
Board
supervisor
Design procedure
Control problem 2
Step 1. ...
Step 2. ...
...
Step n. ...
Design procedure
General plant
Disturbances
Design procedure
General control system
Disturbances
Sensors Noises
Design procedure
General question
There are how many steps on the process of control system design?
Design procedure
1. Study the system plant to be controlled and obtain initial information about
the control objectives.
2. Model the system and simplify the model if necessary
3. Analyze the resulting model determine its properties
4. Decide which variables are to be controlled controlled outputs
5. Decide on the measurements and manipulated variables what sensors and ac-
tuators will be used and where will they be placed.
6. Select the control configuration.
7. Decide on the type of controller to be used.
8. Decide on performance specifications based on the overall control objectives.
9. Design a controller.
10. Analyze the resulting controlled system to see if the specifications are satisfied
and if they are not satisfied modify the specifications or the type of controller.
11. Simulate the resulting controlled system either on a computer or a pilot plant.
12. Repeat from step 1 if necessary.
Nguyen Tien Hung (TNUT) System analysis Academic year 2023-2024 22 / 75
Introduction 1.1 System analysis and design
Design procedure
Predator-prey models
Consider the ”natural” growth rate and the ”carrying capacity” of the environment.
Suppose that there are only 2 types of animals: the predator (foxes) and the prey
(rabbits). They form a simple food-chain where the predator species hunts the prey
species, while the prey grazes vegetation.
The growth rate of rabbits is positive for zero fox, but decreases with increasing of
foxes. Besides, the growth rate of foxes is negative for zero rabbit, but increases
with increasing of rabbits.
Predator-prey models
Let y1 denote the number of rabbits (prey), let y2 denote the number of foxes
(predator). The population growth is described by
ẏ1 = α1 y1
ẏ2 = α2 y2
Here the growth rate α1 for rabbits is positive for y2 = 0, but decreases with
increasing y2 . The growth rate α2 for foxes is negative for y1 = 0, but increases
with increasing y1 .
Predator-prey models
Let
α1 = 1 − 0.01y2
α2 = −1 + 0.02y1
or
ẏ1 = y1 − 0.01y1 y2
ẏ2 = −y2 + 0.02y2 y1
Predator-prey models
t0 = 0;
tfinal = 15;
y0 = [20; 20];
[t,y] = ode23(@lotka,[t0 tfinal],y0);
figure(1)
plot(t,y)
title('Predator/Prey populations over time')
xlabel('Time')
ylabel('Population')
legend('Prey','Predators','Location','North')
grid on;
Predator-prey models
250
Population
200
150
100
50
0
0 5 10 15
Time
Predator-prey models
figure(2)
plot(y(:,1),y(:,2))
title('Phase plane Plot')
xlabel('Prey population')
ylabel('Predator population')
grid on;
Predator-prey models
300
Predator population
250
200
150
100
50
0
0 50 100 150 200
Prey population
L Note
In the case of a linear, time-varying differential equation, the dependent variable
and its derivatives appear as linear combinations, but a coefficient or coefficients of
terms may involve the independent variable. For example:
d2 x
+ (1 − cos2t)x = 0
dt2
d2 x dx
+ (x2 − 1) +x=0
dt2 2 dt
d x dx
+ + x + x3 = sinωt
dt2 dt
Linear systems: For linear systems, the equations that constitute the model
are linear. The most important property of linear systems is that the principle
of superposition is applicable.
Nonlinear systems: For nonlinear systems, the equations that constitute the
model are nonlinear. The most important characteristic is that the principle of
superposition is not applicable. In general, procedures for finding the solutions
of problems involving such systems are extremely complicated.
Mathematical models
Any attempt to design a system must begin with a prediction of its performance
before the system itself can be designed in detail or actually built. Such prediction
is based on a mathematical description of the system’s dynamic characteristics.
This mathematical description is called a mathematical model. For many physical
systems, useful mathematical models are described in terms of differential equations.
Example 1.1
Consider the mechanical system shown below. The displacement y of the mass m is
measured from the equilibrium position, b is the damper constant and k the spring
constant. In this system, the external force F (t) is the input and y is the output.
Find mathematical model of the system.
Solution:
The system equation is
mÿ + bẏ + ky = u
and the block diagram is as follows
+ + + +
Example 1.2
Let us consider the magnetic-ball suspension system
Example 1.3
The electrical behavior of a separately excited DC machine can be expressed by the
following equation:
dia
va = ea + Ra ia + La
dt
where ea = Km Φn is the back-electromotive force (EMF), Φ is the machine excited
field flux, Te = Km Φia is the electrical torque, TL is the load torque, va is the
terminal voltage, Ra is the armature resistance, La is the armature inductance, ia
is the armature current, respectively.
The mechanical behavior of the separately excited DC machine is described by the
following equation:
dn 1
= (Te − TL )
dt 2πJ
where n is the rotor speed, J is the inertial torque of the machine, respectively.
System analysis
Since any system is made up of components, analysis must start by developing a
mathematical model for each component and combining all the models in order
to build a model of the complete system. Once the latter model is obtained, the
analysis may be formulated in such a way that system parameters in the model are
varied to produce a number of solutions. One then compares these solutions and
interprets and applies the results to the basic task.
System design
System design refers to the process of finding a system that accomplishes a given
task. In general, the design procedure is not straightforward and will require trial
and error.
Synthesis
Synthesis is the use of an explicit procedure to find a system that will perform in a
specified way. Here the desired system characteristics are postulated at the outset,
and then various mathematical techniques are used to synthesize a system having
those characteristics. Generally, such a procedure is completely mathematical from
the start to the end of the design process.
Implementation
Implementation can mean different things in different industries. In control engi-
neering, the word implementation usually refers to the action that one must follow
in order to make something actually happen such as installing new hardware, soft-
ware, or application.
Implementation
Implementation can mean different things in different industries. In control engi-
neering, the word implementation usually refers to the action that one must follow
in order to make something actually happen such as installing new hardware, soft-
ware, or application.
DC motor control
Problem formulation
Design a proportional speed controller for a DC motor with angular angle θ, moment
of inertia J = 0.1(Kg/m2 ), friction coefficient B = 0.05, armature resistance
Ra = 1.32(Ω), armature inductance La = 0.15(H), torque coefficient Km = 0.1,
electromotive coefficient Ke = 0.1, electromotive force em = Ke dθdt (V ).
+
M
-
+ -
DC motor control
Step 1. Study the system plant to be controlled and obtain initial information
about the control objectives.
DC motor control
Step 2. Model the system and simplify the model if necessary.
The torque equation (Chapter 2)
d2 θ(t) dθ(t)
J +B = Km ia (t)
dt2 dt
The voltage equation (Chapter 2)
dia (t)
vs (t) = Ra ia (t) + La + em (t)
dt
The motor transfer function is (Chapter 3, 4)
Ω(s) Km
Gm (s) = =
Vs (s) (La s + Ra )(Js + B) + Ke Km
where Ω(s) = sΘ(s), Θ(s) = L[θ(t)].
1
⇒ Gm (s) =
0.15s2 + 1.395s + 0.76
Nguyen Tien Hung (TNUT) System analysis Academic year 2023-2024 54 / 75
Introduction An example of system analysis and design
DC motor control
Step 3. Analyze the resulting model determine its properties.
DC motor control
Step 4. Decide which variables are to be controlled outputs.
The controlled output is the motor angular speed (single output).
DC motor control
Step 5. Decide on the measurements and manipulated variables what sen-
sors and actuators will be used and where will they be placed.
A velocity sensor should be used to measure the angular speed of the motor. It
should be installed on the shaft.
DC motor control
Step 6. Select the control configuration.
+
-
Controller DC motor
DC motor control
Step 7. Decide on the type of controller to be used.
Test with Proportional controller (P).
DC motor control
Step 8. Decide on performance specifications based on the overall control
objectives.
DC motor control
Step 9. Design a controller.
When the proportional controller Kp = 12.4 is applied to the closed-loop system
(Chapter 7).
DC motor control
Step 10. Analyze the resulting controlled system to see if the specifications
are satisfied and if they are not satisfied modify the specifications or the
type of controller.
The steady-state error is (Chapter 7)
1 1
ess = b0
= 1 = 0.058
1 + Kp a0 1 + 12.4 0.76
DC motor control
Step response
1.2
0.8
Magnitude
0.6
0.4
0.2
0
0 0.5 1 1.5 2
Times (s)
DC motor control
Remark 1.1
The steady-state is not satisfied.
Less oscillations.
DC motor control
When the proportional controller Kp = 200.0 is applied to the closed-loop system
the steady-state error is
1 1
ess = = 1 = 0.0038
1 + Kp ab00 1 + 200 0.76
DC motor control
Step response
2
1.5
Magnitude
0.5
0
0 0.5 1 1.5 2
Times (s)
DC motor control
Remark 1.2
The steady-state is small.
More oscillations.
One can now test with another type of the controller.
DC motor control
Test with PID controller (Kp = 12.4, Ki = 25, Kd = 1.54) (Chapter 7).
Step response
1.2
1
Magnitude
0.8
0.6
0.4
0.2
0
0 0.5 1 1.5 2 2.5
Times (s)
DC motor control
Remark 1.3
The steady-state is zero.
No oscillation.
DC motor control
Step 11. Simulate the resulting controlled system either on a computer or
a pilot plant.
DC motor control
Matlab code:
J = 0.1;
B = 0.05;
Km = 0.1;
Ke = 0.1;
Ra = 1.32;
La = 0.15;
num = Km;
den = [(J*La) ((J*Ra)+(La*B)) ((B*Ra)+Km*Ke)];
Kp = 12.4;
Ki = 25;
Kd = 1.54;
DC motor control
Code
numc = [Kd, Kp, Ki];
denc = [1 0];
numa = conv(num,numc);
dena = conv(den,denc);
[numac,denac] = cloop(numa,dena);
sysac = tf(numac,denac);
figure(1);
bode(sysac)
grid on
figure(2);
step(numac,denac)
grid on
DC motor control
Step 12. Repeat from step 1 if necessary.
It is not necessary.
DC motor control
Step 13. Choose hardware and software and implement the controller.
You can choose them yourself.
DC motor control
Step 14. Test and validate the control system and tune the controller online
if necessary.
You can test it yourself.