Download lean/OAI/Analysis/FreeEntropy/BlockGaussianQuantitative.lean from roseking/openAI-math-dataset: direct link, hf CLI and curl.
- Browser
- Download file 4.66 kB
-
https://huggingface.co/datasets/roseking/openAI-math-dataset/resolve/main/lean/OAI/Analysis/FreeEntropy/BlockGaussianQuantitative.lean
- Command line
-
hf download hf://datasets/roseking/openAI-math-dataset/lean/OAI/Analysis/FreeEntropy/BlockGaussianQuantitative.lean
-
curl -L -o BlockGaussianQuantitative.lean https://huggingface.co/datasets/roseking/openAI-math-dataset/resolve/main/lean/OAI/Analysis/FreeEntropy/BlockGaussianQuantitative.lean
4.66 kB
| import OAI.Analysis.FreeEntropy.BlockEnsembleLower | |
| namespace OAI | |
| noncomputable section | |
| open MeasureTheory ProbabilityTheory Finset | |
| open scoped ENNReal | |
| namespace FiniteEntropySeparation | |
| variable {p d : ℕ} | |
| theorem two_pow_le_exp (k : ℕ) : (2:ℝ)^k≤Real.exp k := by | |
| have hh := pow_le_pow_left₀ (by norm_num : (0:ℝ)≤2) (show (2:ℝ)≤Real.exp 1 from by linarith | |
| have hgap : Real.sqrt ((p:ℝ)*d)/4-2*ε*(4*Real.sqrt (v*p*d))=Real.sqrt ((p:ℝ)*d)/8 := by | |
| rw | |
| dsimp | |
| field_simp | |
| ring | |
| have hbase : 1+2/ε≤Real.exp 34 := by | |
| have hb : 1+2/ε≤(2:ℝ)^34 := by | |
| have he : 1+2/ε=1+128*Real.sqrt v := by dsimp | |
| norm_num at hvs ⊢ | |
| linarith | |
| exact hb.trans (two_pow_le_exp 34) | |
| have htail : -((Real.sqrt ((p:ℝ)*d)/8)^2)/(4*(v/d))≤-128*(d:ℝ)^2 := by | |
| rw | |
| have he : -((p:ℝ)*d/(8:ℝ)^2)/(4*(v/d))=-(p:ℝ)*(d:ℝ)^2/(256*v) := by field_simp; ring | |
| rw | |
| apply (div_le_iff₀ (by positivity : 0<256*v)).mpr | |
| have hh := mul_le_mul_of_nonneg_right hpv (sq_nonneg (d:ℝ)) | |
| nlinarith | |
| have h1 : (p:ℝ)^d≤Real.exp ((d:ℝ)^2) := by | |
| calc | |
| _ ≤ (Real.exp 64)^d := pow_le_pow_left₀ hp0.le hp d | |
| _ = Real.exp ((d:ℝ)*64) := (Real.exp_nat_mul _ _).symm | |
| _ ≤ _ := Real.exp_le_exp.mpr (by nlinarith) | |
| have h2 : (1+2/ε)^(2*d^2)≤Real.exp (68*(d:ℝ)^2) := by | |
| calc | |
| _ ≤ (Real.exp 34)^(2*d^2) := pow_le_pow_left₀ (by positivity) hbase _ | |
| _ = _ := by rw | |
| calc | |
| _ ≤ (Real.exp 1)^(2*d^2) := pow_le_pow_left₀ (Real.sqrt_nonneg _) hs _ | |
| _ = _ := by rw | |
| calc | |
| _ ≤ Real.exp ((d:ℝ)^2)*Real.exp (68*(d:ℝ)^2)*Real.exp (-128*(d:ℝ)^2)*Real.exp (2*(d:ℝ)^2) := | |
| mul_le_mul (mul_le_mul (mul_le_mul h1 h2 (by positivity) (Real.exp_pos _).le) h3 (by positivity) (by positivity)) h4 (by positivity) (by positivity) | |
| _ = Real.exp (-57*(d:ℝ)^2) := by simp only | |
| theorem chosenTime_pos : 0<chosenTime := by norm_num | |
| theorem chosen_time_noise_budget : 256*chosenTime≤(chosenP:ℝ) := by norm_num | |
| theorem chosen_gaussian_block (hd : 64≤d) {h : ℝ} (hh : 0<h) (hh1 : h<1) : | |
| (normalLaw ((1+h+chosenTime)/d)) | |
| (blockEvent chosenP d (Real.sqrt ((chosenP:ℝ)*d)/4) (4*Real.sqrt ((1+h+chosenTime)*chosenP*d)))≤ | |
| ENNReal.ofReal (Real.exp (-4*(d:ℝ)^2)) := by | |
| apply blockEvent_gaussian_four hd (by have := chosenTime_pos; linarith) | |
| · apply (Real.sqrt_le_left (by positivity : (0:ℝ)≤(2:ℝ)^25)).mpr | |
| norm_num | |