Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 2.3 — the cost of a Nash flow is C(f)=∑iLi(f)riC(f) = \sum_i L_i(f) r_iC(f)=∑i​Li​(f)ri​

Proved
SelfishRouting.Bicriteria.lemma_2_3

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

nash-equilibriump2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1selfish-routing

Consider an instance with edge–route incidence matrix AAA (entries 000 or 111), commodities i=1,…,ki = 1,\dots,ki=1,…,k with rates ri>0r_i > 0ri​>0, and edge latency functions ℓe\ell_eℓe​ that are nonnegative, nondecreasing and continuous on [0,∞)[0,\infty)[0,∞). Let fff be a Nash flow. Then there are numbers L1(f),…,Lk(f)L_1(f),\dots,L_k(f)L1​(f),…,Lk​(f) such that every route P∈PiP \in \mathcal P_iP∈Pi​ with fP>0f_P > 0fP​>0 has latency ℓP(f)=Li(f)\ell_P(f) = L_i(f)ℓP​(f)=Li​(f), and

C(f)=∑i=1kLi(f) ri.C(f) = \sum_{i=1}^{k} L_i(f)\, r_i .C(f)=i=1∑k​Li​(f)ri​.

The paper states just before the lemma: "if fff is at Nash equilibrium then all sis_isi​-tit_iti​ flow paths … have equal latency, say Li(f)L_i(f)Li​(f)". The lemma expresses the cost of a Nash flow through these common latencies; the proof of Theorem 3.1 starts from it.

Formalization Note. Li(f)L_i(f)Li​(f) is introduced existentially, as the page's "say Li(f)L_i(f)Li​(f)", together with the property that defines it; no minimum over a possibly empty set is taken. Routes are 0/10/10/1 incidence columns, continuity replaces differentiability (footnote 3), and the latency hypotheses are on [0,∞)[0,\infty)[0,∞) only.

Preamble
import Mathlib
import Definitions.Def_KellyStochasticNetworks_Wardrop
import Definitions.Def_SelfishRouting_Bicriteria_Model
Formal statement
namespace SelfishRouting.Bicriteria

/-- Lemma 2.3 (p. 7): all flow paths of commodity `i` of a Nash flow have a common latency
`L i`, and `C(f) = ∑ᵢ Lᵢ(f) rᵢ`. -/
theorem lemma_2_3 {J R Sd : ℕ} (A : Fin J → Fin R → ℝ) (s : Fin R → Fin Sd)
    (ℓ : Fin J → ℝ → ℝ) (rate : Fin Sd → ℝ)
    (hA : ∀ j r, A j r = 0 ∨ A j r = 1)
    (hrate : ∀ i, 0 < rate i)
    (hℓnn : ∀ j t, 0 ≤ t → 0 ≤ ℓ j t)
    (hℓmono : ∀ j, MonotoneOn (ℓ j) (Set.Ici 0))
    (hℓcont : ∀ j, ContinuousOn (ℓ j) (Set.Ici 0))
    (x : Fin R → ℝ) (hx : IsNashFlow A s ℓ rate x) :
    ∃ L : Fin Sd → ℝ, (∀ r, 0 < x r → pathLatency A ℓ x r = L (s r)) ∧
      cost A ℓ x = ∑ i, L i * rate i := by sorry

end SelfishRouting.Bicriteria
Source
Roughgarden & Tardos, How Bad is Selfish Routing?, J. ACM 49(2) (2002), author's manuscript of 5 Dec 2001, p. 7, Lemma 2.3 and the sentence preceding it
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