Quantitative methods: Simulation and modeling

Similar documents
Introduction to Simulation

University of Groningen. Systemen, planning, netwerken Bosman, Aart

An Introduction to Simio for Beginners

Lecture 1: Machine Learning Basics

Major Milestones, Team Activities, and Individual Deliverables

Introduction to Modeling and Simulation. Conceptual Modeling. OSMAN BALCI Professor

Circuit Simulators: A Revolutionary E-Learning Platform

Lecture 10: Reinforcement Learning

WE GAVE A LAWYER BASIC MATH SKILLS, AND YOU WON T BELIEVE WHAT HAPPENED NEXT

Executive Guide to Simulation for Health

GACE Computer Science Assessment Test at a Glance

The CTQ Flowdown as a Conceptual Model of Project Objectives

AGS THE GREAT REVIEW GAME FOR PRE-ALGEBRA (CD) CORRELATED TO CALIFORNIA CONTENT STANDARDS

Designing a Rubric to Assess the Modelling Phase of Student Design Projects in Upper Year Engineering Courses

Software Maintenance

On the Combined Behavior of Autonomous Resource Management Agents

This Performance Standards include four major components. They are

Visual CP Representation of Knowledge

LEGO MINDSTORMS Education EV3 Coding Activities

Radius STEM Readiness TM

Teaching a Laboratory Section

Module 12. Machine Learning. Version 2 CSE IIT, Kharagpur

Algebra 1, Quarter 3, Unit 3.1. Line of Best Fit. Overview

Probability and Statistics Curriculum Pacing Guide

Unit: Human Impact Differentiated (Tiered) Task How Does Human Activity Impact Soil Erosion?

Seminar - Organic Computing

ACTL5103 Stochastic Modelling For Actuaries. Course Outline Semester 2, 2014

A GENERIC SPLIT PROCESS MODEL FOR ASSET MANAGEMENT DECISION-MAKING

Testing A Moving Target: How Do We Test Machine Learning Systems? Peter Varhol Technology Strategy Research, USA

Python Machine Learning

Edexcel GCSE. Statistics 1389 Paper 1H. June Mark Scheme. Statistics Edexcel GCSE

PM tutor. Estimate Activity Durations Part 2. Presented by Dipo Tepede, PMP, SSBB, MBA. Empowering Excellence. Powered by POeT Solvers Limited

Specification and Evaluation of Machine Translation Toy Systems - Criteria for laboratory assignments

Improving Conceptual Understanding of Physics with Technology

Guidelines for Writing an Internship Report

1.11 I Know What Do You Know?

ISFA2008U_120 A SCHEDULING REINFORCEMENT LEARNING ALGORITHM

Degree Qualification Profiles Intellectual Skills

Grade 6: Correlated to AGS Basic Math Skills

Utilizing Soft System Methodology to Increase Productivity of Shell Fabrication Sushant Sudheer Takekar 1 Dr. D.N. Raut 2

Physics 270: Experimental Physics

What is Thinking (Cognition)?

ECE-492 SENIOR ADVANCED DESIGN PROJECT

Mathematics subject curriculum

CS Machine Learning

Using the Attribute Hierarchy Method to Make Diagnostic Inferences about Examinees Cognitive Skills in Algebra on the SAT

Enhancing Learning with a Poster Session in Engineering Economy

Probabilistic Latent Semantic Analysis

KENTUCKY FRAMEWORK FOR TEACHING

Cal s Dinner Card Deals

ICTCM 28th International Conference on Technology in Collegiate Mathematics

ME 443/643 Design Techniques in Mechanical Engineering. Lecture 1: Introduction

On Human Computer Interaction, HCI. Dr. Saif al Zahir Electrical and Computer Engineering Department UBC

Timeline. Recommendations

SOCIAL STUDIES GRADE 1. Clear Learning Targets Office of Teaching and Learning Curriculum Division FAMILIES NOW AND LONG AGO, NEAR AND FAR

OPTIMIZATINON OF TRAINING SETS FOR HEBBIAN-LEARNING- BASED CLASSIFIERS

Green Belt Curriculum (This workshop can also be conducted on-site, subject to price change and number of participants)

Modified Systematic Approach to Answering Questions J A M I L A H A L S A I D A N, M S C.

Moderator: Gary Weckman Ohio University USA

PAGE(S) WHERE TAUGHT If sub mission ins not a book, cite appropriate location(s))

Reduce the Failure Rate of the Screwing Process with Six Sigma Approach

