Interaction in agent-based economics: A survey on the network approach

In this paper we aim to introduce the reader to some basic concepts and instruments used in a wide range of economic networks models. In particular, we adopt the theory of random networks as the main tool to describe the relationship between the organization of interaction among individuals within diﬀerent components of the economy and overall aggregate behavior. The focus is on the ways in which economic agents interact and the possible consequences of their interaction on the system. We show that network models are able to introduce complex phenomena in economic systems by allowing for the endogenous evolution of networks.


Introduction
Various approaches may be followed in modeling the connections among agents: from local to global, from deterministic to stochastic, from exogenous to endogenous interactions.Clearly, it does not exist a "best"approach in modeling agents' interaction; instead, the choice of model should depend on the "circumstances"to be modeled and on the purpose of the model [1].Local interaction characterizes models in which agents behavior (and then preferences, information, and choices) is directly affected by others' behavior, rather than being mediated by a centralized agent or (market) mechanism.
The basic assumption in these models is that individuals interact locally, with a neighbors set determined by a social or economic "distance metric".Instead, when interaction is global, individual behavior depends on the behavior of all other agents (for instance, because there are very low costs of information/transaction and geographical or socioeconomic distance is negligible).The rule defining the set of interacting agents can be of exogenous (e.g., a Von Neumann or Moore neighborhood in a "lattice" economy) or endogenous nature (e.g., an agent decides to interact with a neighbor -and not with another one -because this partner choice maximizes its utility).Moreover, the set of neighbors may be the result of a deterministic (again, a Von Neumann or Moore neighborhood) or stochastic rule (e.g., the switching from a partner to another depends on a probability distribution).All in all, the interactive structure may be static, that is the neighbor sets are determined once and for all, or dynamic, because it evolves along time depending on model assumptions.
In this paper we list, among the main features of Agent Based Models (ABM), the explicit modeling of interaction space, and in particular the preference towards local interaction as a more realistic modeling device than global interaction, which is generally at odds with bounded rationality.Interaction, in fact, is quoted as one of the main ingredients of ABMs.We are going to push further these claims, by advocating the intimate connection between ABM and network or graph theory 1 .The latter, in fact, provides the basic mathematical concepts needed to describe exactly any collection of interactions between agents, as well as the tools to analyze the collective, emerging, properties of this collection.These properties, on their part, allow us to investigate how interaction patterns affect the behavior of agents.Shortly, we may state that each ABM maps onto one or more networks (since the pattern of interaction between agents could be either fixed or changing over time), and the mathematical properties of these networks can be used to analyze and eventually forecast, at least for some variables, the behavior of the model. 2he quest for a deeper connection with network theory has become an important topic in the research agenda of ABM, with a growing amount of research efforts especially devoted to the twin problems of interaction over fixed networks (see [6]) and of endogenous network formation (see [1]).On the other hand, we must admit that currently the two fields are only partially overlapping.For example, the economics-oriented handbook of Jackson [7] makes only a marginal reference to ABM, while the more physics-oriented monograph of Vega-Redondo [8] is silent on the subject.Among the few systematic efforts to better integrate the two approaches, it is worth to mention the ambitious theoretical framework proposed by Potts [9], which is explicitly geared towards multi-agent simulation modeling, and relies heavily on network theory.
In general, it is clear that Walrasian economics requires a complete network, where any agent (firm or consumer) exchanges information with all other agents simultaneously and instantaneously at no cost.It is also clear that this network cancels out from the beginning the possibility of heterogeneous information sets among agents.Moreover, agents have access to the same set of decision rules (i.e., again, the network between agents and decision rules is a complete one), which are on their part evaluated with respect to the same objective function.Finally, all sources of heterogeneity are lost and the representative agent is obtained.AB economics requires instead, as key notion at the level of agents, that of neighborhood, which may be framed either in a deterministic (fixed set) or in a stochastic (fixed probabilities) flavor, as well as with reference to search costs or any other suitable matching heuristic.The difference with Walrasian economics becomes substantial, as soon as asymmetry between agents is introduced with the help of heterogeneous neighborhoods, since in that case the coexistence of different classes of agents is, at least in principle, allowed.
At the system level, instead, the key notion of AB economics, in this context, is that of structure.Each non trivial pattern of connections between agents can be viewed as a structure, which may act as a constraint over the path followed by the system as a whole (in fact, the same set of decision rules economics, do not explicitly make use of network concepts and measures.[1] contains a very useful discussion on the various approaches followed in AB economic models, with a particular focus on endogenous interaction. acting on structurally different neighborhood will generally produce different values of the state variables), and/or emerge as a by-product of decision rules themselves, whenever these include algorithms for partner selection and matching.
From the point of view of network theory, each relevant structure is associated with a set of observables.In general, it would be difficult, and possibly useless, to predict the value of observables at the single agent level (when a definition at this level is possible).That is why network theory strongly relies on a statistical approach, whereby we are more interested in characterizing the statistical properties (e. g. moments or probability distributions) of observables, viewed as random variables, across the population of agents.Network theory is interested in (some of) the mesoscopic properties of systems, and this meso-level of analysis is a natural one to define structure.In fact, the latter is obviously a meso concept, since it entails the description of a system by means of its main components and their relationships.As we will see, network theory describes the main components of interaction (defined by observables) along with their relationships, since the statistical properties of one observable are in general not independent from the statistical properties of other observables.
To summarize, network theory deals with the structure of interaction within a given multi-agent system.Consequently, it is naturally interested in the statistical equilibrium of these systems, to be defined as the stability of probability distributions of observables, which implies "a state of macroscopic equilibrium maintained by a large number of transition in opposite directions"( [10]).Following this path, we come close to the idea, championed by Aoki [11], of reconstructing macroeconomics under the theoretical framework of statistical physics and combinatorial stochastic processes.Not surprisingly, the same methods (which were originally developed to study systems made of large numbers of interacting micro-units by means of a set of macro state variables) are now of fundamental importance in the field of network theory and, for the same reasons, they are expected to take an increasing role in ABM.
The paper is organized as follows.In Section 2, we introduce some basic notions of network theory.In Section 3 we focus on the issue of interaction over fixed networks, by introducing two well known topologies: Poisson net-works and Small World networks.Subsequently (Section 4), we present two well established models of network formation, namely the preferential attachment model along with its generalization to arbitrary fitness measures, and the strategical linking model of Jackson and Wolinsky.In Section 5, we focus on the interdependent behavior of interconnected agents, firstly by introducing the issue of coordination over fixed networks and secondly by introducing interdependency between behavior and link formation.Finally, Section 6 concludes.

