Documentation

CslibFrontier.Computability.LogSpaceDerandomization.PolynomialAtomCompression

Actual compression comparison and fourth-moment assembly #

The final output of the actual compression recursion is compared with truth on every run outside false first overflows. A least actual overflow is selected when one exists; the selected tail retains both that first-overflow event and the caller's chosen heavy-event predicate. No bound on the final output discrepancy is assumed.

The final-prefix and tail coefficient is fixed before the compression scale; only the weighted preloss coefficient depends on that scale. The heavy predicate is a parameter of this deterministic partition, not a claim about its probability. Clients can instantiate it with the concrete heavy-count event and separately charge false overflows.

These are bounded assembly steps toward the fourth-moment adaptation of [OpenAI2026LogSpace, Section 8.4, Proposition 8.5]. The integrated estimate also charges false first overflows by their actual raw-prefix moments. Mean/noise decomposition and convergent parameter schedules remain separate. The budget hypotheses control every raw prefix pointwise; this module does not yet derive these budgets from estimator input moments.

Main results #

References #

theorem Cslib.PolynomialAtomRow.exists_compression_root_bound (kind : PolynomialAtomRow) {θ : ℝ} (hθ : 0 < θ) :
∃ (C : ℝ), 0 ≤ C ∧ ∀ (η : ℝ), 0 < η → η ≤ θ / 10000 → ∃ (A : ℝ), 0 ≤ A ∧ ∀ {ι : Type u_1} (S : Finset ι) (n : ℕ → ℕ) (Δ : ℕ → ι → Fin 2 → ℝ) (a : RowCompression.State ι) (truth : ι → Fin 2 → ℝ) (K m : ℕ) (heavy : ℕ → Prop), 0 < K → a.defaultValue = 0 → (∀ y ∈ S, 0 ≤ truth y 0) → (∀ y ∈ S, |truth y 1| ≤ η / 2) → (∀ i < m, K ≤ n i) → ∀ (ε : ℕ → ℝ), (∀ i < m, 0 ≤ ε i) → (∀ i < m, ∀ y ∈ S, RowCompression.clippedError (truth y 0) (truth y 1) (RowCompression.uncompressedRow Δ a.row (i + 1) y) ≤ ε i) → ∀ (εfinal : ℝ), 0 ≤ εfinal → (∀ y ∈ S, RowCompression.clippedError (truth y 0) (truth y 1) (RowCompression.uncompressedRow Δ a.row m y) ≤ εfinal) → (¬∃ j < m, RowCompression.IsFirstOverflow S n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) Δ a j ∧ ¬heavy j) → ∀ y ∈ S, |kind.stateRootError θ S K (RowCompression.iterate S n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) Δ a m) { defaultValue := 0, row := truth } y| ≤ (A * ∑ i ∈ Finset.range m, RowCompression.dyadicFloor η m i * ε i + C * if ∀ i < m, RowCompression.stepThreshold S n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) Δ a i ≤ RowCompression.dyadicFloor η m i then εfinal else 0) + C * ∑ j ∈ Finset.range m, if RowCompression.IsFirstOverflow S n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) Δ a j ∧ heavy j then ∑ i ∈ Finset.Ico j m, 28 ^ (m - i) * ε i else 0

Outside false first overflows, the actual output has a weighted prefix contribution, a no-overflow final contribution, and the tail at the actual true first overflow. The final and tail coefficient is chosen before the compression scale.

