Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Remark 4.12, p. 439 — d_H is a distance on the projective cone: triangle inequality, d_H(u, u′) = 0 iff u = r u′

Proved
CompOT.Sinkhorn.remark_4_12_distance

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

hilbert-projective-metricmetricoptimal-transportp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-bookp2o-v1

Let n≥1n \ge 1n≥1 and let u,u′,u′′∈Rnu, u', u'' \in \mathbb{R}^nu,u′,u′′∈Rn have positive entries. Hilbert's projective metric dHd_{\mathcal H}dH​ is a distance on the rays of the positive cone:

  1. dH(u,u′)≥0d_{\mathcal H}(u,u') \ge 0dH​(u,u′)≥0;
  2. dH(u,u′)=dH(u′,u)d_{\mathcal H}(u,u') = d_{\mathcal H}(u',u)dH​(u,u′)=dH​(u′,u);
  3. dH(u,u′′)≤dH(u,u′)+dH(u′,u′′)d_{\mathcal H}(u,u'') \le d_{\mathcal H}(u,u') + d_{\mathcal H}(u',u'')dH​(u,u′′)≤dH​(u,u′)+dH​(u′,u′′);
  4. dH(u,u′)=0d_{\mathcal H}(u,u') = 0dH​(u,u′)=0 if and only if u=ru′u = r u'u=ru′ for some r>0r > 0r>0.

That is, dHd_{\mathcal H}dH​ is a metric on the projective cone R+,∗n/ ⁣∼\mathbb{R}^n_{+,*}/\!\simR+,∗n​/∼, where u∼u′u \sim u'u∼u′ means that the two vectors agree up to a positive factor. The triangle inequality is the tool behind the a posteriori bound (4.23) in the proof of Theorem 4.2.

Formalization Note The book states "distance" and spells out the triangle inequality and the zero set; nonnegativity and symmetry, which "distance" includes, are stated explicitly.

Preamble
import Mathlib
import Definitions.Def_CompOT_Sinkhorn_Defs
Formal statement
namespace CompOT.Sinkhorn

/-- Remark 4.12, p. 439: `d_H` is a distance on the projective cone of positive vectors:
it is nonnegative and symmetric, satisfies the triangle inequality, and
`d_H(u, u') = 0` if and only if `u = r u'` for some `r > 0`. -/
theorem remark_4_12_distance {n : ℕ} (hn : 0 < n) (u u' u'' : Fin n → ℝ)
    (hu : ∀ i, 0 < u i) (hu' : ∀ i, 0 < u' i) (hu'' : ∀ i, 0 < u'' i) :
    0 ≤ hilbertMetric u u' ∧
    hilbertMetric u u' = hilbertMetric u' u ∧
    hilbertMetric u u'' ≤ hilbertMetric u u' + hilbertMetric u' u'' ∧
    (hilbertMetric u u' = 0 ↔ ∃ r : ℝ, 0 < r ∧ u = r • u') := by sorry

end CompOT.Sinkhorn
Source
Peyré & Cuturi, Computational Optimal Transport (FnT ML 2019), Remark 4.12, p. 439
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