Got Gas? Jim and Michael. Problem Statement (Weight 15%) An investigation of a gas pump queue as a function of rationing policy We modeled the queue at.

Slides:



Advertisements
Similar presentations
Time Sheet Training Press the F5 Key to view the Presentation. It may be helpful to have a printed copy of this slide presentation for the practice sessions.
Advertisements

Sampling Distributions
Cost Behavior, Operating Leverage, and Profitability Analysis
© 2004 Dominion Dominion Proposal January 24, 2005.
Tutorial 3 – Creating a Multiple-Page Report
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
1 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt Wants.
CS1512 Foundations of Computing Science 2 Week 3 (CSD week 32) Probability © J R W Hunter, 2006, K van Deemter 2007.
Teacher/Mentor Institute Using the Cortex Chuck Powell.
U.S. 10 Year Production Trends. CME Class III Prices and Trend.
U SING V ARIABLES T O R EPRESENT C O -V ARYING Q UANTITIES & D EFINE F ORMULAS Module 1 Investigation #2 Day 1.
NETLOGO LISTS Or… James says, fput THIS!. What are LISTS? Shopping list Address list DNA sequences Any collection of similar or dissimilar things Often.
Introduction to the Practice of Statistics
User Friendly Price Book Maintenance A Family of Enhancements For iSeries 400 DMAS from Copyright I/O International, 2006, 2007, 2008, 2010 Skip Intro.
The Money Market.
Capacity Planning For Products and Services
Copyright © Cengage Learning. All rights reserved. OPTIMIZING LOT SIZE AND HARVEST SIZE 3.5.
Battelle Ultrasonic Liquid Level Monitor. Process and Measurement Technology Battelle Ultrasonic Liquid Level Monitor Demonstration Battelle 2 This demonstration.
Agents and Pervasive Computing Group Università di Modena e Reggio Emilia System Requirements NetLogo is designed: to run almost any type of computer.
CAR Training Module PRODUCT REGISTRATION and MANAGEMENT Module 2 - Register a New Document - Without Alternate Formats (Run as a PowerPoint show)
 Copyright I/O International, 2013 Visit us at: A Feature Within from Item Class User Friendly Maintenance  Copyright.
