Modeling and Simulation
IT-417
Week-1
Lecture-2
Topic: Concepts of Complex System Modeling
Instructor: Saqib Ali Shah
Email: [email protected]
Contents
What are complex systems? .................................................................................................... 2
Applications of complex systems. .......................................................................................... 2
Modeling Concepts ................................................................................................................. 3
Model Classifications.............................................................................................................. 7
Examples of Different Systems .............................................................................................. 9
Page 1 of 9
What are complex systems?
I. A system comprised of a (usually large) number of (usually strongly) interacting
entities, processes, or agents, the understanding of which requires the development, or
the use of, new scientific tools, nonlinear models, out-of equilibrium descriptions and
computer simulations.
II. A system that can be analyzed into many components having relatively many relations
among them, so that the behavior of each component depends on the behavior of others.
III. A system that involves numerous interacting agents whose aggregate behaviors are to
be understood. Such aggregate activity is nonlinear, hence it cannot simply be derived
from summation of individual components behavior.
Applications of complex systems.
1. Computational Biology.
DNA Sequencing: Combinatorial optimization in biology.
Genetic Regulatory Networks: Design Principles of Genetic Regulatory Networks
Models of genetic regulatory processes such as RNA Editing
Neuroscience: Network properties of living neural networks
2. Social Systems
Social Networks: Social trends and the structure of human societies, Identification of
Interests, Trends and Dynamics in Document Networks, Dynamics of Social Networks.
Decision Processes and Knowledge Structures of Multi-Agent Systems: agent-based
modeling of socio-technical organizations, Agent-based modeling for Agents with
Knowledge
Economic and Financial Markets Modeling. - Modeling and Simulation of Deregulated
Electricity Market
Homeland Defense and Intelligence Community: Discovery of latent associations in
terrorist networks, Infrastructure Protection.
3. Distributed Knowledge Systems.
Information Retrieval, Web Technology, and Digital Libraries: Adaptive Behavior and
Reinforcement Learning to develop Recommendation Systems for Digital
Libraries, Identification of Interests, Trends and Dynamics in Document Networks
Page 2 of 9
Knowledge Integration: Advanced Knowledge Integration in Assessing Terrorist
Threats, Integrative Technology for Bioinformatics
4. Optimization.
Local Search Methods, Extremely Optimization, Combinatorial optimization in biology.
5. Evolutionary Systems
Evolutionary Algorithms: Contextual Genetic Algorithms, Mate Selection Schemes in
Genetic Algorithms, Immune System Model to Explore Mate Selection in Genetic
Algorithms.
Cellular Automata and Artificial Life: Reproduction Strategies, Evolving Cellular
Automata Rules
Modeling Concepts
1. Model and System
A model is a representation of an actual system
i. A model is an abstraction of the real system
ii. Simplifying assumptions are used to capture (only) important behaviors
iii. Linearization, time-bound behaviors, etc., may make analysis tractable
Output(s)
Actual System
Parameters System
Output(s)
Model
(Simplified) Parameters Model
Pictorial Representation of System Model
Formally we can define, Modeling is the application of methods to analyze complex, real-
world problems in order to make predictions about what might happen with various actions.
Object is some entity in the Real World. Such an object can exhibit widely varying behavior
Page 3 of 9
depending on the context in which it is studied, as well as the aspects of its behavior which
are under study.
Base Model is a hypothetical, abstract representation of the object's properties, in particular,
its behavior, which is valid in all possible contexts, and describes all the object's facets. A
base model is hypothetical as we will never in practice be able to construct/represent such a
total model. The question whether a base model exists at all is a philosophical one.
System is a well-defined object in the Real World under specific conditions, only considering
specific aspects of its structure and behaviour.
Experimental Frame When one studies a system in the real world, the experimental frame
(EF) describes experimental conditions (context), aspects, within which that system and
corresponding models will be used. As such, the Experimental Frame reflects the objectives
of the experimenter who performs experiments on a real system or, through simulation, on a
model.
Immediately, there is a concern about the limits or boundaries of the model that supposedly
represent the system. The model should be complex enough to answer the questions raised,
but not too complex. Consider an event as an occurrence that changes the state of the system.
In the example, events include the arrival of a customer for service at the bank, the beginning
of service for a customer, and the completion of a service. There are both internal and external
events, also called endogenous and exogenous events, respectively. For example, an
endogenous event in the example is the beginning of service of the customer since that is
within the system being simulated. An exogenous event is the arrival of a customer for service
since that occurrence is outside of the simulation. However, the arrival of a customer for
service impinges on the system, and must be taken into consideration.
Realit Mode
y l GOAL
S
Real World Entity Model Base
only study
behaviour
in
experiment within
contex Model Base a
t priori
System Model
Knowldge
Experiment Simulate =
within Virtual
context Environme
Experiementt Validatio
n Simulation Modelling and
Observed Results
Data Simulation
Modeling and Simulation
Page 4 of 9
Discrete-event simulation models are contrasted with other types of models such as
mathematical models, descriptive models, statistical models, and input-output models. A
discrete-event model attempts to represent the components of a system and their interactions
to such an extent that the objectives of the study are met. Most mathematical, statistical, and
input output models represent a system's inputs and outputs explicitly, but represent the
internals of the model with mathematical or statistical relationships. An example is the
mathematical model from physics,
Force = Mass × Acceleration
Based on theory. Discrete-event simulation models include a detailed representation of the
actual internals.
Discrete-event models are dynamic, i.e., the passage of time plays a crucial role. Most
mathematical and statistical models are static in that they represent a system at a fixed point
of time. Consider the annual budget of a firm. This budget resides in a spreadsheet. Changes
can be made in the budget and the spreadsheet can be recalculated, but the passage of time is
usually not a critical issue. Further comments will be made about discrete-event models after
several additional concepts are presented.
Models have Many Uses, Typically
I. To understand the behaviour of an existing system (why does my network performance
die when more than 10 people are at work?)
II. To predict the effect of changes or upgrades to the system (will spending 100,000 on a
new switch cure the problem?)
III. To study new or imaginary systems (let’ s bin the Ethernet and design our own scalable
custom routing network)
2. System State Variables
The system state variables are the collection of all information needed to define what is
happening within the system to a sufficient level (i.e., to attain the desired output) at a given
point in time. The determination of system state variables is a function of the purposes of the
investigation, so what may be the system state variables in one case may not be the same in
another case even though the physical system is the same.
Determining the system state variables is as much an art as a science. However, during the
modeling process, any omissions will readily come to light. (And, on the other hand,
unnecessary state variables may be eliminated.) Having defined system state variables, a
contrast can be made between discrete-event models and continuous models based on the
variables needed to track the system state. The system state variables in a discrete-event
model remain constant over intervals of time and change value only at certain well- defined
points called event times. Continuous models have system state variables defined by
differential or difference equations giving rise to variables that may change continuously over
time.
Some models are mixed discrete-event and continuous. There are also continuous models
that are treated as discrete-event models after some re-interpretation of system state variables,
Page 5 of 9
and vice versa.
3. Entities and Attributes
An entity represents an object that requires explicit definition. An entity can be dynamic in
that it "moves" through the system, or it can be static in that it serves other entities. In the
example, the customer is a dynamic entity, whereas the bank teller is a static entity. An entity
may have attributes that pertain to that entity alone. Thus, attributes should be considered as
local values. In the example, an attribute of the entity could be the time of arrival. Attributes
of interest in one investigation may not be of interest in another investigation. Thus, if red
parts and blue parts are being manufactured, the color could be an attribute. However, if the
time in the system for all parts is of concern, the attribute of color may not be of importance.
From this example, it can be seen that many entities can have the same attribute or attributes
(i.e., more than one part may have the attribute “red”)
4. Resources
A resource is an entity that provides service to dynamic entities. The resource can serve one
or more than one dynamic entity at the same time, i.e., operate as a parallel server. A dynamic
entity can request one or more units of a resource. If denied, the requesting entity joins a
queue, or takes some other action (i.e. diverted to another resource, ejected from the system).
(Other terms for queues include files, chains, buffers, and waiting lines.) If permitted to
capture the resource, the entity remains for a time, then releases the resource.
There are many possible states of the resource. Minimally, these states are idle and busy. But
other possibilities exist including failed, blocked, or starved.
5. List Processing
Entities are managed by allocating them to resources that provide service, by attaching them
to event notices thereby suspending their activity into the future, or by placing them into an
ordered list. Lists are used to represent queues. Lists are often processed according to FIFO
(first-in first-out), but there are many other possibilities. For example, the list could be
processed by LIFO (last-in-first out), according to the value of an attribute, or randomly, to
mention a few. An example where the value of an attribute may be important is in SPT
(shortest process time) scheduling. In this case, the processing time may be stored as an
attribute of each entity. The entities are ordered according to the value of that attribute with
the lowest value at the head or front of the queue.
6. Activities and Delays
An activity is duration of time whose duration is known prior to commencement of the
activity. Thus, when the duration begins, its end can be scheduled. The duration can be a
constant, a random value from a statistical distribution, the result of an equation, input from
a file, or computed based on the event state. For example, a service time may be a constant
10 minutes for each entity, it may be a random value from an exponential distribution with a
mean of 10 minutes, it could be 0.9 times a constant value from clock time 0 to clock time 4
Page 6 of 9
hours, and 1.1 times the standard value after clock time 4 hours, or it could be 10 minutes
when the preceding queue contains at most four entities and 8 minutes when there are five or
more in the preceding queue. A delay is an indefinite duration that is caused by some
combination of system conditions. When an entity joins a queue for a resource, the time that
it will remain in the queue may be unknown initially since that time may depend on other
events that may occur. An example of another event would be the arrival of a rush order that
preempts the resource. When the preempt occurs, the entity using the resource relinquishes
its control instantaneously. Another example is a failure necessitating repair of the resource.
Discrete-event simulations contain activities that cause time to advance. Most discrete-event
simulations also contain delays as entities wait. The beginning and ending of an activity or
delay is an event.
Model Classifications
Several classification categories for models exist. A system we are modeling exhibits
probabilistic or stochastic behavior if an element of chance exists. For example, the path of a
hurricane is probabilistic. In contrast, a behavior can be deterministic, such as the position of
a falling object in a vacuum. Similarly, models can be deterministic or probabilistic. A
probabilistic or stochastic model exhibits random effects, while a deterministic model does
not. The results of a deterministic model depend on the initial conditions; and in the case of
computer implementation with particular input, the output is the same for each program
execution. As we studied this and other modules, we can have a probabilistic model for a
deterministic situation, such as a model that uses random numbers to estimate the area under a
curve .Figure 6 is depicted the classification of different kinds of models.
Classification of Different Types of Model
Page 7 of 9
1. Discrete-Event Simulation Model
Sufficient modeling concepts have been defined so that a discrete event simulation model can
be defined as one in which the state variables change only at those discrete points in time at
which events occur. Events occur as a consequence of activity times and delays. Entities may
compete for system resources, possibly joining queues while waiting for an available resource.
Activity and delay times may "hold" entities for durations of time. A discrete-event simulation
model is conducted over time ("run") by a mechanism that moves simulated time forward. The
system state is updated at each event along with capturing and freeing of resources that may
occur at that time.
2. Stochastic and Deterministic Systems
Definitions A system exhibits probabilistic or stochastic behavior if an element of chance
exists. Otherwise, it exhibits deterministic behavior. A probabilistic or stochastic model
exhibits random effects, while a deterministic model does not.
Deterministic: Randomness does not affect the behaviour of the system. The output of the
system is not a random variable.
Stochastic: Randomness affects the behaviour of the system. The output of the system is a
random variable.
3. Static and Dynamic Simulations
We can also classify models as static or dynamic. In a static model, we do not consider time,
so that the model is comparable to a snapshot or a map. For example, a model of the weight of
a salamander as being proportional to the cube of its length has variables for weight and length,
but not for time. By contrast, in a dynamic model, time changes, so that such a model is
comparable to an animated cartoon or a movie. For example, the number of salamanders in an
area undergoing development changes with time; and, hence, a model of such a population is
dynamic. Many of the models we consider in this text are dynamic and employ a static
component as part of the dynamic model.
Definitions A static model does not consider time, while a dynamic model changes with time.
Static: A simulation of a system at one specific time, or a simulation in which time is not a
relevant parameter for example, Monte Carlo & steady-state simulations.
Dynamic: A simulation representing a system evolving over time for examples, the
majority of simulation problems.
4. Discrete vs. Continuous Systems
When time changes continuously and smoothly, the model is continuous. If time changes in
incremental steps, the model is discrete. A discrete model is analogous to a movie. A sequence
of frames moves so quickly that the viewer perceives motion. However, in a live play, the action
is continuous. Just as a discrete sequence of movie frames represents the continuous motion of
actors, we often develop discrete computer models of continuous situations.
Definitions In a continuous model, time changes continuously, while in a discrete model time
changes in incremental steps.
Page 8 of 9
Continuous: State variables change continuously as a function of time and generally analytical
method like deductive mathematical reasoning is used to define and solve the system.
State Variable (S.V.) = f (t)
S.V.
Continuous Model behavior is shown
Discrete: State variables change at discrete points in time and generally numerical method like computational
procedures is used to solve mathematical models.
State Variable (S.V.) = f(n t)
S.V
Discrete Model behavior is shown
Examples of Different Systems
1. Queue length at a cash machine: Stochastic, Discrete Time, Discrete System
2. The motion of the planets: Deterministic, Continuous Time, Discrete System
3. Logic circuit in a computer: Deterministic, Discrete Time, Discrete System
4. Flow of air around a car: Deterministic, Continuous Time, Continuous System
5. Closing prices of the 30 DAX shares: Stochastic, Discrete Time, Discrete System
Page 9 of 9