File size: 4,012 Bytes
9dbc64e | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 | import OAI.Computability.DepthThree.HardSliceExistence
import OAI.Computability.DepthThree.HardSliceParameters
import OAI.Computability.DepthThree.FinalParameterBounds
import OAI.Computability.DepthThree.IrreducibleEncoding
import OAI.Computability.DepthThree.LanguageSlice
namespace OAI
noncomputable section
open scoped BigOperators Classical
namespace DepthThreeLowerBound
theorem exists_good_language_slice_eventually (b : ℕ) (hb : 1 ≤ b)
(B : ℝ) (hB : 0 < B) :
∃ N : ℕ, 20480 ≤ N ∧ ∀ n : ℕ, N ≤ n →
∃ α : Fin n → Sum (Fin (dataDimension n)) Bool,
restrictionAvg (liveProbability B (dataDimension n)) (fun σ =>
if ¬ goodRestriction (liveProbability B (dataDimension n))
((2 : ℝ) ^ (-(B * Real.sqrt (dataDimension n : ℝ)) / 16)) b
(fun x => language (List.ofFn (GateInput.assignment α x))) σ
then 1 else 0) ≤
4 * (2 : ℝ) ^ (-(B * Real.sqrt (dataDimension n : ℝ)) / 16) := by
obtain ⟨De, hDe, herr⟩ := actual_hard_slice_error_bound_eventually b hb B hB
obtain ⟨Dp, hDp, hprob⟩ := exists_liveProbability_threshold B hB
let D := max De Dp
refine ⟨5 * D, ?_, ?_⟩
· have hbig : 4096 ≤ D := hDe.trans (le_max_left _ _)
omega
intro n hn
let d := dataDimension n
have hDd : D ≤ d := by
dsimp [d, dataDimension]
omega
have hde : De ≤ d := (le_max_left _ _).trans hDd
have hdp : Dp ≤ d := (le_max_right _ _).trans hDd
have hd4096 : 4096 ≤ d := hDe.trans hde
have hdpos : 0 < d := by omega
have hr : 0 < hashDimension d := hashDimension_pos hdpos
have ht2 : 2 ≤ independenceOrder d := (independenceOrder_two_le_iff d).mpr (by omega)
obtain ⟨h, hh⟩ := independenceOrder_even d
have heven : 2 * h = independenceOrder d := by omega
have hhpos : 0 < h := by omega
obtain ⟨hq0, hqhalf⟩ := hprob d hdp
have hq1 : liveProbability B d ≤ 1 := by linarith
obtain ⟨p, hp⟩ := exists_irreducible_inputPolynomialBits (hashDimension d) hr
let : Fact (Irreducible (BinaryAlgebra.inputPolynomialBits p)) := ⟨hp⟩
have hbound (m : ℕ)
(hmlo : (liveProbability B d * d) / 2 ≤ (m : ℝ))
(hmhi : (m : ℝ) ≤ 2 * (liveProbability B d * d)) :
(2 : ℝ) ^ m / (2 : ℝ) ^ hashDimension d +
sparseMomentBound m b (hardSliceSparseConstant b hb * m) h
((2 : ℝ) ^ (-(m : ℝ) / 4)) ≤
2 * (2 : ℝ) ^ (-(liveProbability B d * d) / 16) := by
rw [liveProbability_mul_dimension B d hdpos] at hmlo hmhi ⊢
exact herr d hde m h hmlo hmhi heven
have hex : ∃ (u : Fin (d + hashDimension d - 1) → Bool)
(β : Fin (independenceOrder d) → BinaryAlgebra.BitQuotient p),
restrictionAvg (liveProbability B d) (fun σ =>
if ¬ goodRestriction (liveProbability B d)
((2 : ℝ) ^ (-(B * Real.sqrt (d : ℝ)) / 16)) b
(hashAcceptance p (independenceOrder d) u β) σ then 1 else 0) ≤
4 * (2 : ℝ) ^ (-(B * Real.sqrt (d : ℝ)) / 16) := by
rw [← heven]
simpa only [liveProbability_mul_dimension B d hdpos] using
exists_good_hash_coefficients p hr hb hhpos (liveProbability B d) hq0.le hq1 hbound
obtain ⟨u, β, hβ⟩ := hex
let c := coefficientInputBits p β
let α : Fin n → Sum (Fin (dataDimension n)) Bool := canonicalSlice n u p c
have hfit : blockLen d ≤ n :=
(blockLen_le_five_mul d hd4096).trans (five_mul_dataDimension_le n)
have heval : (fun x => language (List.ofFn (GateInput.assignment α x))) =
hashAcceptance p (independenceOrder d) u β := by
funext x
rw [language_canonicalSlice_acceptEval n u p c x hdpos ht2 hfit]
change hashAcceptance p (independenceOrder d) u
(fun j => BinaryAlgebra.encode (fun i => BinaryAlgebra.bitValue (p i))
(fun i => BinaryAlgebra.bitValue (coefficientInputBits p β j i))) x = _
rw [hashAcceptance_coefficientInputBits]
refine ⟨α, ?_⟩
rw [heval]
exact hβ
end DepthThreeLowerBound
end
end OAI
|