Advertisement

Prisoner's dilemma calculator

Build a symmetric two-player payoff matrix, check the prisoner's dilemma inequalities and compare expected payoffs for cooperation and defection.

Calculator

Expected payoff: cooperate
1.50000000
Expected payoff: defect
3.00000000
Strict one-shot prisoner's dilemma?
Yes
Mutual cooperation beats alternating exploitation?
Yes
Best response at this probability
Defect
Symmetric payoff matrix
Your actionOpponent actionYour payoffOpponent payoff
CooperateCooperate3.003.00
CooperateDefect0.005.00
DefectCooperate5.000.00
DefectDefect1.001.00

Advertisement

How this calculator works

Enter payoffs as utility, where larger is better, rather than as prison years unless you negate them. The symmetric matrix gives both players the same reward structure. The one-shot dilemma has T > R > P > S: defection is strictly dominant although mutual cooperation pays both more than mutual defection. A separate check shows the common repeated-game condition 2R > T + S.

Formula

E(cooperate) = qR + (1-q)S. E(defect) = qT + (1-q)P. Strict one-shot dilemma: T > R > P > S.

Worked example

For R = 4, T = 6, P = 2, S = -2 and q = 25%, cooperation pays -0.5 on average and defection pays 3. Both players cooperating would give each 4.

Advertisement

Frequently asked questions

Can payoffs be negative?

Yes. Only their ordering matters for the strict dilemma condition. Expected payoffs also depend on their magnitudes.

What if I enter prison years?

Fewer years is better, so convert years to negative utility before using the larger-is-better convention.

Does this model repeated strategies?

No. It evaluates one decision against a stated cooperation probability. Reputation and future retaliation require a repeated-game model.

Sources

Advertisement