Networks: basic concepts and properties
Networks or graphs3 are mathematical entities composed by vertices (nodes) connected by links (edges) or, more shortly G = (V, E), where V is typically assumed to be a subset of N, while E ⊂ N × N can eventually map onto any subset of R N .For this general setting a functional representation looks natural, where we let l i,j be a function taking vertices as arguments and having a suitable co-domain.For instance with l i,j → (0, 1], we can represent the relative frequency of interaction or any ex-ante probability measure on a suitably defined interaction space.To simplify further, let's take l i,j → {0, 1}, where l i,j = 1 if the edge between i and j is in E, and l i,j = 0 in the opposite case, further assuming l i,j ≡ l j,i . Within this setting, a convenient representation of a graph is given by the "connectivity matrix", C. Each element c i,j of this matrix stores the image of l i,j associated to each point (i, j) of its (finite) domain.We can exclude the possibility of selfloops by adding the condition l i,i ≡ 0, but this is not necessarily the best option in all cases.For example, a standard model of random networks, the so called configuration model, requires not only self loops, but also multiple edges to be included, which would mean that the matrix elements can take integer values larger than 1.In this case, we talk of a multigraph.In the second place, by eventually allowing C to be non symmetric, we introduce the notion of a directed graph or digraph.Incidentally, we observe that asymmetric relationships are pervasive in the economic context, since exchange itself is asymmetric (think about the asymmetry between seller and buyer on goods' markets, or between creditor and debtor on capital markets).
Moreover, links can be weighted.Their weight mirrors the strength of relations among the connected nodes.We can define, thus, the weighted connectivity matrix W in analogy with C.
A network is said to be sparse when |E| |V | 2 .Real networks are, almost without exception, sparse, since the capacity to interact of agents does not grow proportionally with the dimension of the system.Consequently, models of complex networks generally display this feature, e. g. by assuming that the expected number of vertices connected to a given one remains finite as |V | → ∞.This property implies that heterogeneous local structures become very important in order to grasp the behavior of complex networks.This feature is captured within network theory by the key notion of the neighborhood of an agent in a network, defined as the set ψ(i) of other agents with whom i has a direct link.
Neighborhoods find ubiquitous application in network theory, especially within the social and economic domain.In socio-economic systems individuals tend to link with people they are socially close to.A clear manifestation of this phenomenon is shown in the identification of groups or communities inside the network (see below).The neighborhood set is related to the connectivity of nodes within networks, as measured by their degree k, which is defined as the number of nodes connected to it or equivalently as the cardinality of ψ.In digraphs, we must distinguish between in-degree, i.e. the number of edges pointed to some vertex, and out-degree, i.e. the number of edges pointing away from it.It is worth to stress again that the role of neighborhoods and groups puts network theory in stark contrast with Walrasian economics, which requires full interaction of agents, regardless of the dimension of the system these agents are embedded in [9].
All networks may be conceived as the outcome of a generative process, which mathematically takes the form of an algorithm.Then, it is convenient to introduce a fundamental distinction between deterministic and random graphs, where the former are the outcome of a deterministic sequence of steps, while the latter's construction involves one or more stochastic processes.
We observe that, if a network is random, then, all the observables defined over this networks, including the degree, become random variables, which take their values in agreement with a specific probability measure.Then it is possible to define the probability degree distribution p(k) as the probability that a vertex chosen uniformly at random has degree k.As we will show, different models of random networks have different degree distributions, but a well-established stylized fact is that real-world networks display a degree distribution which is highly right-skewed, meaning that their distribution has a long right tail of values that are far above the mean.
There are many properties closely related to the degree distribution.Resilience, clustering, community structure and assortative mixing can be counted among the most frequently used in social sciences.
Resilience analyses how the network's structure changes if some node is removed.Whenever a vertex i is removed from a network, the average distance among nodes increases and, as this process goes further, ultimately some nodes will be disconnected.Nodes can be removed in many ways.They may be attacked randomly or according to some of their intrinsic properties (such as their degree).Depending on the rules used to remove nodes, the network shows a different level of resilience.For instance, [12] show that social networks, usually highly right-skewed, are remarkably resistant to random attacks but extremely vulnerable to attacks targeted at nodes with the highest degree (hubs).To prove this claim, the authors remove nodes in decreasing order of their connectivity, showing that, as a small number of hubs are removed, the average distance of the scale-free network increases rapidly 4 .
Clustering is often associated with heterogeneous local structures and neighborhoods.In many social networks we find that if node i is linked to node j and node j to node h, then there is a fairly high probability that i and h are also linked.
Community provides a powerful extension of the notion of clustering, by looking at groups of vertices such that there is a higher density of links within groups than between them 5 .The presence of subsets of highly interconnected 4 The study of network resilience is closely related to the analysis of contagion.Studying the propagation of contagion and, therefore, the network resilience to the attack of nodes, has become increasingly important in the aftermath of the global financial crisis [13].This topic has been extensively analyzed by financial agent-based models (see, for instance, [14], [15], [16], [17]). 5The field of community oriented research is quite heterogeneous and rapidly growing.
nodes is a key feature of empirically observed social networks.Usually these communities, which are sparsely interconnected, reflect agents' preferences and choices. 6 Within social networks' theory, this kind of selective linking, based upon similarity, is called assortative mixing.One of the characteristics shared by connected agents can be degree itself.Positive assortativeness, defined as positive degree-degree correlation, has been detected in many social networks (see [22]).In this case assortative mixing can be detected by means of the correlation between some node i's degree and the average degree of its neighbors.If the latter increases (decreases) with k, there is assortative mixing (disassortative mixing), that is high-degree nodes are more likely to be connected to high-degree (low-degree) nodes. 7

