47
An Introduction to Multi-agent Simulation 31-05-2002

An Introduction to Multi-agent Simulation 31-05-2002

  • View
    217

  • Download
    0

Embed Size (px)

Citation preview

An Introduction to Multi-agent Simulation

31-05-2002

                          

2\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Context and Issues

Introduction to simulation

Multi-agent simulation

Business process modelling and simulation

Simweb perspective

Modelling exercise

Agenda

3\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Context and Issues

Introduction to simulation

Business process modelling and simulation

Multi-agent simulation

Simweb perspective

Modelling exercise

Agenda

4\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

This seminar is a deliverable of work package 1, “Participatory Problem Analysis”

The objective of is to1. Refine the definition of the problem and the user requirements

2. Establish a common knowledge base among all participants in the project

We should add “model specifications” to the first point When talking about building models in SimWeb, we should

distinguish two aspects1. Creating the model infrastructure

2. Implementing the sector model(s)

Today we would like to gain a better understanding of what we can expect as input from the other partner activities and how the modelling process takes account of the information

Context and IssuesObjective of the Training Seminar: The Modeler’s View

5\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Context and IssuesThe Modelling Process

“No-Model”

Real-World

Description

Market

Analysis

Simulation

System

EvaluationFeedback

Stakeholders

Mo

del

Infr

astr

uct

ure

Calibration

How?

6\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

... the strategy of the market analysis – what are you looking for and how is this decided?

... how the results of the market analysis can be used to build the sector models

... how the choice of model (MA simulation in our case) constrains the market analysis methodology – e.g. aggregate vs. agent model

... how MA models are designed and adjusted in other areas of social science (e.g. Firma) – the process

... if, how, and when the participatory evaluation methodology influences the modelling process

We propose to set up a work package spanning task to address this problem

Context and IssuesWe would like to (better) understand...

7\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Context and Issues

Introduction to simulation

Business process modelling and simulation

Multi-agent simulation

Simweb perspective

Modelling exercise

Agenda

8\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulationFormal modelling

mathematical analysismathematical analysis computer simulationcomputer simulation

formal modellingformal modelling

physical sciencesphysical sciences social sciencessocial sciences

9\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Understanding of features in the social world Prediction: e.g. business forecasting, demography over the

years Tools: expert systems (simulate expertise of professionals) Training: flight simulators, simulators of national economies Entertainment: SimCity, Sims, flight simulators... Formalisation: theory (precise, coherent, complete) Discovery of consequences in the artificial society

Introduction to simulationThe uses of simulation

10\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

parameter estimationsimulation

predicted datapredicted data

Introduction to simulationThe logic of simulation

modelmodel simulated datasimulated data

targettarget collected datacollected data

abstraction similarity

data gathering

11\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulationStages of simulation-based research

designing a modeldesigning a model building the modelbuilding the model verification and validation

verification and validation publicationpublication

12\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulationModel accuracy

simplicity accuracy

understanding prediction

13\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulationSocial simulation: special features

simple behaviour and simple rules -> complex organisation (sand pile, ants...)

mathematical analysis impossible

simple behaviour and simple rules -> complex organisation (sand pile, ants...)

mathematical analysis impossible

complexitycomplexity

local information

limited capacity to process information

local information

limited capacity to process information

bounded-rationalitybounded-rationality

appears without central planning from the actions of individual agents

flocks, markets, Internet...

appears without central planning from the actions of individual agents

flocks, markets, Internet...

self-organisationself-organisation

interactions among objects at one level give rise to different types of objects at another level

interactions among objects at one level give rise to different types of objects at another level

emergenceemergence

linear: proportional

non-linear: chaotic

linear: proportional

non-linear: chaotic

non-linearitynon-linearity

14\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Discrete event• event: distinct points of time

• between two consecutive events nothing happens

• number of events are finite

Continuous• the state changes all the time (e.g. water

level in a reservoir)

• discrete event simulation can serve as an approximation.

Introduction to simulationTypes of simulation

t

t

15\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulation

Business process modelling and simulation

Multi-agent simulation

Simweb perspective

Modelling exercise

Agenda

