12/7/2015© 2008 raymond p. jefferis iii1 simulation of computer systems

Post on 17-Jan-2016

217 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

04/21/23 © 2008 Raymond P. Jefferis III 1

Simulation of Computer Systems

04/21/23 © 2008 Raymond P. Jefferis III 2

Overview of Simulation

• Fundamentals of discrete system simulation

• Building a system model

• Gathering system data

• Fitting the model

• Simulating the system

• Evaluating what-if conditions

• Using simulation in training

04/21/23 © 2008 Raymond P. Jefferis III 3

Available Tools

• Commercial simulation packages - CACI– SIMPROCESS– SIMSCRIPT

• Student versions of commercial packages– Arena (Systems Modeling Corporation)– ProModel (Promodel Corporation)

• Network monitor to gather data files

04/21/23 © 2008 Raymond P. Jefferis III 4

Introduction to Simulation

System types

Definition

Reasons for simulation

Simulation components

Development of a simulation --from model to verified results

04/21/23 © 2008 Raymond P. Jefferis III 5

System Types• Continuous

– Variables take on quasi-continuous values– Described by ordinary differential equations– Example: Motion of objects

• Discrete– Variables take on discrete values– Described by difference equations– Example: Queuing systems and networks

04/21/23 © 2008 Raymond P. Jefferis III 6

Definition

Simulation is the study of a process through observation of the behavior of a model over time in response to a pattern of inputs.

04/21/23 © 2008 Raymond P. Jefferis III 7

Keywords

• process

• model

• pattern of inputs

• response - behavior over time

• observations

• study

04/21/23 © 2008 Raymond P. Jefferis III 8

Process

• system to be simulated - aspect of whole

• exists as a physical object or system

• obeys natural (possibly known) laws

• responds predictably to inputs (controllable)

• responds over time

• may be observed (observable)

04/21/23 © 2008 Raymond P. Jefferis III 9

Model

• mathematical representation of the process

• based upon natural laws

• usually built by engineering scientist

• based upon experimental data

• must be verified

• predicts behavior for known inputs

04/21/23 © 2008 Raymond P. Jefferis III 10

Pattern of Inputs

• inputs affect system

• may be a time sequence

• may be statistically distributed– time is random variable– magnitude is random variable

04/21/23 © 2008 Raymond P. Jefferis III 11

Response

• behavior over time– Example: queue length

• may be statistical– Examples: arrival time, service time

04/21/23 © 2008 Raymond P. Jefferis III 12

Observations

• Inputs– Examples: packets, frames and their lengths,

arrival times

• Outputs– Examples: packets, frames and their lengths,

service times, queue lengths

04/21/23 © 2008 Raymond P. Jefferis III 13

Study

• network monitor (“SnifferTM”)

• “smart” switches, routers, & hubs

• modeling of distribution functions• verification of traffic rates and queues

TM Trademark of Network Associates, Inc.

04/21/23 © 2008 Raymond P. Jefferis III 14

Why simulate?

• Mathematical intractability

• Process independence needed

• Change of time scale needed

• Design tool

• Training tool

• Inference tool

04/21/23 © 2008 Raymond P. Jefferis III 15

Mathematical Intractability

• nonlinear models (queuing problems)

• models too complex (combinatorics)

• microscopic details wanted (distributions)

• analytical methods inadequate

• non-steady state solutions desired

04/21/23 © 2008 Raymond P. Jefferis III 16

Process Independence

• high testing costs - many alternatives

• parametric studies - many variations

• inaccessible processes - scale issues

• measurements alter the process - monitors

• hazards

04/21/23 © 2008 Raymond P. Jefferis III 17

Time Scale Change

• very short times - expand (microscopic)

• very long times - compress (macroscopic)

04/21/23 © 2008 Raymond P. Jefferis III 18

Design

• Model– reduction of time and cost to develop model

• Process– reduction of time and cost to optimize process– performance by some criterion

04/21/23 © 2008 Raymond P. Jefferis III 19

Training

• reduction of time and cost to train operator

• elimination of off-spec production that would otherwise occur during training

• elimination of costly “crashes” that would otherwise occur during training

• preparation for events not yet experienced

04/21/23 © 2008 Raymond P. Jefferis III 20

Inference

• Learning about possible relationships in system from external behavior

• model-reference diagnostics (possibly on-line using validated model)

04/21/23 © 2008 Raymond P. Jefferis III 21

Simulation Components

• Queuing system model

• Probability distributions

• Random numbers (generators)

• Random variable distributions

• Experiments - system data

04/21/23 © 2008 Raymond P. Jefferis III 22

Model System

04/21/23 © 2008 Raymond P. Jefferis III 23

Model Development (scientist)

• Fixed input/output data sets

• Adjust model & parameters to give best fit

04/21/23 © 2008 Raymond P. Jefferis III 24

Process Development (engineer)

• Fixed model & parameters

• Vary inputs to give best output performance

04/21/23 © 2008 Raymond P. Jefferis III 25

Optimization (process mgmt.)

• Fixed model and input data

• Adjust some parameters

• Review simulation results

• Repeat parameter adjustment to optimize

• Hill-climbing method

04/21/23 © 2008 Raymond P. Jefferis III 26

Scenarios (What-ifs)

• Fixed model

