Ants, agents and product form Contents

advertisement
Ants, agents and product form
Nigel Thomas
with
Jeremy Bradley and Will Knottenbelt
Contents
•
•
•
•
Massively parallel systems
Modelling ant colonies (David Sumpter)
El Botellón (Jon Rowe)
Conclusions and further work
1
Massively parallel systems
• Many instances of a small number of simple
component types,
– e.g. insect colonies (Sumpter et al) and crowd
dynamics (Rowe et al).
• Global behaviour is complex, despite simple
components.
• The state space is generally huge.
• Measures of interest are transient as well as steady
state.
Modelling insect colonies
• Sumpter has considered a number of different scenarios
using WSCCS.
• “Uses process algebra as they were always meant to be
used!” (Bradley).
Active ≡ p:√ .Passive + q:√ .Active
Passive ≡ 1:√ .Active
Colonyn(i) ≡ Active × … × Active × Passive × … × Passive
i
n-i
2
Ants in continuous time
• n ants, either active or passive, at least one
active, (nb. pair-wise cooperation).
Active
def
Passive
def
∏ Active
n
( sleep, r1 ).Passive + ( sleep, T).Active
( wakeup , r2 ). Active
{ sleep }
Product form
• This model has a product form solution over
the components, such that,
Pr[i Active & j Passive] = 1 .π i
.π j
B Active Passive
where,
B = 1 -π
n
Passive
3
Alternative representation
• Sumpter’s analysis sums active and passive
ants. In standard PEPA:
Activei
def
def
Passivej
Activen
( sleep, ir1 ). Activei −1 + ( wakeup, T). Activei +1 , n ≥ i > 0
( wakeup, jr2 ).Passivej −1 + ( sleep, T).Passivej +1 , n − 1 ≥ j > 0
{sleep,wakeup}
Passive0
Recruiting ants
• n ants, either active, recruiting or passive, at
least one not passive,
Active
def
( sleep, r1 ).Passive + ( sleep, T).Active + (recruit , r3 ).Recruit
Recruiting
def
( sleep, r1 ).Passive + ( sleep, T).Recruit
+ ( wakeup, T).Recruit + (return, r4 ).Active
Passive
def
∏ Active
n
( wakeup, r2 ). Active
{ sleep , wakeup }
4
El Botellón: The Big Bottle
• Rowe and Gomez have modelled a Spanish social
phenomenon whereby spontaneous parties erupt.
– A city is a set of squares connected by alleys.
– People move from square to square pausing to
chat.
– People chat with a given probability dependent on
the number of people present in the square.
– Bars increase the chat and attractiveness of
squares.
• Simulated in discrete time to find the probability of a
party.
5
El Botellón in continuous time
• People are much harder to model than ants!
Sq{ X , Y }0
Sq{ X , Y }i
def
def
( moveto { X , Y }, T ). Sq{ X , Y }1
( moveto { X , Y }, T ). Sq{ X , Y }i +1
ir
(1-c ) i-1 ).Sq{ X , Y }i −1
d
ir
+ ( moveto { X , Y ± 1}, (1-c ) i-1 ).Sq{ X , Y }i −1 , 0 < i ≤ n
d
+ ( moveto { X ± 1, Y },
∏
∀{ X , Y }
Sq{ X , Y }
{ moveto { X ,Y }}
Steady state probability that all agents are in the
same square varied with chat probability, c.
population = 10
1
0.8
0.6
0.4
0.2
0
0.1
0.2
0.3
0.4
chat probability
6
Conclusions
• Massively parallel systems are of practical interest
but are costly to analyse.
• Product form can give one way to tackle this
problem.
– However, only when systems are modelled in
the right way!
• What we really want to find are transient results:
time to extinction, time to party, etc.
– These are somewhat harder!
– We’d like to apply Sumpter’s analysis to
continuous time models.
References
• Sumpter, Blanchard and Broomhead, Ants and
Agents: a Process Algebra Approach to Modelling
Ant Colony Behaviour.
• Bradley, Ants and Agents: Global Complexity
from Local Simplicity, PASTA 2002.
• Rowe and Gomez, El Botellón: Modelling the
Movement of Crowds in a City.
7
Download