theorem Cslib.PolynomialAtomRow.exists_compression_rowNormPow_le (kind : PolynomialAtomRow) {θ : ℝ} (hθ : 0 < θ) :
∃ (C : ℝ), 0 ≤ C ∧ ∀ (η : ℝ), 0 < η → η ≤ θ / 10000 → η ≤ 1 → ∃ (A : ℝ), 0 ≤ A ∧ ∀ {Ω : Type u_1} {V : Type u_2} [inst : Fintype Ω] [inst_1 : Fintype V] (N u : ℝ), 0 ≤ N * u → ∀ (X Y : Ω → V → Prop) [inst_2 : (σ : Ω) → (x : V) → Decidable (X σ x)] [inst_3 : (σ : Ω) → (y : V) → Decidable (Y σ y)] (n : ℕ → ℕ) (K m : ℕ), 0 < K → (∀ i < m, K ≤ n i) → ∀ (Δ : Ω → V → ℕ → V → Fin 2 → ℝ) (a : Ω → V → RowCompression.State V) (truth : Ω → V → V → Fin 2 → ℝ), (∀ (σ : Ω) (x : V), X σ x → (a σ x).defaultValue = 0) → (∀ (σ : Ω) (x y : V), X σ x → Y σ y → 0 ≤ truth σ x y 0) → (∀ (σ : Ω) (x y : V), X σ x → Y σ y → |truth σ x y 1| ≤ η / 2) → (∀ j < m, ∀ (σ : Ω) (x y : V), X σ x → Y σ y → truth σ x y 0 ≤ RowCompression.dyadicFloor η m j / 4 → truth σ x y 1 = 0) → ∀ (ε : ℕ → Ω → V → ℝ) (εfinal : Ω → V → ℝ), (∀ i < m, ∀ (σ : Ω) (x : V), X σ x → 0 ≤ ε i σ x) → (∀ (σ : Ω) (x : V), X σ x → 0 ≤ εfinal σ x) → (∀ i < m, ∀ (σ : Ω) (x y : V), X σ x → Y σ y → RowCompression.clippedError (truth σ x y 0) (truth σ x y 1) (RowCompression.uncompressedRow (Δ σ x) (a σ x).row (i + 1) y) ≤ ε i σ x) → (∀ (σ : Ω) (x y : V), X σ x → Y σ y → RowCompression.clippedError (truth σ x y 0) (truth σ x y 1) (RowCompression.uncompressedRow (Δ σ x) (a σ x).row m y) ≤ εfinal σ x) → have S := fun (σ : Ω) => {y : V | Y σ y}; have actual := fun (σ : Ω) (x : V) => RowCompression.iterate (S σ) n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) (Δ σ x) (a σ x) m; have Pre := fun (σ : Ω) (x : V) => ∑ i ∈ Finset.range m, RowCompression.dyadicFloor η m i * ε i σ x; have No := fun (σ : Ω) (x : V) => if ∀ i < m, RowCompression.stepThreshold (S σ) n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) (Δ σ x) (a σ x) i ≤ RowCompression.dyadicFloor η m i then εfinal σ x else 0; have Tail := fun (σ : Ω) (x : V) => ∑ j ∈ Finset.range m, if RowCompression.IsFirstOverflow (S σ) n (fun (x : ℕ) => K) (RowCompression.dyadicFloor η m) (Δ σ x) (a σ x) j ∧ Probability.heavyCountEvent Y Finset.univ (fun (y : V) => truth σ x y 0) (RowCompression.dyadicFloor η m j) (n j) σ then ∑ i ∈ Finset.Ico j m, 28 ^ (m - i) * ε i σ x else 0; (rowNormPow 4 N u X Y fun (σ : Ω) (x y : V) => kind.stateRootError θ (S σ) K (actual σ x) { defaultValue := 0, row := truth σ x } y) ≤ 128 * ↑K * (A ^ 4 * vertexNormPow 4 N u X Pre + C ^ 4 * vertexNormPow 4 N u X No + C ^ 4 * vertexNormPow 4 N u X Tail) + ∑ j ∈ Finset.range m, 64 * ↑K / (↑(n j) * RowCompression.dyadicFloor η m j ^ 4) * rowNormPow 4 N u X Y fun (σ : Ω) (x y : V) => RowCompression.clippedError (truth σ x y 0) (truth σ x y 1) (RowCompression.uncompressedRow (Δ σ x) (a σ x).row (j + 1) y)

The actual final output is bounded by weighted prefix, no-overflow final and true-overflow budgets, plus the existing false-overflow raw-prefix charge. The masks and all errors may be correlated. No final-output error premise or factor counting endpoints or groups is introduced.