System Simulation

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 60

SYSTEM SIMULATION

What is system
• The system is collection of components
wherein individual components are
constrained by connecting interrelationship
such that system as a whole fullfills some
specific in response to varying demands.
Different types of system
• Continues system The system in which
changes are predominently smooth
• Discrete system The changes occurs
discontinuously
System modelling
• Model is a body of information about the system
gathered for the purpose of studying the system.
• DERIVE MODEL
• Establish the model structure Deciding system
boundry identifying the entities , attributes and
acivities of the system
• Supplyin data
• The data provides the values the attribute can have
and define the relationship involved in the activities
continued
• Model is a body of information about the
system gathered for the purpose of studying
the system.
• Types of models
• Physical
• Mathematical
Static and Dynamic model

• Static model can only shows the values that


System attributes take when system is in
balance.
Dynamic models on the other hand follow the
changes overt time that result from system
activities
Types of models

MODELS

PHYSICAL MATHEMATICAL

STATIC STATIC

NUMERICAL NUMERICAL

SYSTEM
SIMULATION
Ways of solution

• Analytical method
• It is based on deductive reasoning of
mathematical theory to solve a model .
• It is best fits with certain forms of equations.
• Knowing this the engineer will restricts the
description of a system of a system to that
form will derive the model that can be solved
analytically
Numerical method
• It involves applying computational procedure
• To be strictly accurate any assignment of
numerical values that uses mathematical
tables.
Types of system study
• System analysis
It aims to understand how the existing system or
proposed system works. It is actually construct the
model of the system and investigate the behaviour
of the model.The result obtained are interpreted in
terms of system performance.
• System design
It studies the object is to produce a system that
meets some specification. Certain system parameter
continued
• Or components can be selected or planned by
the designer and conceptually he chooses
particular combination of components to
construct a system. The proposed system is
modelled and its performance from the
knowledge of models behaviour. If the
predicted performance compared favourably
with desired performance then the designed is
accepted.
continued
• System postulation
• It is a charecterstics of the way models are
employed in social,economical,political and
medical studies where the behaviour of the
system is known but processes that produce
the behaviour are not.Hypotheses are made
on likely set of entities and acivities that can
explain the behaviour.
Principles used in modelling
• Block building

• Relevance

• Accuracy

• Aggregation
Corporate model
• Management
• Policy making aspects of corporation

• Plant
• It provides the means of production.

• Environement

• The corporation as a whole operates


Environment segment
• National economy
• Market
• Demand ,supply,price
• Population
• Competition
Management segment
INPUT
Demand
Forcasting
National economy
World economy
Financing
INVESTMENT,labour,machinery
OUTPUT
Pricing ,profit
Application Areas of Simulation

• Simulation is an experimental technique. It is a fast and


experimental method of doing an experiment under
computer.
• There is no specific unifying theory of computer simulation
and no principle guiding the formulation of simulation
model.
• Simulation may be applied for system, there is difficult to
predict like whether or public jam where the system itself is
complex or the theory is not sufficiently regular.
• Simulation provides an alternative that is cheap and fast and
fills the gap between exact analysis and physical intuition.
Simulation in Science and Engineering
Research
• Earlier most experiments were carried out
physically in the laboratories.
• Millions were spent on physical models like
network analysers, Aircraft flight, Simulators and
expensive experiments.
• Today a majority of experiments are simulated
in a simulator. Computer experiments are faster
cheaper, easier and provide better inside into
the system than laboratory experiments.
Deterministic vs Stochastic
•Deterministic
•An activity is said to be deterministic where the outcome of
an activity can be described completely in term of its input,
•Example: AND, OR, NOT operations.
 
•Stochastic
•An activity is said to be stochastic where the effects of the
activity vary randomly over various possible outcomes.
•Example: Throwing a dice or tossing a coin. 
Continuous vs. Discrete system

 
• Continuous system
• Systems in which the changes are predominantly smooth
are called continuous system.
• Discrete system
• Systems in which the changes are predominantly
discontinuous are called discrete system.
• Example:
• Changes in the factory occur discontinuously so factory
system is a discrete system.
Monte Carlo Technique
It is defined as the technique of solving problems by the observations of performance
over time of a dynamic model of system. This definition includes the use of dynamic physical
models where the results are derived from physical measurements rather than numerical
computations.

Monte Carlo Technique of Simulation:


𝑦

ƒ(X0)

a X0 b x
Figure - The Monte Carlo Method

The Monte Carlo method is a numerical computational method which consists of


experimental sampling with random number.
F
The main drawback of simulation
 It gives specific solution rather than general solution.
• For example, in the study of automobiles wheel, an analytical
solution gives all the condition that can cause oscillation. To
try to find all such condition required that the simulation be
repeated under many different condition.
– Coupled with the need to make many runs, the simulation
model result in extensive amount of computing.
– Many simulation runs may be needed to find a maximum
and yet leave undecided the question of whether it is a
local or global maximum.
Drawback of Analytical Technique:

