Weighted functions computed by formulas #
Interpreter.Does θ F x Q c says four things:
- all runs of the formula
Fat the treexstop; - they use no named constants;
- the accepting runs have cost at most
c; - for every function
φof the value, their weighted sum is that of the listQof (weight, value) pairs (Interpreter.wsum).
Interpreter.Gives θ F x o c is the case Q = [(1, o)]. Its rules follow the formulas, so the
evaluation of compound programs can be bounded compositionally.
From VP ≠ VNP over every field [Ant26], module NS1.Comp.
Main definitions #
Main results #
Interpreter.Does.plain: the plain sum of a formula thatDoes.Interpreter.Does.cons,Does.app,Does.lett,Does.run,Does.ite_true,Does.ite_false,Does.either,Does.theta: rules for the formulas.Interpreter.Gives.after,Interpreter.Does.of_gives.
theorem Cslib.Circuits.Arithmetic.Separation.Interpreter.Does.congr {A : Type} [CommRing A] {θ : List Bool → A} {F : Fm} {x : Tree} {Q : List (A × Tree)} {c : ℕ} {Q' : List (A × Tree)} (h : Does θ F x Q c) (h1 : ∀ q ∈ Q, ∃ q' ∈ Q', q'.2 = q.2) (h2 : ∀ (φ : Tree → A), wsum Q φ = wsum Q' φ) :
Does θ F x Q' c
Replace the list by an equivalent one.
theorem Cslib.Circuits.Arithmetic.Separation.Interpreter.Does.app {A : Type} [CommRing A] {θ : List Bool → A} {F : Fm} {x : Tree} {Q : List (A × Tree)} {c d : ℕ} {p : Tree} {R : Tree → List (A × Tree)} (hF : Does θ F x Q c) (hG : ∀ q ∈ Q, Does θ (Fm.ofTree p) q.2 (R q.2) d) :
Apply a fixed program to the value.
theorem Cslib.Circuits.Arithmetic.Separation.Interpreter.Does.run {A : Type} [CommRing A] {θ : List Bool → A} {F G : Fm} {x : Tree} {c d : ℕ} {p y : Tree} {R : List (A × Tree)} {e : ℕ} (hF : Gives θ F x p c) (hG : Gives θ G x y d) (h : Does θ (Fm.ofTree p) y R e) :
Apply a program that is the value of a formula.
theorem Cslib.Circuits.Arithmetic.Separation.Interpreter.Does.ite_of {A : Type} [CommRing A] {θ : List Bool → A} {F G H : Fm} {x : Tree} {Q : List (A × Tree)} {c d : ℕ} {K : Fm} {o : Tree} (hF : Gives θ F x o c) (hK : Does θ K x Q d) (hev :
∀ {l l' : List (Run A)},
Ev θ F x l →
(∀ r ∈ l, r.out = o) →
Ev θ K x l' →
Ev θ (F.ite G H) x
(List.flatMap (fun (r : Run A) => List.map (fun (s : Run A) => (r.seq s).tick s.out) l') l)) :
A branch K of an ite whose condition has the one value o: the branch that o selects.
theorem Cslib.Circuits.Arithmetic.Separation.Interpreter.Does.tick {A : Type} [CommRing A] {θ : List Bool → A} {F : Fm} {x : Tree} {c : ℕ} {G : Fm} {f : Tree → Tree} {o : Tree} (h : Gives θ F x o c) (hG : ∀ {l : List (Run A)}, Ev θ F x l → Ev θ G x (List.map (fun (r : Run A) => r.tick (f r.out)) l)) :
A step that maps the value of every run by f (as hd and tl do) maps a value o to
f o.