Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.

Slides:



Advertisements
Similar presentations
NETLOGO LISTS Or… James says, fput THIS!. What are LISTS? Shopping list Address list DNA sequences Any collection of similar or dissimilar things Often.
Advertisements

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.
Agents and Pervasive Computing Group Università di Modena e Reggio Emilia System Requirements NetLogo is designed: to run almost any type of computer.
13 giugno 2006Master in economia e politica sanitaria - Simulazione per la sanità 1 _Strumenti, seguito _______________________________________ Un modello.
Netlogo and its Relatives Logo (Papert) –Language for teaching mathematics graphically –Tell turtle how to move Starlogo (Resnick) & StarlogoT (Wilensky)
Biomedical Modeling: Introduction to the Agent-based epidemic modeling
New Mexico Computer Science For All Designing and Running Simulations Maureen Psaila-Dombrowski.
Week 7 DO NOW QUESTIONS. Question: In the following segment of code, “food-location” is a ___? breed [ foragers forager ] breed [ followers follower ]
Wurzer, Lorenz, Popov: „NetLogo Workshop (Part 1)“, in eCAADe 2012 Prague, Slide 1 „Netlogo First Steps (Artif. Societies) “, in Social Simulation Conference.
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.
New Mexico Computer Science for All Agent-based modeling By Irene Lee December 27, 2012.
New Mexico Computer Science For All Breeds and Shapes in NetLogo Maureen Psaila-Dombrowski.
EPIDEMIOLOGY: Introduction to the Agent-based epidemic modeling Dr. Qi Mi Department of Sports Medicine and Nutrition, SHRS, Univ. of Pitt.
Agent-based model of a simple stable economy Alexandre Lomovtsev Advisor: Dr. Russell Abbott, Ph.D. California State University, Los Angeles Department.
Agent-based model of a simple stable economy Alexandre Lomovtsev Advisor: Dr. Russell Abbott, Ph.D. California State University, Los Angeles Department.
Lab 01 Fundamentals SE 405 Discrete Event Simulation
2-Day Introduction to Agent-Based Modelling Day 2: Session 5 Variables and Debugging.
Break Even Analysis AS Business Studies.
Teaching Contemporary Mathematics Conference January 25, 2013 Christine Belledin NC School of Science and Mathematics.
Department of Computer Science What is NetLogo UH-DMML  Multi-agent programmable modeling environment  Well suited for modeling complex systems evolving.
Principles of Macroeconomics: Ch. 13 First Canadian Edition Overview-8 u Financial Markets and Intermediaries u Saving and Investment u Market for Loanable.
An Introduction to NetLogo given by Gabriel Wurzer. ,
Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.
CPSC 171 Introduction to Computer Science 3 Levels of Understanding Algorithms More Algorithm Discovery and Design.
2-Day Introduction to Agent-Based Modelling Day 1: Session 4 Networks.
 Desire to want something and the ability to pay for it.