CAAP. Content Analysis Report. Sample College. Institution Code: 9011 Institution Type: 4-Year Subgroup: none Test Date: Spring 2011

The Political Engagement Activity Student Guide

Extending Place Value with Whole Numbers to 1,000,000

CHAPTER 4: REIMBURSEMENT STRATEGIES 24

Statewide Framework Document for:

MADERA SCIENCE FAIR 2013 Grades 4 th 6 th Project due date: Tuesday, April 9, 8:15 am Parent Night: Tuesday, April 16, 6:00 8:00 pm

PH.D. IN COMPUTER SCIENCE PROGRAM (POST M.S.)

Medical Complexity: A Pragmatic Theory

Statistical Analysis of Climate Change, Renewable Energies, and Sustainability An Independent Investigation for Introduction to Statistics

Spring 2016 Stony Brook University Instructor: Dr. Paul Fodor

Guidelines for Project I Delivery and Assessment Department of Industrial and Mechanical Engineering Lebanese American University

Beyond the Blend: Optimizing the Use of your Learning Technologies. Bryan Chapman, Chapman Alliance

Candidates must achieve a grade of at least C2 level in each examination in order to achieve the overall qualification at C2 Level.

Learning Methods for Fuzzy Systems

PRODUCT COMPLEXITY: A NEW MODELLING COURSE IN THE INDUSTRIAL DESIGN PROGRAM AT THE UNIVERSITY OF TWENTE

Functional Skills Mathematics Level 2 assessment

Modeling user preferences and norms in context-aware systems

Evaluation of Usage Patterns for Web-based Educational Systems using Web Mining

Evaluation of Usage Patterns for Web-based Educational Systems using Web Mining

Probability estimates in a scenario tree

USING SOFT SYSTEMS METHODOLOGY TO ANALYZE QUALITY OF LIFE AND CONTINUOUS URBAN DEVELOPMENT 1

Commanding Officer Decision Superiority: The Role of Technology and the Decision Maker

Application of Virtual Instruments (VIs) for an enhanced learning environment

Conceptual modelling for simulation part I: definition and requirements

Generative models and adversarial training

Abstractions and the Brain

M55205-Mastering Microsoft Project 2016

The 9 th International Scientific Conference elearning and software for Education Bucharest, April 25-26, / X

Students Understanding of Graphical Vector Addition in One and Two Dimensions

Ontologies vs. classification systems

Sample Performance Assessment

MTH 141 Calculus 1 Syllabus Spring 2017

FIGURE IT OUT! MIDDLE SCHOOL TASKS. Texas Performance Standards Project

University of Cincinnati College of Medicine. DECISION ANALYSIS AND COST-EFFECTIVENESS BE-7068C: Spring 2016

Generating Test Cases From Use Cases

Rover Races Grades: 3-5 Prep Time: ~45 Minutes Lesson Time: ~105 minutes

AGENDA LEARNING THEORIES LEARNING THEORIES. Advanced Learning Theories 2/22/2016

POLA: a student modeling framework for Probabilistic On-Line Assessment of problem solving performance

Transcription:

Quantitative methods: Simulation and modeling Lecture 1 and Lecture 2 Urban Bilstrup (E327) Urban.Bilstrup@hh.se 140911

2 INTRODUCTION TO COMPUTER SIMULATION

Outline Simulation and modeling The Nature of Simulations Application Areas of Computer Simulation Advantages with Computer Simulation Drawbacks with Computer Simulation Pitfalls with Computer Simulation Systems, Models and Simulation Elements of Simulation Analysis 3

The Nature of Simulations The process of designing a mathematical or logical model of a real system and then conduct computer-based experiments with the model to describe, explain, and predict the behavior of the real system T. H. Naylor et al., Computer Simulation Techniques, John Wiley and Sons, 1966. 4

The Nature of Simulations A computer simulation imitates the operation of various kinds of real-world facilities or physical processes. The facility or process is usually referred to as a system. In order to study it scientifically one have to make a set of assumptions about how the system works. These assumptions usually take the form of mathematical or logical relationships that constitutes a model of the realworld system. 5

The Nature of Simulations If the relationships, that compose the model, are simple enough, it may be possible to use analytic methods to obtain an exact answer on questions of interest. However, most real-world systems are too complex to be evaluated analytically (only a very limited set of algebraic equations can be solved analytically) and these must be studied by means of simulation. In a simulation a computer is used to evaluate a model numerically where data is gathered to estimate the characteristics of the model. 6

