Evolutionary Simulation 83
The initial group size: N
The initial female ma le ratio (ratio of males to total population):
male_femaleRatio
The initial T genotype ratio (ratio of T
1
genotype to total population):
tGeneratio
The initial P ge notype ratio (ratio of P
1
genotype to total po pulation):
pGeneRatio
The probability of death of males of T
0
genotype: maleDeathProb
The probability of extinction of males of T genotype: sRatio, males of
T
1
genotype will survive with (1sRatio) times the probability as T
0
genotype males
The probability of extinction of females: femaleDeathProb
Mating pr obability a
0
by the Kirkpatrick model: a0Coeff
Mating pr obability a
1
by the Kirkpatrick model: a1Coeff
End ge neration of simulation: EndTime
Lifetime o f an individual: lifetime
Children born by mating once: numChild
Executing the program displays the genotype frequency of ea ch genotype
and the number of individuals in each genotype (Fig. 4.8). Simulation stops
when either males or females become extinct or the end generation is reached.
An individual’s life and/or number of children c an be specified by the
parameters mentioned above. Furthermore, setting the extinction pr obability
other than the T
0
genotype is also possible. Through this, the simulation of
very reproductive individuals and individuals with longer life can be done.
Note that in the Kirkpatrick model, geographica l conditions are not used,
and basically random mating is done. Let’s try to implement the g e nder se-
lection process in a two-dimensional grid model in Swarm. In the simulation
below, the rules of movement of an individual are as follows:
1. Female chooses one mating partner from among the males in sight (a
square with side lengths of 2×visibility+1) depending on the fre-
quency and a
0
, a
1
, and produces a child.
2. After that, the male and the female bo th move randomly.
The state of execution is shown in Fig. 4.9. The display in simulation and
graphs is as follows:
84 Agent-Based Modeling and Simulation with Swarm
FIGURE 4.8: Swarm simulation based on Kirkpatrick’s model.
Orange male_t0 Male expressing the tr aits of T
0
Blue male_t1 Male expressing the traits of T
1
Green female_p0 Female expressing the traits of P
0
Yellow female_p1 Female expressing the traits of P
1
4.3 Simulation of the prisoner’s dilemma
4.3.1 The prisoner’s dilemma
Two susp e c ts (A and B) have been arrested by the police for a certain crime
(Fig. 4.10). Although the suspects are accomplices and their guilt is strongly
suspected, insufficient evidence exists to prove their guilt beyond doubt, and
therefore the police separ ate the suspects a nd wait fo r a confession. A and B
can adopt one of two strategies, na mely, to confess (i.e., to defect, denoted
by D below) or refuse to confess (i.e., to cooper ate, denoted by C b e low),
as shown in Table 4.1. The case where A does not confess is labeled A1,
and the case where A confesses is la beled A2. Similarly for B, B1 denotes a
refusal to confess and B2 denotes a confession. If neither suspect confesses,
both of them would receive two-year sentences; however, if only one of them
confesses, the one confessing would be sentenced to only one year due to
extenuating circumstances, while the other suspect would receive a five-year
Evolutionary Simulation 85
FIGURE 4.9 (See Color Insert): Sexual selection in a two-dimensional
space.
sentence. Finally, if both suspects confess, both of them would receive three-
year sentences.
Therefore, although the sentence is only two years for both s uspe c ts if
neither of them c onfesses, the loss for one suspect is co nsiderably greater
if a confession is obtained from only their accomplice. The dilemma here is
whether A and B should confess. In terms of pure strategy, it is straightfor-
ward to show that the pair (A2, B2) is an equilibrium point, and that no
other equilibrium points exist. Here, the equilibrium point indicates that if
either suspect adopts confession as their strategy, their accomplice is at a dis-
advantage if they do not a dopt the same strategy. Conversely, if the suspects
adopt the strategic pa ir (A1, B1), neither suspect confesses in the belief that
their accomplice will not confess either, and the sentence for both of them is
only two years. This sentence is obviously a more favorable outcome than the
equilibrium point for both suspects, but since the suspects are separated from
each other when taken into custody, they are unable to c ooperate. This type
of game is known as the prisoner’s dilemma.
Situations such as those arising in the prisoner’s dilemma are also often
encountered in biology as well as in human soc iety. Fo r example, if an appro-
86 Agent-Based Modeling and Simulation with Swarm
FIGURE 4.10: The prisoner’s dilemma.
TABLE 4.1: Benefit and cost in the prisoner’s dilemma.
(a) Benefit and cost fr om the v iew point of A
B
1
B
2
B: not confess (C) B: confess (D)
A
1
2 5
A: not confess (C) Two years of impris onment Five years of imprisonment
A
2
1 3
A: confess (D) One year o f imprisonment Three years of imprisonment
(b) Benefit and c ost from the viewpoint of B
B
1
B
2
B: not confess (C) B: confess (D)
A
1
2 1
A: not confess (C) Two years of imprisonment One year of imprisonment
A
2
5 3
A: confess (D) Five years of imprisonment Three years of imprisonment
Evolutionary Simulation 87
priate incentive is present, the following situations can be modeled similarly
to the prisoner’s dilemma.
Social interaction betwee n animals in nature:
Social grooming in primates
Cleaner fish and the fish that they clean
Parasites and hosts
Social interaction betwee n humans:
Interaction between countries
Interaction between tribes
4.3.2 Iterated prisoner’s dilemma
This section considers an extended version of the prisoner’ s dilemma known
as the “iterated prisoner’s dilemma” (IPD), in which the prisoner ’s dilemma
is repeated a number of times w ith the same participants, and a final score
is obtained as the sum of the scores in all iterations. Hereinafter, the choice
made at ea ch step is referred to as a move, o r more precisely, a move indicates
either cooperation (C: no confession) or defection (D: confession).
As with the priso ner’s dilemma, situations similar to an IPD can re gularly
be observed in nature and in human society. A well-known example is regur-
gitation in vampire bats [25]. These small bats, living in Central and South
America, feed on mammalian blood at night. However, their bloodsucking en-
deavors are no t always successful, and at times they face starvation. Therefore,
vampire bats that successfully fed will regurgitate part of their food and share
it with other vampire bats that were una ble to find food. Bats who receive food
in this manner later return the favo r. Wilkinson et al. observed 110 instances
of regurgitation in vampire ba ts, of which 77 ca ses were from a mother to her
children, and other genetic relations were typically involved in the remaining
cases [120A]. Nevertheless, in several cases r e gurgitation was also witnessed
between companions sharing the same den, with no genetic affinity. Model-
ing this behavior o n the basis of the prisoner’s dilemma, where cooperation
is defined as regurgitation and defection is defined as the lack ther e of, yields
results simila r to those in Table 4.2. A correlation between weight loss and the
possibility of death due to starvation has also been found in bats. Therefore,
the same amount of blood is of completely different value to a well-fed bat
immediately after feeding and to a bat that has almost starved to death. In
addition, it appear s that individual bats can identify each other to a certain
extent, and as a result they can conceivably determine how a certain compan-
ion has behaved in the pas t. Thus, it can be said that bats will donate blood
to old friends.”
To set up the IPD, one player is denoted as P
1
and the other party is
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.15.194.172