Network-constrained Interaction
The simplest way to introduce networks within ABMs is to think that the environment acts as a 'constraint'over interaction, and that agents must learn how to behave within this constraint.The issue at stake, then, is how economic outcomes are affected by network structures over which agents make their decisions.By keeping the interaction environment (here represented by the network) fixed, we can analyze, either analytically or with the help of simulations, how state variables8 evolve within that environment.This view of the environment is common in the sociological literature, where a great emphasis is put on the networks in which agents are "embedded"(see [23]; [24]).The relevance of this approach for economics was outlined by the early study of Baker [25], who showed that the volatility of options prices is dependent on the structure of the communication network in the market.
For a recent review the reader can refer to [18]. 6Communities can mirror friendships, loyal relationship, cooperation or segregation among agents or many different kind of relationships among individuals.Among the early works on this subject it's noteworthy Jacob Moreno's work [19] in the 1920s and 30s on the friendship patterns within small groups; the mathematical models of [20], who was one of the first theorist to stress the importance of the friendship graphs of school children; the important set of experiments of [21] on the famous "small-world effect", which is the origin of the popular concept of the "six degrees of separation". 7For a more rigorous treatment in terms of conditional probability see [4] (par.1.3) Many recent contributions have confirmed this findings, analyzing the many different ways in which network structure affects economic behavior9 .

Random interactions: the Poisson model
The binomial or Poisson model is one of the most popular models for random graphs, thanks to its simplicity and mathematical tractability.The model starts with a set of N isolated vertices, and then each pair of vertices is independently connected with probability q.In this model the degree values follow a common binomial distribution,and agents on average have the same degree value: The mathematical simplicity of the model comes with a cost.It is well known that the Poisson model lacks many properties which are common in real networks.For example, the clustering coefficient C is low and equal to q = z N .Then, C tends to zero as N −1 in the limit of large system size.Similarly, both community structure and assortative mixing are absent in this ensemble.On the other hand, one of most well known properties of the Poisson model is the occurrence of a phase transition in connectivity for increasing q.In fact, at a critical value for q the system passes from a state in which there are few links and components are small, to a state in which an extensive fraction of all vertices are joined in a single giant component.Then, crossing the phase transition threshold has dramatic effects on whichever interaction process is taking place over the network, favoring for example coordinated/homogeneous outcomes over uncoordinated/heterogeneous ones.
The Poisson model has been used in the economic literature on contagion to study the importance of the agents' connectivity in the analysis of sharing and systemic risk.In particular, Allen & Gale (see [29]) have shown that, modeling the credit system as a random graph, when increasing the degree of connectivity of the network, the probability of bankruptcy avalanches decreases.However, when the credit network is completely connected (i.e.q = 1), these authors have proven that the probability of bankruptcy cascades goes to zero (i.e the Poisson network becomes more resilient as the connectivity increases).The explanation for this result is that, in credit networks, two opposite effects interact.On the one hand, increasing the network connectivity decreases the agents' risk, thanks to risk sharing.On the other hand, increasing the connectivity rises the systemic risk, due to the higher numbers of connected agents which, in case of default, may be compromised.According to this model, the impact of the risk sharing plays a leading role.So, in the model there is a benefit in creating links between agents, because they allow to diversify risk.An exception to this view is the recent contribution by [30].The authors model credit and inter-bank systems as a Poisson random graph and they study the network resilience by changing the degree of connectivity among agents (i.e.q).They show that a too high node (agent) connectivity generates larger bankruptcy cascades due to the larger systemic risk.However, the authors find a non-monotonic relation between connectivity and resiliency.Indeed, the network resiliency increases with the level of the connectivity up to a threshold which can be dubbed as pseudo-optimal.In the model, the level of the optimal connectivity depends critically on the emergence of a giant component.When the Poisson graph reaches the phase transition (i.e. from a low-density, low-state in which there are few edges and all components are small, to a high-density, highstate in which an extensive fraction of all banks is joined together in a single giant component) the authors show that the credit market is more susceptible to the domino effect.In this case, when failures occur, many agents are potentially compromised.
Within an ABM setting, the Poison model may be also summarized as follows: in every decision period, each agent communicates with a set of other agents chosen at random from the population.This mechanism could be interpreted as a stochastic collection of information.Once the different informative signs are found, one has to understand where the dynamic process converges, that is, which outcome agents obtain. 10Poisson graphs have an important role to determine some economic structures where agents decide at random with whom they will trade.It is logical to think that, when an agent for the first time enters into a market he decides to trade or to communicate with others just at random, since he does not yet have any knowledge of the environment where he is going to operate.When his knowledge increases, he will probably choose a different, more elaborated, mechanisms to create his relationships.