Application Areas of Computer Simulation Designing and analyzing manufacturing systems Designing and evaluating electronic circuits. Construction modeling Evaluate military systems or logistics requirements. Determining requirements or evaluating protocols for communication protocols. Determining hardware and software requirements for a computer systems. Designing and operating transportation systems such as airports, freeways, ports and subways. 7

Application Areas of Computer Simulation Evaluating designs for service organizations such as contact centers, fast-food restaurants, hospitals, post offices. Reengineering of business processes Analyzing supply chains Determining ordering policies for inventory systems Analyzing mining operations 8

Advantages with Computer Simulation 9 Most complex, real world systems with stochastic elements cannot be accurately described by a mathematical model that can be evaluated analytically, simulation (numerical) methods is the only available type of evaluation. Simulation allow one to estimate the performance of an existing system under some projected set of operation conditions. Alternative proposed system designs can be preevaluated via simulation to see which design that meets the system requirements best. Much better control over experimental conditions can be maintained in a simulation than experimenting with a real system.

Drawbacks with Computer Simulation Models to study large-scale systems tend to be very complex, writing computer programs that execute these models can be a very tedious and hard task. A second problem is that the computational complexity of large scale simulations, extremely large amount of computer time is sometimes required. Verification of the correctness of the simulation model and its implementation can be hard to accomplish. 10

Drawbacks with Computer Simulation There exist an impression that simulation is just an exercise in computer programming (a complicated one). Consequently, many simulation studies have been composed of ad hoc models, ad hoc implementation and just run the simulator once to obtain the answer, attitude. This attitude, which neglects the important issue of how a properly coded model should be used, has doubtless led to that erroneous conclusions have been drawn in many simulation studies. Stochastic simulation models produce output that is itself random, and must therefore be treated as only an estimate of the true characteristics of the model. This is one of the disadvantages of simulation. 11

Pitfalls with Computer Simulation Failure to have a well-defined set of objectives at the beginning of the simulation. Failure to have the entire project team involved at the beginning of the study. Inappropriate level of model detail. Failure to communicate with management throughout the course of the simulation study. Misunderstanding of simulation by the management. Treating simulation as if it were primarily an exercise in computer programming. Failure to have people with a knowledge of simulation methodology and statistics on the modeling team. 12

Pitfalls with Computer Simulation Failure to collect good system data, e.g. not enough data to create a good model. Inappropriate simulation software. Belief that easy-to-use simulation tools require a significantly lower level of technical competence. Failure to account correctly for sources of randomness in the system under consideration. Using arbitrary random distributions as input to the simulation. Analyzing the output from the simulation using formulas that assumes independence. 13

Pitfalls with Computer Simulation Making single replication of a particular system design and treating the output statistics as true answers. Failure to have warm up period, if the steady state behavior of a system is of interest. Comparing alternative system designs on the basis of one replica for each design. Using wrong performance measures. 14

Systems, Models and Simulation A system is defined as collection of entities, (e.g. people or machines) that acts and interacts towards the accomplishment of some logical end. In practice what is meant by the system depends on the objectives of a particular study. The state of a system is defined as the collection of variables necessary to describe a system at a particular time, relative to the objectives of a study. 15

Systems, Models and Simulation Systems can be categorized in to two types: discrete and continuous. A discrete system is one for which the state variables change instantaneously at separated point in time. A continuous system is one for which the state variables change continuously with respect to time. 16

Systems, Models and Simulation System Experiment with the actual system Experiment with a model of the system Physical model Mathematical model Analytical Solution Simulation 17

Systems, Models and Simulation Experiment with the actual system versus Experiment with a model of the system If it is possible to alter an existing system physically and then let it operate under the new conditions it is probably desirable to do so. However, it is rarely feasible to do so caused by that: The system may not exist The stimulus may not exist High cost to alter a existing system Dangerous elaborate with a existing system. 18

Systems, Models and Simulation Physical model versus Mathematical model Sometimes small scale physical models are used to evaluate constructions, e.g. air plane or car models in wind tunnels, ship models in swimming pools etc. The vast majority of used models are mathematical, representing a system in terms of logical and quantitative relationships that are possible to manipulate and change to see how the model reacts. Faster, lower cost, etc.. 19

Systems, Models and Simulation Analytic solution versus Simulation The vast majority of used models are mathematical, e.g. d=rt, where r is the rate of travel, t is the time spent traveling, and d is the distance traveled, the closed form solution of this model is very simple to find. However, a closed form solution can become extraordinary complex to find, e.g. inverting a large non-sparse matrix is a well known example. The formula is well known, but obtaining the solution is far from trivial. Many systems are highly complex, so that valid mathematical models of them are themselves complex precluding any possibility of analytical solutions. In these cases the model must be studied by means of simulation, i.e. numerically exercising the model for the inputs in question to see how they affect the output measures of performance. 20

