Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Proposition 2.4, p. 382 — Kantorovich duality: L_C(a, b) = max over (f, g) ∈ R(C) of ⟨f, a⟩ + ⟨g, b⟩

Proved
CompOT.Duality.proposition_2_4

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

kantorovich-dualitylinear-programmingoptimal-transportp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-bookp2o-v1

Let a∈Σna \in \Sigma_na∈Σn​ and b∈Σmb \in \Sigma_mb∈Σm​ be histograms and let C∈Rn×mC \in \mathbb R^{n\times m}C∈Rn×m be any cost matrix. The Kantorovich problem

LC(a,b)=min⁡P∈U(a,b)⟨C,P⟩L_C(a,b) = \min_{P\in\mathbf U(a,b)} \langle C, P\rangleLC​(a,b)=P∈U(a,b)min​⟨C,P⟩

admits the dual

LC(a,b)=max⁡(f,g)∈R(C)⟨f,a⟩+⟨g,b⟩,R(C)={(f,g)∈Rn×Rm:f⊕g≤C}.L_C(a,b) = \max_{(f,g)\in\mathbf R(C)} \langle f,a\rangle + \langle g,b\rangle, \qquad \mathbf R(C) = \{(f,g)\in\mathbb R^n\times\mathbb R^m : f\oplus g \le C\}.LC​(a,b)=(f,g)∈R(C)max​⟨f,a⟩+⟨g,b⟩,R(C)={(f,g)∈Rn×Rm:f⊕g≤C}.

Precisely: there exist a coupling P∈U(a,b)P \in \mathbf U(a,b)P∈U(a,b) minimizing ⟨C,⋅⟩\langle C,\cdot\rangle⟨C,⋅⟩ over U(a,b)\mathbf U(a,b)U(a,b) and a pair (f,g)∈R(C)(f,g)\in\mathbf R(C)(f,g)∈R(C) maximizing ⟨f,a⟩+⟨g,b⟩\langle f,a\rangle+\langle g,b\rangle⟨f,a⟩+⟨g,b⟩ over R(C)\mathbf R(C)R(C), and

⟨C,P⟩=⟨f,a⟩+⟨g,b⟩.\langle C,P\rangle = \langle f,a\rangle + \langle g,b\rangle.⟨C,P⟩=⟨f,a⟩+⟨g,b⟩.

The maximizing (f,g)(f,g)(f,g) are the Kantorovich potentials. This is the finite-dimensional Kantorovich duality on which the dual algorithms of the book (dual ascent, auction, Sinkhorn's dual interpretation) rest.

Formalization Note Both the minimum and the maximum are claims of the book, so both attainments are asserted, through the predicates "optimal coupling" and "dual optimal" rather than through real infima/suprema. The histogram hypotheses are essential: if ∑a≠∑b\sum a \ne \sum b∑a=∑b then U(a,b)\mathbf U(a,b)U(a,b) is empty and the dual is unbounded.

Preamble
import Mathlib
import Definitions.Def_CompOT_Duality_Defs
Formal statement
namespace CompOT.Duality

/-- Proposition 2.4, p. 382 (Kantorovich duality (2.20)): for histograms `a ∈ Σ_n`, `b ∈ Σ_m` and
any cost matrix `C`, the minimum `L_C(a, b)` of (2.11) is attained by some `P ∈ U(a, b)`, the maximum
of `⟨f, a⟩ + ⟨g, b⟩` over `R(C)` is attained by some `(f, g)`, and the two values are equal. -/
theorem proposition_2_4 {n m : ℕ} (a : Fin n → ℝ) (b : Fin m → ℝ)
    (ha : a ∈ stdSimplex ℝ (Fin n)) (hb : b ∈ stdSimplex ℝ (Fin m))
    (C : Matrix (Fin n) (Fin m) ℝ) :
    ∃ (P : Matrix (Fin n) (Fin m) ℝ) (f : Fin n → ℝ) (g : Fin m → ℝ),
      CompOT.Assignment.IsOptimalCoupling C a b P ∧ IsDualOptimal C a b f g ∧ CompOT.Assignment.frob C P = dualObj a b f g := by sorry

end CompOT.Duality
Source
Peyré & Cuturi, Computational Optimal Transport (FnT ML 2019), Proposition 2.4, (2.20)–(2.21), p. 382
Human review
  • Endorsed by Shuze Chen · Oct 8, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 8, 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