File size: 1,550 Bytes
e320e82 | 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 | import OAI.Combinatorics.GraphThreshold.Resampling
import Mathlib.Analysis.SpecialFunctions.Exp
import Mathlib.Tactic
namespace OAI
/-! # Success and failure of a local resampling transition -/
noncomputable section
namespace LeanBlast.SecondKahnKalai
variable {X B : Type*} [DecidableEq X] [Fintype B]
/-- The denominator is large enough and the retained fragment fits in the
halved integral capacity. -/
def LocalSuccess (ν : FiniteLaw B) (A : B → Finset X) (ρ : ℝ) (m : ℕ)
(W : Finset X) (c b : B) : Prop :=
Real.exp (-10 * (m : ℝ)) ≤ resamplingZ ν A ρ (W ∪ A c) ∧
(A b \ W).card ≤ m / 2
/-- A local failure is the complement of the actual local success event. -/
def LocalFailure (ν : FiniteLaw B) (A : B → Finset X) (ρ : ℝ) (m : ℕ)
(W : Finset X) (c b : B) : Prop :=
¬ LocalSuccess ν A ρ m W c b
theorem localFailure_iff (ν : FiniteLaw B) (A : B → Finset X) (ρ : ℝ) (m : ℕ)
(W : Finset X) (c b : B) :
LocalFailure ν A ρ m W c b ↔
resamplingZ ν A ρ (W ∪ A c) < Real.exp (-10 * (m : ℝ)) ∨
m / 2 < (A b \ W).card := by
simp only [LocalFailure, LocalSuccess, not_and_or, not_le]
theorem localFailure_iff_twice (ν : FiniteLaw B) (A : B → Finset X) (ρ : ℝ) (m : ℕ)
(W : Finset X) (c b : B) :
LocalFailure ν A ρ m W c b ↔
resamplingZ ν A ρ (W ∪ A c) < Real.exp (-10 * (m : ℝ)) ∨
m < 2 * (A b \ W).card := by
rw [localFailure_iff]
apply or_congr Iff.rfl
omega
end LeanBlast.SecondKahnKalai
end
end OAI
|