16\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Business Process Modelling and Simulation

BPM commercial software packages facilitate business process improvements through modelling and simulation.

They allow to:• Model your processes to define, document, and communicate.

• Simulate the future performance of your business to understand complex relationships and identify opportunities for improvement.

• Visualise your operations with dynamic animation graphics.

• Analyse how your system will perform in its “as-is” configuration and under a myriad of possible “to-be” alternatives so that you an confidently choose the best way to run your business.

17\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Mortgage Applications• Simple mortgage application review process.

Truck Assembly• This model demonstrates the operations of a truck assembly line. A

new truck chassis enters the line every 9.5 minutes. It is then conveyed down the line from work position to work position, whereby each work position adds a part or performs an operation.The model animation includes a display of utilization statistics for each work position, as well as the number of trucks produced.

Flexible Manufacturing• This model shows a detailed operation of a typical factory. The Factory

includes an Injection molding area, machining centre, foam gasket assembly, painting area, and warehouse. Detailed statistics are kept for performance measurements at each area.

Business Process Modelling and SimulationExamples

18\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Mortgage ApplicationSimulation Run

19\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Mortgage ApplicationReports

20\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Truck AssemblySimulation Run

21\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Flexible ManufacturingSimulation Run

22\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulation

Business process modelling and simulation

Multi-agent simulation

Simweb perspective

Modelling exercise

Agenda

23\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

“Computational system situated in some environment, that is capable of flexible autonomous action in order to meet its design objectives” [Jennings et al. 1998]

By flexible, it is meant that the system is:• Responsive. Agents perceive and respond to their environment.

• Pro-active. Goal-directed behaviour; agents take the initiative.

• Social. Capability of interacting with artificial agents and humans.

Multi-agent simulationWhat is an agent? A weak definition

24\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationSimulation and the environment

Collective behavioiurs of a system’s components can have dynamics that influence the environment. If so

• constraints on components are not fixed• attempts to analyze the system must provide ongoing

mutable parameterization of the environment

Even when a clean formulation is possible, analysis often involves concurrent expansion of recursive functions -> analytical compression is hard or impossible

25\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

To study complex nonlinear systems e.g.• Organisms Cell behavior drives and is driven-by

metabolism, hormones• Ecologies The viability of a certain species being

dependent on a complex of other species• Economies Consumer behaviour drives economy.

Economy places constraints on consumers.• Transportation Automobiles make up traffic patterns.

Traffic jams constrain drivers

Multi-agent simulationWhy multi-agent simulation?

26\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

With synthesis, the modeller aims to accurately describe a systems' components and plausible interactions, and then use a realization of that description as an empirical basis for study of the systems' global dynamics.

This bottom up approach is called Agent-Based Modelling (ABM). ABM complements and enhances, rather than supplants, traditional

approaches.

Agent-based models allow us to study • Spatial interaction• Adaptive, heterogeneous agents• Agents which face costs of information acquisition and

processing• Nested subsystems - economy, markets, firms, plants, employees• etc.

Multi-agent simulation Why multi-agent simulation? Synthesis and Analysis

27\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Organizations of agents

Animate agents

Data

Artificial world

Observer

Inanimate agents

If <cond>

then <action1>

else <action2>

If <cond>

then <action1>

else <action2>

Multi-agent simulationHow to

28\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Simulation proceeds in discrete time steps

Interaction between agents or procedures within simulation may have own event schedule

Multi-agent simulationDiscrete event simulation

29\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Software:• AgentSheets

• ARVA (cellular automata)

• Ascape

• CABLE

• CORMAS

• EVO (Swarm-based)

• MAGSY

• Multi-agent modelling language – MAML (Swarm-based)

• REPAST (Java, Swarm-like)

• Sim_Agent

• Swarm

• XRaptor

Multi-agents simulationSoftware

30\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Swarm

Sub-Swarm

Agent

Schedule The Model

Multi-agent simulationAn implementation: Swarm

The Interface

Probes

Objective C, Java… Object-oriented (not agent-oriented) Structure:

31\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

A Swarm as a virtual computer

A computer’s CPU executes program instructions

Swarm kernel is virtual CPU running model and GUI events

