The expected cost of a phase to EATR is
ProvedCompetitivePaging.EATR.eatr_phase_costLet algorithm EATR start with its servers on two distinct vertices , let be a request sequence, and let the requests with indices form a complete EATR phase in which clean vertices are requested. Then the expected number of server moves EATR makes on the requests of the phase is exactly
Each request to a clean vertex costs , repeated requests to the most recently requested vertex cost nothing, and the terminating request costs the probability that the stale vertex requested is not covered. This is the on-line side of the per-phase comparison behind Theorem 3.
import Mathlib import Definitions.Def_KServer_model import Definitions.Def_CompetitivePaging_EATR_eatr open scoped ENNReal
namespace CompetitivePaging.EATR
theorem eatr_phase_cost {M : Type*} [DecidableEq M] (a b : M) (hab : a ≠ b)
(σ : List M) (i i' : ℕ) (hph : IsCompletePhase a b σ i i') :
eatrPhaseCost a b σ i i'
= (numClean a b σ i i' : ℝ) + (numClean a b σ i i' : ℝ) / ((numClean a b σ i i' : ℝ) + 1) := by sorry
end CompetitivePaging.EATR
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Setting.
- is any type with decidable equality. No metric is assumed.
- with .
- is a request list, and form a complete phase of EATR's bookkeeping started from , as defined in the bundle above.
Notation.
- is the number of indices whose request was clean just before being served.
- is the expected cost of EATR on request . It is the expected number of vertices covered after the move but not before, averaged over EATR's random state after and then converted to a real number.
Claim. The statement asserts the exact equality, in the real numbers,
Degenerate cases.
- The denominator , so there is no division by zero.
- A complete phase forces , so every in the sum is taken at an index within range and none is the out-of-range default .
- If has at most two points, no phase can start, and the statement is vacuous.
- The "cost" counts newly covered vertices and makes no reference to any distance.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.