Systems, Models and Simulation Given that there exist a mathematical (numerical) model, we must then look for a particular tool to do this. For this purpose it useful to classify models along three different dimensions: Static versus Dynamic models Deterministic versus Stochastic models Continuous versus Discrete models 21

Systems, Models and Simulation Static versus dynamic model A static model is a representation of a system at a particular time, or a model that may be used to represent a system in which time have no role. A dynamic model evolves over time, i.e. the state variables are time dependent. 22

Systems, Models and Simulation Deterministic versus Stochastic models If a model does not contain any probabilistic components, it is called deterministic, often a complicated system of differential equation (analytically intractable). Many systems must however be modeled as having at least some random input component, and these gives rise to stochastic models, e.g. communication, queuing and inventory systems are modeled stochastically. Stochastic models produce output that is itself random, and must therefore be treated as only an estimate of the true characteristics of the model. 23

Systems, Models and Simulation Continuous versus Discrete models Discrete and continuous models analogously to the way discrete and continuous systems. A discrete model is one for which the state variables change instantaneously at separated point in time. A continuous model is one for which the state variables change continuously with respect to time. 24

Systems, Models and Simulation Static vs. Dynamic Dynamic, Deterministic, Continuous Dynamic, Deterministic, Discrete Dynamic, Stochastic, Continuous Static, Deterministic, Continuous Dynamic, Stochastic, Discrete Static, Deterministic, Discrete Continuous vs. Discrete Static, Stochastic, Continuous Static, Stochastic, Discrete Deterministic vs. Stochastic 25

Elements of Simulation Analysis Introduction Simulation analysis is a descriptive modeling technique. As such, simulation analysis does not provide the explicit problem formulation and solution steps. Consequently, one must specify in detail a procedure for the development and use of simulation models to assure successful outcome from a simulation study. 26

Elements of Simulation Analysis Introduction Problem Formulation: questions for which answer are sought, the variables involved and measures of system performance to be used Data Collection and Analysis: assembling the information necessary to further refine our understanding of the problem. Model Development: building and testing the model of the real system, selecting simulation tool (programming language), coding the model and debugging it. 27

Elements of Simulation Analysis Introduction Model Verification and Validation: establish that the model is an appropriate accurate representation of the real system. Model Experimentation and Optimization: precision issues, how large sample (simulation time) is necessary to estimate the performance of the system. The design of effective experiments with which to answer the question asked in the problem formulation. Implementation and Simulation result: acceptance of the result by the users and improved decision making stemming from the analysis. 28

Elements of Simulation Analysis Introduction Major Iterative Loops in a Simulation Study Problem Formulation Data Collection and Analysis Model development Model Verification and Validation Model Experimentation and Optimization Implementation of Simulation Results 29

Elements of Simulation Analysis Problem Formulation Problem formulation is the most important step in a simulation study. Problem formulation often include: Technical aspects Economical aspects Political aspects The problem formulation can have a significant impact on the success of the simulation study. 30

Elements of Simulation Analysis Problem Formulation But let us concentrate on the required tasks from a technical perspective!!!!! Four fundamental design issues must be addressed in the problem formulation phase. Identify decision and uncontrolled variable Specify constraints on the decision variable Define measures of the system performance and their objectives Develop a preliminary model structure to interrelate the system variable and the measure of performance 31

Elements of Simulation Analysis Problem Formulation The first step is the specification of variables that define the system and its outputs. Variables may be classified as exogenous or endogenous. Exogenous (input variables) are external to the model and exist independently of the model. Endogenous are internal to the model and are a function of the exogenous variables and the model structure. Exogenous variables can be further classified as controllable and uncontrollable. Exogenous controllable variables (decision variables) can be manipulated within some limit by the decision maker. Exogenous uncontrollable variable (parameters) is beyond the control of the decision maker. 32

Elements of Simulation Analysis Problem Formulation To evaluate the effectiveness of a system, we must identify a measure (or measures) of performance by which to judge it. Performance measure (or measures) of the system are selected from the endogenous variables. The measure (or measures) which we chose to optimize on, minimize/maximize, in a simulation are referred to as the objective function. 33

