Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 7.2, p. 16 — Gaussian elimination on a Z₊-matrix: T′ = YT, Y ≥ 0, T′ upper triangular with 0/1 diagonal

Proved
LinExchangeSP.ZPlus.lemma_7_2

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

gaussian-eliminationlinear-algebrap2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1z-matrix

Let T∈Z+(ℓ,t)T \in \mathcal{Z}_+(\ell,t)T∈Z+​(ℓ,t) be a Z+Z_+Z+​-matrix and let (Y,T′)(Y, T')(Y,T′) be the output of the Gaussian elimination of the proof of Lemma 7.2 (step kkk: if the pivot Tkk(k−1)T^{(k-1)}_{kk}Tkk(k−1)​ is nonzero, divide row kkk by it and add −Tik(k−1)/Tkk(k−1)-T^{(k-1)}_{ik}/T^{(k-1)}_{kk}−Tik(k−1)​/Tkk(k−1)​ times row kkk to every row i>ki > ki>k; YYY records the row operations). Then:

  1. T′=YTT' = YTT′=YT;
  2. every entry of Y∈Qℓ×ℓY \in \mathbb{Q}^{\ell\times\ell}Y∈Qℓ×ℓ is nonnegative;
  3. T′T'T′ is upper triangular: Tij′=0T'_{ij} = 0Tij′​=0 for j<ij < ij<i;
  4. every diagonal entry of T′T'T′ is 000 or 111;
  5. every off-diagonal entry of T′T'T′ is nonpositive;
  6. if Tik<0T_{ik} < 0Tik​<0 for some k∈[t]k \in [t]k∈[t] and i∈[k+1,ℓ]i \in [k+1,\ell]i∈[k+1,ℓ], then Tkk′=1T'_{kk} = 1Tkk′​=1:
Tik<0 for some i>k ⟹ Tkk′=1.T_{ik} < 0 \text{ for some } i > k \ \Longrightarrow\ T'_{kk} = 1.Tik​<0 for some i>k ⟹ Tkk′​=1.

Gaussian elimination on a Z+Z_+Z+​-matrix thus only adds nonnegative multiples of rows to other rows. This is what lets the proof of Theorem 6.4 derive valid two-variable constraints for PMP_MPM​ from Mpˉ≥−λM\bar p \ge -\lambdaMpˉ​≥−λ and Mpˉ≤γM\bar p \le \gammaMpˉ​≤γ.

Formalization Note The statement is about the specific elimination procedure of the paper's proof (p. 17), defined in the construction module, not about the existence of some Y≥0Y \ge 0Y≥0: the existential form would be nearly trivial (Y=0Y = 0Y=0 meets every clause but the last). The paper writes T′∈Rℓ×tT' \in \mathbb{R}^{\ell\times t}T′∈Rℓ×t, Y∈Rℓ×ℓY \in \mathbb{R}^{\ell\times\ell}Y∈Rℓ×ℓ; for rational TTT the elimination stays rational and is computed in Q\mathbb{Q}Q. Indices are 0-based.

Preamble
import Mathlib
import Definitions.Def_LinExchangeSP_ZPlus_Setting
import Definitions.Def_LinExchangeSP_ZPlus_Construction
Formal statement
namespace LinExchangeSP.ZPlus

/-- Lemma 7.2 (p. 16), about the output `(Y, T') = gaussElim T` of the elimination of its proof
(p. 17): `T' = YT`, `Y ≥ 0` entrywise, `T'` is upper triangular with diagonal entries `0` or `1`
and nonpositive off-diagonal entries, and `T'_kk = 1` whenever `T_ik < 0` for some `i > k`.
Indices are 0-based. -/
theorem lemma_7_2 {l t : ℕ} (T : Matrix (Fin l) (Fin t) ℚ) (hT : IsZPlus T) :
    (gaussElim T).2 = (gaussElim T).1 * T ∧
    (∀ i j, 0 ≤ (gaussElim T).1 i j) ∧
    (∀ (i : Fin l) (j : Fin t), (j : ℕ) < (i : ℕ) → (gaussElim T).2 i j = 0) ∧
    (∀ (i : Fin l) (j : Fin t), (i : ℕ) = (j : ℕ) →
      (gaussElim T).2 i j = 0 ∨ (gaussElim T).2 i j = 1) ∧
    (∀ (i : Fin l) (j : Fin t), (i : ℕ) ≠ (j : ℕ) → (gaussElim T).2 i j ≤ 0) ∧
    (∀ (k : Fin t) (i : Fin l), (k : ℕ) < (i : ℕ) → T i k < 0 →
      ∀ hk : (k : ℕ) < l, (gaussElim T).2 ⟨k, hk⟩ k = 1) := by sorry

end LinExchangeSP.ZPlus
Source
Garg & Végh, A strongly polynomial algorithm for linear exchange markets, arXiv:1809.06266v3, p. 16, Lemma 7.2 (proof p. 17)
Human review
  • Endorsed by Shuze Chen · Oct 15, 2026

    Confirmed by the moderator at approval.

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