The "Small-World" Model
We have seen that Poisson networks are essentially devoid of local structure 11 .
As explained above, Poisson networks exhibit a low average clustering coefficient, which is in contrast with the high clustering coefficient of realworld social networks.If we want to reproduce the random network low distance among agents jointly with the high clustering coefficient of real network, we need to introduce the so-called "small-world"model of Watts and Strogatz [33].
In order to describer the model we must introduce the notion of average path length Λ as the average geodesic (i.e shortest) distance between node pairs in a network: where d i,j is the geodesic distance from node i to j.In the terminology of network theory, "small-world"exists when a network exhibits both high average clustering coefficient and low average path length.The starting point of the "small-world"model is an r-dimensional lattice with periodic boundary conditions 12 .If r = 1, this network can be represented as a ring whose vertices are connected to their z closest neighbors, as shown in figure (1-a).The small-world model is then created by taking a small fraction of the edges in this graph and "rewiring" them.The rewiring procedure involves going through each edge in turn and, with probability q, reconnecting that edge to a new one chosen uniformly at random from the lattice, except that no double edges or self-edges are included.With probability 1 − q, thus, the edge is not reconnected.When q = 0, the small-world network is obviously coincident with the original lattice.In this case the clustering coefficient is C = (3z − 3)/(4z − 2), which tends to 3/4 for large z, which means that average clustering is non vanishing in the limit of large network size.The regular lattice, however, does not show the small-world effect, since the average geodesic distance grows linearly with n.In fact, in this case the mean geodesic distances between vertices tend to n/4z for large n.When q = 1, every edge is rewired to a new random location and the graph is almost a random graph, with typical geodesic distances on the order of log n − z ∼ log n, but very low clustering C ∼ z/n.Via numerical simulation, the authors have proved that, between the extremes q = 0 and q = 1, there is a region in which clustering is high and average path length is simultaneously low.In this region, a "small-world"network configuration finally emerges.
The small-world effect has important implications for the dynamics of processes taking place on networks.In particular, any coordination process will be facilitated, thus increasing the likelihood of a coordinated outcome, since communication across the entire set of agents is made simpler by low average distances, even if interaction is mostly local.Following this idea, Wilhite [34] has built a simple bilateral search and trade model, comparing by simulation alternative network configurations with respect to their ability to deliver a single equilibrium market price under the same trading mechanism.In this framework, the small-world network is seen as a intermediate configuration between purely global (i.e.equivalent to a complete network) and purely local interaction.Simulation results show that, although the complete network converges more rapidly to equilibrium than any other configuration, the small-world network is able to reach equilibrium with a significant saving of search efforts.Thus small-world networks emerge 13 as a more realistic configuration for market exchange, since they take into account the fact that economic agents are willing to economize on search efforts, while on the same time retaining the efficiency of global interaction.

Network formation
In economics the assumption of fixed network topologies is satisfactory only as an initial approximation, since what is most important is the mechanism underlying link formation.Why do different individuals interact with each other?Which motivation pushes agents to communicate with particular individuals and, perhaps, to follow their indications?Some agents may prefer to trade with some others according, for instance, to their geographical position, their loyalty or their popularity.In general, this means there is some variable which affects linking probabilities, introducing a deviation from symmetric models like the Poisson network: some agents are preferred as partners because of some quality, which may be network-related or not.In both cases, this quality may be interpreted as a fitness measure of the agent over the network in question.To illustrate this idea, in the first subsection we are going to present the well known model of preferential attachment, which employs degree itself as a fitness measure, along with its generalization to arbitrary fitness measures.
Alternatively, we may argue that individuals form, maintain or delete relationships using a cost/benefit approach.In order to introduce this approach, in the second subsection we are going to present the popular benchmark model for strategical network formation of Jackson & Wolinsky [36].This model, known as "Symmetric Connection model", refers to an undirected network, since the formation of a link requires the agreement of both agents who are directly involved.Consistently, linking is triggered by a cost/benefit analysis: agents form relationships that they find beneficial and remove those that are not, although they are not necessarily fully rational or aware of all the potential options.

