Documentation

CslibFrontier.Computability.Circuit.Boolean.WeightedThreshold.LTF

Linear threshold functions on finite domains #

Evaluation, nonzero coordinate support and magnitude ranks for real-weight threshold functions on arbitrary finite input types. Restriction and counting arguments can import this module without the depth-two circuit constructor.

Main definitions #

noncomputable def Cslib.Circuits.Boolean.WeightedThreshold.ltfEval {ι : Type u_1} [Fintype ι] (a : ι → ℝ) (θ : ℝ) (w : ι → Bool) :

Linear threshold function decide (θ ≤ ∑ i : ι, a i * (w i).toNat) on ι → Bool.

Evaluating op : WeightedThreshold.Op under WeightedThreshold.interpretation is ltfEval.

noncomputable def Cslib.Circuits.Boolean.WeightedThreshold.ltfSupport {ι : Type u_1} [Fintype ι] (a : ι → ℝ) :

The active coordinate support {i : ι | a i ≠ 0} of a weight vector a : ι → ℝ.

@[simp]
theorem Cslib.Circuits.Boolean.WeightedThreshold.mem_ltfSupport {ι : Type u_1} [Fintype ι] (a : ι → ℝ) (i : ι) :
i ∈ ltfSupport a ↔ a i ≠ 0
noncomputable def Cslib.Circuits.Boolean.WeightedThreshold.ltfWeightRank {ι : Type u_1} [Fintype ι] (a : ι → ℝ) (i : ι) :

The weight rank k_i = #{j ∈ ltfSupport a | |a i| ≤ |a j|} of coordinate i in ltfSupport a (counting nonzero weights of magnitude at least |a i|).

theorem Cslib.Circuits.Boolean.WeightedThreshold.one_le_ltfWeightRank {ι : Type u_1} [Fintype ι] {a : ι → ℝ} {i : ι} (hi : i ∈ ltfSupport a) :

For every i ∈ ltfSupport a, 1 ≤ ltfWeightRank a i.

theorem Cslib.Circuits.Boolean.WeightedThreshold.ltfWeightRank_le_of_abs_le {ι : Type u_1} [Fintype ι] (a : ι → ℝ) {i j : ι} (hij : |a i| ≤ |a j|) :

If |a i| ≤ |a j|, then ltfWeightRank a j ≤ ltfWeightRank a i.