Documentation

LeanPool.ErdosGinzburgZiv.EGZ.Expansion.AffineRelations

Integer affine relations #

Clearing denominators in a rational generalized inverse produces a finite family of integer relations. Their evaluations measure the discrepancy from a function that factors through the original constraint matrix.

theorem EGZ.Expansion.exists_integer_generalized_inverse {I : Type u_1} {J : Type u_2} [Fintype I] [Fintype J] (A : Matrix I J ℤ) :
∃ (N : ℕ) (M : Matrix J I ℤ), 0 < N ∧ A * M * A = ↑N • A

An integer multiple of a generalized inverse.

theorem EGZ.Expansion.exists_integer_relations {I : Type u_1} {J : Type u_2} [Fintype I] [Fintype J] [DecidableEq J] (A : Matrix I J ℤ) :
∃ (N : ℕ) (B : Matrix J I ℤ) (Q : Matrix J J ℤ), 0 < N ∧ Q = ↑N • 1 - B * A ∧ A * Q = 0

The rows recording total mass and every affine coordinate.

Equations
Instances For
    theorem EGZ.Expansion.exists_affine_relations {r : ℕ} (S : Finset (IntCoord r)) :
    ∃ (N : ℕ) (B : Matrix (↥S) (Option (Fin r)) ℤ) (Q : Matrix ↥S ↥S ℤ), 0 < N ∧ Q = ↑N • 1 - B * affineConstraintMatrix S ∧ affineConstraintMatrix S * Q = 0
    theorem EGZ.Expansion.relation_column_sum {r : ℕ} {S : Finset (IntCoord r)} {Q : Matrix ↥S ↥S ℤ} (hQ : affineConstraintMatrix S * Q = 0) (q : ↥S) :
    ∑ z : ↥S, Q z q = 0
    theorem EGZ.Expansion.relation_column_weighted_sum {r : ℕ} {S : Finset (IntCoord r)} {Q : Matrix ↥S ↥S ℤ} (hQ : affineConstraintMatrix S * Q = 0) (q : ↥S) :
    ∑ z : ↥S, Q z q • ↑z = 0
    theorem EGZ.Expansion.relation_column_pos_neg_sum {r : ℕ} {S : Finset (IntCoord r)} {Q : Matrix ↥S ↥S ℤ} (hQ : affineConstraintMatrix S * Q = 0) (q : ↥S) :
    ∑ z : ↥S, (Q z q).toNat = ∑ z : ↥S, (-Q z q).toNat

    A signed affine relation is represented by its positive and negative parts, which have the same nonnegative total size.

    theorem EGZ.Expansion.relation_column_pos_neg_weighted_sum {r : ℕ} {S : Finset (IntCoord r)} {Q : Matrix ↥S ↥S ℤ} (hQ : affineConstraintMatrix S * Q = 0) (q : ↥S) :
    ∑ z : ↥S, (Q z q).toNat • ↑z = ∑ z : ↥S, (-Q z q).toNat • ↑z
    theorem EGZ.Expansion.relation_column_evaluation_pos_neg {J : Type u_2} [Fintype J] {R : Type u_3} [AddCommGroup R] {Q : Matrix J J ℤ} (q : J) (v : J → R) :
    ∑ z : J, (Q z q).toNat • v z - ∑ z : J, (-Q z q).toNat • v z = ∑ z : J, Q z q • v z
    theorem EGZ.Expansion.relation_evaluation {I : Type u_1} {J : Type u_2} [Fintype I] [Fintype J] {R : Type u_3} [CommRing R] [DecidableEq J] {A : Matrix I J ℤ} {N : ℕ} {B : Matrix J I ℤ} {Q : Matrix J J ℤ} (hQ : Q = ↑N • 1 - B * A) (v : J → R) :
    theorem EGZ.Expansion.affine_relation_evaluation {r : ℕ} {R : Type u_3} [CommRing R] {S : Finset (IntCoord r)} {N : ℕ} {B : Matrix (↥S) (Option (Fin r)) ℤ} {Q : Matrix ↥S ↥S ℤ} (hQ : Q = ↑N • 1 - B * affineConstraintMatrix S) (v : ↥S → R) (q : ↥S) :
    ∑ z : ↥S, ↑(Q z q) * v z = ↑N * v q - (∑ z : ↥S, ↑(B z none) * v z + ∑ i : Fin r, (∑ z : ↥S, ↑(B z (some i)) * v z) * ↑(↑q i))
    def EGZ.Expansion.affineFromCoefficients {R : Type u_3} [CommRing R] {r : ℕ} (a : Option (Fin r) → R) :
    (Fin r → R) →ᵃ[R] R

    The affine function encoded by its constant and linear coefficients.

    Equations
    Instances For
      theorem EGZ.Expansion.affineFromCoefficients_apply {R : Type u_3} [CommRing R] {r : ℕ} (a : Option (Fin r) → R) (x : Fin r → R) :
      (affineFromCoefficients a) x = a none + ∑ i : Fin r, a (some i) * x i
      theorem EGZ.Expansion.affine_relation_residual_bounded {p r t N W L : ℕ} {S : Finset (IntCoord r)} {B : Matrix (↥S) (Option (Fin r)) ℤ} {Q : Matrix ↥S ↥S ℤ} (hQ : Q = ↑N • 1 - B * affineConstraintMatrix S) (v : ↥S → ZMod p) (ξ : FpCoord p t →ₗ[ZMod p] ZMod p) (q : ↥S) (x : FpCoord p (r + t)) (hx : (Coord.first r t) x = IntCoord.mod p ↑q) (hlocal : HasBoundedRepresentative p W (ξ ((Coord.last r t) x) - v q)) (hrelation : HasBoundedRepresentative p L (∑ z : ↥S, ↑(Q z q) * v z)) :
      theorem EGZ.Expansion.nonconstant_scaled_fibre_residual {p r t N : ℕ} [Fact (Nat.Prime p)] (hN : 0 < N) (hNp : N < p) (ξ : FpCoord p t →ₗ[ZMod p] ZMod p) (hξ : ξ ≠ 0) (a : FpCoord p r →ᵃ[ZMod p] ZMod p) :

      Scaling a nonzero functional in the fibre directions and subtracting an arbitrary affine function of the labels still distinguishes a fibre.