scieee AI-readable full text Open interactive document viewer

Evolution of cooperation in social dilemmas with assortative interactions

Iyer, Swami,Killingback, Timothy

Abstract

EconStor is a publication server for scholarly economic literature, provided as a non-commercial public service by the ZBW.

Full text

Iyer, Swami; Killingback, Timothy Article Evolution of cooperation in social dilemmas with assortative interactions Games Provided in Cooperation with: MDPI – Multidisciplinary Digital Publishing Institute, Basel Suggested Citation: Iyer, Swami; Killingback, Timothy (2020) : Evolution of cooperation in social dilemmas with assortative interactions, Games, ISSN 2073-4336, MDPI, Basel, Vol. 11, Iss. 4, pp. 1-31, https://doi.org/10.3390/g11040041 This Version is available at: https://hdl.handle.net/10419/257459 Standard-Nutzungsbedingungen: Die Dokumente auf EconStor dürfen zu eigenen wissenschaftlichen Zwecken und zum Privatgebrauch gespeichert und kopiert werden. Sie dürfen die Dokumente nicht für öffentliche oder kommerzielle Zwecke vervielfältigen, öffentlich ausstellen, öffentlich zugänglich machen, vertreiben oder anderweitig nutzen. Sofern die Verfasser die Dokumente unter Open-Content-Lizenzen (insbesondere CC-Lizenzen) zur Verfügung gestellt haben sollten, gelten abweichend von diesen Nutzungsbedingungen die in der dort genannten Lizenz gewährten Nutzungsrechte. Terms of use: Documents in EconStor may be saved and copied for your personal and scholarly purposes. You are not to copy documents for public or commercial purposes, to exhibit the documents publicly, to make them publicly available on the internet, or to distribute or otherwise use the documents in public. If the documents have been made available under an Open Content Licence (especially Creative Commons Licences), you may exercise further usage rights as specified in the indicated licence. https://creativecommons.org/licenses/by/4.0/ games Article Evolution of Cooperation in Social Dilemmas with Assortative Interactions Swami Iyer 1and Timothy Killingback 2,* 1Department of Computer Science, University of Massachusetts, Boston, MA 02125, USA; [email protected] 2Department of Mathematics, University of Massachusetts, Boston, MA 02125, USA *Correspondence: timothy[email protected] Received: 4 July 2020; Accepted: 16 September 2020; Published: 23 September 2020   Abstract: Cooperation in social dilemmas plays a pivotal role in the formation of systems at all levels of complexity, from replicating molecules to multi-cellular organisms to human and animal societies. In spite of its ubiquity, the origin and stability of cooperation pose an evolutionary conundrum, since cooperation, though beneficial to others, is costly to the individual cooperator. Thus natural selection would be expected to favor selfish behavior in which individuals reap the benefits of cooperation without bearing the costs of cooperating themselves. Many proximate mechanisms have been proposed to account for the origin and maintenance of cooperation, including kin selection, direct reciprocity, indirect reciprocity, and evolution in structured populations. Despite the apparent diversity of these approaches they all share a unified underlying logic: namely, each mechanism results in assortative interactions in which individuals using the same strategy interact with a higher probability than they would at random. Here we study the evolution of cooperation in both discrete strategy and continuous strategy social dilemmas with assortative interactions. For the sake of tractability, assortativity is modeled by an individual interacting with another of the same type with probability r and interacting with a random individual in the population with probability 1 −r , where r is a parameter that characterizes the degree of assortativity in the system. For discrete strategy social dilemmas we use both a generalization of replicator dynamics and individual-based simulations to elucidate the donation, snowdrift, and sculling games with assortative interactions, and determine the analogs of Hamilton’s rule, which govern the evolution of cooperation in these games. For continuous strategy social dilemmas we employ both a generalization of deterministic adaptive dynamics and individual-based simulations to study the donation, snowdrift, and tragedy of the commons games, and determine the effect of assortativity on the emergence and stability of cooperation. Keywords: evolutionary game theory; replicator dynamics; adaptive dynamics; prisoners dilemma; hawk-dove game; coordination game; tragedy of the commons 1. Introduction The evolution and stability of cooperative behavior in social dilemmas is a key aspect of the formation of biological systems at multiple levels of complexity, ranging from replicating molecules, at the lower level, to multi-cellular organisms, at the mid level, to human societies, at the high level. Some examples of cooperation in social dilemmas include: formation of early replicating molecules to form larger replicating systems capable of enhanced information encoding [ 1 , 2 ]; integration of the originally autarchic prokaryote precursors of mitochondria and chloroplasts into eukaryotic cells [ 2 ]; differential production of replication enzymes in an RNA phage [ 3 ]; blood meal donation to roost mates by vampire bats [ 4 ]; predator inspection in fish [ 5 ]; allogrooming in social mammals [ 6 ]; Games 2020,11, 41; doi:10.3390/g11040041 www.mdpi.com/journal/games Games 2020,11, 41 2 of 31 alarm calls in response to danger by mammals and birds [ 7 ]; contribution to a wide variety of public goods [ 8 ], including, social security, health and welfare programs; restraint in consuming common pool resources [ 9 , 10 ], such as responsible use of fishing stocks, limiting the emission of pollution into the atmosphere, and sharing Internet bandwidth; correct implementation of the Transmission Control Protocol (TCP) so as to avoid congestion in Internet traffic [ 11 ]; and file sharing over peer-to-peer networks [12]. Despite the widespread emergence of cooperation in social dilemmas it has proved to be fundamentally challenging to achieve a satisfactory understanding of the origin and maintenance of this phenomenon [ 2 , 13 – 18 ]. The difficulty in achieving such an understanding is a direct consequence of the nature of a social dilemma itself. A social dilemma may be defined, in classical game theory, as a game which possesses at least one socially inefficient Nash equilibrium [ 16 , 19 ], and in evolutionary game theory, as a game that possesses at least one socially inefficient evolutionary attractor, such as an evolutionary stable strategy [ 20 , 21 ], a stable equilibrium point of the replicator dynamics [ 22 , 23 ], a convergent stable singular strategy of the adaptive dynamics [ 24 – 27 ], or an attracting state in stochastic evolutionary dynamics [ 28 – 33 ]. Since in a social dilemma adopting the strategy at the socially inefficient equilibrium or attractor constitutes defection, while adopting the socially efficient strategy is considered to be cooperation, the nature of the dilemma is that individuals employing strategies corresponding to the socially inefficient attractor will be trapped there by the evolutionary dynamics, despite all individuals being better off if they adopted socially efficient behavior. As an aside it is interesting to note that many acts of cooperation (when the word cooperation is taken in the literal sense meaning the “process of working together to the same end”) may have a direct benefit to the cooperating individual that exceeds the cost (see for example [ 34 ]). The emphasis on considering cooperation in social dilemmas in theoretical work is due to this case providing the most challenging theoretical problems, rather than cooperation in social dilemmas being necessarily more common than other forms of cooperation. A considerable number of different approaches to understanding the evolution of cooperation in social dilemmas have been studied [ 35 ]. These include: kin selection [13,36], direct reciprocity [14,37–39] , indirect reciprocity [ 40 , 41 ], evolution in network structured populations [ 19 , 42 – 75 ], and evolution in group structured populations [ 76 , 77 ]. The underlying logic in all these approaches is that they all result in individuals assorting positively, that is, individuals of the same type interact with a greater probability than they would at random. The fundamental role of assortativity in promoting cooperative behavior was already clearly recognized by Hamilton in his work on inclusive fitness [ 78 ]. The central position occupied by assortativity in the evolution of cooperation through kin selection was made even more explicit by Grafen in his geometric interpretation of relatedness [ 79 , 80 ]. Grafen’s interpretation of relatedness in terms of assortativity is also discussed in [81]. Assortativity is clearly also a key feature of many other proximate mechanisms for promoting the evolution of cooperation. For example, in network structured populations [ 37 , 43 – 64 , 66 – 70 , 72 , 73 ] and in group structured populations [ 76 , 77 ], the formation of clusters of cooperators results in preferential interactions between cooperators [ 50 ]. The general role played by assortativity in the evolution of cooperation has also been considered recently in [82]. We should emphasize here that many of the most important challenges in understanding the evolution of cooperation center on identifying the different proximate mechanisms that give rise to the assortativity that results in cooperation. However, it is also important to study the effect of assortativity in its own right on the evolution of cooperation. The most significant reason for studying assortativity in its own right is that if it can be shown that positive assortativity leads to some particular outcome in the evolution of cooperation then that provides a rationale for expecting that that outcome will occur for many different proximate mechanisms for obtaining cooperation. In the present paper we give a detailed and systematic study of the effect of positive assortative interactions, modeled in the manner originally suggested by [ 79 , 80 ], on the evolution of cooperation in a wide variety of both discrete and continuous strategy social dilemmas. In such a system, an individual Games 2020,11, 41 3 of 31 interacts with another of the same type with probability r and interacts with a random individual in the population with probability 1 −r (where r is a parameter that characterizes the degree of assortativity in the system). In this paper we take assortativity to be “positive” in the sense that a given individual has a higher probability of interacting with its own type than would be expected at random. The main reason why we focus here on this case is that most mechanisms through which assortativity naturally emerges result in positive assortativity. Perhaps the paradigm of such a situation is evolutionary dynamics in a spatially structured population. In such a population the spatially local nature of the interaction and reproduction processes typically results in the offspring of an individual being localized in the same region of space, and consequently individuals of the same type will often interact with a higher probability than expected from their frequencies in the total population. Thus, evolutionary dynamics in spatially structured populations often results in positive assortativity. It would be interesting to also consider the possibility of “negative” assortment, in which a given individual would interact with its own type with a lower probability than expected at random. To allow both positive and negative assortativity in a model would require that the degree of assortativity should be dependent on the strategy adopted by the individual, since an individual with a given strategy clearly cannot assort both positively and negatively. In the case of 2 × 2 games the generalization to also allow negative assortment would be relatively straight forward. However, for finite strategy games with more than two strategies or for continuous strategy games, the models would be considerably more complicated. For example, in the case of a continuous strategy game, it would be necessary to specify an “assortativity kernel” that would describe precisely the amount of positive or negative assortativity that any given strategy experiences. Despite the possible complications that may arise, studying the effects of negative as well as positive assortment seems to be an interesting area for future research. It should also be noted that a different and important approach to elucidating the general role played by assortative interactions in promoting the evolution of cooperation focuses on the use of Price’s equation [ 83 ]. This approach was first developed by Hamilton [ 78 ], and has been more recently studied in [84]. We consider here three discrete strategy social dilemmas: the donation game, the snowdrift game, and the sculling game. The donation game is the fundamental exemplar in the prisoner’s dilemma class of games, and provides the basic game theory model for altruism [ 13 , 17 , 18 ]. The snowdrift game is an exemplar of a social dilemma in the hawk-dove class of games [ 15 , 18 ]. While games of hawk-dove type have been extensively studied as models of conflicts and contests [ 20 , 21 , 85 ], the snowdrift game provides an interesting model for certain types of cooperative behavior that differ from pure altruism [15,17] . The sculling game, is an exemplar of a social dilemma in the coordination class of games. Games in this class have been widely used as models for conventions [ 28 , 29 , 86 ], but they have typically received little attention as models of cooperation, although interesting exceptions to this trend are [56,70,87,88] . The sculling game, as we define it [ 19 ], serves as a model for certain types of cooperative behavior not described by the donation or snowdrift games. We must emphasize here that there is a very substantial literature on the evolution of cooperation in the prisoner’s dilemma with assortative interactions, and we do not claim any great novelty for our results in this case. Equivalent results to those that we have obtained for the discrete donation game can therefore be found in the literature [ 13 , 79 , 80 , 89 – 98 ]. We have discussed the donation game essentially for completeness and to allow comparison with the more novel cases of the snowdrift game and the sculling game. Furthermore, the interesting work [ 98 ] considers some closely related issues. The minimum level of assortativity required to allow cooperation to be stably maintained in the prisoner’s dilemma, hawk-dove, and stag hunt games is described in terms of the payoff matrix entries in [ 98 ], and this leads to a different formulation of some of the results that we obtain here for the discrete strategy games. Games 2020,11, 41 4 of 31 Cooperative behavior is often not discrete in nature. This is true of many of the examples of cooperation given above: for instance, when vampire bats share a blood meal with a roost mate [ 4 ]. Such situations can be described very naturally using social dilemmas formulated in terms of continuous strategy games. The strategies of individuals in the game represent the level of cooperation, or investment, that they make, and are described by continuous variables. The costs and benefits associated with given investments are represented as continuous functions of the investments. Here we consider three continuous strategy games: the continuous donation game [ 50 , 53 ], in which a cooperative investment made by one individual (the donor or investor) towards another individual (the recipient) benefits the recipient but is costly to the donor; the continuous snowdrift game [ 26 ], in which the investment benefits both the donor and the recipient but is also costly to the donor; and the continuous tragedy of the commons game [ 27 ], in which the investment—in this context an investment typically represents the level of consumption of a limited common-pool resource, and cooperative behavior correspond to modest levels of consumption—benefits the investor but is also costly to both the investor and the recipient. For the continuous donation game, just as for the corresponding discrete game, in a well-mixed population cooperation will never evolve: that is, the investments made by individuals in the continuous game will evolve to zero for any cost and benefit functions [ 50 , 99 ]. Various mechanisms have been proposed for the emergence and maintenance of cooperative investments in the game including: spatial [50] and network [53] structure, and reciprocal altruism [99]. For the continuous snowdrift game [ 26 ] and continuous tragedy of the commons game [ 27 ] in a well-mixed population a variety of different evolutionary outcomes are possible, depending on the nature of the cost and benefit functions. For example, for some cost and benefit functions the evolutionary end state of the population consists of all individuals making the same non-zero investment. However, for other cost and benefit functions high and low investing individuals coexist—an outcome termed the “Tragedy of the Commune” [ 26 ]. In the Tragedy of the Commune there is a two-fold social dilemma—not only does evolutionary dynamics result in socially inefficient behavior, but furthermore it forces an unequal outcome in which some individuals make large investments while others invest little or nothing. Here we consider the effects of positive assortativity on the evolution of cooperation in the continuous donation game, snowdrift game and tragedy of the commons game. We discuss the consequences of assortative interactions both for the level of cooperation that arises and for the emergence of dimorphic evolutionary end states. Related works consider the evolutionary dynamics of continuous strategy games with interaction structure [ 34 , 100 , 101 ] and the connection to inclusive fitness theory [ 98 ]. The interesting work [ 101 ] is of particular relevance to our work here in that it considers the effect of relatedness in promoting cooperation in a multi-player version of the continuous snowdrift game. In this work relatedness is introduced in a more general manner to our definition of assortativity: the authors of [ 101 ] consider a probability distribution over the number of co-players that are identical-by-descent to a focal individual, and then quantify this assortment distribution based upon the mean and variance of the assortative interactions. The remainder of this article is organized as follows. In the Models section we formulate the three discrete games in terms of a single cost-to-benefit ratio parameter ρ . We analyze the games using the framework of replicator dynamics generalized to include the degree of assortativity r , and derive mathematical relations (analogs of Hamilton’s rule) involving parameters ρ and r that must be satisfied for the evolution of complete cooperation. We also formulate and analyze the three continuous strategy games using the framework of adaptive dynamics generalized to allow for assortative interactions, and derive conditions that determine the effect of assortativity on the stability of cooperation. In the Results section we describe the results of studying the evolution of cooperation in these discrete and continuous strategy games with assortative interactions using an individual-based model, and we compare the results obtained from these simulations with those obtained analytically from the assortative generalizations of replicator dynamics and adaptive dynamics. Finally, in the Games 2020,11, 41 5 of 31 Discussion section we conclude the article with a discussion of the significance of our results and with some suggestions for further inquiry. 2. Models 2.1. Discrete Games 2.1.1. Replicator Dynamics with Assortative Interactions In general, consider a 2-player game with m pure strategies σ1 , . . . , σm and strategy space S={σ1, . . . ,σm}. Let P be a large population of individuals, each of which uses a strategy from S . We define assortative interactions as follows. An assortative interaction among individuals is an interaction that occurs preferentially among individuals of the same type, i.e., such an interaction occurs among individuals of the same type with a greater probability than would occur through random interactions. In the context of game theory, this means that individuals using the same strategy interact with a probability greater than that which would occur with random interactions. The most direct and convenient way to introduce assortative interactions in a population is to specify a parameter r∈[ 0,1 ] , called the degree of assortativity or simply the assortativity, which is defined as follows: with probability r , an individual interacts with another individual of its own type, and with probability 1 −r , the individual interacts with a randomly chosen individual from the population [ 79 , 80 ]. Thus, we say that the population P is assortatively-interacting or assortatively-mixed, with assortativity r , if an individual in P interacts with another individual in P with the same strategy with probability rand with a randomly picked individual in Pwith probability 1 −r. Let the payoff to strategy σi against σj be denoted by π(σi , σj) . In biological evolution π(σi , σj) represents the change in the Darwinian fitness (that is, the change in the expected number of offspring) of an individual using strategy σi in an interaction with an individual using σj . In social evolution through imitation dynamics π(σi , σj) measures the utility obtained by an individual using strategy σi in an interaction with an individual using σj . At time t , let N(t) be the total size of the population P , and let ni(t) be the number of individuals in P using strategy σi . The frequency of strategy σi is defined to be pi(t) = ni(t) N(t) . If p(t) = (p1(t) , . . . , pm(t)) denotes the vector of frequencies, then the state of the population at time t is given by p(t)∈∆m , where ∆m={p(t)∈Rm +:∑m i=1pi(t) = 1 } is the m-simplex. We now consider how the frequencies of the different strategies σi change with time in an assortatively-interacting population P, with assortativity r, due to natural selection. The fitness fr iof σiis the average payoff of σi, which, from the definition of assortativity, is given by fr i=rπ(σi,σi) + (1−r) m ∑ j=1 pjπ(σi,σj). (1) The dynamics of p(t) on ∆m in an assortatively-interacting population can be determined (in analogy with the non-assortative case [ 17 , 18 , 22 , 23 , 102 ]) as follows. The growth rate of the number of individuals niusing strategy σiis ˙ ni=nifr i. Therefore, ˙ pi=d dt ni N=˙ niN−ni∑j˙ nj N2 =pifr i−pi∑ j pjfr j =pi(fr i−¯ fr), (2) where ¯ fr=∑jpjfr j is the mean fitness of the strategies in the population. This equation is the analog of the standard replicator equation for an assortatively-interacting population. We shall refer to this equation as the assortative replicator equation with assortativity r , or the r -replicator equation for Games 2020,11, 41 6 of 31 short. The r -replicator equation is the natural generalization of the standard replicator equation when assortative interactions are included in the manner proposed by [ 79 , 80 ]. The r -replicator equation is equivalent to the standard (non-assortative) replicator equation under a transformation of the payoffs. If A= (aij) , where aij =π(σi , σj) , is the payoff matrix, then it is elementary to verify that the replicator equation with transformed payoff matrix ˆ A=rB + ( 1 −r)A , where B= (bij) is the matrix such that bij =aii , is equivalent to the r -replicator equation. Notwithstanding this equivalence, however, we feel that the best way to think about the replicator equation when there are assortative interactions is to consider the assortativity as directly affecting how the fitness is defined, as we have done here, since the change in the fitness is clear and natural, whereas the necessary transformation in the payoffs is less clear. Grafen did not formulate the r -replicator equation in his work, since it was unnecessary for his aim of studying evolutionary stable strategies with assortative interactions. Equations similar to the r -replicator equation have been considered for assortativity that depends on the frequencies of the strategies by [ 91 ] and for different population structures (including those that include relatedness) by [92]. For r= 0, the r -replicator equation reduces to the standard replicator equation for a well-mixed population [17,18,22,23,102]: ˙ pi=pi(fi−¯ f), (3) where ¯ f=∑jpjfjis the mean fitness of the population. Consider now the case of a symmetric 2 × 2 game, with strategies denoted by C and D , and with payoff matrix πgiven by π=" C D Cα β Dγ δ #, (4) where α , β , γ , δ∈R . Let p denote the frequency of strategy C in the population, and thus 1 −p is the frequency of strategy D. Now consider a population of assortatively-interacting individuals who are playing this 2 × 2 game. Let r denote the degree of assortativity in the population. The fitnesses fr C and fr D of the strategies Cand D, with assortativity, are given by fr C=rπ(C,C) + (1−r)[pπ(C,C) + (1−p)π(C,D)] =rα+ (1−r)[pα+ (1−p)β]and (5) fr D=rπ(D,D) + (1−r)[pπ(D,C) + (1−p)π(D,D)] =rδ+ (1−r)[pγ+ (1−p)δ], (6) and the average fitness of the population is ¯ fr=p f r C+ ( 1 −p)fr D . The evolutionary dynamics of the population, with assortativity, is thus given by the r-replicator equation ˙ p=p(fr C−¯ fr) =p(1−p)( fr C−fr D) =p(1−p){r(α−δ) + (1−r)[p(α−γ) + (1−p)(β−δ)]}. (7) Games 2020,11, 41 7 of 31 We note that for r= 0, this equation reduces to the standard replicator equation for a symmetric 2×2 game [17,18,22,23,102]): ˙ p=p(fC−¯ f) =p(1−p)( fC−fD) =p(1−p)[p(α−β−γ+δ) + β−δ], (8) where fC=pπ(C , C) + ( 1 −p)π(C , D) and fD=pπ(D , C) + ( 1 −p)π(D , D) are the fitnesses of the strategies Cand D, respectively, and ¯ f=p fC+ (1−p)fDis the mean fitness of the population. Here, for simplicity, in the rest of this paper when we discuss discrete strategy games we shall restrict our attention to two-strategy games—however, our analysis of evolutionary dynamics in assortatively-mixed populations can be extended to games with any number of strategies, and this may represent an interesting topic for future study. 2.1.2. Donation Game The donation game is the fundamental exemplar in the prisoner’s dilemma class of games, and provides the basic game theory model for altruism [ 13 , 17 , 18 ]. We must emphasize here that there is significant literature on the evolution of cooperation in the prisoner’s dilemma with assortative interactions, and we do not claim any particular originality for our results in this case. We discuss the donation game here essentially for completeness and to allow comparison with the more novel cases of the snowdrift game and the sculling game that follows. Equivalent results to those that we obtain here for the discrete donation game can therefore be found in the literature [13,79,80,89–98]. Consider the situation of two individuals, John and Bill, who donate blood to each other, as described in [ 19 ]. Suppose that the act of donating blood to someone incurs a cost c to the donor but confers a benefit b to the recipient, where b , c∈R+ and b>c . If we consider donation as the cooperative strategy C and non-donation as the defective strategy D , then the payoff matrix for the donation game is given by [19]: π=" C D C1−ρ−ρ D1 0 #, (9) where ρ∈( 0,1 ) is the cost-to-benefit ratio ρ=c b . It follows directly from the rank ordering of the elements of the payoff matrix that the game is in the prisoner’s dilemma class of symmetric 2×2 games. The standard replicator Equation (8) gives the evolutionary dynamics for the game without assortative interactions to be ˙ p=−p( 1 −p)ρ . The equilibrium points for the dynamics are ˆ p= 0 and ˆ p= 1, the former being asymptotically stable, while the latter is unstable. Thus, a well-mixed population of individuals playing the donation game, starting from an initial frequency p0∈( 0,1 ) of cooperators, will evolve towards the all-defector ( ˆ p=0) equilibrium state [19]. Consider now an assortatively-interacting population playing the donation game with the payoff matrix given by (9) . Let the degree of assortativity be r . It follows directly from the r -replicator Equation (7) that the evolutionary dynamics with assortativity for the population is given by ˙ p=p(1−p)(r−ρ). (10) Figure 1shows the phase line diagrams and the bifurcation diagram for the game. The system has two equilibria, ˆ p= 0 and ˆ p= 1. For r<ρ , the equilibrium point ˆ p= 0 is asymptotically stable, while the equilibrium point ˆ p= 1 is unstable. Thus, a population, starting from an initial frequency p0∈( 0,1 ) of cooperators, will evolve towards the stable equilibrium ˆ p= 0, representing a state in which all individuals defect. However, a bifurcation occurs at rc=ρ , reversing the stability Games 2020,11, 41 8 of 31 of the two equilibrium points. Hence, if r>ρ a population starting with any positive frequency of cooperators will evolve towards the stable equilibrium ˆ p= 1, representing a state in which all individuals cooperate. A similar inequality is arrived at in [ 92 ] for the prisoner’s dilemma game that has constant gains from switching (that is, in which fitness effects are additive), with the constant r representing the population structure and ρ the ratio of total costs to total benefits (not including self). Thus, as is essentially well-known, assortative interactions provide a mechanism for promoting cooperative behavior in the donation game [ 13 , 79 , 80 , 89 – 98 ]. It should be noted that the condition for cooperation to evolve through assortativity in the donation game, r>ρ , is formally identical to Hamilton’s inequality, which governs the evolution of altruism through kin selection [ 13 ]. This correspondence is completely natural given Grafen’s geometric interpretation of relatedness in terms of assortativity [79,80]. DC 0 1 (a) assortativity asymptotic frequency of cooperation 01 0 1 (b) Figure 1. Phase line diagrams and the bifurcation diagram for the donation game with assortative interactions. ( a ) In the phase line diagrams closed circles represent stable equilibrium points, open circles represent unstable equilibrium points, and the curved line connecting equilibrium points indicates the graph of the function on the right-hand side of the r -replicator equation. ( b ) In the bifurcation diagram solid lines represent stable equilibrium points, dashed lines represent unstable equilibrium points, and arrows indicate the direction of evolutionary change. 2.1.3. Snowdrift Game The snowdrift game is an interesting exemplar of a social dilemma in the hawk-dove class of games, and provides a model for certain types of cooperative behavior that differ from pure altruism [ 15 , 17 , 18 ]. Consider the situation described in [ 19 ] of two individuals, John and Bill, who are stuck in a car on their way home because the road is blocked by a snowdrift. Let the benefit of getting home be b and the cost of clearing the snow be c , where b , c∈R+ and b>c . If we consider shoveling as the cooperative strategy C and non-shoveling as the defective strategy D , then the payoff matrix for the snowdrift game is given by [19]: π=" C D C1−ρ 21−ρ D1 0 #, (11) where ρ∈( 0,1 ) is the cost-to-benefit ratio ρ=c b . It follows immediately from the rank ordering of the elements of the payoff matrix that the snowdrift game is in the hawk-dove class of symmetric 2×2 games. Games 2020,11, 41 15 of 31 Convex Cost and Concave Benefit Functions Now we consider the case in which the cost function is convex (i.e., C00(x)> 0) and the benefit function is concave ( B00(x)< 0). There is good evidence that in many situations the benefit function exhibits diminishing returns for sufficiently large levels of investment [ 108 – 110 ], and the cost is often well described by a convex quadratic function [ 111 ]. Thus, as an illustrative example we take the cost and benefit functions to be quadratic functions of the investment x : C(x) = c1x2 and B(x) = −b2x2+b1x, where c1,b1,b2,>0. The evolution of cooperation is determined by the analog of Hamilton’s inequality given above: namely, cooperation will evolve if r>ρ=C0(0) B0(0) . We now make the interesting observation that ρ= 0 (since C0( 0 ) = 0 and B0( 0 ) = b1> 0) and thus the inequality r>ρ is satisfied for any r> 0. Hence, in this case a non-zero level of cooperation will evolve for any positive degree of assortativity. We obtain the singular strategy x?for the game as x?=rb1 2rb2+2c2. (23) We now choose xm=1, and for simplicity take b1=2b2. Therefore, x?=1 1+2c1 rb1 , (24) and x?∈[ 0,1 ] . Since rB00(x?)−C00(x?) = − 2 b2r− 2 c1< 0, the singular strategy x? is convergent stable, and hence also evolutionarily stable. As a result, an initially monomorphic population in which every individual invests any amount x0∈[ 0,1 ] , will evolve to a final state in which all individuals cooperate by investing x? given by Equation (24). We note in particular that the completely defective initial state x0=0 will evolve to the cooperative state given by x?. Thus, in this case, cooperation will always evolve from the completely defective initial state x0= 0 for any non-zero degree of assortativity. Furthermore, since ∂x? ∂r=2c1 r2b1(1+2c1 rb1)2> 0, the cooperative investment x? made in the final state increases with assortativity r . Therefore, assortative interactions provide a powerful mechanism for the origin and maintenance of cooperation in the social dilemma defined by the CD game. 2.2.3. Continuous Snowdrift Game Consider again the case of two individuals, John and Bill, who are stuck in a car on their way home because the road is blocked by a snowdrift. Let us now assume that the amount of effort invested by each individual in shoveling to clear the snow can vary. Each individual benefits from the total investment that they both make to clear the snow, however, each individual only bears the cost of their own investment. Such interactions among pairs of individuals in which the investment made by each individuals is beneficial to both, but involves a cost only to the investor, can be described using the continuous snowdrift (CSD) game [26]. The CSD game concerns two individuals, making investments x , y∈R+ , respectively. These investments have the following effects: the payoff of each individual is increased by B(x+y) , where B(z) is a function that specifies the benefit to each individual resulting from the total amount of investment made by both participants, and the payoff to the investor, say the x -strategist here, is reduced by C(x) , where C(x) is a function that specifies the cost to an individual of making a given investment. Therefore, the payoff π(x,y)to an x-investor interacting with a y-investor is given by π(x,y) = B(x+y)−C(x). (25) Games 2020,11, 41 16 of 31 We shall again assume that there is an upper limit xm on the possible level of investment, that the cost and benefit functions are smooth and monotonically increasing functions satisfying C(0) = B(0) = 0, and B(x)>C(x), for x∈(0, xc), where 0 <xc<xm. For an assortatively-mixed population of individuals with assortativity r , from Equations (18) and (25), we can write the invasion fitness φr x(y)as φr x(y) = (1−r)B(x+y) + rB(2y)−C(y)−B(2x) + C(x). (26) The adaptive dynamics of the investment xis governed by ˙ x=D(x) =∂φr x(y) ∂yy=x(27) = (1+r)B0(2x)−C0(x). Concave Cost and Benefit Functions We now consider the case in which the cost and benefit functions are concave ( C00(x)< 0 and B00(z)< 0). Saturating benefits are clearly realistic [ 108 – 110 ], and decelerating costs are reasonable when the initiation of cooperative acts is more costly than subsequent increases in cooperative investments. Suppose, as an illustrative example, that we take the cost and benefit functions to be quadratic functions, i.e, suppose C(x) = −c2x2+c1x and B(z) = −b2z2+b1z , where c1 , c2 , b1 , b2 , > 0. We obtain the singular strategy x?for the CSD game as x?=(1+r)b1−c1 4(1+r)b2−2c2. (28) The singular strategy is convergent stable if b2>c2 2(1+r), (29) and a repeller if the inequality is reversed. The singular strategy is an ESS if b2>c2 1+3r, (30) and an EBP if the inequality is reversed. Similar conditions for the convergence and evolutionary stability of a singular strategy are derived in [ 101 ] for a nonlinear public goods game with assortative interactions, in which relatedness is defined as the expected value of a fraction of the group that is identical by descent to the focal individual. Thus, an initially monomorphic population in which every individual is investing x0∈[ 0, xm] will evolve to a final state that crucially depends on the coefficients c1 , c2 , b1 , and b2 of the cost and benefit functions, and on the assortativity r . If Equation (29) is satisfied, then the population initially evolves to a state in which all individuals are investing x? —the fate of the population thereafter depends on whether or not Equation (30) is satisfied. If it is satisfied, then x? is an ESS and the population remains at this end state permanently. Otherwise, x? is an EBP and the population splits into two distinct phenotypic clusters, which diverge evolutionarily from each other. If, however, Equation (30) is not satisfied, then x? is a repeller, and the fate of the population depends on the initial strategy x0 —if x0<x? , then the population evolves to the zero-investment state x= 0, while, if x0>x? , then the population evolves to the maximum-investment state x=xm . We note that ∂x? ∂r= 2 ( 2 b2c1−b1c2)> 0, if c1 b1>c2 2b2 , and thus if the latter inequality holds then increasing assortativity results in higher levels of cooperation x? . For given cost and benefit functions, both the location and the nature of the singular strategy x? varies as the degree of assortative interactions r changes. The varying nature Games 2020,11, 41 17 of 31 of the singular strategy x? with r in turn results in very different end-states for the evolutionary dynamics. These end-states are: an evolutionary repeller in which all individuals either invest nothing or invest the maximum possible amount, depending on the initial state of the population; an ESS, in which all individuals invest the same amount, given by the singular strategy x? ; or an end-state in which evolutionary branching has occurred, leading to the coexistence of high and low investing individuals. This latter outcome represents a two-fold social dilemma—referred to as the “tragedy of the commune” [ 26 ]—not only is the total level of investment socially inefficient, but in addition evolutionary dynamics forces an unequal division in the levels of investment. We observe from Equation (30) that increasing assortativity inhibits evolutionary branching in the CSD game. Thus, assortative interactions have a dual action on the evolutionary dynamics of the CSD game—increased assortativity first leads to higher levels of cooperation and second reduces the potential for evolutionary branching, thereby reducing the likelihood of unequal levels of cooperation. 2.2.4. Continuous Tragedy of the Commons Game Consider the case of two individuals, John and Bill, who jointly use a finite common-pool resource, such as a common fishing ground or shared Internet bandwidth. Each of them benefits from consuming the resource, but the costs incurred are shared among both. Such interactions between pairs of individuals sharing a common-pool resource in which consumption of the resource benefits the consuming individual but is costly to both individuals, can be described using the continuous tragedy of the commons (CTOC) game [27]. The CTOC game involves two individuals, making investment x , y∈R+ , where in this context, the investment means the level of consumption of a limited common-pool resource, and thus cooperative behavior is identified with lower levels of consumption (i.e., lower levels of investment). The investments have the following effects: the payoff of the investor is increased by B(x) , where B(x) is a function that specifies the benefit to an individual obtained from consuming a given amount of the resource, and the payoff of each individual is decreased by C(x+y) , where C(z) is a function that specifies the cost to both individuals resulting from a given total level of consumption. Therefore, the payoff π(x,y)to an x-investor interacting with a y-investor is given by π(x,y) = B(x)−C(x+y). (31) Again we shall assume that there is an upper limit xm on the possible level of investment, that the cost and benefit functions are smooth and monotonically increasing functions satisfying C( 0 ) = B( 0 ) = 0, and B(x)>C(x) , for x∈( 0, xc) , where 0 <xc<xm . These assumptions simply reflect the fact that the public resource is both finite and valuable to those consuming it. For an assortatively-mixed population of individuals with assortativity r , from Equations (18) and (31), we can write the invasion fitness φr x(y)as φr x(y) = B(y)−rC(2y)−(1−r)C(x+y)−B(x) + C(2x). (32) The adaptive dynamics of the investment xis governed by ˙ x=D(x) =∂φr x(y) ∂yy=x =B0(x)−(1+r)C0(2x). (33) Convex Cost and Sigmoidal Benefit Functions We now consider the case in which the cost function is convex and the benefit function is sigmoidal. Accelerating costs represent a realistic assumption and are often observed in nature [ 111 ]. Games 2020,11, 41 18 of 31 Benefits are also often accelerating initially and then saturate, resulting in sigmoidal benefit functions [ 21 ]. Suppose, as an illustrative example of this type of cost and benefit functions, we take the cost function to be a quadratic function and the benefit function to be a cubic function, i.e, suppose C(z) = c1z2 and B(x) = −b3x3+b2x2+b1x, where c1,b1,b2,b3>0. To simplify the analysis, we take b2= 2 b1 and c1=b1 . We obtain the singular strategy x? for the CTOC game as x?=q16r2b2 1+12b1b3−4rb1 6b3. (34) The singular strategy is always convergent stable. Moreover, it is an ESS if b1<q16r2b2 1+12b1b3 2(1−r), (35) and an EBP if the inequality is reversed. Thus, an initially monomorphic population in which every individual is investing x0∈[ 0, xm] will evolve to an end-state that depends crucially on the coefficients c1 , b1 , and b3 of the cost and benefit functions, and on the assortativity r . The population first evolves to a state in which all individuals are investing x? , and the subsequent fate of the population depends on whether or not Equation (35) is satisfied. If it is satisfied, then x? is an ESS, and the population remains in this state permanently. Otherwise, x? is an EBP and the population splits into two distinct and diverging phenotypic clusters. We note that ∂x? ∂r= 4b1(4rb1 √16r2b2 1+12b1b3−1) 6b3< 0, if 4rb1 √16r2b2 1+12b1b3 < 1, and thus if the latter inequality holds then increasing assortativity results in higher levels of cooperation, i.e, lower values of x? . For given cost and benefit functions, the location and the type of the singular strategy x? varies as the degree of assortative interactions r varies. Thus, as the degree of assortative interactions r changes, so does the form of the evolutionary dynamics. The end-state of the evolutionary dynamics can be either an ESS in which all individuals consume the same amount x? of the common resource, or it can be an end-state in which evolutionary branching has taken place, resulting in the coexistence of high and low consuming individuals. This latter outcome represents a second tragedy of the commons—not only is the resource over consumed to the detriment of all, but evolutionary dynamics forces an unequal division degree of consumption. We observe from Equation (35) that increasing assortativity inhibits evolutionary branching in the CTOC game. Thus, just as in the case of the CSD game, assortative interactions have a double action on the evolutionary dynamics of the CTOC game, with increased assortativity resulting both in higher levels of cooperation and in a reduced likelihood of unequal levels of consumption. 2.3. Individual-Based Model An individual-based model (IBM), or agent-based model [ 112 ], provides a natural alternative method of studying the evolutionary dynamics of a population with assortative interactions, which is complementary to the deterministic approaches discussed above. 2.3.1. Discrete Games We assume here that the individuals in the population play a symmetric 2 × 2 game with the payoff matrix given by Equation (4). We consider a population of n individuals, with an initial strategy profile s0={s0 1 , s0 2 , . . . , s0 n} at generation 0, where s0 i∈ {C , D} , for 1 ≤i≤n . Each generation of the evolutionary dynamics consists of an asynchronous interaction/update round, which involves sampling the population ntimes with replacement. Each interaction/update step at generation t is carried out as follows: in the interaction phase we pick uniformly at random two individuals i and j from the population. The two individuals Games 2020,11, 41 19 of 31 iand j interact (i.e., play the symmetric 2 × 2 game) with individuals k6=i and l6=j respectively. The interactions are assortative, i.e., with probability r, the individual k(respectively l) is of the same strategy type as i (respectively j ), and with probability 1 −r , the individual k (respectively l ) is chosen uniformly at random from the population. The change of individual i ’s strategy from one generation to the next is determined by the payoff that player i receives from interacting with player k and the payoff that player j receives from interacting with player l . Precisely, if st−1 i , st−1 j , st−1 k , and st−1 l denote the strategies of i , j , k , and l , respectively, in generation t− 1, then in generation t the payoff Pi received by individual i is π(st−1 i , st−1 k) and the payoff Pj received by individual j is π(st−1 j , st−1 l) , where π is the payoff matrix for the game under consideration. In the update phase the probability that the focal individual iwill inherit j’s strategy, pi←j, is determined using the Fermi update rule as [19] pi←j=1 1+e−β(Pj−Pi), (36) where the parameter β>0 is the “selection strength” of the update rule. We note that the results of the individual-based simulations described in the next section are robust to changes in the update rule. For example, in addition to employing the Fermi update rule given by Equation (36), we have also simulated the individual-based model using the replicator update rule, in which the probability pi←j that the focal individual i inherits individual j ’s strategy is given by [19] pi←j=(0 if Pi≥Pj Pj−Pi Pmax−Pmin otherwise, (37) where Pmax =max(P1 , P2 , . . . , Pn) , and Pmin =min(P1 , P2 , . . . , Pn) . We find that the evolutionary dynamics of the symmetric 2 × 2 games that we study is essentially identical irrespective of which of these update rules we employ. The results presented in the next section arise from simulations using the Fermi update rule (Equation (36)). 2.3.2. Continuous Games An IBM also provides a natural way of studying the evolutionary dynamics of a population playing a pairwise continuous game with assortative interactions. We again consider a population of n individuals, now with an initial monomorphic strategy profile x0={x0 1 , x0 2 , . . . , x0 n} in generation 0, where x0 1=x0 2=··· =x0 n=x0∈( 0, xm) and xm∈R+ . Thus in generation t= 0, every individual in the population uses the strategy x0 . The interactions/update rounds are carried out in the same manner as in the case of discrete games, but with the following additional step: if during the update round at generation t , the focal individual i would have inherited the strategy xt−1 j of the individual j , then with probability µ it instead inherits a mutation of this strategy, picked from a normal distribution with mean xt−1 j and standard deviation σ . If the strategy space is a finite interval [a , b] then the mutations are taken from a truncated normal distribution on [a , b] . We note here that changing the precise way in which the random numbers are generated does not effect the outcome of the adaptive dynamics. For example, it was shown in [ 113 ] that including random numbers that are uniformly distributed in addition to having random numbers taken from a truncated normal distribution does not significantly change the evolutionary dynamics of the system considered in that paper. The simulation results presented in the section below are based on the Fermi update rule given by Equation (36). We have also simulated the IBM using the replicator update rule (Equation (37)), and have found the results obtained using both rules to be qualitatively identical. Games 2020,11, 41 20 of 31 3. Results from Individual-Based Simulations 3.1. Discrete Games In this subsection we present the main results of simulations using the IBM introduced above for the donation, snowdrift, and sculling games. Additional results can be found in the Supplementary Materials document. 3.1.1. Donation Game Figure 4a,b, respectively, show how the analytically predicted and simulated values of p∞ vary with the assortativity r∈[ 0,1 ] and the cost-to-benefit ratio ρ∈( 0,1 ) . Figure 4c shows how p∞ varies with r when ρ= 0.25 and Figure 4d shows how p∞ varies with ρ when r= 0.25. The results are in excellent agreement with the analysis given above, showing that a population of individuals playing the donation game will evolve to the all-cooperator state ( p∞= 1) if r>ρ and to the all-defector state (p∞=0) if the inequality is reversed. 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ (a) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 asymptotic frequency of cooperation p ∞ (b) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ simulated predicted (c) 0.0 0.2 0.4 0.6 0.8 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ simulated predicted (d) Figure 4. Variation of the long-term frequency p∞ of cooperators with assortativity r∈[ 0,1 ] and cost-to-benefit ratio ρ∈( 0,1 ) for the donation game. ( a ) p∞ (analytically predicted) versus r and ρ . ( b ) p∞ (simulated) versus r and ρ . ( c ) p∞ versus r when ρ= 0.25. ( d ) p∞ versus ρ when r= 0.25. Parameters: n= 10,000, p0=0.5, and β=1. 3.1.2. Snowdrift Game Figure 5a,b, respectively, show how the analytically predicted and simulated values of p∞ vary with the assortativity r∈[ 0,1 ] and the cost-to-benefit ratio ρ∈( 0,1 ) . Figure 5c shows how p∞ varies with r when ρ= 0.75 and Figure 5d shows how p∞ varies with ρ when r= 0.25. The results agree very well with the analysis, which indicates that in a population of individuals playing the snowdrift game, increasing the assortativity r has the effect of increasing the fraction of cooperators at equilibrium, while increasing the cost-to-benefit ratio ρ has the effect of decreasing the fraction of cooperators at Games 2020,11, 41 21 of 31 equilibrium. Thus, cooperation is promoted by increasing assortativity r , with a transition to complete cooperation occurring when r>ρ 2. 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ (a) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 asymptotic frequency of cooperation p ∞ (b) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ simulated predicted (c) 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ simulated predicted (d) Figure 5. Variation of the long-term frequency p∞ of cooperators with assortativity r∈[ 0,1 ] and cost-to-benefit ratio ρ∈( 0,1 ) for the snowdrift game. ( a ) p∞ (analytically predicted) versus r and ρ . ( b ) p∞ (simulated) versus r and ρ . ( c ) p∞ versus r when ρ= 0.75. ( d ) p∞ versus ρ when r= 0.25. Parameters: n= 10,000, p0=0.5, and β=1. 3.1.3. Sculling Game Figure 6a,b respectively show how the predicted and simulated values of p∞ vary with assortativity r∈[ 0,1 ] and cost-to-benefit ratio ρ∈(1 2 , 3 2) . Figure 6c shows how p∞ varies with r when ρ= 1.2 and Figure 6d shows how p∞ varies with ρ when r= 0.25. The results are in very good agreement with the analysis, which indicates that in a population of individuals playing the sculling game, increasing the assortativity r has the effect of increasing the basin of attraction around ˆ p= 1, thus decreasing the value of the initial fraction p0 of cooperators that is needed for the population to evolve to the all-cooperator state. Contrarily, increasing the cost-to-benefit ratio ρ has the effect of increasing the basin of attraction around ˆ p= 0, thus increasing the value of the initial fraction p0 of cooperators that is needed for the population to evolve to the all-cooperator state. Thus, cooperation is promoted by increasing assortativity r , with a transition to complete cooperation occurring when r>2ρ 3−1 3. Games 2020,11, 41 22 of 31 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.6 0.8 1.0 1.2 1.4 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ (a) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.6 0.8 1.0 1.2 1.4 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 asymptotic frequency of cooperation p ∞ (b) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ simulated predicted (c) 0.6 0.8 1.0 1.2 1.4 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic frequency of cooperation p ∞ simulated predicted (d) Figure 6. Variation of the long-term frequency p∞ of cooperators with assortativity r∈[ 0,1 ] and cost-to-benefit ratio ρ∈(1 2 , 3 2) for the sculling game. ( a ) p∞ (analytically predicted) versus r and ρ . ( b ) p∞ (simulated) versus r and ρ . ( c ) p∞ versus r when ρ= 1.2. ( d ) p∞ versus ρ when r= 0.25. Parameters: n=10,000, p0=0.5, and β=1. 3.2. Continuous Games In this subsection we present the main results of simulations using the IBM introduced above for the continuous donation (CD), continuous snowdrift (CSD), and continuous tragedy of the commons (CTOC) games. Additional results can be found in the Supplementary Materials document. 3.2.1. Continuous Donation Game We first consider the CD game with linear cost and benefit functions C(x) = cx and B(x) = bx , where b>c . We denote the ratio c b by ρ and refer to it as the cost-to-benefit ratio. The condition r>ρ that promotes cooperative investments, where r is the degree of assortativity, is similar to the one for the discrete donation game, and hence we study the CD game using a similar set of plots. Figure 7a,b, respectively, show how the analytically predicted and simulated values of the long-term mean strategy ¯ x∞ (taken over the last 10% of the generations) varies with the assortativity r∈[0,1]and the cost-to-benefit ratio ρ∈(0,1). Figure 7c shows how ¯ x∞varies with rwhen ρ=0.26 and Figure 7d shows how x∞ varies with ρ when r= 0.26. The results are in excellent agreement with the analysis, which shows that in a population of individuals playing the CD game with linear cost and benefit functions, individuals will asymptotically invest the maximum amount xm if r>ρ and make zero investment if the inequality is reversed. Games 2020,11, 41 23 of 31 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic strategy ¯ x ∞ (a) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.2 0.4 0.6 0.8 asymptotic strategy ¯ x ∞ (b) 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic strategy ¯ x ∞ simulated predicted (c) 0.0 0.2 0.4 0.6 0.8 1.0 cost-to-benefit ratio ρ 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic strategy ¯ x ∞ simulated predicted (d) Figure 7. Variation of the long-term mean strategy ¯ x∞ with assortativity r∈[ 0,1 ] and cost-to-benefit ratio ρ∈( 0,1 ) in the CD game with linear cost and benefit functions: C(x) = cx and B(x) = bx with b>c . ( a ) ¯ x∞ (analytically predicted) versus r and ρ . ( b ) ¯ x∞ (simulated) versus r and ρ . ( c ) ¯ x∞ versus r when ρ= 0.26. ( d ) ¯ x∞ versus ρ when r= 0.26. Parameters: n= 10,000, x0= 0.1, xm= 1, µ= 0.01, σ=0.005, and β=1. We next consider the CD game with quadratic cost and benefit functions C(x) = c1x2 and B(x) = −b2x2+b1x , where c1 , b1 , b2> 0. We let b1= 2 b2 , in which case the singular strategy, given by Equation (24), is convergent stable and hence also evolutionarily stable. Figure 8shows the variation of the distribution of the long-term values x∞ (taken over the last 10% of the generations) of strategies with assortativity r ; the dotted line indicates the singular strategy x? . The results are in very good agreement with the analysis, which indicates that in a population of individuals playing the CD game with quadratic cost and benefit functions, individuals will in the long term invest an amount given by the evolutionarily stable singular strategy x? , which increases with assortativity r. Games 2020,11, 41 24 of 31 0.0 0.2 0.4 0.6 0.8 1.0 assortativity r 0.0 0.2 0.4 0.6 0.8 1.0 asymptotic distribution of strategies x∞ singular strategy x Figure 8. Variation of the distribution of long-term strategy values x∞ with assortativity r in the CD game with quadratic cost and benefit functions: C(x) = x2 and B(x) = −x2+ 2 x . Parameters: x0= 0.1, xm=1, µ=0.01, σ=0.005, and β=1. Arrows indicate the direction of evolutionary change. 3.2.2. Continuous Snowdrift Game The next game we consider is the CSD game with quadratic cost and benefit functions C(x) = −c2x2+c1x2 and B(x) = −b2x2+b1x , where c1 , c2 , b1 , b1> 0. The singular strategy for the game, given by Equation (28), is convergent stable if the inequality given by Equation (29) is satisfied and a repeller if the inequality is reversed. On the other hand, the singular strategy is an ESS if the inequality given by Equation (30) is satisfied and an EBP otherwise. Figure 9a,b show the variation of the distribution of the asymptotic strategy values x∞ (taken over the last 10% of the generations) with assortativity r . The dotted line indicates the singular strategy x? . The value of r in (a) at which the singular strategy transitions from an EBP to an ESS is determined by equating the two sides of Equation (30) and solving for r . For the given choice of parameters, the transition point (indicated by the dashed vertical line) is r= 0.2. Similarly, the value of r in (b) where the singular strategy changes from a repeller where every individual makes zero asymptotic investment to one in which all individuals make the maximum asymptotic investment xm can be obtained from Equation (29). For the given choice of parameters, the transition point (indicated by the dashed vertical line) is r= 0.13. The results are in very good agreement with the analysis, which shows that in a population of individuals playing the CSD game with quadratic cost and benefit functions, for suitable values of the coefficients, the singular strategy can change from an EBP to an ESS as the assortativity increases. Similar results are presented in [ 101 ] for a nonlinear public goods game with assortative interactions, in which evolutionary attractors increase with relatedness (defined as the expected value of a fraction of the group that is identical by descent to the focal individual) while evolutionary repellers decrease with relatedness. Games 2020,11, 41 31 of 31 96. Cooney, D.; Allen, B.; Veller, C. Assortment and the evolution of cooperation in a Moran process with exponential fitness. J. Theor. Biol. 2016,409, 38–46. [CrossRef] [PubMed] 97. Nax, H.; Rigos, A. Assortativity evolving from social dilemmas. J. Theor. Biol. 2016 ,395, 194–203. [CrossRef] [PubMed] 98. Van Veelen, M.; Allen, B.; Hoffman, M.; Simon, B.; Veller, C. Hamilton’s rule. J. Theor. Biol. 2017 ,414, 176–230. [CrossRef] [PubMed] 99. Killingback, T.; Doebeli, M. The continuous prisoner’s dilemma and the evolution of cooperation through reciprocal altruism with variable investment. Am. Nat. 2002,160, 421–438. [CrossRef] 100. Allen, B.; Nowak, M.; Dieckmann, U. Adaptivedynamics with interactionstructure. Am. Nat. 2013 ,181, 139–163. [CrossRef] [PubMed] 101. Coder Gylling, K.; Brännström, Å. Effects of relatedness on the evolution of cooperation in nonlinear public goods games. Games 2018,9, 87. [CrossRef] 102. Zeeman, E. Population dynamics from game theory. Glob. Theory Dyn. Syst. 1980 ,819, 471–497. [CrossRef] 103. Meszéna, G. Adaptive dynamics: The continuity argument. J. Evol. Biol. 2005,18, 1182–1185. [CrossRef] 104. McGill, B.; Brown, J. Evolutionary game theory and adaptive dynamics of continuous traits. Annu. Rev. Ecol. Evol. Syst. 2007,38, 403–435. [CrossRef] 105. Brännström, A.; Johansson, J.; Von Festenberg, N. The hitchhiker’s guide to adaptive dynamics. Games 2013,4, 304–328. [CrossRef] 106. Dieckmann, U.; Law, R. The dynamical theory of coevolution: A derivation from stochastic ecological processes. J. Math. Biol. 1996,34, 579–612. [CrossRef] 107. Hamilton, W. The evolution of altruistic behavior. Am. Nat. 1963,97, 354–356. [CrossRef] 108. Altmann, S. Altruistic behaviour: The fallacy of kin deployment. Anim. Behav. 1979 ,27, 958–959. [CrossRef] 109. Weigel, R. The distribution of altruism among kin: A mathematical model. Am. Nat. 1981 ,118, 191–201. [CrossRef] 110. Schulman, S.; Rubenstein, D. Kinship, need, and the distribution of altruism. Am. Nat. 1983 ,121, 776–788. [CrossRef] 111. Sibly, R.; McFarland, D. On the fitness of behavior sequences. Am. Nat. 1976,110, 601–617. [CrossRef] 112. Bonabeau, E. Agent-based modeling: Methods and techniques for simulating human systems. Proc. Natl. Acad. Sci. USA 2002,99, 7280–7287. [CrossRef] 113. Iyer, S.; Killingback, T. Evolutionary dynamics of a smoothed war of attrition game. J. Theor. Biol. 2016,396, 25–41. [CrossRef] c 2020 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).