Nested Swarms merge activity schedules into one

Operating System

CPU

Swarm kernel

GUI Model

Multi-agent modelsAn implementation: Swarm

32\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Examples:• Sugarscape

• MANTA

• Evolution of organised society (EOS)

• SFI Artificial Stock Market

• Fish Market

Multi-agents simulationExamples

33\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulation Artificial stock market: why agent-based simulation?

Agent-based

simulation

Agent-based

simulation

Agents are heterogeneous!!! They act and evolve differently (there are signs of heterogeneity in the rules that financial agents apply)

Agents are not hyper-rational utility maximising but rationally bounded

Mathematical analysis too complex. Difficult to obtain the clean solutions found for homogeneous agents.

Agents are heterogeneous!!! They act and evolve differently (there are signs of heterogeneity in the rules that financial agents apply)

Agents are not hyper-rational utility maximising but rationally bounded

Mathematical analysis too complex. Difficult to obtain the clean solutions found for homogeneous agents.

Standard

economic

theory

Standard

economic

theory

Agents are homogeneous

• same demand functions for assets

• rational expectations about prices and dividends There exists unique price that clears the market Researchers can obtain analytical solutions

Agents are homogeneous

• same demand functions for assets

• rational expectations about prices and dividends There exists unique price that clears the market Researchers can obtain analytical solutions

34\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Standard neo-classical model of asset pricing Agents are risk averse. Agents have heterogeneous demand functions for the asset

that change based on their prediction of next period asset price and dividend.

Each agent employs a number of different ways to forecast prices and dividends.

Agents evolve over time via evolutionary algorithms. Auctioneer calculates the price the most closely cleas the

market.

Multi-agent simulation Artificial stock market: multi-agent model

35\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationArtificial stock market: multi-agent simulation parametrisation

numBFagents – the number of agents in the simulation.

initholding – the initial asset holding of each agent.

initialcash – the initial cash holding of each agent.

minholding – the minimum asset holding of each agent (short selling constraint).

mincash – the minimum cash holding of each agent (borrowing constraint).

intrate – the interest rate.

baseline – the dividend baseline.

mindividend – the minimum dividend.

maxdividend – the maximum dividend.

amplitude – the amplitude of deviations from the baseline.

period – the mean period or auto-correlation time.

exponentialMAs – whether moving averages are exponential or uniform

maxprice – the maximum price.

minprice – the minimum price.

taup – moving average healing time for profit.

sptype – the specialist type

maxiterations – the maximum number of price iterations for iterative specialists.

minexcess – the target for |bids - offers| for iterative cases.

eta – the amount by which price changes per bid or offer for eta specialist.

etamax – maximum value of eta with the adaptive eta specialist.

etamin – minimum value of eta with the adaptive eta specialist.

rea – dividend multiplier for RE price with the re specialist.

reb – constant offset for RE price with the re specialist.

randomSeed – the random number seed for the market and specialist (0 is random).

tauv – moving average healing time for forecaster variances.

numBFagents – the number of agents in the simulation.

initholding – the initial asset holding of each agent.

initialcash – the initial cash holding of each agent.

minholding – the minimum asset holding of each agent (short selling constraint).

mincash – the minimum cash holding of each agent (borrowing constraint).

intrate – the interest rate.

baseline – the dividend baseline.

mindividend – the minimum dividend.

maxdividend – the maximum dividend.

amplitude – the amplitude of deviations from the baseline.

period – the mean period or auto-correlation time.

exponentialMAs – whether moving averages are exponential or uniform

maxprice – the maximum price.

minprice – the minimum price.

taup – moving average healing time for profit.

sptype – the specialist type

maxiterations – the maximum number of price iterations for iterative specialists.

minexcess – the target for |bids - offers| for iterative cases.

eta – the amount by which price changes per bid or offer for eta specialist.

etamax – maximum value of eta with the adaptive eta specialist.

etamin – minimum value of eta with the adaptive eta specialist.

rea – dividend multiplier for RE price with the re specialist.

reb – constant offset for RE price with the re specialist.

randomSeed – the random number seed for the market and specialist (0 is random).