1 Copyright © 2008 Thomson South-Western, a part of the Thomson Corporation. Thomson, the Star logo, and South-Western are trademarks used herein under.
Chapter 2 Basic Managerial Accounting Concepts
CISC 1600 – Lecture 3.2 Simulations Complex Input & Output NetLogo.
Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.
Week 11 DO NOW QUESTIONS. An ask turtles block is a set of instructions that is issued to every turtle. Even though computers can do things very quickly,
Week 14 DO NOW QUESTIONS. You have been asked by a leader of your community to think about how a sudden increase in fuel price (gas= $12/gal) will affect.
An Introduction to NetLogo Gabriel Wurzer, Vienna University of Technology AnthropologischeGesellschaftWien.
Week 9 DO NOW QUESTIONS. Question: If the following procedure is executed after 1 turtle is created in the program, what shape is created on the NetLogo.
Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.
Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.
DEVELOPING A BUSINESS PLAN:
Chapter 2. Cost-volume-profit analysis examines the behavior of total revenues total costs operating income as changes occur in the output level selling.
New Mexico Computer Science For All Command Procedures in NetLogo Maureen Psaila-Dombrowski.
2-Day Introduction to Agent-Based Modelling Day 2: Session 6 Mutual adaption.
Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.
Week 10 DO NOW QUESTIONS. A programmer has created 100 turtles of random colors and randomly distributes green patches. Every time the turtles land on.
New Mexico Computer Science For All Variables and Scope Maureen Psaila-Dombrowski.
New Mexico Computer Science For All Creating Turtles Maureen Psaila-Dombrowski.
Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University.
MIS 585 Special Topics in IMS Agent-Based Modeling Bertan Badur Department of Management Information Systems Boğaziçi University.
BREAKEVEN - WHAT IS IT? DEFINITION: When a business is breaking even it is just earning enough sales revenue to pay for all of its total costs No profit.
MIS 585 Special Topics in MIS: Agent-Based Modeling 2015/2016 Fall.
Introduction to Multiple Regression Lecture 11. The Multiple Regression Model Idea: Examine the linear relationship between 1 dependent (Y) & 2 or more.
MIS 585 Special Topics in MIS: Agent-Based Modeling 2015/2016 Fall Chapter 7 Verification, Validation, and Replication.
Copyright © 2011 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill/Irwin Chapter 25 Managerial Accounting Concepts and Principles.
MIS 585 Special Topics in MIS Agent-Based Modeling NetLogo: Summary of Manual and Dictionary.
Calculating Costs, Revenues and Profits. LEARNING OUTCOMES By the end of the lesson I will be able to: –Define Profit, Revenue and Cost –Calculate Revenue.
M10 WS11:Krankenhausbedarfsplanung The World as We See It given by Gabriel Wurzer and Wolfgang E. Lorenz
Social Simulation of Rescue Teams' Dynamic Planning João Ulisses, Rosaldo J. F. Rossetti, João E. Almeida, Brígida Mónica Faria, presented by: Luis Paulo.
1 Agent-Based Tools: focus on NetLogo Ing. Cristina Ponsiglione University of Naples Federico II Laboratorio di Simulazione ad Agenti.
FINANCE QUIZ Name: ______________________ Total marks: 20 My mark: _________ My target grade is: __________ My grade: _________.
M10 WS11:Krankenhausbedarfsplanung More, More and Even-More More given by Gabriel Wurzer and Wolfgang E. Lorenz
An Introduction to NetLogo given by Gabriel Wurzer and Wolfgang E
Management Information Systems
MIS 643 Agent-Based Modeling NetLogo: Summary of Manual and Dictionary.
Creating Simple Agent-Based Models
Management Information Systems
MIS 643 Agent-Based Modeling and Simulation 2016/2017 Fall.
Chapter 6: Estimating demand and revenue relationships
Global Entrepreneurship and Small Business Management
creating a ecosystems model in net logo
MIS 643 Agent-Based Modeling and Simulation 2016/2017 Fall
MIS 585 Special Topics in MIS: Agent-Based Modeling 2015/2016 Fall
Presentation transcript:

Agent-Based Modeling and Simulation (ABMS) Bertan Badur Department of Management Information Systems Boğaziçi University

Thetelemarketer Model Chapter 13, 14, of Agent-Based and Individual- Based Modeling: A Practical Introduction, by S. F. Railsback and V. Grimm NetLogo User Menual

Outline 13.

4. The Telemarketer Model ODD Description Purpose Entitie, States Variables, and Scales –patches – poterntial customers called in one time step – boolean – color black or red –turtles – telemarketers location – xcor, ycor size – staff, telephone,... bank-balance – money –Time – weeks 200 steps –no wraping in x and y, max-x 200, max-y 200

NetLogo Code globals [n-telemar] turtles-own [bank-bal] to setup ca set n-telemar 200 crt n-telemar [ set bank-bal 0.0 ] reset-ticks end to go tick if ticks > 200 [stop] end

Process Overview and Scheduling (1) For actions in each time step First: set calling “no” – with a color Second: sales – make sales –order is important – each time random –call customers in radius proportional with size –if a customer not called previously in the same week – then buy – else not buy

Process Overview and Scheduling (1) Third: accounting –revenue form sales –fixed cost proportionla with size –update bank balance –updete size if bank balance is high enough –die if bank balance is lessw then 0 Forth: output –marketers in business at each time –size distribution and total sales

NetLogo Code - go to go tick if ticks > 200 [stop] ask patches [set pcolor black] ask turtles [ sales account ] output end

NetLogo Code - submodels to sales end to account end to output end

Design Concepts Basic principles Emergence Adaptive behavior Prediction Sensing Interraction Stochasticity Observation

Initialization Telemarketers: –bank balance 0.0 –size 1.0 –color random –lacation random –chape circle Potential customers: –called no – color black

NetLogo code to setup ca set n-telemar 200 crt n-telemar [ set bank-bal 0.0 set sıze 1.0 setxy random-xcor random-ycor set shape "circle" ] ask patches [ set pcolor black ] reset-ticks end

Submodels - sales radius: 10 times square root of size max number of calls: 100 times size if potential cust > nax number of calls select nax number of calls of them else select all of them if poterntial customer is not called sell to the poterntial customers change its call to yes – color to red