Fitness networks
A classical example of network formation is given by the work of Price [37] on citations among scientific publications.In this study nodes are represented by articles, and a directed edge indicates that article i cites article j.Let p(k) be the fraction of vertices with in-degree k, i.e. with k citations.According to the model, new nodes are continually added to the network.Each new vertex has a certain out-degree (number of cited papers), which is fixed permanently at the creation of the vertex.The out-degree may vary across nodes but its average value z is constant over time.The model finally dictates that the probability of a new article linking to an existing one is proportional to the in-degree k of latter: where D in stands for the sum of in-degrees across agents, which acts as a normalization constant.It is possible to show that, under this assumption, the in-degree follows a power-law distribution p(k) ∝ k −a (e. g. [8], pp.67-70), which is a good descriptor of the empirical degree distribution found in citation networks, as well as in many other domains.For instance, H. Simon [38] found that the power-law distribution of wealth could be explained as a consequence of a "rich get richer" process which is similar to the Price model.Barabasi & Albert [39], [40] have applied an equivalent "preferential attachment" scheme to an undirected network in order to obtain a growth model for the Web, which has become a widely employed benchmark in the field of complex networks.Other models have removed some of the constraints of the original Price's model, e. g. by allowing the addition of new out-going edges from incumbent nodes or the deletion/rewiring of existing links [41].
An important generalization of the preferential attachment scheme is provided by Bianconi & Barabasi [42].In their model each newly appearing vertex i is given a fitness value f i that represents its attractiveness and hence its propensity to accrue new links.It is worth to underline the difference between preferential attachment and fitness: when one considers a fitness algorithm it is true that the larger the fitness the larger the degree, but the converse implication doesn't hold anymore, since the larger degree becomes only a consequence of an intrinsic quality.It's easy to see that fitness based linking lends itself more naturally to economic interpretation than preferential attachment.For instance, it seems reasonable to expect that agents entering some market will observe incumbents' performance or reputation, and they will accordingly decide to communicate with and/or conform with the most successful ones.
A simple example of fitness algorithm is implemented by Tedeschi et al. [43].In this model, directed links are created and deleted by agents seeking advice from a single other agent, who is selected as advisor on the basis of a fitness parameter given by its wealth.Agents start with the same initial wealth W t , but some agents may become richer than others as time goes by.Agents' fitness at time t is defined as their wealth relative to the wealth W max t of the wealthiest agent: Each agent i starts with one outgoing link with a random agent j, and possibly with some incoming links from other agents.Links are rewired at the beginning of each period in the following way: each agent i cuts its outgoing link with agent k and forms a new link, with a randomly chosen agent j, with the following probability: Otherwise, it maintains its existing link with probability 1 − p i .The rewiring algorithm is designed so that successful agents gain a higher number of incoming links.Nonetheless the algorithm introduces a certain amount of randomness, and links with more successful agent have a positive probability to be deleted in favor of links with less successful agents.This randomness helps unlocking the system from the situation where all agents link to the same individual.The parameter β i ∈[0, ∞] in Eq. 5 is the key element generating different network structures.It represents the signal credibility and answers the question how much agents trust on the information about other agents' performance.For β i ∈ [0, 1) differences in fitness are smoothed, unchanged for β i = 1 and amplified for β i > 1.By varying the parameter β i , therefore, the fitness network self-organizes itself through different topologies, ranging from the random (for β i = 0) to the scale-free one.It is straightforward how the network architecture depends on the fitness signal strength β i .This parameter shapes the network topology by amplifying the signal on agent's attractiveness (see [44], [17], [45]).In table (1), left side, we plot one snapshot of the configuration of the resulting network.The graph shows that few rich agents co-exist and compete for popularity.Moreover the network is very centralized, with a small number of rich agents.The topology of the network is different from that of a Poisson random graph, which would require degrees to follow the Binomial (or Poisson) distribution, but closer to the topology of real world networks, where some agents are found to have a disproportionately large number of incoming links while others have very few.In fact, Table .(1), right side, shows that the decumulative distribution function (DDF) of the in-degree follows a power-law distribution.

A Cost/Benefit Approach: the Symmetric Connections Model
In the symmetric connections model, agents are supposed to be able to compute the net payoff of adding and/or removing a link to any other agent, and to be motivated to maximize their own total payoff from linking/delinking.In particular, for some decay factor δ ∈ (0, 1) and linking cost c > 0, the payoff of any agent is given by: where π i (.) is a function of the underlying network since it depends on the geodesic distance d(i, j) and the degree k i .The meaning of this expression is clear: connected agents receive a direct benefit from the interaction with their first neighbors, and an undirected benefit from the interaction with neighbors of neighbors, which is decreasing with distance d(i, j).On the other hand, direct links bear a cost c, while indirect ones bear no cost.The problem, for each agent, is to maximize π i , for given δ and c, by adding removing links with other players.Since agents are not fully rational, it becomes interesting to check if their interactions move toward efficient outcomes.In order to tackle this problem, we need an equilibrium notion suitable for network contexts 14 .Jackson and Wolinsky provide the following definition, which is based on the simple idea that any two nodes should link whenever this action is in their own interest, and each single node should sever a link whenever this is in her/his own interest: Definition 1. : Pairwise Stability (PwS hereinafter) A network G = (V, E) is said to be pairwise stable if where 15The authors show that, given the payoff function described above, the following results hold ( [36]: prop.2): 1. if δ 2 < δ − c, the unique PwS network is the complete network 2. if δ − δ 2 < c < δ, a star encompassing all vertices is PwS, but the converse is not true 3. if δ < c, any PwS network which is non-empty is such that each player has at least two links.
While the first result is pretty obvious, the second and third ones are more interesting but fairly weak.The former depends either from the star being the initial condition of the linking process, and then showing that no deviation is possible, or from the empty network being the initial condition, and then linking decisions following a particular sequence 16 .The latter relies on the fact that no link will be retained unless it bears additional indirect benefits, so nodes with k = 1 cannot be part of a PwS network in that case.But in this case we gain no clue as to how the stable network structure will look like, since the latter will depend from the exact values of the parameters, the initial network and the sequence of linking and de-linking decisions made by the agents.
The plurality of outcomes lends itself perfectly for a simple computational implementation, which shows how the assumptions regarding the sequence of linking decisions determine the outcome of the model.In the first place, from Def.(1), we see that agents add edges whenever they bring benefits, i.e. when π = δ − δ d(i,j) − c 0. Since d(i, j) is symmetric, no double checking is needed, with a time saving of O (V ÷ 2) obtained by excluding neighbors of the examined nodes.Verifying this condition on a star graph, we can obtain the results (1) and (2) above, since in this case agents form no additional link.Unfortunately, things are not that simple if we want our agents to delete edges consistently.In fact, although there are no negative externalities generated by edge addition, there are indeed negative externalities generated by link deletion.This is quite clear if we think about result (3), which implicitly assumes that no agent will delete one edge that serves as a gateway to access a valuable portion of the network, even in case this edge costs more than its direct value.On the other hand, whenever some agent deletes one link, some of its neighbors may be worse off, in case their distance from other nodes increases.Then, we must equip our agents, and their neighbors, with the ability to compare the values of the network over the two alternatives of deleting or not deleting the edge in question 17 .But, in order to do this, we must equip them with the ability to compute the value of a network in the first place.As a first step, each agent computes the frequencies of neighbors at a given distance d from i: Then the payoff of the network for i is computed as follows: By letting agents delete links whenever ∆π i 0 upon deletion, we may check the results (1) and (2), provided that we start from an initial complete graph and let each node delete all its edges in sequence.Under this specification we verify, consistently with (3), that the empty graph is a PwS network if δ < c.This happens because all nodes delete all edges except one, and none of them wishes to be the center of a star graph, since this position gets a negative payoff.In this way everybody gets worse off, and the PwS network is inefficient 18 .
One way to avoid this undesirable result is to enable a random pick order of edges.With this adjustment, and starting from a sufficiently large complete graph, with δ < c we get either the empty network or a connected subgraph with each of its vertices displaying at least 2 edges.It is also easy to see that if c is large enough for fixed δ and |V |, the only PwS network is the empty network.We can see this fact most easily in a cycle graph G, i.e. a graph that consists of a single cycle, where πi = 2 i=D−1 i=1 Stability can be checked by verifying that π i 0 for all i ∈ V and, if δ > c, that the diameter of G doesn't exceed the limit log(δ−c) log(δ) which is the maximal distance d(i, j) such that adding a new edge between i and j is providing a negative payoff.
Of course, the deletion process does not help us with the problem of finding a PwS configuration when the initial network is empty.But, if we let nodes add all potentially valuable edges in whatever sequence, we get invariably the complete graph, the star graph and the empty graph for δ 2 < δ − c, δ − δ 2 < c < δ and δ < c respectively.This result highlights the asymmetry generated by the different initial configuration: it is impossible for agents to deviate from the empty graph, whenever δ < c, while, for different random sequences of choices, it is possible to find a non-empty PwS network, in the same parameters' range, if the initial graph is non-empty too.Note also that, if we allow the agents to delete myopically edges as proposed in [47] (see footnote 17), the latter result does not attain, and we are left with the empty network as the unique PwS network.To overcome this state of affairs, we can resort to two different options.The first alternative, following [48], is to introduce randomness, letting agents make errors according to some small probability ε.Then, thanks to the properties of Markov chain processes, agents will settle, among alternative PwS configurations, to those that are stochastically stable 19 , which may be possibly different from the empty graph.The second alternative is to make agents forward looking, by letting them anticipate the subsequent changes of the network, so that they become, so to speak, patient to wait until a PwS configuration is formed that is improving over the empty graph for a subset of the agents.Otherwise we may allow them to compensate each other.In this case, efficient networks may become stable too.The basic idea is that, since the efficient network ends up with a higher level of total resources, if these are appropriately redistributed everyone is better off than at some inefficient network (see again [7], Ch. 11.5).

