Offline · exact source
Exact Lean source

YoungUniformLocalCells

formalization/Cloning/YoungUniformLocalCells.lean

Source hash: 228acdb718ab0abdf37a7dd9dbf51d3b63f4b863f6c442ae4b05838a4e6f232d

Full source copied without mathematical changes from the snapshot whose input hash matches the passing audit. Select a line number for a stable source pointer.

The declarations belong to the compiled inventory covered by the project’s shared axiom audit. That audit records an aggregate union, without attributing axioms to individual declarations.

Declarations in this module
1import Cloning.YoungHyperplaneSampling
2import Cloning.YoungMultinomialLocalLimit
3 
4/-! Quantitative control of every rescaled lattice cell in the actual root
5hyperplane, including its dependent final coordinate. -/
6 
7noncomputable section
8open scoped BigOperators Topology Classical
9open Filter
10namespace Cloning.YoungHyperplane
11set_option backward.isDefEq.respectTransparency false
12set_option maxHeartbeats 800000
13 
14/-- Head coordinates of the cell center are within half the scaled mesh. -/
15theorem sampleCenter_head_distance (d : ℕ) (N : ℤ) (hN : 0 < (N : ℝ))
16    (p : Fin (d + 1) → ℝ) (hp : ∑ i, p i = 1) (μ : Lattice d N)
17    (x : rootSpace d) (hx : x ∈ sampleCell d N p μ) (i : Fin d) :
18    |(sampleCenter d N p μ).1 i.castSucc - x.1 i.castSucc| ≤ 1 / (2 * Real.sqrt (N : ℝ)) := by
19  have hs : 0 < Real.sqrt (N : ℝ) := Real.sqrt_pos.mpr hN
20  have hi : (μ.1 i.castSucc : ℝ) - 1 / 2 ≤
21      Real.sqrt (N : ℝ) * x.1 i.castSucc + (N : ℝ) * p i.castSucc ∧
22      Real.sqrt (N : ℝ) * x.1 i.castSucc + (N : ℝ) * p i.castSucc <
23        (μ.1 i.castSucc : ℝ) + 1 / 2 := hx i (Set.mem_univ i)
24  rw [sampleCenter_apply d N p hp μ]
25  have heq : ((μ.1 i.castSucc : ℝ) - N * p i.castSucc) / Real.sqrt (N : ℝ) - x.1 i.castSucc =
26      ((μ.1 i.castSucc : ℝ) - N * p i.castSucc - Real.sqrt (N : ℝ) * x.1 i.castSucc) /
27        Real.sqrt (N : ℝ) := by field_simp
28  rw [heq, abs_div, abs_of_pos hs]
29  have hb : |(μ.1 i.castSucc : ℝ) - N * p i.castSucc - Real.sqrt (N : ℝ) * x.1 i.castSucc| ≤ 1 / 2 :=
30    abs_le.mpr ⟨by linarith [hi.2], by linarith [hi.1]⟩
31  calc
32    _ ≤ (1 / 2) / Real.sqrt (N : ℝ) := div_le_div_of_nonneg_right hb hs.le
33    _ = _ := by ring
34 
35/-- The dependent last coordinate has the sum of the head mesh errors. -/
36theorem sampleCenter_last_distance (d : ℕ) (N : ℤ) (hN : 0 < (N : ℝ))
37    (p : Fin (d + 1) → ℝ) (hp : ∑ i, p i = 1) (μ : Lattice d N)
38    (x : rootSpace d) (hx : x ∈ sampleCell d N p μ) :
39    |(sampleCenter d N p μ).1 (Fin.last d) - x.1 (Fin.last d)| ≤
40      (d : ℝ) / (2 * Real.sqrt (N : ℝ)) := by
41  have hz := (sampleCenter d N p μ).2
42  have hxx := x.2
43  change (∑ i, (sampleCenter d N p μ).1 i) = 0 at hz
44  change (∑ i, x.1 i) = 0 at hxx
45  rw [Fin.sum_univ_castSucc] at hz hxx
46  have heq : (sampleCenter d N p μ).1 (Fin.last d) - x.1 (Fin.last d) =
47      -(∑ i : Fin d, ((sampleCenter d N p μ).1 i.castSucc - x.1 i.castSucc)) := by
48    rw [Finset.sum_sub_distrib]
49    linarith
50  rw [heq, abs_neg]
51  calc
52    _ ≤ ∑ i : Fin d, |(sampleCenter d N p μ).1 i.castSucc - x.1 i.castSucc| :=
53      Finset.abs_sum_le_sum_abs _ _
54    _ ≤ ∑ _i : Fin d, 1 / (2 * Real.sqrt (N : ℝ)) := by
55      exact Finset.sum_le_sum fun i _ ↦ sampleCenter_head_distance d N hN p hp μ x hx i
56    _ = _ := by simp; ring
57 
58/-- A single bound controls every coordinate, with no discarded last row. -/
59theorem sampleCenter_coordinate_distance (d : ℕ) (N : ℤ) (hN : 0 < (N : ℝ))
60    (p : Fin (d + 1) → ℝ) (hp : ∑ i, p i = 1) (μ : Lattice d N)
61    (x : rootSpace d) (hx : x ∈ sampleCell d N p μ) (i : Fin (d + 1)) :
62    |(sampleCenter d N p μ).1 i - x.1 i| ≤
63      ((d : ℝ) + 1) / (2 * Real.sqrt (N : ℝ)) := by
64  refine Fin.lastCases ?_ (fun j ↦ ?_) i
65  · exact (sampleCenter_last_distance d N hN p hp μ x hx).trans
66      (div_le_div_of_nonneg_right (by linarith) (by positivity))
67  · exact (sampleCenter_head_distance d N hN p hp μ x hx j).trans
68      (div_le_div_of_nonneg_right (show (1 : ℝ) ≤ (d : ℝ) + 1 from le_add_of_nonneg_left (Nat.cast_nonneg d)) (by positivity))
69 
70/-- A bounded set of cell points gives a bounded set of centers. -/
71theorem sampleCenter_coordinate_bound (d : ℕ) (N : ℤ) (hN : 0 < (N : ℝ))
72    (p : Fin (d + 1) → ℝ) (hp : ∑ i, p i = 1) (μ : Lattice d N)
73    (x : rootSpace d) (hx : x ∈ sampleCell d N p μ) (R : ℝ)
74    (hR : ∀ i, |x.1 i| ≤ R) (i : Fin (d + 1)) :
75    |(sampleCenter d N p μ).1 i| ≤ R + ((d : ℝ) + 1) / (2 * Real.sqrt (N : ℝ)) := by
76  calc
77    _ ≤ |(sampleCenter d N p μ).1 i - x.1 i| + |x.1 i| := by
78      simpa only [sub_add_cancel] using
79        abs_add_le ((sampleCenter d N p μ).1 i - x.1 i) (x.1 i)
80    _ ≤ ((d : ℝ) + 1) / (2 * Real.sqrt (N : ℝ)) + R :=
81      add_le_add (sampleCenter_coordinate_distance d N hN p hp μ x hx i) (hR i)
82    _ = _ := by ring
83 
84theorem sample_mesh_tendsto_zero (d : ℕ) :
85    Tendsto (fun N : ℕ ↦ ((d : ℝ) + 1) / (2 * Real.sqrt (N : ℝ))) atTop (𝓝 0) := by
86  simpa only [div_mul_eq_div_mul_one_div, one_div, mul_zero] using
87    YoungMultinomial.inv_sqrt_nat_tendsto_zero.const_mul (((d : ℝ) + 1) / 2)
88 
89end Cloning.YoungHyperplane