6/28/2022
8024103-3
AUTOMATIC CONTROL
SYSTEMS
Lecture Note 3: Mathematical modeling
Instructor
Ahmed Al Otaibi, Ph.D.
Dept. of Mechanical Engineering
Taif University
1
6/28/2022
Mathematical Modelling
We use mathematical models of physical systems to
design and analyze control systems. The dynamic
behavior is generally described by ordinary
differential equations.
We will consider a wide range of systems, including
mechanical, hydraulic, and electrical. Since most
physical systems are nonlinear, we will discuss
linearization approximations, which allow us to use
Laplace transform methods.
Six Step Approach to Dynamic System
Problems
⚫ Define the system and its components
⚫ Formulate the mathematical model and list the
necessary assumptions
⚫ Write the differential equations describing the model
⚫ Solve the equations for the desired output variables
⚫ Examine the solutions and the assumptions
⚫ If necessary, reanalyze or redesign the system
2
6/28/2022
Mathematical Modelling
⚫ For any system we need to be able to
describe mathematically how the output y(t)
depends on the input u(t)
u y
Input Output
System
u(t) y(t)
t t
⚫ How to calculate y(t) from u(t)?
Concept
⚫ A mathematical model of a system consists
of the governing equations (or equations of
motion) that completely describe the
behaviour of the system.
⚫ The governing equations are derived from the
laws of physics for the system under
consideration.
3
6/28/2022
MECHANICAL SYSTEMS
TRANSFER FUNTIONS
Torque-angular velocity, torque-angular displacement,
and impedance rotational relationships for springs,
viscous dampers, and inertia
4
6/28/2022
Spring-mass-damper system
⚫ This simple model can represent various engineering
systems, e.g. a car suspension.
Example 2.1 :
Governing Equations f = ma
x
b dx(t ) d 2 x(t )
f
f (t ) − kx(t ) − b =m
m dt dt 2
k
mx(t ) + bx (t ) + kx(t ) = f (t )
FBD x displacement
(output)
damper force
bx f applied force
(input)
m
kx
spring force
Example 2.2 : A mechanism
Define: input → F ,output → y. We have:
2
dy d y
F − ky − f=m 2
F k dt d t
d2y dy
m m 2 +f + ky = F
dt dt
y
f
10
5
6/28/2022
Voltage-current, voltage-charge, and
impedance relationships for capacitors,
resistors, and inductors
11
12
6
6/28/2022
13
Differential Equation of Physical Systems
Electrical Resistance Describing Eq. Energy of power
1 1 2
i v 21 P v 21
R R
Translational Damper
2
F b v 21 P b v 21
Rotational Damper
2
T b 21 P b 21
Fluid Resistance
1 1 2
Q P21 P P21
Rf Rf
Thermal Resistance
1 1
q T21 P T21
Rt Rt
14
7
6/28/2022
15
DC Motor Speed: System
Modeling
⚫ A common actuator in control
systems is the DC motor.
⚫ It directly provides rotary motion
and, coupled with wheels or
drums and cables, can provide
translational motion.
⚫ The electric equivalent circuit of
the armature and the free-body
diagram of the rotor are shown in
the following figure.
Ref: https://ctms.engin.umich.edu/CTMS/index.php?example=MotorSpeed§ion=SystemModeling
16
8
6/28/2022
⚫ For this example, we will assume that the
input of the system is the voltage source (V)
applied to the motor's armature, while the
output is the rotational speed of the shaft 𝜃.ሶ
⚫ The rotor and shaft are assumed to be rigid.
We further assume a viscous friction model,
that is, the friction torque is proportional to
shaft angular velocity.
17
⚫ The physical parameters for our example are:
18
9
6/28/2022
DC Motor Speed: System Modeling
System equations
⚫ In general, the torque generated by a DC
motor is proportional to the armature current
and the strength of the magnetic field. In this
example we will assume that the magnetic
field is constant and, therefore, that the motor
torque is proportional to only the armature
current i by a constant factor 𝐾𝑡 as shown in
the equation below. This is referred to as an
armature-controlled motor.
𝑇 = 𝐾𝑡 𝑖
19
Cont.
⚫ The back emf, e, is proportional to the
angular velocity of the shaft by a constant
factor 𝐾𝑒 .
𝑒 = 𝐾𝑒 𝜃ሶ
⚫ In SI units, the motor torque and back emf
constants are equal, that is, 𝐾𝑡 = 𝐾𝑒 ;
therefore, we will use 𝐾 to represent both the
motor torque constant and the back emf
constant
20
10
6/28/2022
Cont.
⚫ From the figure above, we can derive the
following governing equations based on
Newton's 2nd law and Kirchhoff's voltage law.
⚫ Applying the Laplace transform, the above
modeling equations can be expressed in
terms of the Laplace variable s
21
Cont.
⚫ We arrive at the following open-loop transfer
function by eliminating I between the two
above equations, where the rotational speed
is considered the output and the armature
voltage is considered the input.
22
11
6/28/2022
Modeling a Process - Filling a
Tank
The tank above is filled at a flow rate of
Qin m3/sec which is the input to the system. The
output is the discharge flowrate, Qout m3/sec. If
Qin = Qout, the level, h, remains constant. If Qin >
Qout, the level, h, rises. If Qin < Qout, the level, h,
falls. This much is obvious but what exactly is
the relationship between the flow in, the flow out
and the level.
The following equation is a mass balance that can
be applied to any system:
In - Out = Accumulation
Ref: https://eleceng.dit.ie/gavin/Control/Modeling/Filling%20a%20Tank.htm
23
Cont.
In this case, the accumulation manifests itself as an increase or a decrease in
volume. Accumulation is the change in volume with time.
Qin - Qout = DV/Dt
Volume, V = area x height = A x h. The diameter, d, is a constant because the
walls of the tank are vertical and parallel. Therefore, h is the only variable which
means that DV = Dh x A. Writing the equation in differential form, we have:
Qin - Qout = A dh/dt
24
12
6/28/2022
Cont.
Next, consider the output flowrate, Qout. The driving force for the discharge flow is
the head of water in the tank which is given by rgh. The restriction to the discharge
flow is the presence of the valve (and to a lesser extent the pipe) and this can be
represented by a resistance, R, i.e.
Qout = rgh/R
R has units of Newton seconds/metre5
Therefore, the above equation can be rewritten as follows:
25
Cont.
Examination of this equation reveals that it has the following form:
i.e. it has the first order characteristic where the output, qo, is equivalent to height, h;
the input, qi, is equivalent to the flow in, Qin, and the time constant and gain are as
follows:
26
13
6/28/2022
The Transfer Function of Linear Systems
V2( s ) R2 R2
V1( s ) R R1 + R2
R2 q
R q max
29
Linear Systems
⚫ In the previous examples, we have seen the governing
equations of linear systems. A linear dynamical system is
a system that has a governing equation of the form
d n x(t ) d n −1 x(t ) d n − 2 x(t ) dx(t )
+ a (t ) + a (t ) + ... + a n −1 (t ) + a n (t ) x(t ) = f (t )
dt n −1 dt n − 2
1 2
dt n dt
⚫ This form of equation is called linear ordinary differential equation
(linear ODE)
Note: the coefficient ai (t) can be a function of time. They can also
be a constant, in which case the system is said to be linear time
invariant (LTI).
30
14
6/28/2022
Properties of Linear Systems
⚫ Linear systems have two essential properties
known as superposition properties
1. Multiplicative or scaling property
system If
x(t) y(t) x(t) → y(t)
input output
then
system
Ax(t) → Ay(t)
Ax(t) Ay(t)
31
Properties of Linear Systems
2. Additive property
If
system
x1(t) → y1(t)
x1(t) y1(t)
and
system
x2(t) → y2(t)
x2(t) y2(t)
then
system
x1(t) + x2(t)
x1(t)+ x2(t) y1(t)+ y2(t) → y1(t) + y2(t)
32
15
6/28/2022
Linear Approximations
⚫ Linear systems have nice properties, but most real systems
are nonlinear.
⚫ For example, most springs have non-constant stiffness:
k = k1 x
⚫ Substitute this into the governing equation for the spring-mass-
damper system:
mx(t ) + bx (t ) + kx(t ) = f (t ) mx + bx + k1 x 3 / 2 = f
nonlinear term in x
33
Linear Approximations
⚫ If the system is operating with small variation in x, we
may use a linear approximation:
linear approximation about x0
linear approximation
y
dy
y = y(x) y ( x) y ( x0 ) + ( x − x0 )
Dy
dx x = x0
actual function so
y(x0)
Dx y ( x) − y ( x0 ) m( x − x0 )
m = slope calculated at x0
x0 x
Dy = m Dx this is linear in Dy and Dx
Dy = y − y ( x0 ) Dx = ( x − x0 )
34
16
6/28/2022
Equation of motion of a pendulum
Equation of motion about O: torque (T) = rate of change of angular momentum
T = mL2q
O FBD
F
but T = −mgL sin q
g
q L mL2q + mgL sin q = 0
mg nonlinear term in q
m
linearise around q = 0
linearized equation of motion:
sin q sin (0) +
d sin
(q − 0)
dq q =0 mL2q + mgLq = 0
= 0 + cos q q =0 q g
q + q = 0
=q L
35
Questions?
36
17