Interdependency and The Evolution of Networks
Influence is a ubiquitous phenomenon over networks.Agents may change their expectations or behavior due to the expectations or behavior of those with whom they communicate, creating in this way phenomena of herd behavior and/or imitation.Generally speaking, this means that the probability of the agent i being in some state s is conditioned by the states of his neighbors.Then it becomes important to specify how individual behavior reacts to the behavior of neighbors, in order to study what aggregate properties emerge in the population as a consequence of mutual influence.In addition, if we allow agents to update their connections depending on their state, we expect network observables and agents' state variables to become interdependent, since the interaction among linked agents affects state variables which on their turn affect network structures.For instance, in the symmetric connections model the utility of agents depends on their links with other agents, while the same agents modify their links over time depending on the utility they expect from links themselves.
In this section, we wish to introduce a model which elaborates further this sort of interdependency.In order to do so, we need to borrow some concepts and tools from the field of statistical mechanics.In fact, we are interested in computing some aggregate macro variables, like for instance the average degree, starting from the micro-configurations of the system, and this is a task for which statistical mechanics is especially suited.As a first step, following [49], we will define a simple coordination game model, played by neighbors over a fixed network, which provides a simple implementation of interdependent behavior over networks.Subsequently, we will introduce a model, proposed in [50,51], which allows agents to update their connections when playing the same kind of game.As we will see, it is possible to show that this model provides multiple equilibria, thereby making the actual configuration of the network dependent on the history of the network itself.

