OAI/Algebra/DepthFive/GateSums.lean
12 declarations, 0 contain sorry, 0 declared as axioms
- def
OAI.Problem335.gateCoefficientline 13Source documentation
The combined coefficient of all wires from a fixed predecessor. Wire multiplicity is absorbed into this coefficient, not charged as gates.
def gateCoefficient {K ι : Type*} [AddCommMonoid K] [DecidableEq ι] (inputs : List (K × ι)) (i : ι) : K := … - theorem
OAI.Problem335.gateCoefficient_nilline 17 - theorem
OAI.Problem335.gateCoefficient_consline 21 - theorem
OAI.Problem335.list_weighted_sum_eq_sumline 28Source documentation
Any finite list of weighted inputs can be regrouped over its finite gate type.
theorem list_weighted_sum_eq_sum {K R ι : Type*} [Semiring K] [Semiring R] [Fintype ι] [DecidableEq ι] (f : K →+* R) (value : ι → R) (inputs : List (K × ι)) : (inputs.map (fun entry => f entry.1 * value entry.2)).sum = ∑ i, f (gateCoefficient inputs i) * value i := by …Mentions: OAI.Problem335.gateCoefficient
- theorem
OAI.Problem335.gateCoefficient_eq_zero_of_not_memline 43Source documentation
A combined coefficient vanishes if its predecessor does not occur.
theorem gateCoefficient_eq_zero_of_not_mem {K ι : Type*} [AddCommMonoid K] [DecidableEq ι] (inputs : List (K × ι)) (i : ι) (h : ∀ entry ∈ inputs, entry.2 ≠ i) : gateCoefficient inputs i = 0 := by …Mentions: OAI.Problem335.gateCoefficient
- theorem
OAI.Problem335.exists_mem_of_gateCoefficient_ne_zeroline 53Source documentation
A nonzero combined coefficient must come from an actual wire.
theorem exists_mem_of_gateCoefficient_ne_zero {K ι : Type*} [AddCommMonoid K] [DecidableEq ι] (inputs : List (K × ι)) (i : ι) (h : gateCoefficient inputs i ≠ 0) : ∃ entry ∈ inputs, entry.2 = i := by …Mentions: OAI.Problem335.gateCoefficient
- theorem
OAI.Problem335.bottomValue_eq_sumline 62 - theorem
OAI.Problem335.middleValue_eq_sumline 68 - theorem
OAI.Problem335.circuitValue_eq_sumline 74 - theorem
OAI.Problem335.bottomDegree_of_gateCoefficient_ne_zeroline 81Source documentation
Aggregating wires preserves the bottom homogeneous-degree constraint.
theorem bottomDegree_of_gateCoefficient_ne_zero {K : Type*} [CommSemiring K] {n : ℕ} (c : Depth5Circuit K n) (i : Fin c.bottomCount) (j : Fin c.leafCount) (h : gateCoefficient (c.bottomInputs i) j ≠ 0) : d5LeafDegree (c.leaves j) = c.bottomDegree i := by …Mentions: OAI.Problem335.Depth5Circuit, OAI.Problem335.gateCoefficient, OAI.Problem335.d5LeafDegree
- theorem
OAI.Problem335.middleDegree_of_gateCoefficient_ne_zeroline 89Source documentation
Aggregating wires preserves the middle homogeneous-degree constraint.
theorem middleDegree_of_gateCoefficient_ne_zero {K : Type*} [CommSemiring K] {n : ℕ} (c : Depth5Circuit K n) (i : Fin c.middleCount) (j : Fin c.lowerCount) (h : gateCoefficient (c.middleInputs i) j ≠ 0) : ((c.lowerInputs j).map c.bottomDegree).sum = c.middleDegree i := by …Mentions: OAI.Problem335.Depth5Circuit, OAI.Problem335.gateCoefficient
- theorem
OAI.Problem335.outputDegree_of_gateCoefficient_ne_zeroline 97Source documentation
Aggregating wires preserves the output homogeneous-degree constraint.
theorem outputDegree_of_gateCoefficient_ne_zero {K : Type*} [CommSemiring K] {n : ℕ} (c : Depth5Circuit K n) (j : Fin c.upperCount) (h : gateCoefficient c.outputInputs j ≠ 0) : ((c.upperInputs j).map c.middleDegree).sum = c.outputDegree := by …Mentions: OAI.Problem335.Depth5Circuit, OAI.Problem335.gateCoefficient