What does Attachment Games and Ceasefire Protocols conclude, in numbers, about “A Safe Dose of Forgiveness: Generous Tit for Tat and the Invasion Window”?
Answer: Forgiveness has a safe window. At a noise level of 0.05 the forgiveness probability should lie between 0.0437 and 0.2811: too little traps a couple in the echo and cannot even hold off an alternator, too much is exploited by alternators and unconditional defectors. The more noise, the narrower the window, and at eps of 0.10 it closes; at that point it is the misreading that has to come down, not the forgiveness that has to be tuned. The evolutionary simulation reproduces the four acts in which tit for tat opens the way and generous rules take over, ending with (0.988, 0.433) as the most common strategy. The payoff table shifts the safe dose: when the last word is sweet, the ceiling is only 1/6. The next chapter asks whether the anxiety and avoidance of attachment research can be written as these parameters.
Scope of the numbers: Its parameters are illustrative, and all calculations are generated by its programs. The parts on founder couples are not individual business advice.
Data table
The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 0.0437, 0.05, 0.10, 0.2811
| eps | 0.05; GTFT(g) residents against two entrants |
| g P(CC) self pay self ALLD vs G ALT vs G invaded by | |
| 0.000 | 0.250 2.250 1.325 2.453 ALT |
| 0.100 | 0.543 2.668 1.663 2.590 none |
| 0.200 | 0.675 2.790 2.001 2.727 none |
| 0.250 | 0.716 2.822 2.170 2.796 none |
| 0.300 | 0.748 2.847 2.338 2.864 ALT |
| 0.333 | 0.766 2.859 2.451 2.910 ALT |
| 0.400 | 0.794 2.879 2.676 3.002 ALT |
| 0.500 | 0.826 2.901 3.014 3.139 ALLD+ALT |
| 0.700 | 0.868 2.927 3.689 3.413 ALLD+ALT |
| 1.000 | 0.902 2.947 4.702 3.825 ALLD+ALT |
| largest g safe from ALLD at eps | 0.05: 0.4646 (noise-free 0.5) |
| largest g safe from ALT at eps | 0.05: 0.2811 (noise-free 0.3333) |
| smallest g safe from ALT at eps | 0.05: 0.0437 (noise-free 0) |
| safe forgiveness window by noise (grid of 1/100, then bisection) | |
| eps 0.01: g from 0.008 to 0.325 | |
| eps 0.02: g from 0.016 to 0.316 | |
| eps 0.05: g from 0.044 to 0.281 | |
| eps 0.08: g from 0.087 to 0.227 | |
| eps 0.10: empty |
Show the full program
# Chapter 2. p21: how much forgiveness, generosity sweep at eps = 0.05.
# Model: the exact chain of p11 with payoffs T=5, R=3, P=1, S=0. GTFT
# with generosity g cooperates after a partner's C and, after a D,
# still cooperates with probability g. For each g we report the payoff
# of GTFT against itself and of two entrants against it: a pure
# defector (ALLD) and an alternator (ALT: C after own D, D after own
# C). An entrant invades when its payoff beats the residents' own.
# Molander's (1985) noise-free bound is g* = min(1 - (T-R)/(R-S),
# (R-P)/(T-P)) = min(1/3, 1/2): ALT sets the first term, ALLD the
# second. g is illustrative.
from fractions import Fraction as F
from functools import reduce
from operator import add
T, R, P, S = 5, 3, 1, 0
PAY = [R, S, T, P]
SWAP = [0, 2, 1, 3]
def fsum_exact(xs):
return reduce(add, xs, F(0))
def noisy(p, e):
return (1 - e) * p + e * (1 - p)
def chain(s1, s2, e):
rows = []
for k in range(4):
a = noisy(F(s1[k]), e)
b = noisy(F(s2[SWAP[k]]), e)
rows.append([a * b, a * (1 - b), (1 - a) * b, (1 - a) * (1 - b)])
return rows
def solve(a, y):
n = len(y)
m = [row[:] + [y[i]] for i, row in enumerate(a)]
for k in range(n):
piv = next(r for r in range(k, n) if m[r][k] != 0)
m[k], m[piv] = m[piv], m[k]
for r in range(n):
if r != k and m[r][k] != 0:
f = m[r][k] / m[k][k]
m[r] = [x - f * z for x, z in zip(m[r], m[k])]
return [m[i][n] / m[i][i] for i in range(n)]
def stationary(mat):
n = len(mat)
a = [[mat[j][i] - (1 if i == j else 0) for j in range(n)]
for i in range(n)]
a[-1] = [F(1)] * n
return solve(a, [F(0)] * (n - 1) + [F(1)])
def pay(s1, s2, e):
pi = stationary(chain(s1, s2, e))
return fsum_exact(p * v for p, v in zip(pi, PAY)), pi
E = F(1, 20)
ALLD = [0, 0, 0, 0]
ALT = [0, 0, 1, 1]
print("eps = 0.05; GTFT(g) residents against two entrants")
print(" g P(CC) self pay self ALLD vs G ALT vs G invaded by")
for g in (F(0), F(1, 10), F(1, 5), F(1, 4), F(3, 10), F(1, 3),
F(2, 5), F(1, 2), F(7, 10), F(1)):
rule = [1, g, 1, g]
ps, pi = pay(rule, rule, E)
pd, _ = pay(ALLD, rule, E)
pa, _ = pay(ALT, rule, E)
who = [n for n, v in (("ALLD", pd), ("ALT", pa)) if v > ps]
print("%5.3f %10.3f %8.3f %9.3f %8.3f %10s"
% (float(g), float(pi[0]), float(ps), float(pd), float(pa),
"+".join(who) if who else "none"))
def bound(entrant, lo=F(0), hi=F(1), rising=True):
# bisect the g at which the entrant stops (or starts) winning
for _ in range(40):
mid = (lo + hi) / 2
rule = [1, mid, 1, mid]
pe, _ = pay(entrant, rule, E)
ps, _ = pay(rule, rule, E)
if (pe > ps) == rising:
hi = mid
else:
lo = mid
return float(lo)
print("largest g safe from ALLD at eps = 0.05: %.4f (noise-free 0.5)"
% bound(ALLD))
print("largest g safe from ALT at eps = 0.05: %.4f (noise-free %.4f)"
% (bound(ALT, F(1, 5), F(1)), 1 / 3))
print("smallest g safe from ALT at eps = 0.05: %.4f (noise-free 0)"
% bound(ALT, F(0), F(1, 5), False))
def safe(g, e):
rule = [1, g, 1, g]
own = pay(rule, rule, e)[0]
return pay(ALT, rule, e)[0] <= own and pay(ALLD, rule, e)[0] <= own
print("safe forgiveness window by noise (grid of 1/100, then bisection)")
for e in (F(1, 100), F(1, 50), F(1, 20), F(2, 25), F(1, 10)):
ok = [i for i in range(101) if safe(F(i, 100), e)]
if not ok:
print(" eps %.2f: empty" % float(e))
continue
ends = []
for i, j in ((ok[0], ok[0] - 1), (ok[-1], ok[-1] + 1)):
lo, hi = F(i, 100), F(j, 100)
for _ in range(30):
mid = (lo + hi) / 2
lo, hi = (mid, hi) if safe(mid, e) else (lo, mid)
ends.append(float(lo))
print(" eps %.2f: g from %.3f to %.3f" % (float(e), ends[0], ends[1]))Single source and citation
Fan, Y. (2026). Attachment Games and Ceasefire Protocols in Intimate Partnerships: Repeated Non-Zero-Sum Games, Emotion-Decay Equations and Ending Cold Wars between Founder Couples (Version 1.0.0), Chapter 2: A Safe Dose of Forgiveness: Generous Tit for Tat and the Invasion Window. 5D Library. DOI pending
DOI pending · monograph page goes live after publication · 5DL-B-285 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026285,
author = {Fan, Yafu},
title = {Attachment Games and Ceasefire Protocols in Intimate Partnerships: Repeated Non-Zero-Sum Games, Emotion-Decay Equations and Ending Cold Wars between Founder Couples},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
note = {DOI pending}
}Other chapter answers in this book
- Chapter 1 · The Echo: an Exact Markov Chain for Tit for Tat under Noise
- Chapter 3 · Attachment as Parameters: Misreading, Forgiveness and the Demand-Withdraw Loop
- Chapter 4 · Emotion-Decay Equations: Coupling, Cooling Times and Two Attractors
- Chapter 5 · The Structure of a Ceasefire: Pause Length, a Named Return and the Shadow of the Future
- Chapter 6 · Founder Couples: Two Boards at Once
- Chapter 7 · Classical Sources: Repaying Grievance with Uprightness, and Seneca on Anger
- Chapter 8 · Closing the Loop: a Ceasefire Card Signed by Both Partners, and a Plan to Refute It