Documentation

MIPRE.Foundations.Introspection.LineRepresentativeProg

Uniform executable line representatives #

The program selects the first nonzero direction coordinate, divides the point coordinate by it, and subtracts that multiple of the direction. Selection, inversion, multiplication and the coordinate scan are actual ambient programs. The raw program is polynomial-time and total on every input; correctness is stated on canonical encodings in the constructed Shoup field.

Equations
Instances For
    theorem MIPRE.Introspection.LineProgram.firstPair_getD {F : Type u_1} [Zero F] [DecidableEq F] (l : List (F × F)) (j : ℕ) (hj : (l.getD j (0, 0)).2 ≠ 0) (hprev : ∀ i < j, (l.getD i (0, 0)).2 = 0) :
    firstPair l = l.getD j (0, 0)
    theorem MIPRE.Introspection.LineProgram.firstPair_ofFn {F : Type u_1} [Zero F] [DecidableEq F] {n : ℕ} (u v : Fin n → F) (hv : ∃ (j : Fin n), v j ≠ 0) :
    firstPair (List.ofFn fun (i : Fin n) => (u i, v i)) = (u (Fin.find (fun (j : Fin n) => v j ≠ 0) hv), v (Fin.find (fun (j : Fin n) => v j ≠ 0) hv))
    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      theorem MIPRE.Introspection.LineProgram.representative_nonzero {F : Type u_1} [Field F] [DecidableEq F] {n : ℕ} (u v : Fin n → F) (hv : ∃ (j : Fin n), v j ≠ 0) :
      representative u v = u - (u (Fin.find (fun (j : Fin n) => v j ≠ 0) hv) / v (Fin.find (fun (j : Fin n) => v j ≠ 0) hv)) • v
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          Equations
          • One or more equations did not get rendered due to their size.
          Instances For

            Select a pivot and compute its point/direction ratio; the all-zero direction has coefficient zero.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              Equations
              • One or more equations did not get rendered due to their size.
              Instances For

                One uniform program for arbitrary field widths and vector lengths.

                Equations
                • One or more equations did not get rendered due to their size.
                Instances For

                  The ambient program halts within one polynomial for every raw input, including malformed field elements and unequal vector lengths.

                  The same program has one polynomial bound in field width plus vector length; the polynomial is independent of both parameters.