– The range of problem that can be solve


mathematically is limited.
– Mathematical technique requires that the model
be expressed in some particular format. For
example, in the form of linear algebraic equation
and continuous linear differential equation.
– There are many simple limitation on a system such
as physical stock, finite time delays or non-linear
forces which makes a soluble mathematical model
insoluble. But simulation removes this limitation.
Experimental nature of simulation
• It is therefore essentially an experimental
problem solving technique
• Many simulation runs have to be made to
understand the relationship involved in the
system
• The use of simulation in study must be
planned as series of experiments
Numerical computational technique
for continuous model
• . A builder observes that the rate at which he can
sell houses depends directly upon the number of
families who do not yet have a house.
• As the number of people without houses
diminishes, the rate at which he sells house drops.
• Let H be the potential number of households, and
y be the number of families with houses. The
situation is represented in Fig. 1
continued
• The horizontal line at H is the total market for houses. The
curve for y indicates how the number of houses sold
increases with time.
• The slope of the curve (i.e., the rate at which y increases)
decreases as H-y gets less.
• This reflects the slowdown of sales as the market becomes
saturated. Mathematically, the trend can be expressed by the
equation
• y. = k1 (H-y), y=0 at t=0

 
continued
• Consider now a manufacturer of central air conditioners
designed for houses. His rate of sales depends upon the
number of houses build.
• As with house sales, the rate of sales diminishes as the
unfilled market diminishes Let s be the number of installed
air conditioners.
• Then the unfilled market is the difference between the
number of houses and the number of installed air
conditioners. The sales trend may be expressed
mathematically by the equation
• x. = k2(y-x),x=0 at t=0
Continued…
• The change of s with time is also illustrated in
Fig. 2. The two equation constitute a mode of
the growth of air conditioner sales. The
market limit, for example, may not be stable.
• These influences could also depend upon the
population growth or prevailing economic
condition, and so further complicate the
model.
Continued…
•The calculation steps forward an interval ∆t to ti+1 = ti+ ∆t. The rates of sales are
assumed to be constant over the interval. The rates can be interpreted as the
amount of change per unit time. That is,
•rate of change of y = Δ𝑦i
•Δ𝑡
 
•rate of change of x = Δ𝑦i
•Δ𝑡
 
•From the equations of the model, these may be written
 
•∆yi = k1 (H-yi) Δ𝑡
•∆xi = k2(H-xi) Δ𝑡
Continued..
• Since yi and xi are known, it is a simple matter to get the values of y
and x at time ti+1. However, it will be noticed that the equation for
∆yi must be solved first to get the value of yi needed in the
equation for xi. In preparation for the solution of a continuous
system model, therefore, there must be a careful sorting of the
equations to establish a workable order.
• Repetition of the calculation using the new values of y and x
produces the output at the end of the next interval. As illustrated in
Fig.2, the calculation is equivalent to calculation the slope at each
point and projecting a short straight line at that slope. The
simulation output is a series of such line segments, approximating
the continuous curve that represents the true output of the model.
Continued..
• Rather, they use several previous values to
predict the rate at which the variables are
changing. (Special methods are used to supply
initial values to start the process.)
• In addition, the computation interval is often
adjusted in size to match the rate at which the
variables are changing.
NCT for Discrete Models: -

Document Start Work Finish Cumulative Break


Pending
No. Time(Tw) Time(Tc) Flag(Y/N)
Time(Ts) Time(Tf)
Jobs(N)

1 0 45 45 45 N 57

2 45 16 61 61 Y 56

3 66 5 71 5 N 55

4 71 29 100 34 N 54

5 100 33 133 67 Y 53

6 138 25 163 25 N 52

7 163 21 184 46 N 51

NOTE :-Tf = Ts + Tw, Tc= Tc + Tw


Example of clerk
• Consider the above example, a clerk begins his days of works with a file
of document to be processed. The time taken to process them varies.
• He works through the file beginning each document, as soon as he
finishes the previous one except that he takes that 5min break if at that
time, he finishes a document is an hour or more, since he begins work
or he left a break.
• We assume that the time to process the documents are given. We will
keep a count of no. of documents left for processing. This count will be
initially set to the no. of document at the beginning of the day and we
assume that no. of document arrive during the day. The count will be
decremented for each completed job and the work will stop when
count goes to zero.
 
continued
• The first column numbers the documents, the second column gives the
time the clerk begins to work for a document denoted by (Ts), the third
column give the time required to work on the document called as the work
time(Tw), the fourth column gives the time at which the document is
finished processing in time (Tf), the fifth column contains the
 
