Modeling & Simulation
Lecture-1
Introduction
1
Types of Systems
•
Static System: If a system does not change
with time, it is called a static system.
•
Dynamic System: If a system changes with
time, it is called a dynamic system.
2
Static Systems
• A system is said to be static if its output y(t) depends only
on the input u(t) at the present time t, mathematically
described as [out put dependent upon input]
𝑦 ( 𝑡 )=𝒉(𝑢 ( 𝑡 ))
𝑦 ( 𝑡 )=𝒉(𝑢 1 ( 𝑡 ) , 𝑢2 ( 𝑡 ) , … , 𝑢𝑚 ( 𝑡 ) )
3
Static Systems
• Following figure gives an example of static systems, which is a
resistive circuit excited by an input voltage u(t).
4
Static Systems
• Some of the non-electrical static system examples are
systems with no acceleration
• E.g. Furniture, Bridges, Buildings, etc. (ignoring
vibration)
5
Dynamic Systems
• A system is said to be dynamic if its current output may depend on
the past history as well as the present values of the input variables.
• Mathematically,
y(t ) [u( ),0 t ]
u : Input, t : Time
Example: A moving mass
y
u
M
Model: Force=Mass x Acceleration
F = ma
Dynamic Systems
examples: RC circuit, Bicycle, Car, Pendulum (in motion)
7
Ways to Study a System
System
Experiment with Experiment with a
actual System model of the System
Physical Model Mathematical Model
Analytical Solution
Simulation
Frequency Domain Time Domain Hybrid Domain
8
Model
•
A model is a simplified representation or
abstraction of reality.
•
Reality is generally too complex to copy
exactly.
•
Much of the complexity is actually irrelevant
in problem solving.
9
Types of Models
Model
Physical Mathematical Computer
Static Dynamic Static Dynamic Static Dynamic
10
What is Mathematical Model?
A set of mathematical equations (e.g., differential eqs.) that
describes the input-output behavior of a system.
What is a model used for?
• Simulation
• Prediction/Forecasting
• Diagnostics
• Design/Performance Evaluation
• Control System Design
Classification of Mathematical Models
•
Linear vs. Non-linear
•
Deterministic vs. Probabilistic (Stochastic)
•
Static vs. Dynamic
•
Discrete vs. Continuous
•
White box, black box and gray box
12
Black Box Model
• When only input and output are known.
• Internal dynamics are either too complex or
unknown.
Input Output
• Easy to Model
13
Black Box Model
• Consider the example of a heat radiating system.
14
Black Box Model
• Consider the example of a heat radiating system.
Heat Raadiating System
Room Heat Raadiating System
Valve 3535
Position Temperature Room Temperature
Temperature in Degree Celsius (y)
(oC) 3030
Temperature in Degree Celsius
Room Temperature
quadratic Fit
0 0 2525
2 3 20
20 y = 0.31*x 2 + 0.046*x + 0.64
4 6 15
15
6 12
10
8 20 10
5
10 33 5
0
00 2 4 6 8 10
0 2 4 6 8 10
Valve Position
Valve Position (x)
15
Grey Box Model
• When input and output and some information
about the internal dynamics of the system is
known.
u(t) y(t)
y[u(t), t]
• Easier than white box Modelling.
16
White Box Model
• When input and output and internal dynamics
of the system is known.
dy(t ) du(t ) d 2 y(t )
u(t) 3 y(t)
dt dt dt 2
• One should know have complete knowledge
of the system to derive a white box model.
17
Mathematical Modelling Basics
Mathematical model of a real world system is derived using a
combination of physical laws and/or experimental means
• Physical laws are used to determine the model structure (linear
or nonlinear) and order.
• The parameters of the model are often estimated and/or
validated experimentally.
• Mathematical model of a dynamic system can often be expressed
as a system of differential (difference in the case of discrete-time
systems) equations
Simulation
•
Computer simulation is the discipline of
designing a model of an actual or theoretical
physical system, executing the model on a
digital computer, and analyzing the execution
output.
•
Simulation embodies the principle of
``learning by doing'' --- to learn about the
system we must first build a model of some
sort and then operate the model.
19
Advantages to Simulation
Can be used to study existing systems without
disrupting the ongoing operations.
Proposed systems can be “tested” before committing
resources.
Allows us to control time.
Allows us to gain insight into which variables are
most important to system performance.
20
Disadvantages to Simulation
Model building is an art as well as a science. The
quality of the analysis depends on the quality of the
model and the skill of the modeler.
Simulation results are sometimes hard to interpret.
Simulation analysis can be time consuming and
expensive.
Should not be used when an analytical method would
provide for quicker results.
21