What the Lean code literally says, in plain math · claude-fable-5-1 (independent sub-agent, blind: Lean code + auditor instructions only)
Read-back: BitcoinSelfishErgodic.avgPoolGain_tendsto
Setting. α,γ are real numbers with 0<α<21; there is no hypothesis on γ (it may be any real number, e.g. negative or larger than 1).
Assertion. The real sequence (An)n∈N of time-averaged pool credits from zero converges, as n→∞, to the stationary pool revenue:
n→∞limAn=Revpool(α,γ)=Σ(s↦πα(s)g(s)).
Definitions used, unfolded
State space S. The states are zero, tie, and one state leadm for every natural number m=0,1,2,…; all of these are distinct. (The source comments say that leadm stands for a private lead of m+1 blocks, so lead0 is "lead 1", lead1 is "lead 2", and so on. Formally these are only labels, and every subscript below is this shifted index.)
Sum over all states. For any f:S→R,
Σf=f(zero)+f(tie)+m≥0∑f(leadm),
where the infinite series is the value of the series when the real sequence (f(leadm))m≥0 is summable (for real sequences: absolutely summable). The series is defined to be 0 when that sequence is not summable.
One-step transition weights Pα,γ. For arbitrary real numbers α,γ (the definitions themselves impose no range), there are three outcomes, with weights
qpool=α,qhP=(1−α)γ,qhO=(1−α)(1−γ).
A deterministic successor map step(s,o) is given by
| current state | outcome pool | outcome hP | outcome hO |
|---|
| zero | lead0 | zero | zero |
| tie | zero | zero | zero |
| lead0 | lead1 | tie | tie |
| lead1 | lead2 | zero | zero |
| leadm+2 (m≥0) | leadm+3 | leadm+1 | leadm+1 |
and Pα,γ(s,t)=∑o:step(s,o)=tqo (sum of the weights of the outcomes leading from s to t). Using qhP+qhO=1−α and qpool+qhP+qhO=1, the only entries that can be nonzero are
P(zero,lead0)=α,P(lead0,lead1)=α,P(lead1,lead2)=α,P(leadm+2,leadm+3)=α,P(zero,zero)=1−α,P(lead0,tie)=1−α,P(lead1,zero)=1−α,P(leadm+2,leadm+1)=1−α(m≥0),P(tie,zero)=1,
and every other entry is 0. These identities hold for every real α,γ: the transition weights do not depend on γ, each row sums to 1, and all entries are ≥0 exactly when 0≤α≤1.
Point mass. For a state t, δt(s)=1 if s=t and δt(s)=0 otherwise.
One step applied to a function. For any μ:S→R (not required to be nonnegative, summable or normalized),
(Dμ)(s)=Σ(t↦μ(t)Pα,γ(t,s))=μ(zero)P(zero,s)+μ(tie)P(tie,s)+m≥0∑μ(leadm)P(leadm,s).
(The parameters α,γ are implicit in D=Dα,γ.) For a fixed target s, at most two lead states t have P(t,s)=0, so the lead series here has only finitely many nonzero terms and is an ordinary finite sum.
n steps. D0μ=μ and Dn+1μ=D(Dnμ) for n≥0.
Per-step credits. Blocks credited at a transition from state s under outcome o (natural numbers, cast to reals):
| current state | pool credit (pool / hP / hO) | others credit (pool / hP / hO) |
|---|
| zero | 0/0/0 | 0/1/1 |
| tie | 2/1/0 | 0/1/2 |
| lead0 | 0/0/0 | 0/0/0 |
| lead1 | 0/2/2 | 0/0/0 |
| leadm+2 (m≥0) | 0/1/1 | 0/0/0 |
The expected per-step credits are the weight-averages gα,γ(s)=∑oqo⋅(pool credit) and hα,γ(s)=∑oqo⋅(others credit) with the (possibly negative, if α,γ are out of range) weights qo above. Explicitly, for all real α,γ:
g(zero)=0,g(tie)=2α+(1−α)γ,g(lead0)=0,g(lead1)=2(1−α),g(leadm+2)=1−α;h(zero)=1−α,h(tie)=(1−α)(2−γ),h(leadm)=0 for all m.
Time-averaged credits from zero. For n∈N,
An=n1k=0∑n−1Σ(s↦(Dkδzero)(s)g(s)),Bn=n1k=0∑n−1Σ(s↦(Dkδzero)(s)h(s)),
with 1/0=0, so A0=B0=0. Each inner Σ uses the "series is 0 if not summable" convention separately for each k. Since h vanishes on the lead states, Bn=n1∑k<n[(1−α)(Dkδzero)(zero)+(1−α)(2−γ)(Dkδzero)(tie)].
The fixed distribution πα (it depends on α only). With d(α)=2α3−4α2+1,
πα(zero)=d(α)1−2α,πα(tie)=d(α)(1−α)(α−2α2),πα(leadm)=(1−αα)m⋅d(α)α−2α2,
with real division by 0 giving 0. (For 0<α<21 one has 41<d(α)<1 and 0<α/(1−α)<1, so no division by zero occurs there.)
Stationary revenues.
Revpool(α,γ)=Σ(s↦πα(s)g(s))=πα(tie)(2α+(1−α)γ)+m≥0∑πα(leadm)g(leadm)
(series set to 0 if not summable; its terms are 0 for m=0, 2(1−α)πα(lead1) for m=1, (1−α)πα(leadm) for m≥2), and
Revoth(α,γ)=Σ(s↦πα(s)h(s))=(1−α)πα(zero)+(1−α)(2−γ)πα(tie).
Confirmed by the moderator at approval.