• cumulative time since work started on since the last break measured at the
time each job is completed (Tc), the sixth column contains the break flag,
this take the value ‘Y’ ,if the clerk should take a break after the ith
document and the value ‘N’ if he should not. The clerk works until there
are no more documents to be processed. On the time he finishes the
document goes beyond some prescribed time limit representing the end of
the working period. The computation proceeds row by row and from left to
right.
Distributed lag model
Model that have properties of changing only at
fixed interval of time and of basing current
values of the variables on the current values and
values that occurred in previous intervals are
called distributed lag model.
continued
• Let c be consumption,
• I be investment,
• T be taxes
• G be goverrment expenditure,
• Y be national income
continued
• C=20+0.7(Y-T)
• I=2+0.1Y
• T=0.2Y
• Y=C+I+G
Continued

• Conceptually simple
• Computers are extensively used to run them
Cobeb model
Progress of simulation study
• An initial state to describe the problem to be solved in a concise
manner so that there is a clear statement of what questions to
be asked and what measurements needed to be taken answer
these questions.
• Based on these problem definition a problem must be defined
• A possible part explore the cost of a model that can be solved
analytically the results in guiding the simulation study.
• When it is decided to simulate we must plan the study by
deciding upon the measure parameter to be varied the number
of cases to be conducted and the order in which runs at to be
made.
continued
• Given that the simulation is to be on a digital
computer a program must be written. The next stage
is executing runs to be study plans.
• The main value of the early runs in a simulation
study is to get inside into the general behaviour of
the system and to know which Parameters are
important for the system.
• This may lead to re-assessment of the model, when
results are verified and it found reasonable the
simulation will be stopped.
Continuous System Models
UNIT2
Continuous System Models
• Continuous System Models
• A continuous system is the system in which the activities of the main
elements of the system cause smooth changes in the attributes of the
entities of the system.
On mathematical modeling, the attributes of the system are
controlled by a continuous functions.
In such system, the relationships depicts the rates at which the
attributes changes.
The continuous system is modeled using the differential equations.
The complex continuous system with non-linearity can be simulated
by showing the application to models for linear differential equations
to obtain constant coefficients and then generalize to more complex
equations.
Differential and Partial Differential Equations

The equation that consists of the higher order derivatives of


the dependent variable is known as differential equations.
- The differential equation is said to be linear if any of the
dependent variables and its derivatives have power of one
and are multiplied by the constant.
Eg: M x’’ + D x’ + K x = K F(t)
where, M, D and K are constants; F(t) is the input to the
system depending upon the independent variable t; x’’ and x’
are second and first order derivatives of dependent variable x.
continued
• - The differential equation is said to be non-linear if the
dependent variable or any of its derivatives are raised to
a power or are combined in other way like multiplication.
• - The differential equation is said to be partial if more
than one independent variables occur in a differential
equation.
- Eg: Equation of flow of heat in three dimensional body.
It consists of four independent variables ( three
dimensions and time ) and one dependent variable
( temperature ).
continued
• Necessity of differential equations:
• 1. Most physical and chemical process
occurring in the nature involves rate of
change, which requires differential equations
to provide mathematical model.
2. It can be used to understand general effects
of growth trends as differential equations can
represent a growth rate.
Analog computers
• - Analog computers are those computers that are unified
with devices like adder and integral so as to simulate the
continuous mathematical model of the system, which
generates continuous outputs.
- The electronic analog computer based on the use of high
gain dc amplifiers are widely used analog computer.
- In such analog computer, voltages are equated to
mathematical variables and the op amps can add and
integrate the voltages.
- The proper configurations can handle addition of several
input voltages each representing the input variables.
continued
• The coefficient of the model equations are obtained
by using the scale factors.
- The circuit can be arranged to produce integrator
that provides integral w.r.t time of a single input
voltage or sum of input voltages.
- Sign inverter is used to reverse the sign of the input
as per the requirement of the model equation.
- The analog computer provides limited accuracy
because op amps have many assumptions which can
never be true in reality.
continued
The general method to apply analog computers
for the simulation of continuous system models
involves following components:
Hybrid Simulation

• - In reality, the system is of neither a pure


continuous nor a pure discrete nature.
- For simulating such system, the combination of
analog and digital computers are used. Such setup
is known as hybrid computers.
- The simulation provided by the hybrid computers
is known as hybrid simulation.
- The major difficulty in use of hybrid simulation is
that it requires high speed converters to transform
signals from analog to digital form and vice versa.
Digital Analog Simulator
• Digital Analog simulators indicates the use of
programming languages in digital computer to
simulate the continuous system.
The language is composed of macro-instructions
which are able to act as adder, integrator and sign-
changer.
A program is written to link these macro-
instructions as per the necessity which are provide
virtual connections of op amps in analog
computers.
System dynamics
• It concerns about the study to understand
forces operating in the system in order to
determine their influences on the stability or
growth of system
• Exponential growth model
• Exponential decay model

You might also like