tauv – moving average healing time for forecaster variances.

36\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationArtificial stock market: multi-agent simulation parametrisation

numfcasts – number of forecasters per agent.

tauv – moving average healing time for forecaster variances.

lambda – the degree of agent risk aversion.

maxbid – the maximum bid or offer.

selectionmethod – the method by which to select between activated rules: best, roulette, or average.

mincount – the minimum number of observations before a forecaster is used.

subrange – this is used for initialization of the forecast parameters a, b, and c.

min and max values of the parameter a ( the coefficient on pt+dt in the prediction equation).

min and max values of b (the coefficient on dt).

min and max values of c (the constant term).

newfcastvar – variance assigned to a new forecaster.

initvar – variance of overall forecast for time steps t < 200.

bitcost – penalty parameter for specificity (i.e., non-hashed bits in a forecaster).

maxdev – max deviation of a forecast in variance estimation.

individual – whether to use individual forecast variances: yes or no.

bitprob – probability each bit is either 0 or 1 (i.e., non-hashed) initially.

numfcasts – number of forecasters per agent.

tauv – moving average healing time for forecaster variances.

lambda – the degree of agent risk aversion.

maxbid – the maximum bid or offer.

selectionmethod – the method by which to select between activated rules: best, roulette, or average.

mincount – the minimum number of observations before a forecaster is used.

subrange – this is used for initialization of the forecast parameters a, b, and c.

min and max values of the parameter a ( the coefficient on pt+dt in the prediction equation).

min and max values of b (the coefficient on dt).

min and max values of c (the constant term).

newfcastvar – variance assigned to a new forecaster.

initvar – variance of overall forecast for time steps t < 200.

bitcost – penalty parameter for specificity (i.e., non-hashed bits in a forecaster).

maxdev – max deviation of a forecast in variance estimation.

individual – whether to use individual forecast variances: yes or no.

bitprob – probability each bit is either 0 or 1 (i.e., non-hashed) initially.

37\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationArtificial stock market: multi-agent simulation output

38\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationFish market (I)

39\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationFish market (II)

40\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Multi-agent simulationFish market (III): tournament setting

41\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulation

Business process modelling and simulation

Multi-agent simulation

Simweb perspective

Modelling exercise

Agenda

42\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Simweb perspective Multi-agent simulation for strategical decision

Simweb allows to research or adapt business models to new reality of digital content markets.

Simweb allows to determine business models which minimise the risk over a rank of possible futures, as well as those with the highest success or failure probability.

Simweb uses multi-agent simulation to forecast the reacheable market shares for each scenario.

Simweb is based on market characterisation:• consumers (i.e. bargain hunters, image sensitives...)• products (i.e. low-cost, high marketing investments...)• providers (business models)

43\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Simweb perspectiveDigital content distribution model

<20 years old <10 €/month high bandwidth >30 conn/week

<20 years old <10 €/month high bandwidth >30 conn/week

20-35 years old 15-30 €/month high bandwidth <5 conn/week

20-35 years old 15-30 €/month high bandwidth <5 conn/week

month subscription: 20€ max: 10 downlds

month subscription: 20€ max: 10 downlds

pay-per-download: 0,10€

max: 1 Mb/s

pay-per-download: 0,10€

max: 1 Mb/s

consumers

providers

44\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Expected Market Share

Decision MakerNEW

MARKET

STRATEGY

Simweb perspective Multi-agent simulation for supporting strategical decisions

Simweb is meant to be a strategic decision support tool to help select the most succesful business models in the digital contents sector.

45\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Introduction to simulation

Business process modelling and simulation

Multi-agent simulation

Simweb perspective

Modelling exercise

Agenda

46\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Modelling exerciseFish market

47\\Users\iSOCOLab\Projects\Simweb\SIMWEB-MAS-20020531-jar

Agent Description• Why multi-agent simulation?

• Describing agent roles

• Describing agent interactions

How do we implement interaction protocols How do we model the environment? How can we interpret the results? Once the (uncalibrated) model is produced:

• How should we adjust it?

• What elements of the model are affected by the adjustments?- Structural- Parameters

Modelling exerciseTechnical Issues