Hours Listening To Music In A Week! David Burgueño, Nestor Garcia, Rodrigo Martinez.
ECODISTR-ICT Functional Mock-up of Graphical User-Interface for IDSS Dashboard This mock-up is best viewed in the Slide Show mode of PowerPoint.
Teacher instructions: 1.Print 2.Display slide 2 with Procedure steps 1 and 2 in the lesson. 3.Display slides 3 with Procedure steps 3 and 4. 4.Display.
FIRM BEHAVIOR AND THE ORGANIZATION OF INDUSTRY
Import Tracking and Landed Cost Processing An Enhancement For AS/400 DMAS from  Copyright I/O International, 2001, 2005, 2008, 2012 Skip Intro Version.
Step 1: Enter your “21 Character Employee Id Or Alternate User Id” Step 2: Enter Personal Password & Click Login NOTE : (First use password is “21 Character.
13 giugno 2006Master in economia e politica sanitaria - Simulazione per la sanità 1 _Strumenti, seguito _______________________________________ Un modello.
Microsoft® Small Basic
9-1 COBOL for the 21 st Century Nancy Stern Hofstra University Robert A. Stern Nassau Community College James P. Ley University of Wisconsin-Stout (Emeritus)
Netlogo and its Relatives Logo (Papert) –Language for teaching mathematics graphically –Tell turtle how to move Starlogo (Resnick) & StarlogoT (Wilensky)
Michael Alves, Patrick Dugan, Robert Daniels, Carlos Vicuna
WRITE DOWN 5 OBSERVATIONS ABOUT THE FOLLOWING PICTURE.
Applications of Systems of Linear Equations Example 1: Steve invested $12,000 for one year in two different accounts, one at 3.5% and the other at 4%.
Day 1 Goal: To create a model of people hunting in the forest for mushrooms and then start working on improving their mushroom hunting ability mathematically.
Find a linear function to represent each scenario.
Programming with Alice Computing Institute for K-12 Teachers Summer 2011 Workshop.
Finding Optimal Refueling Policies Shieu-Hong Lin Biola University.
1 Lab Session-VI CSIT-120 Fall 2000 Let us look at C++ syntax rules in brief Next, we complete the lab session-V Lab session-VI deals with functions (OPTIONAL)
1 Prepared for SSAC by Semra Kilic-Bahi, Colby-Sawyer College, New London NH Modified by Fred Annexstein © The Washington Center for Improving the Quality.
Department of Computer Science What is NetLogo UH-DMML  Multi-agent programmable modeling environment  Well suited for modeling complex systems evolving.
Scatterplots Grade 8: 4.01 & 4.02 Collect, organize, analyze and display data (including scatter plots) to solve problems. Approximate a line of best fit.
CSC103: Introduction to Computer and Programming
Data Structures Introduction Phil Tayco Slide version 1.0 Jan 26, 2015.
How Much is Too Much? America’s Addiction to Gasoline and Its Impact on the Workforce June 10, 2008.
PROGRAMMING, ALGORITHMS AND FLOWCHARTS
Science: Research Summary & Conflicting Viewpoints
Implementing the Rule of Four Module 0 This project is sponsored, in part, by a grant from the National Science Foundation: NSF DUE Any opinions,
A Generic Model of Motor- Carrier Fuel Optimization Yoshinori Suzuki.
First tutorial.
Math 1050 Project Transportation Costs
Introduction to TouchDevelop
New Mexico Computer Science For All Variables and Scope Maureen Psaila-Dombrowski.
COSC 1P02 Introduction to Computer Science 8.1 Cosc 1P02 “For myself, I am an optimist--it does not seem to be much use being anything else.” Winston Churchill.
CS161 Topic #16 1 Today in CS161 Lecture #16 Prepare for the Final Reviewing all Topics this term Variables If Statements Loops (do while, while, for)
Sherman School sold magazine subscriptions to raise money. Anna sold more than Katie and Greg. Belinda sold more than Anna. Who sold the MOST subscriptions?
When the program is first started a wizard will start to setup your Lemming App. Enter your company name and owner in the fields designated “Company Name”
This tutorial will talk you through a very basic workbench queueing simulation. The queueing system modelled is of customers entering an infinite capacity.
© The McGraw-Hill Companies, 2006 Chapter 3 Iteration.
When the program is first started a wizard will start to setup your Lemming App. Enter your company name and owner in the fields designated “Company Name”
DESIGNING CLASSES. SPECIFICATIONS FOR THE CAR CLASS Professional programmers carefully design the classes they need before any coding is done. With well-
Management Information Systems
Management Information Systems
Week 14 DO NOW QUESTIONS.
MIS 643 Agent-Based Modeling and Simulation 2016/2017 Fall.
Learning to program with Logo
Introduction to TouchDevelop
How do I file an ASAP? Got to AMT home page
Using Logo and Logic This presentation uses a version of Logo called StarLogo available through MIT. It can be downloaded for free and installed on your.
creating a ecosystems model in net logo
Presentation transcript:

Got Gas? Jim and Michael

Problem Statement (Weight 15%) An investigation of a gas pump queue as a function of rationing policy We modeled the queue at a gas station specifically during a gas crisis in which the number of gallons in a single purchase is limited.

Mathematical/Algorithmic Model (Weight 25%) Queue length was modeled by following a decision making matrix that was created using fixed quantities for amount of gas in a tank. Later matrix was improved to use percentages since agents have varying gas tank capacities.

Mathematical/Algorithmic Model (Weight 25%) - cMap

Agent-Based Model (Weight 25%) Gas Crisis 1973 –Know 2-3 hour wait –Know purchase limited to 10 gallons Agent never join queue if tank is > 50% as per policy –Know MPG was 14 MPG –Model functions as expected

Agent-Based Model (Weight 25%) If gas crisis today – what would happen? –Know mpg = 24 (2004) –Fewer gas station –Faster checkout – pay at pump and no full- service –Based on model queue wait time would be longer at 5 gallons per fill up

Agent-Based Model (Weight 25%) Is the agent-based model a reasonable representation of the problem? –We believe that it does based on its reflection of the 1973 situation. Does the model provide insight into the problem? –Yes, it demonstrates that improved MPG would minimize wait times. Can anything be learned from the model? –Continued investment in improving MPG or alternates to gas purchases (public transportation alternative fuels) will continue to erode the effect of gas pump queue lines.

Agent-Based Model (Weight 25%) Agent-Based Model (Weight 25%) Factors modeled –Various tank sizes –Various initial states –Average miles per gallon –Varied number of cars to fix demand –Agents have various sizes of tanks Decision to join queue based on –fuel state –line length – policy Does the team understand the agents states and behaviors, and the role of the environment? In particular, does the team understand how the agents affect each other and/or modify their environment? –Used agents to generate demand and represent queue length

Agent-Based Model (Weight 25%) Assumptions –One pump –50 miles of road –15 cars –Decision to get in line depends on number of people in queue Limitations –Driving habits –Option for alternative transportation

Results & Conclusions (Weight 15%) - Graphs

Results & Conclusions (Weight 15%) Limiting the amount of gas per purchase did not have a significant impact until quantities were reduced to below 10 gallons. One factor that is not modeled is anxiety. We believe that the long lines at the pump are more a result of concern about future availability at current prices.

Code (Weight 10%) Globals [queue totWait totVisit ] turtles-own [gas done tanksize waittime waithold visits] to setup ca set totVisit 0 set queue 0 set gasPlus 20 ask patches [ setup-road ] setup-cars open-file end

Code (Weight 10%) - This function draws the roads to setup-road ;; patch procedure if ( pycor 1 ) [ set pcolor white ] ; upper road if ( pycor -4 ) [ set pcolor white ] ; lower road if ( pycor = 0 ) and ( pxcor = 48 ) [set pcolor green] ; gas station if ( pycor = -4 ) and ( pxcor = 47 ) [set pcolor grey ] ; gas pump end

Code (Weight 10%) - This function creates the cars to setup-cars set-default-shape turtles "car" crt numcars [ set color 10 + random 130 set visits 0 set waittime 0 set done -1 set tanksize 10 + random 12 set gas random 7.5 ; various amounts of gas at start setxy random 50 3 ; spreads out cars along road set heading 90 ; cars drive east set label gas ; tells how many gallons each car has separate-cars ] ; set sample-car one-of turtles ; ask sample-car [ set color red ] end

Code (Weight 10%) - This function spreads the cars out ; this function is needed so when we click "Setup" we ; don't end up with any two cars on the same patch to separate-cars ;; turtle procedure if any? other turtles-here [ fd 1 ; 1 separate-cars ] end ; this function is needed so when we click "go" we ; don't end up with any two cars on the same patch to separate-queque ;; turtle procedure if any? other turtles-here [ bk 1 separate-queque ] end

Code (Weight 10%) - This function is an envelope for the loop to master start if gasPlus < 5 [ printout file-close stop] end

Code (Weight 10%) - This function runs each iteration to start tick ask turtles [go] if totvisit > 0 [ plot (totwait / totvisit) ] if ticks > 2500 [ printout type gasPlus type " " print (totwait / totvisit) set gasPlus gasPlus - 1 reset-ticks set totvisit 0 set totwait 0 ] end

Code (Weight 10%) - Allows cars to know if they are in line to Go ifelse ([pcolor] of (patch-at 1 3)) = 55 ; Am at the pump? [ ;Yes I am set done (done + 1) if done > 9 [ ; Im done I need to leave the pump>> setxy 49 3 set done 0 set gas (gas + gasplus) set queue (queue - 1) set totwait totwait + (waittime - waithold) set totvisit totvisit + 1 if gas > tanksize [set gas tanksize ] ;don't overflow tank ] [ ; I am not at the pump if ycor = -3 [set waittime (waittime + 1) ] fd 1 if any? other turtles-here [bk 1] ]

Code (Weight 10%) - Continuation of Go for cars on road Code (Weight 10%) - Continuation of Go for cars on road ifelse ( ([pcolor] of patch-at 1 -3) = 55 ) ;is the gas station close? [ shouldI ] [ move ] end

Code (Weight 10%) - Moves cars if they are driving – using gas Code (Weight 10%) - Moves cars if they are driving – using gas to move if gas > 0 [ if ycor != -3 [fd 1 set gas (gas - ( factor / mipg ))] ;move consuming gas ;show (sentence precision gas 2 tanksize precision (gas / tanksize) 2 waittime totwait totvisit ) ;tell us percent of gas left in tank ] end

Code (Weight 10%) - THE MATRIX to shouldI ifelse ( gas / tanksize ) >.5 [move] [ ifelse ( gas / tanksize ) >.25 and queue > 5 [move] [ ifelse gas > 2.5 and queue > 10 [move] [getInLine] ] end

Code (Weight 10%) - Moves cars to Queue to getInLine set visits (visits + 1) set waithold waittime setxy ; move to the queue road set queue (queue + 1) ; increase the queue count separate-queque ; keeps cars seperate in line end

Code (Weight 10%) - Creates a CSV file and creates headers to open-file let file "output1.csv" ;user-new-file if ( file != false ) [ if ( file-exists? file ) [ file-delete file ] file-open file ] file-print (word "Gas Plus,Number of Cars,Wait time,Visits,Average") end

Code (Weight 10%) - Adds data to CSV file for each iteration to printout let average (totWait / (totVisit ) ) ; file-print (word "Gas Plus,Number of Cars,Wait time,Visits,Average") file-print (word gasPlus "," numcars ","totWait","totVisit "," average ) ; end

Code (Weight 10%) - Sample CSV file

Code (Weight 10%) - Real-time demo Got Gas-G.nlogo

Display (Weight 10%) We recognize that time is limited and we may have skipped something, so we would like to take this opportunity to ask if there are any questions or parts of the presentation that need to be repeated?

f u wn2 mEt ppl, travL, n lern hw vid gmes r md C d comp teacha