*Note: We have two versions of the simulation, our original and our newest version. This readME describes the updated version(V2), and our original is there for our reference.
There are N countries who have the ability to build nuclear arms. Each country has incentive to build arms for protection based on the perceived threat of other countries also building/owning nuclear arms. However, it's in all countries' best interest to participate in disarmament to reduce the risk of nuclear conflict. Collectively they benefit, but individual incentive promotes defection. This project simulates the Security Dilemma in game theory, where multiple players(countries) choose between two strategies: to defect(build arms) or cooperate(disarmament). This simulation explores how individual decisions affect utility and outcomes for other players.
- N player game
- Two Strategies:
- Build Arms
- Disarmament
* Let n_b = number of countries that build arms
* Let n_nb = number of countries that do NOT build arms
* Ub = utility for building arms
* Unb = utility for not building arms
* A is the utility gained for building arms, a fixed value
* C(n_b) is the cost function shown below:
where:
* ln (n_B + 1) is the logarithm of the number of countries building arms
The idea for a logarithmic function is that the tensions will eventually plateau as more nations are added or contribute to their nuclear arms. The incremental impact on each nation’s utility will decrease. (+ 1 for the case where 0 countries build arms as ln(0) is undefined)
* B is the utilty that a nation gets for not building arms (like peace points), a fixed value
* G(n_b) is the cost function for not building arms shown below:
where:
* Y is the constant representing the scale of the cost
* n_B is the number of countries not building arms
We chose a dominant strategy game in order to simulate a more realistic environment, where countries are faced with uncertainties of other nations' actions but still choose what's in their best interest. In this game, each country has a clear best strategy(defecting) regardless of what other nations choose to do. We wanted to incorporate more factors playing a role in the decision making process to express the complexity of strategic considerations countries have to make. Each country would consider things like international relationships, reputation, and previous choices to calculate the probability that other countries would cooperate or defect, and base their own decision off of that probability.
To make the decision each round, we formulated expected utility functions for both if a country cooperates or deviates. The utility differs depending on the choice they make, but in both cases they need to consider:
- Probability of all countries cooperating
- Probability of all countries defecting
- All probabilities of all combinations (2 ^ N-1) of each country either cooperating or defecting
These functions consider all possible outcomes of player 𝐴's decision to cooperate or defect, factoring in both the best-case scenario (where all cooperate) and worse-case scenarios (where some or all defect). This reflects the uncertainty and strategic complexity in international relations.
-
$$U_A^{CC}$$ : This is the utility for player A if they cooperate while others also cooperate -
$$U_A^{CD}$$ : This is the utility for player A if they cooperate while others defect -
$$i_r, iA, 0$$ : Reputation of i is$$i_r$$ , i's relationship with A is$$iA$$ , and 0 is i's choice (0 meaning defection, 1 meaning cooperation) -
$$\prod_{i \neq A} p_i^{i_r, iA, 0}$$ : This notation means we're multiplying the probabilities of the other players (all players except A) cooperating. Each$$p_i$$ represents the probability that player$$i$$ cooperates -
$$\prod_{i \neq A} (1 - p_i^{i_r, iA, 0})$$ : This notation indicates the product of the probabilities that the other players do not cooperate.$$1 - p_i$$ represents the probability that player$$i$$ defects -
$$\sum_{S \subset {1, 2, \ldots, N}, S \neq A}$$ : This terms sums over all subsets of players excluding A -
$$U_A^{C,S}$$ : Represents the utility for Player A given a specific subset 𝑆 of players cooperate while the others do not -
$$\prod_{i \in S} p_i^{i_r, iA, 0}$$ : Gives probability that all players in subset 𝑆 will cooperate -
$$\prod_{i \in \bar{S}} (1 - p_i^{i_r, iA, 0})$$ : Gives probability that all players not in 𝑆 will defect
-
$$U_A^{DC}$$ :: This is the utility for player A if they cooperate while others defect -
$$U_A^{DD}$$ : This is the utility for player A if they defect while others also defect -
$$i_r, iA, 1$$ : Reputation of i is$$i_r$$ , i's relationship with A is$$iA$$ , and 1 is i's choice (1 meaning cooperation, 0 meaning defection) -
$$\prod_{i \neq A} p_i^{i_r, iA, 1}$$ : This notation means we're multiplying the probabilities of the other players (all players except A) cooperating. Each$$p_i$$ represents the probability that player$$i$$ cooperates -
$$\prod_{i \neq A} (1 - p_i^{i_r, iA, 1})$$ : This notation indicates the product of the probabilities that the other players do not cooperate.$$p_i$$ represents the probability that player$$i$$ defects. -
$$\sum_{S \subset {1, 2, \ldots, N}, S \neq A}$$ : This terms sums over all subsets of players excluding A -
$$U_A^{C,S}$$ : Represents the utility for Player A given a specific subset 𝑆 of players cooperate while the others do not -
$$\prod_{i \in S} p_i^{i_r, iA, 1}$$ : Gives probability that all players in subset 𝑆 will cooperate -
$$\prod_{i \in \bar{S}} (1 - p_i^{i_r, iA, 1})$$ : Gives probability that all players not in 𝑆 will defect
-
$$P_i$$ shows the probabilty that player i decides to cooperate based on:- player i's previous choice
- player i's relationship with N and,
- player i's reputation for defecting/cooperating
The idea is the relationship value varies for each calculation, allowing each country to assess the probabilities based on its unique relationships with other countries. In this example the relationship value is between current player N and another country
$$i$$ . Player N is going to calculate the probability based on$$i$$ 's reputation, N's relationship with$$i$$ , and$$i$$ 's previous decision to defect or cooperate. They will calculate this for all players$$i$$ . We will then move to player N+1, and N+1 will do the same. This will continue for N players.
- w1, w2, and w3 are weights that determine the influence of each factor on the probability of cooperation and are fixed values in this implementation
- We're using an exponential function because it will always output a value between 0 and 1, where 0 means an event will never occur, and 1 means it will certainly occur
Simulation V2 uses our new utility functions for an n player game. We coded this simulation so that it represents a realistic real world outcome.
In this simulation, there are two rounds. In both rounds, each nation compares its expected utility when cooperating to their expected utility when defecting. Each nation then chooses the maximum between the two.
In this simulation, one important factor is the “reputation” of each nation. This is a number from 0 to 1. Zero means that a nation will always defect and one means a nation will always cooperate. This reputation is used in the probability function and is weighed much heavier than all other parameters.
In the first round, all n players should defect. This is because in the real world, most nations are skeptical of each other and will assume that every other nation is very likely to defect and build arms. Thus, it's in every nation's best interest to also defect and build arms. To represent real world conditions, we set the reputation of each nation to range from 0 to 0.3 to show the initial cautious outlook nations have on one another.
In our second round, we want to show what could be possible with future mechanisms. We change each country's reputation to range from 0.7 to 1.0, showing more developed and trustworthy relationships between nations. Thus, each nation should now cooperate. This is because, if everyone is willing to cooperate, every nation gets more utility compared to when they defect.
Therefore, this second round shows that with the proper mechanisms, we can reach a globally optimal Nash, where no nations defect!
Simulation V1 represents an older, simpler model which achieves the same results. However, simulation V1 does not use our new utility functions.
- Since players are maximizing utility based on probabilities of what other countries will do, the nash occurs when:
- All countries’ best responses are in equilibrium meaning no country has incentive to change its strategy
- The Nash Equilibrium is gauranteed because each player is choosing their best response
- Countries may find defecting as a dominant strategy, leading to a suboptimal outcome
- Our utility functions are convex meaning:
- As players increase their investment in arms (defection), the marginal utility gained decreases
- players may be risk-averse, preferring strategies that ensure a more stable and predictable outcome
- We want to decide on mechanisms from below and incorporate them into our simulation, which will impact our utility/cost functions to create an even more realistic simulation
- Find and fix any potential bugs in our simulation V2
- Study and refine our utility functions, if needed
- Study and refine our probability function, if needed
- If we recognize that players may prefer strategies that mitigate risk due to the convexity of our function, our mechanisms can be aimed more toward incentivizing cooperation, and disincentivizing defection to achieve a more optimal outcome
- Some ideas for incentives include:
- Mutual alliances - if a country defects, their cost could increase(losing alliance benefits/points)
- Providing nations with anti-nuclear arms - adding peace points to utility function, and decreasing the perceived threat making cooperation more attractive
- Reputation costs - damaged reputation increases the cost by losing ability to form alliances, or influences other countries to defect when considering the probability of defection
- Peace points - gain utility for cooperation
- Security gaurantee from other countries - reduces perceived threat, reduces cost in utility function
- Economic advantages - countries involved in disarmament are rewarded with economic/trade advantages increasing utility