Coordination games over networks
We start with a simple coordination game model, played by neighbors over a fixed network [49].Agents select the action maximizing their payoff, which is defined as follows: The definition assumes the action space is s = {−1, 1} and that each player i displays the same action with all of its neighbors, while h ∈ (−1, 1) is a key parameter that, if different from zero, introduces a payoff bias in favor of one of the two actions.The vector s(t) ∈ {−1, 1} |N | represents the action profile of the N agents prevailing at time t.Finally, we suppose that each action profile occurs with the following probability: with β 0. Eq. ( 9) means that, if β > 0, then larger values of P * are assigned to action profiles with higher payoffs.Nevertheless, agents are not assumed to behave optimally in this case since, as long as β is finite, action profiles with lower payoffs display positive probability too.
From a theoretical point of view, this model is equivalent to the well known Ising model of magnetization, with s, β, π and h playing the part respectively of the configuration of spins, (the reciprocal of) absolute temperature, (the opposite of) energy, and an external magnetic field.The magnitude of interest is the equivalent of magnetization, as given by a conformity index : Not surprisingly, a large set of economic models can be mapped to various versions of the Isling model to account for different stylized facts, such as bubbles and crashes (see [52], [53]), volatility clustering and power law distribution of returns ( [54]), agents' expectation and herding (see [55], [56]).
Among the many well-known solutions for the Ising or Potts model20 available for regular topologies, some have proven to be relevant also for complex networks.In particular, [57] provides the exact solution for the Ising model defined over a Bethe lattice.This is an infinite rooted tree network where each node has the same number u of neighbors, and each agent (excepted the root node) has one ancestor and u − 1 descendants.This solution has become of particular interest for complex networks, since it's been extended to provide mean-field ( [58])and exact solutions ( [50]) for Potts models on random trees.These solutions are suitable also for random graphs of arbitrary degree distribution (configuration model), because the latter are locally tree-like for large network size.Since the Ising model on Bethe lattice provides a simple entry-point to understand these more complex models, next we are going to provide the basic algorithms needed to simulate it, while referring the reader to the quoted articles for the more advanced analysis required for the extension to random trees.
In general, the need for numerical simulations of this class of models arise systematically, since most exact solutions hold for the limit N → ∞ or under other analogue analytical approximations.The best option is to rely on Markov Chain Monte Carlo (MCMC) methods [59], and in particular on the Metropolis-Hastings (MH)) algorithm, since we know how to evaluate the acceptance probability of a new configuration from eq. ( 9).The pseudocode for this algorithm is reproduced in appendix.Since the MH algorithm is independent from the underlying topology of the network, all we need to simulate our model on a Bethe Lattice is precisely an algorithm to implement such a topology.The main difficulty here derives from the fact that exact solutions of the Ising model refer to deep nodes of a Bethe lattice.The latter, in fact, may be considered as a lattice of coordination number q only by ignoring the boundary sites, which have degree q = 1.The problem with Bethe Lattice is that the ratio of the number of boundary sites to the number of interior sites is not vanishing for n → ∞, since both numbers grow exponentially like (q − 1) n (see [57]: Ch. 4).In this limit deep nodes may be consistently defined as those at infinite distance from the boundary, but this is not possible anymore for finite structures.In the latter, which are sometimes called Cayley trees to draw a clear distinction from the infinite case, boundary effects are predominant, since most nodes are within a short distance from boundary nodes, while deep nodes form a negligible fraction of the total.
In order to solve this problem, we follow [60] in taking, as a substitute for a Cayley tree, a regular random graph which is obtained in the following two steps: (i) create a cycle or ring graph with the desired number of nodes; (ii) add to the cycle graph random pairings of nodes until the desired degree is reached for each node.In the regular random graph there is no boundary but, unlike in Cayley trees, there are loops.On the other hand, the average number of loops of length l increases as λ l with λ = q − 1, and a negligible fraction of nodes belong to any loop of length l for l log N/ log λ.Thus, within a distance d = log q−1 N the random regular graph behaves like a Bethe lattice and it can be shown that in the thermodynamic limit the free energy per site of the random regular graph is the same as in the Bethe-Peierls approximation.Consequently, we can obtain this topology by specifying a procedure for creating the random pairings required from step (ii).These couples can be added as edges to a cycle graph of the desired length to obtain an approximation of a Bethe lattice.The pseudocode for this procedure is reproduced in appendix.
Simulations of the coordination model over this kind of topology correspond to the exact solutions for Bethe lattice with high accuracy for large N ≈ 10 6 .This correspondence can be verified by computing the theoretical value of C, which is given in the limit n → ∞ by the following expression ( [57]; [8]): where x is obtained as a fixed-point solution of the map x t = Φ(x t−1 ) and

