Solving binary linear systems with certified elimination #
theorem
MIPRE.LowDegree.BinaryLinear.IsPivotBasis.reduce_eq_zero
{n t : ℕ}
{b : List (Pivot n t)}
(hb : IsPivotBasis b)
(r : Row n t)
(hr : r.1 ∈ pivotSpan b)
:
A member of the basis span reduces to zero.
theorem
MIPRE.LowDegree.BinaryLinear.represents_typedInsert
{n t : ℕ}
(L : (Fin t → ZMod 2) →ₗ[ZMod 2] Fin n → ZMod 2)
(b : List (Pivot n t))
(r : Row n t)
(hb : ∀ p ∈ b, Represents L p.2)
(hr : Represents L r)
(p : Pivot n t)
:
p ∈ typedInsert b r → Represents L p.2
theorem
MIPRE.LowDegree.BinaryLinear.represents_fold_typedInsert
{n t : ℕ}
(L : (Fin t → ZMod 2) →ₗ[ZMod 2] Fin n → ZMod 2)
(rows : List (Row n t))
(b : List (Pivot n t))
(hb : ∀ p ∈ b, Represents L p.2)
(hr : ∀ r ∈ rows, Represents L r)
(p : Pivot n t)
:
p ∈ List.foldl typedInsert b rows → Represents L p.2
theorem
MIPRE.LowDegree.BinaryLinear.typedBasis_represents
{n t : ℕ}
(L : (Fin t → ZMod 2) →ₗ[ZMod 2] Fin n → ZMod 2)
(rows : List (Row n t))
(hr : ∀ r ∈ rows, Represents L r)
(p : Pivot n t)
:
p ∈ typedBasis rows → Represents L p.2
Every constructed basis row retains its expression in the original generating family.
theorem
MIPRE.LowDegree.BinaryLinear.solve_certificate
{n t : ℕ}
(L : (Fin t → ZMod 2) →ₗ[ZMod 2] Fin n → ZMod 2)
(b : List (Pivot n t))
(hb : IsPivotBasis b)
(hrep : ∀ p ∈ b, Represents L p.2)
(v : Fin n → ZMod 2)
(hv : v ∈ pivotSpan b)
:
Reducing a target with an initially zero certificate solves the original system.
Equations
Instances For
@[simp]
Solve using a supplied pivot basis; the certificate width is unary.
Equations
- One or more equations did not get rendered due to their size.
Instances For
theorem
MIPRE.LowDegree.BinaryLinear.solveBitsProg_encoding
{n t : ℕ}
(b : List (Pivot n t))
(v : Fin n → ZMod 2)
:
solveBitsProg.toFun (Cost.unary t, List.map pivotBits b, vectorBits v) = vectorBits (typedReduce b (v, 0)).2
Solver output is the canonical fixed-width encoding of its coefficient vector.
theorem
MIPRE.LowDegree.BinaryLinear.solveBitsProg_correct
{n t : ℕ}
(L : (Fin t → ZMod 2) →ₗ[ZMod 2] Fin n → ZMod 2)
(b : List (Pivot n t))
(hb : IsPivotBasis b)
(hrep : ∀ p ∈ b, Represents L p.2)
(v : Fin n → ZMod 2)
(hv : v ∈ pivotSpan b)
:
Correctness of the actual uniform binary solver on every target in the basis span.
Construct a basis and solve, all within one ambient polynomial-time program.
Equations
- One or more equations did not get rendered due to their size.
Instances For
theorem
MIPRE.LowDegree.BinaryLinear.basisSolveProg_encoding
{n t : ℕ}
(rows : List (Row n t))
(v : Fin n → ZMod 2)
:
basisSolveProg.toFun (Cost.unary t, List.map rowBits rows, vectorBits v) = vectorBits (typedReduce (typedBasis rows) (v, 0)).2
theorem
MIPRE.LowDegree.BinaryLinear.basisSolveProg_correct
{n t : ℕ}
(L : (Fin t → ZMod 2) →ₗ[ZMod 2] Fin n → ZMod 2)
(rows : List (Row n t))
(hr : ∀ r ∈ rows, Represents L r)
(v : Fin n → ZMod 2)
(hv : v ∈ rowSpan rows)
:
The program solves any consistent binary linear system with supplied generator coordinates.