How to understand the Nash equilibrium

I was reading some course notes, and I don't quite understand the mathematical definition of Nash equilibrium enter image description here

How should I interpret the mathematical definition? Also, why is (D,D) the unique Nash equilibrium for the prisoner's dilemma even if (C,C) is a better choice for both prisoners???


First, the notation. A game consists of a set of agents or players, denoted by $A_{\rm gt}$, their strategies, $\Sigma$, and the associated payoff functions, $(g_{A})_{A\in A_{\rm gt}}$.

So for the prisoners dilemma the set of players is Player 1 and Player 2. Each have 2 strategies C and D. The payoff function for each player takes the strategy of both players and allocates a payoff. For example if player 1 plays C and player 2 plays D then the payoff for player 1 is $-10$, or $g_{\rm Player 1}(C,D) = -10$, similarly, the payoff for player 2 is $0$, or $g_{\rm Player 2}(C,D) = 0$.

Now Nash Equilibrium is a set containing strategies for each player, denoted $\mathbf{b}$ like our (C,D) that was passed to the payoff functions in our above example, in which no SINGLE player can do better by switching their strategy.

Lets consider the prisoners dilemma again. If player 1 picks $C$ then player 2 will pick $D$ as that gives the better payoff of $0$ over $-3$. Now if player 1 picks $D$ player 2 will again pick $D$ as they get $-5$ over the $-10$ they would get for picking $C$. Thus Player 2 will always pick $D$ as, no matter what player 1 does, the strategy of $D$ will give a higher payoff.

The same goes for player 1. If player 2 plays $C$, player 1 gets a better outcome by picking $D$, if player 2 plays $D$ then player 1 will again be better off by playing $D$. Thus Player 1 will also always play $D$.

In fact we say that both players have a dominant strategy of $D$ as that is the best strategy to play INDEPENDENT of what the other player picks.

So the game will result in the outcome $(D,D)$ which is also the Nash equilibria. Now of course if both players were to pick $C$ then they would get a better outcome for them both. However $(D,D)$ is the Nash equilibria as if a SINGLE player changes their strategy to $C$ they would get a lower payoff. I.e. if player two switches to $C$ when player 1 is playing $D$ they would be worse of, and similarly for player 1. So $(D,D)$ is a set of strategies where no single player can do better by changing their strategy.

Another way of thinking about this is, if they are playing $(C,C)$ then player 1 has an incentive to switch their strategy to $D$ as they will move from $-3$ payoff to $0$ payoff. And the same goes for player 2. Hence they would end back up on $(D,D)$. That is why it is the Nash equilibria, any strategy switch away from that point by a single player would result in a worse outcome for that player.

Finally, the remaining math is essentially saying that. The statement says:

We say $\mathbf{b}$ is a Nash equilibrium iff $\forall A\in A_{\rm gt} \forall d_A\in \Sigma $ s.t. (it shouldn't be "s.t." or "such that", it should be "we have") $g_A(\mathbf{b}_{-A},d_A) \leq g_A(\mathbf{b})$

Notation:

  • $\mathbf{b}$ = the nash equilibrium strategy profile/set
  • iff = if and only iff (its a math way of saying these two things are identical or equivalent)
  • $\forall A\in A_{\rm gt}$ = for any/for all player in the set of players, which we will denote by $A$
  • $\forall d_A\in \Sigma$ = for any/for all alternative strategies of (or deviations by) player $A$
  • $\mathbf{b}_{-A}$ = the nash equilibrium strategy profile/set but not including the strategy of player $A$
  • $g_A(\mathbf{b}_{-A},d_A) \leq g_A(\mathbf{b})$ = the payoff player A gets by switching their strategy, or deviating, is less than or equal to that of the equilibrium

So this math says a set of strategies $\mathbf{b}$ is a nash equilibria if all players get less or the same payoff when they are the only one to deviate from $\mathbf{b}$. I.e. if player 2 switches to $C$ when they are playing $(D,D)$ they get a lower payoff.