Evolving networks
The model of [50,51] allows agents to update connections when playing a coordination game of the kind presented in the previous section.This model can be interpreted as a simplified representation of how agents may evolve their reciprocal interactions over time, according to their goals and behavior rules.Because of this process, network topology cannot be taken as fixed anymore.Instead, since the network is endogenously generated by micro-interactions, at each t the network itself should be viewed as "fitted"to agents' needs.
The model may be conceived as an extension of our previous coordination model to an arbitrary number q of actions a r ∈ A with r = (1, 2, . . ., q) and to an arbitrary, possibly empty, initial network G. On the other hand, the payoff function is simplified to the following form: where time indexes are omitted for simplicity and s i , s j stand, as before, for the states of the agents.The dynamics of the model is described by the following procedures: 1. link formation: at each t every agent is given the opportunity to form new links at a rate η > 0 with a randomly chosen j ∈ V according to the following probability: p = 1 if s i = s j = a r if s i = s j for some small .2. link removal: existing links are taken to vanish at a constant rate, which is normalized to unity 3. action revision: at every t each agent is given the opportunity to revise her strategy at a rate ν > 0; if this event occurs, the agent chooses any a r with the probability where s is identical to s except for the switching of s i to a r .
To simplify things further, here we follow [61] in supposing = 0 and β → ∞, since the most essential features of the model are unaffected by these suppositions.Then new links are formed only between homogeneous agents, and action revision selects only those actions which maximize π i , i. e. those adopted by the largest subsets of neighbors of i, according to the following definition: Actions in B i are then selected with equal probability 1/|B i |.This action revision procedure can be implemented with a simplified version of the standard MH algorithm (see appendix).Since the value of ν doesn't affect the behavior of the model ( [61]), we also suppose for simplicity that ν = 1.This means that, at each t, every agent receive exactly one opportunity to revise her action.
At any t, the state of the system is given by ω(t) = (s(t), G(t)), and its evolution is described by a Markov process for ω(t), whose properties are determined by the transition rates between any two states ω and ω .It can be proven ([61]: prop. 1) that the process is ergodic, and that a single recurrent class of events Ω exists such that µ( Ω) = 1, where µ is the invariant distribution of the process.This class is characterized by the property of having only homogeneous agents reciprocally connected (i.e. ij ∈ E ⇒ s i = s j ), which is a straightforward consequence of the link removal and link formation processes.In fact, the former makes the network empty from any initial condition, while the latter only allows connections between coordinated agents.Then it can be proven ( [61]: prop.2) that µ(ω) ∝ i,j∈V,i<j ( 2η N −1 ) I ij , where I ij is the indicator function of the event ij ∈ E.
Of course, in order to characterize the behavior of the model, we are not interested in single states ω, rather in classes of states displaying the same features.Taking into account the purpose of the model, the most important of these features is indeed the distribution of agents across different actions, because this variable affects directly the mean connectivity of the network and indirectly, through the latter, the level of payoffs.Given any state ω ∈ Ω, we can define P r (w) = {i ∈ V : s i = a r } to be the set of agents choosing a r , and N r = |P r | to be its cardinality.Then P(ω) = (P 1 (ω), . . ., P q (ω)) and N(ω) = (N 1 (ω), . . ., N q (ω)) represent the profiles associated to ω, and Ω(P), Ω(N) are the collections of states consistent with those profiles.Since agents are treated symmetrically in the model excepted for their state, we are particularly interested in the latter subsets, whose measure can be written as follows: The system will converge to those profiles N which have the largest probability according to the previous expression.To find the solution to this maximization problem, it is convenient to replace the previous expression with a continuous approximation e −N f (n) where n = (n 1 , . . ., n q ) with n r = N r /N and f (n) = c + q r=1 (n r log n r − ηn 2 r ) for some constant c.Then we are interested in finding the minima of f (n) under the constraints n 0 and q r=1 n r = 1.In view of the properties of f , there can be at most two values of n r , which can be denoted as n + and n − with n + n − , that can provide a solution to the problem.This fact allows us to divide actions in two classes: predominant, with frequency n + , and dominated, with frequency n − .If we now let L + and L − = q − L + represent the number of actions in the predominant and dominated class respectively, it is possible to write the resolutive values of n + , in force of FOC, as a function of L + and η: In order to find which values of L + are admissible for a given value of η, we must take into account the relevant second order conditions.A full characterization of the problem is then given by the following proposition: Proposition 1.Given q 2, and two thresholds η and η such that η η = q/2, the local minima of f as a function of η can be detected as follows: 1. there is a local minimum with L + = 0 if and only if η η.This minimum is unique in the class with L + = 0. 2. there are q local minima with L + = 1, one for each action being dominant, if and only if η η.These minima are unique in the class L + = 1. 3.There are no minima with L + 2.
The properties of the model in terms of average payoff are captured, as already explained, by the average connectivity prevailing over the network.We can compute the expected value of this quantity as a function of the solution n+ of the optimization problem, for given L + , η and q, using the following expression: The local minima identified by proposition 1 coincide with global minima outside the open interval (η, η).Within the latter, we have two local minima, and only one of these is also the global minimum.For t → ∞ the system converges to the latter, which is the one corresponding to either L + = 1 or L + = 0 depending on either η being larger or smaller of the threshold η * = [(q − 1)(q − 2)] log(q − 1).But the other local minimum still attracts the process for any t < ∞, if the system starts from initial conditions which are closer to that minimum than to the global minimum.Thus, following [61], it is possible to distinguish between an ultralong run (i.e with t → ∞) behavior and a long run (i.e. with t large but finite) behavior of the system, with the latter being the only relevant one for our simulation purposes.In this context, the key to obtain the convergence of simulations towards the desired theoretical results is to keep the profile s fixed while agents are engaged in the process of link formation.This condition allows us to write the degree distribution of agents, conditional on a given s, as This is the binomial distribution characterizing the well-known ER random graph ensemble, with 2η N −1 representing the probability of two nodes in the same class being connected.Thus all we need to implement correctly the link formation process is a procedure to build efficiently ER random graphs (see [62]).
The final arrangement for the simulation setting is to schedule link formation and action update in a sequence such that the latter occurs after links have formed and before they disappear.This is because any systematic action update undertaken when the network is empty leads immediately to a disordered state, since the probability for an isolated node to adopt any action is identical and equal to 1/q.
The results of simulations performed for N = 1000 and q = 10, together with the predicted values derived from equations 16 and 17, are depicted in Figure 2. We must remark that the transition from a low-connected to a highly-connected state occurs before the threshold η = q/2 due to finite size effects.The results highlight the most interesting features of the model which, notwithstanding its simplicity, displays a dynamical behavior which is usually assumed to be typical of real-world complex networks.In the first place, we detect discontinuity as a consequence of sharp phase-transition between a low-connected locally-coordinated state (the one represented mathematically by solutions obtained for L + = 0) and a highly-connected globallycoordinated state (the one represented mathematically by solutions obtained for L − = 0).In the second place, the system displays hysteresis, since the initial conditions matter for its long run (t < ∞) behavior.In fact, a system which was initially in a coordinated state (represented in the figure by triangles) displays higher connectivity when compared to an originally uncoordinated system (represented by stars), both observed at the same value of η.This property may be particularly relevant for those contexts in which time matters, like it is usually the case in the economic domain.According to this model, the likelihood of coordination failures, which lie at the root of institutional failures, depends from the specific historical conditions of the system under consideration.

Conclusions
If we want to understand the influence that social systems have on agents and the way by which heterogeneous individuals create complex environments, it is worth to reproduce the variegated phenomena which emerge when different types of agents communicate and the influence that the system has on the mechanisms driving this interaction.Network theory is a good candidate for this purpose: it is a good instrument to understand the bijective mapping between individuals and environment.In this paper, we have, particularly, dealt with the influence that a network has on the relationships among agents (Static networks) and with the influence that the relationships among agents have on the structure of the network (Growing networks).Here, the focus has been on the way in which individual incentives shape the formation of structure, in particular with respect to the mechanisms of link formation.With this collection, we hope to have encouraged scientists to use this powerful methodology, able to account for an ensemble of stylized facts regarding both micro behaviors and with macro statistical properties.

Figure 1 :
Figure 1: Regular graph with n = 25 nodes and z = 3 (left a).Small World graph with n = 25 nodes and z = 3 created by choosing at random a fraction q of edges in the graph and moving one end of each to a new location, also chosen uniformly at random.(right b).

Table 1 :
Network configuration (left side).The decumulative distribution function (DDF) of the in-degree (right side).