Download lean/OAI/Combinatorics/GraphThreshold/Basic.lean from roseking/openAI-math-dataset: direct link, hf CLI and curl.
- Browser
- Download file 908 Bytes
-
https://huggingface.co/datasets/roseking/openAI-math-dataset/resolve/main/lean/OAI/Combinatorics/GraphThreshold/Basic.lean
- Command line
-
hf download hf://datasets/roseking/openAI-math-dataset/lean/OAI/Combinatorics/GraphThreshold/Basic.lean
-
curl -L -o Basic.lean https://huggingface.co/datasets/roseking/openAI-math-dataset/resolve/main/lean/OAI/Combinatorics/GraphThreshold/Basic.lean
908 Bytes
| import OAI.Combinatorics.GraphThreshold.Model | |
| namespace OAI | |
| noncomputable section | |
| namespace LeanBlast.SecondKahnKalai | |
| structure FiniteLaw (Ω : Type*) [Fintype Ω] where | |
| weight : Ω → ℝ | |
| nonneg : ∀ ω, 0 ≤ weight ω | |
| total : ∑ ω, weight ω = 1 | |
| namespace FiniteLaw | |
| def expectation {Ω : Type*} [Fintype Ω] (μ : FiniteLaw Ω) (f : Ω → ℝ) : ℝ := | |
| ∑ ω, μ.weight ω * f ω | |
| def prob {Ω : Type*} [Fintype Ω] (μ : FiniteLaw Ω) (P : Ω → Prop) : ℝ := by | |
| classical | |
| exact ∑ ω, if P ω then μ.weight ω else 0 | |
| def IsPositive {Ω : Type*} [Fintype Ω] (μ : FiniteLaw Ω) : Prop := | |
| ∀ ω, 0 < μ.weight ω | |
| end FiniteLaw | |
| def IsSpread {X B : Type*} [DecidableEq X] [Fintype B] | |
| (μ : FiniteLaw B) (A : B → Finset X) (a : ℝ) : Prop := | |
| ∀ J : Finset X, J.Nonempty → μ.prob (fun b => J ⊆ A b) ≤ a ^ J.card | |
| end LeanBlast.SecondKahnKalai | |
| end | |
| end OAI | |