Elements of Simulation Analysis Problem Formulation If multiple measures of performance are identified it is hard to optimize on several of them simultaneously since minimizing one tends to produce large value for the other. There exist two approaches to this dilemma: Make explicit trade-offs among the measures by combining several measures using some common dimension, e.g., cost. Select the measure of most concern to optimize while constraining the others to be at a constant value or within some minimal range. If one is fortune, one measure will dominate the performance for all other alternatives. When dominance cannot be shown, one must deal with the problem of combining several measures into one common dimension for all measures. 34

Elements of Simulation Analysis Problem Formulation A simple example: combining several measures in a simulation of a supermarket multi-lane checkout system. cost Total cost Cashier salaries Cost of customer waiting time Number of cashiers 35

Elements of Simulation Analysis Problem Formulation Developing the model is often a trade off between the level of detail the simulation model should include and the understandability of the measures, i.e. too many variable to optimize on. But how much detail to be included in the model of a system? It depends upon the purpose for which the model is being developed and the marginal contribution of the additional detail. 36

Elements of Simulation Analysis Problem Formulation The level of detail must be based on a subjective trial and error derived assessment of the marginal cost of obtaining the necessary data and including the required relationship in the model, versus the additional accuracy with which estimates of system performance can be made. The ultimate goal of any simulation is to assist in decision making, and this must dictate the problem formulation. 37

Elements of Simulation Analysis Data collection and analysis Data collection methods are as varied as the problems to which they are applied, manual approaches to very sophisticated high technology techniques. The data collection method should be tail ordered to the particular system model that should be derived. Following issues can be considered: Ability to record the data, achieving the desired level of accuracy Impact of the data collection process on the system under observation Ease of conversion of the sampled data to a computer processable form Cost of the method 38

Elements of Simulation Analysis Data collection and analysis Some of the data that defines simulation models are deterministic, that is, known with certainty, but much of it is often probabilistic. Given a set of probabilistic data, there are two main ways to include it in a simulation mode: Use the actual sample data to represent the probabilistic distribution Determine a theoretical probability distribution which is similar to the sample data. If possible, it is often better to use a theoretical distribution. It provides a better understanding of the simulation model and most often a more efficient execution of the simulation model. 39

Elements of Simulation Analysis Model development In the model development step the description of the system being modeled by quantifying the relationships among all of the variable and the performance measures. In order to develop an accurate computer program which implements our model, we must fully understand the system and all of its intricacies. Acquiring this understanding of the system to develop an appropriate model is one of the most difficult tasks in simulation studies. Very often any specific approach or clear description of how to do it is lacking, or it is very hard to communicate the used approach. 40

Elements of Simulation Analysis Model development There exist two commonly used approaches: The physical flow approach State change approach 41

Elements of Simulation Analysis Model development To use the physical flow approach, one identifies the physical entities for which processing or transformation constitutes the main purpose of the system. These entities are then tracked through the system, noting points of processing and branching decision rules that determine their route. A diagram of the entity flow and the system processing elements then provides the representation of the system from which the model and its associated computer program can be developed. 42

Elements of Simulation Analysis Model development Physical flow chart for supermarket checkout system Customer queue Tally purchases Cashier and bagger Pay for purchases Bag purchases Queue choice Customer queue Tally purchases Cashier and bagger Pay for purchases Bag purchases 43

Elements of Simulation Analysis Model development In order to describe the state change approach it is necessary to define additional endogenous variable classification state variable and introduce the concept of an event. State variable describes the present status of the system e.g. number of people in a queue, number of people presently served etc. Event is the particular point in time when a person arrives and joins a queue etc. By incorporating into the model the ability to update state variables as time advances and events occur we can describe the system behavior. 44

Elements of Simulation Analysis Model development A useful approach for the state change approach is to represent this as an event graph. Events are represented as nodes and progression from event to event as arrows. 45

Elements of Simulation Analysis Model development Event graph for the supermarket checkout system Events 1 2 3 4 5 6 7 1. Customer arrives 2. Customer selects cashier 3. Cashier begins checkout 4. Cashier finish checkout 5. Bagger begins packing 6. Bagger Finish packing 7. Customers leaves 46

Elements of Simulation Analysis Model development With an understanding of the type of model that is to be developed the next step is to do the actual model construction. The major tasks in this step are: Developing a computer program flow chart for the simulation model. Selecting programming language or simulation tool Providing entities for the generation of random numbers and random distributions. Writing and debugging program code. 47

Elements of Simulation Analysis Model development The first step is to produce a logic flow chart of the computer program. If the physical flow approach was followed, the previous flow chart can more or less be used but one other factors must be considered. 48