Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Proof of Corollary 2, display — ∑i≥1i(si−1d−sid)=∑i≥0sid\sum_{i\ge1} i(s_{i-1}^d-s_i^d)=\sum_{i\ge0}s_i^d∑i≥1​i(si−1d​−sid​)=∑i≥0​sid​

Proved
PowerTwoChoices.Limit.expected_time_identity

by mikedeng1 · Oct 7, 2026 · Mathlib 0df444a (Lean v4.33.1)

load-balancingmean-fieldp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1queueing

Let d≥2d\ge2d≥2 and let s=(s0,s1,… )s=(s_0,s_1,\dots)s=(s0​,s1​,…) be a state of the limiting supermarket system: s0=1s_0=1s0​=1, si≥0s_i\ge0si​≥0, sis_isi​ nonincreasing in iii. An arriving customer becomes the iii-th customer in its queue with probability si−1d−sids_{i-1}^d-s_i^dsi−1d​−sid​. If si→0s_i\to0si​→0 as i→∞i\to\inftyi→∞, then the expected time it spends in the system satisfies

∑i=1∞i (si−1d−sid)=∑i=0∞sid,\sum_{i=1}^\infty i\,(s_{i-1}^d-s_i^d)=\sum_{i=0}^\infty s_i^d ,i=1∑∞​i(si−1d​−sid​)=i=0∑∞​sid​,

as an identity in [0,∞][0,\infty][0,∞].

This summation by parts turns the expected time into a function of the tails, which is how the convergence of the state to the fixed point becomes convergence of the expected time.

Formalization Note. Both sides are computed in [0,∞][0,\infty][0,∞]. The hypothesis si→0s_i\to0si​→0 is implicit in the paper (it holds along every trajectory to which the identity is applied); without it the identity is false.

Preamble
import Mathlib
import Definitions.Def_PowerTwoChoices_Limit_SupermarketSystem

open scoped ENNReal
open Filter Topology
Formal statement
namespace PowerTwoChoices.Limit

/-- Proof of Corollary 2, display (Mitzenmacher 2001, p. 1099). For a state `x` whose tails tend
to `0`, the expected time `∑_{i ≥ 1} i (x_{i-1}^d - x_i^d)` equals `∑_{i ≥ 0} x_i^d`
(both sides in `[0, ∞]`). -/
theorem expected_time_identity (d : ℕ) (hd : 2 ≤ d) (x : ℕ → ℝ) (hx : IsState x)
    (hlim : Tendsto x atTop (𝓝 0)) :
    expectedTime d x = ∑' i : ℕ, ENNReal.ofReal (x i ^ d) := by sorry

end PowerTwoChoices.Limit
Source
Mitzenmacher, The Power of Two Choices in Randomized Load Balancing, IEEE Trans. Parallel Distrib. Syst. 12(10), 2001, p. 1099, proof of Corollary 2, display
Human review
  • Endorsed by Shuze Chen · Oct 7, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 7, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me