NetLogo code - sales to sales let radius 10 * sqrt sıze let max-call floor ( 100 * sıze ) let pot-custs patches in-radius radius if count pot-custs > max-call [ set pot-custs n-of max-call pot-custs ] ask pot-custs [ if pcolor = black [ set pcolor red ] ] end.

Submodels - account cost: 50 times size income: 2 times succesful sales update bank balance if bank balance is greater then growth param bank balance – growth param is used to increase size size is added: excess money times if size less then zero the telemarketer goes out of business

NetLogo code - updates globals [n-telemar growth-param size-param ] turtles-own [bank-bal n-sales] to setup ca set growth-param 1000 set size-param add tot the sales set n-sales count pot-custs with [pcolor = black]...

NetLogo code - account to account let cost 50 * sıze let income 2 * n-sales set bank-bal bank-bal + income - cost if bank-bal > growth-param [ set sıze sıze + size-param * ( bank- bal - growth-param ) set bank-bal 1000 ] if bank-bal < 0 [ die ] end

Submodels - output number of telemarketers size and bank balance distribution

add a ploter plot count turtles

5. Direct Interraction: Mergers in the Telemarketing Model update balance depends on have a parent or not if bank balance less then zero and not have a parent select a parent with size greater then ist own size and bank balance greater then its deficit or go out of business if balance < 0 and have a parent get subsidize or die

netLogo code – account modififed to account let cost 50 * sıze let income 2 * n-sales let profit income - cost ifelse parent != nobody [ set bank-bal bank-bal * profit ask parent [set bank-bal 0.5 * profit ] ] [ set bank-bal bank-bal + profit ] if bank-bal > growth-param [ set sıze sıze + size-param * ( bank-bal - growth-param ) set bank-bal 1000 ]

netLogo code – account modififed if bank-bal < 0 and parent != nobody [ output-show parent let bank-bal-par [bank-bal] of parent ifelse bank-bal-par > ( -1 * bank-bal ) [ ask parent [set bank-bal bank-bal + [bank- bal] of myself ] set bank-bal 0.0 ] [die stop] ]

netLogo code – account modififed if bank-bal < 0 and parent = nobody [ let pot-parents other turtles with [ sıze > [sıze] of myself and bank- bal > -1 * [bank-bal] of myself ] ifelse any? pot-parents [ set parent one-of pot-parents ask parent [set bank-bal bank-bal + [bank-bal] of myself ] set bank-bal 0 ] [die stop] ] end

updates turtles-own [bank-bal n-sales parent] crt to setup... crt n-telemar [... set parent nobody

Using links to reach parents if aparent set a directed link

NetLogo code -account to account let cost 50 * sıze let income 2 * n-sales let profit income - cost ifelse any? my-out-links [ set bank-bal bank-bal * profit ask one-of out-link-neighbors [set bank-bal 0.5 * profit ] ] [ set bank-bal bank-bal + profit ] if bank-bal > growth-param [ set sıze sıze + size-param * ( bank-bal - growth-param ) set bank-bal 1000 ]

NetLogo code -account if bank-bal < 0 and any? my-out-links [ let bank-bal-par [bank-bal] of one-of out-link-neighbors ifelse bank-bal-par > ( -1 * bank-bal ) [ ask one-of out-link-neighbors [set bank-bal bank-bal + [bank-bal] of myself ] set bank-bal 0.0 ] [die stop] ]

NetLogo code -account if bank-bal < 0 and not any? my-out-links [ let pot-parents other turtles with [ sıze > [sıze] of myself and bank-bal > -1 * [bank-bal] of myself ] ifelse any? pot-parents [ create-link-to one-of pot-parents ask one-of out-link-neighbors [set bank-bal bank-bal + [bank-bal] of myself ] set bank-bal 0 ] [die stop] ] end

6. The Customers Fight Back: Remembering Who Cslled custmers talernce limit if cals from a marketer exceeds taht limit reject call

NetLogo code - sales to sales let radius 10 * sqrt sıze let max-call floor ( 100 * sıze ) let pot-custs patches in-radius radius if count pot-custs > max-call [ set pot-custs n-of max-call pot-custs ] set pot-custs pot-custs with [pcolor = black] set pot-custs pot-custs with [ accept-call myself] set n-sales count pot-custs ask pot-custs [ set pcolor red ] end

NetLogo code – accept-call to-report accept-call [marketer] let num-calls length filter [? = marketer] caller- list set caller-list fput marketer caller-list report num-calls <= tol-lim end

NetLogo code – initilalizations patches-own [caller-list tol-lim] to setpu... ask patches [ set pcolor black set tol-lim 5 + random 16 set caller-list [] ] end