• Adjust some parameters or inputs (what-if)

• Review simulation results

• Repeat adjustment to get desired performance

• Evolutionary algorithm approach

04/21/23 © 2008 Raymond P. Jefferis III 27

Inputs

• assumed known

• assumed to influence process

• time/event bases

• form a sequence

• may be affected by sampling effects

04/21/23 © 2008 Raymond P. Jefferis III 28

Time-based Inputs

• have time-to-go

• triggered by clock

04/21/23 © 2008 Raymond P. Jefferis III 29

Event-based Inputs

• have condition of occurrence(based on process variables)

• triggered by process (model) conditions or state

04/21/23 © 2008 Raymond P. Jefferis III 30

Generalized Events

• time can be an event

• all events queued in linked list

04/21/23 © 2008 Raymond P. Jefferis III 31

Other Forms

• State machine– events– actions

• Expert system– if– then

04/21/23 © 2008 Raymond P. Jefferis III 32

Responses

• process must be observable

• observation must not disturb process

• state variables (observable)(saving state allows rerun from halt)

• assumed predictable and stable

• may be affected by sampling rate

• have time course for each input

04/21/23 © 2008 Raymond P. Jefferis III 33

Observations

• must not affect the process

• suffer from sampling effects - aliasing

• used to validate the model

• used historically to diagnose process faults

• used currently to filter process data

• used predictively to optimize performance

04/21/23 © 2008 Raymond P. Jefferis III 34

Process Study by Simulation

generation of inference about process from observations of model behavior in response to known inputs

04/21/23 © 2008 Raymond P. Jefferis III 35

Implications (Problem Formulation)

• What is the process?– What aspect is to be simulated?– What laws govern its behavior?

• What form should simulation take?– Discrete?– Continuous?

04/21/23 © 2008 Raymond P. Jefferis III 36

Related Issues

• user interface

• data capture interface

• data storage (often large files)

• fitting of distributions & models

• data presentation

• programming requirements

04/21/23 © 2008 Raymond P. Jefferis III 37

Implications (Study Objectives)

• What should be the result?

• What will be the expected benefits?

• Who will be the users of the results?

04/21/23 © 2008 Raymond P. Jefferis III 38

Implications (Model)

• What natural laws are represented?

• What assumptions, goals, measures?

• What boundary (limiting) conditions?

• What form (package, language)?

• How is it to be validated?

04/21/23 © 2008 Raymond P. Jefferis III 39

Implications (Data Collection)

• What data (how much, what type)?

• How often?

• How executed?

• What conditions?

• How processed?

• What precision?

• What format?

04/21/23 © 2008 Raymond P. Jefferis III 40

Implications (Coding)

• Package or language?

• What speed desired?

• Graphical effects?

• Object oriented?

• What interfaces?– User– Network monitor

04/21/23 © 2008 Raymond P. Jefferis III 41

Implications (Verification)

• How will this be accomplished?

• Testing of random number generator?

• Testing of time function inputs?

• Testing of traffic generation model?

• Testing of network monitor?

• Check physical units?

• Verification of predicted values?

04/21/23 © 2008 Raymond P. Jefferis III 42

Implications (Experimental Design)

• For observability

• To validate the model

• To validate the simulation

04/21/23 © 2008 Raymond P. Jefferis III 43

Implications (Analysis of Results)

• Do results make sense?

• Is time/physical scale (detail) appropriate?

• What inferences can be drawn?

• Are further studies needed?

04/21/23 © 2008 Raymond P. Jefferis III 44

Implications (Documentation)

• How will models be documented?

• How will results be presented?

• Save all for further studies?

04/21/23 © 2008 Raymond P. Jefferis III 45

Validation of Simulation

Validation is the determination that the simulated system closely approximates the real system for the given scope.

04/21/23 © 2008 Raymond P. Jefferis III 46

Validation (Functional Approach)

Operate in linear and nonlinear regions and confirm conformity with real system behavior. Operations outside the validated region should be “flagged” with warning messages for the user.

04/21/23 © 2008 Raymond P. Jefferis III 47

Validation (Distribution Issues)

Real-world probability distributions do not always conform to ideal models. Determine the degree of approximation and the resultant error.

Determine what traffic can be ignored, to remove statistical “outliers”

04/21/23 © 2008 Raymond P. Jefferis III 48

Validation (Independence Issues)

Verify statistical independence - does the model assume independence? Lack of it can invalidate such a model.

04/21/23 © 2008 Raymond P. Jefferis III 49

Validation (Aggregation of Effects )

Can effects that are separate be lumped together - time, space, etc. Determine if the degree of aggregation is too great.

04/21/23 © 2008 Raymond P. Jefferis III 50

Validation (Stationarity Issues)

Validate the stationarity of parameters and probability distributions - are there variations and are they significant to the accuracy of the simulation results?

04/21/23 © 2008 Raymond P. Jefferis III 51

Verification

Verification is the determination that the model and simulation are operating in the manner intended - that the logic of the simulation program is correct and is correctly implemented.

04/21/23 © 2008 Raymond P. Jefferis III 52

Verification Steps

• Logic “walkthrough”

• Modular testing for correct I/O relationships

• Comparison with known results(Possibly compare with reduced system)

• Sensitivity testing (parameters output)

• Limit checking (inputs and parameters)

top related