Mathematics 191 Research Seminar in Mathematical Modeling Lecture 6/7 February 24 th, 2005
Today’s Objectives How do we construct a useful simulation for the purposes of testing algorithms and observing behaviors in a system? How do we verify the accuracy and robustness of a simulation?
Overview ● Purposes and Types of Simulations ● Population Models ● Elevator Models, Revisited ● Case Study: Restaurant Scheduling Problem ● Sensitivity Analysis ● Peer Review and Edits
The Modeling Process ● Statement of Problem (abstraction) ● Define Model Objective / Objective Function ● Definitions and Identification of Variables (background research and common sense) ● Assumptions (for tractability) ● Establish Informal Relationships Based on System ● Construct Mathematical Statements ● Construct Base Model ● Estimate Parameters ● Apply Mathematical Methods ● Pure Mathematical Solution ● Simulation and Validation ● Sensitivity Analysis ● Relax Assumptions ● Iterate ● Assess Model Limitations
What are simulations? Simulations are computer implementations of models
Advantages to Computer Simulation The use of computers in mathematics has become commonplace, although their use in proving things remains a bit controversial. In modeling, computer simulations provide three advantages: Facilitates understanding of a complex system Demonstrates unusual behaviors or shortcomings of model when plotted against data Enables easy prediction of behavior under different conditions and parameters
Three Classes of Simulations ● Evaluations of predetermined equations over time ● System Models / Algorithm Testbeds ● Simulations to Fit Data
Case Study: Population Models ● Population models deal with the rate of change of several populations. ● The Lotka-Volterra equations for predator-prey populations are: = =
Computer Evaluations of These Equations
In what other ways can we simulate populations via computers?
Step-by-Step Process for Setting Up a System Model / Testbed ● Identify variables ● Establish Mathematical Relationships ● Design Problem Constraints ● Evaluate Solution ● Define variables and assign names ● Create data structures ● Design rules for operation ● Define steps taken per time step ● Return
Sample Simulation: Evans Hall, Revisited Position = [e1, e2, e3] Destination = [d1, d2, d3] Occupants = [{a}, {b}, {c}] {a destinations }={1, 1, 1, 3, 4} {a times }={10, 10, 11, 12, 13} Persons = [f1,…,f10] Person = (x, y)
At Each Time Step: 1. Move all elevators closer to their destination, if not already there. 2. If at a destination, transfer individuals. 3. Calculate new destinations.
Case Study: Restaurant Design The “dinner service” problem: A restaurant consists of (at minimum) wait staff, patrons, kitchen, and a certain number of tables. Your task: design a simulation with open parameters for the number of tables, then optimize it to find the best number of tables.
The Thing to Remember about Simulations ● Simulations are only as accurate as the assumptions that go into them! ● Simulations are not necessarily any more accurate than another type of model. ● They do have the ability to account for a very large number of variables.
Sensitivity Analysis ● What is sensitivity analysis? ● Why is sensitivity analysis essential in the modeling process?
Field Trip ● Meet Saturday, 9:30, at downtown BART, unless we have enough vehicles to carpool. ● If you haven’t already, us with a summary of the data you intend to collect. Will you be collecting data to optimize the parameters for a preexisting model, to cross-check a model you’ve designed, or for the purpose of designing a new model based on the data? ● Culinary models in North Beach to follow
Peer Evaluations: Project Two
Fin