Buckets:
| import OAI.Analysis.NodalLength.Excursions | |
| namespace OAI | |
| noncomputable section | |
| open scoped ContDiff Bundle ENNReal | |
| open Bundle Manifold MeasureTheory | |
| open scoped ContDiff ENNReal Topology | |
| open MeasureTheory Filter Set | |
| open scoped Topology ENNReal | |
| open MeasureTheory Filter Set | |
| open scoped Topology ENNReal ContDiff | |
| open MeasureTheory Filter Set | |
| open scoped Topology ENNReal ContDiff | |
| open MeasureTheory Filter Set | |
| open scoped Topology ENNReal ContDiff | |
| open MeasureTheory Filter Set | |
| open scoped Topology ContDiff | |
| open Filter Set | |
| open scoped Topology ContDiff | |
| open Filter Set | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory TopologicalSpace | |
| open scoped Topology ContDiff | |
| open Filter Set | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory TopologicalSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory TopologicalSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory Laplacian | |
| open scoped Topology ENNReal ContDiff ComplexConjugate | |
| open Filter Set MeasureTheory Laplacian | |
| open scoped Topology ENNReal ContDiff ComplexConjugate | |
| open Filter Set MeasureTheory Laplacian | |
| open scoped Topology ENNReal NNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal | |
| open Set MeasureTheory Filter | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Laplacian | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff CompactlySupported | |
| open Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff CompactlySupported | |
| open Set MeasureTheory | |
| open scoped Topology ENNReal ContDiff CompactlySupported | |
| open Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Laplacian | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff Convolution | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Convolution | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Convolution | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Convolution | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Convolution | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff Convolution ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory Function | |
| open scoped Topology | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped BigOperators | |
| open Filter Set MeasureTheory | |
| open scoped BigOperators | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff Convolution | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology | |
| open Filter Set MeasureTheory | |
| open scoped Topology ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff BigOperators | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped Topology ENNReal ContDiff BigOperators | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped BigOperators | |
| open MeasureTheory | |
| open scoped BigOperators | |
| open Set MeasureTheory | |
| open scoped BigOperators | |
| open scoped Classical | |
| open scoped BigOperators Topology ENNReal | |
| open Set MeasureTheory | |
| open scoped BigOperators | |
| open scoped Topology ENNReal ContDiff | |
| open Filter Set MeasureTheory InnerProductSpace | |
| open scoped BigOperators Classical Topology | |
| open Filter Set MeasureTheory | |
| open scoped BigOperators Classical Topology | |
| open Filter Set MeasureTheory | |
| open scoped BigOperators | |
| open Set | |
| open scoped BigOperators Topology | |
| open Set MeasureTheory | |
| open scoped BigOperators | |
| open Set | |
| open scoped BigOperators symmDiff | |
| open Set | |
| open scoped BigOperators | |
| open Set | |
| open scoped BigOperators symmDiff | |
| open Set | |
| open scoped BigOperators Classical | |
| open Set | |
| open scoped BigOperators | |
| open Set | |
| open scoped BigOperators Classical | |
| open Set | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| def wordPoint (A n : ℕ) (p : Point) (w : GridWord A n) : Point := | |
| fun j =>p j*(A:ℤ)^n+(wordIndex A n w j:ℕ) | |
| lemma wordPoint_mem (A n : ℕ) (p : Point) (w : GridWord A n) : | |
| wordPoint A n p w∈(Cell.mk n p).points A := by | |
| apply mem_square.mpr | |
| intro j | |
| have hl : (0:ℤ)≤(wordIndex A n w j:ℕ) := Int.natCast_nonneg _ | |
| have hu : ((wordIndex A n w j:ℕ):ℤ)<(A:ℤ)^n := by exact_mod_cast (wordIndex A n w j).isLt | |
| dsimp only [wordPoint,Cell.side] | |
| push_cast | |
| constructor <;> nlinarith | |
| lemma wordPoint_injective (A n : ℕ) (p : Point) : Function.Injective (wordPoint A n p) := by | |
| intro w v h | |
| apply wordIndex_injective A n | |
| funext j | |
| apply Fin.ext | |
| have hh:=congrFun h j | |
| dsimp only [wordPoint] at hh | |
| exact_mod_cast (add_left_cancel hh) | |
| lemma image_wordPoint (A n : ℕ) (p : Point) : | |
| Finset.univ.image (wordPoint A n p)=(Cell.mk n p).points A := by | |
| apply Finset.eq_of_subset_of_card_le | |
| · intro x hx | |
| obtain ⟨w,-,rfl⟩:=Finset.mem_image.mp hx | |
| exact wordPoint_mem A n p w | |
| · rw [Finset.card_image_iff.mpr (wordPoint_injective A n p).injOn,Finset.card_univ, | |
| gridWord_card,Cell.card_points] | |
| rfl | |
| lemma sum_wordPoint (A n : ℕ) (p : Point) (f : Point → ℝ) : | |
| (∑w : GridWord A n,f (wordPoint A n p w))=∑x∈(Cell.mk n p).points A,f x := by | |
| rw [←image_wordPoint,Finset.sum_image (fun w _ v _ h =>wordPoint_injective A n p h)] | |
| lemma wordPoint_zero (A : ℕ) (p : Point) (w : GridWord A 0) : wordPoint A 0 p w=p := by | |
| ext j | |
| simp [wordPoint,wordIndex] | |
| def childPos (A : ℕ) (p : Point) (i : GridIndex A) : Point := fun j =>p j*A+(i j:ℕ) | |
| lemma wordPoint_succ (A n : ℕ) (p : Point) (w : GridWord A (n+1)) : | |
| wordPoint A (n+1) p w=wordPoint A n (childPos A p (w 0)) (Fin.tail w) := by | |
| ext j | |
| simp only [wordPoint,wordIndex,childPos,Fin.val_cast,finProdFinEquiv,Equiv.coe_fn_mk, | |
| Int.natCast_add,Int.natCast_mul,Int.natCast_pow,pow_succ] | |
| ring | |
| def cellScale (A : ℕ) (t : ℝ) (Q : Cell) : ℝ := t*(A:ℝ)^Q.level | |
| def cellMap (A : ℕ) (t : ℝ) (Q : Cell) : Plane → Plane := | |
| rescaleMap (extendedGridCenter (cellScale A t Q) Q.pos) (cellScale A t Q) | |
| def gridGrowth (A : ℕ) (t : ℝ) (U : Plane → ℝ) (K : ℝ) (Q : Cell) : ℝ := | |
| fieldGrowth (U ∘ cellMap A t Q) (K*cellScale A t Q) | |
| lemma cellScale_succ {A : ℕ} (hA : 0<A) (t : ℝ) (n : ℕ) (p q : Point) : | |
| cellScale A t (Cell.mk n q)=cellScale A t (Cell.mk (n+1) p)/(A:ℝ) := by | |
| have hAr : (A:ℝ)≠0 := by exact_mod_cast hA.ne' | |
| simp only [cellScale,pow_succ] | |
| field_simp | |
| lemma cellMap_child {A : ℕ} (hA : 0<A) (t : ℝ) (n : ℕ) (p : Point) (i : GridIndex A) : | |
| cellMap A t (Cell.mk n (childPos A p i))= | |
| cellMap A t (Cell.mk (n+1) p) ∘ rescaleMap (gridCenter A i) (A:ℝ)⁻¹ := by | |
| have hAr : (A:ℝ)≠0 := by exact_mod_cast hA.ne' | |
| funext x | |
| ext j | |
| simp only [cellMap,cellScale,childPos,rescaleMap,extendedGridCenter,gridCenter, | |
| Function.comp_apply,PiLp.add_apply,PiLp.smul_apply,smul_eq_mul, | |
| Int.cast_add,Int.cast_mul,Int.cast_natCast,pow_succ] | |
| field_simp | |
| ring | |
| lemma pathGrowth_grid {A : ℕ} (hA : 0<A) (t : ℝ) (U : Plane → ℝ) (K : ℝ) | |
| (n : ℕ) (p : Point) (w : GridWord A n) : | |
| pathGrowth A n (U ∘ cellMap A t ⟨n,p⟩) (K*cellScale A t ⟨n,p⟩) w= | |
| gridGrowth A t U K (atLevel A 0 (wordPoint A n p w)) := by | |
| induction n generalizing p with | |
| | zero => | |
| rw [wordPoint_zero] | |
| simp only [pathGrowth,gridGrowth,atLevel,pow_zero,Int.ediv_one] | |
| | succ n ih => | |
| rw [pathGrowth,wordPoint_succ,←ih] | |
| rw [cellMap_child hA,cellScale_succ hA t n p] | |
| simp only [Function.comp_assoc,mul_div_assoc] | |
| lemma pathHigh_grid {A : ℕ} (hA : 0<A) (t : ℝ) (U : Plane → ℝ) (K L : ℝ) | |
| (n : ℕ) (p : Point) (w : GridWord A n) : | |
| PathHigh A L n (U ∘ cellMap A t ⟨n,p⟩) (K*cellScale A t ⟨n,p⟩) w ↔ | |
| ∀R : Cell,R.level≤n → wordPoint A n p w∈R.points A → L<gridGrowth A t U K R := by | |
| induction n generalizing p with | |
| | zero => | |
| simp only [PathHigh] | |
| constructor | |
| · intro h R hR hx | |
| have he : R=⟨0,p⟩:=Cell.equal_level_eq_of_intersection hA (by change R.level=0; omega) hx (wordPoint_mem A 0 p w) | |
| simpa only [he,gridGrowth] using h | |
| · intro hh | |
| exact hh ⟨0,p⟩ le_rfl (wordPoint_mem A 0 p w) | |
| | succ n ih => | |
| have heU : (U ∘ cellMap A t ⟨n,childPos A p (w 0)⟩)= | |
| (U ∘ cellMap A t ⟨n+1,p⟩) ∘ rescaleMap (gridCenter A (w 0)) (A:ℝ)⁻¹ := by | |
| rw [cellMap_child hA]; rfl | |
| have heK : K*cellScale A t ⟨n,childPos A p (w 0)⟩=(K*cellScale A t ⟨n+1,p⟩)/(A:ℝ) := by | |
| rw [cellScale_succ hA t n p]; ring | |
| rw [PathHigh,←heU,←heK,ih] | |
| constructor | |
| · rintro ⟨h,hh⟩ R hR hx | |
| by_cases he : R.level=n+1 | |
| · have hEq : R=⟨n+1,p⟩:=Cell.equal_level_eq_of_intersection hA he hx (wordPoint_mem A (n+1) p w) | |
| simpa only [hEq,gridGrowth] using h | |
| · apply hh R (by omega) | |
| simpa only [←wordPoint_succ] using hx | |
| · intro hh | |
| exact ⟨hh ⟨n+1,p⟩ le_rfl (wordPoint_mem A (n+1) p w), | |
| fun R hR hx =>hh R (by omega) (by simpa only [wordPoint_succ] using hx)⟩ | |
| end SharpNodal.Grid | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| lemma pathHigh_activeSet {A : ℕ} (hA : 0<A) (t : ℝ) (U : Plane → ℝ) (K L : ℝ) | |
| {root Q : Cell} (hQ : Q∈fullTree A root) (w : GridWord A Q.level) : | |
| PathHigh A L Q.level (U ∘ cellMap A t Q) (K*cellScale A t Q) w ↔ | |
| wordPoint A Q.level Q.pos w∈activeSet A (fullTree A root) (gridGrowth A t U K) L Q := by | |
| rw [pathHigh_grid hA] | |
| constructor | |
| · intro h | |
| exact Finset.mem_filter.mpr ⟨wordPoint_mem A Q.level Q.pos w,fun R _ =>h R⟩ | |
| · intro h R hR hx | |
| rcases Finset.mem_filter.mp h with ⟨hxQ,hhigh⟩ | |
| have hxroot:=((mem_fullTree hA).mp hQ).2 hxQ | |
| have hRF : R∈fullTree A root := (mem_fullTree hA).mpr ⟨hR.trans ((mem_fullTree hA).mp hQ).1, | |
| Cell.subset_of_intersection hA (hR.trans ((mem_fullTree hA).mp hQ).1) hx hxroot⟩ | |
| exact hhigh R hRF hR hx | |
| lemma activeGrowth_sum {A : ℕ} (hA : 0<A) (t : ℝ) (U : Plane → ℝ) (K L : ℝ) | |
| {root Q : Cell} (hQ : Q∈fullTree A root) : | |
| (∑w : GridWord A Q.level,activeGrowth A L Q.level (U ∘ cellMap A t Q) (K*cellScale A t Q) w)= | |
| ∑x∈activeSet A (fullTree A root) (gridGrowth A t U K) L Q, | |
| gridGrowth A t U K (atLevel A 0 x) := by | |
| have he (w : GridWord A Q.level) : | |
| activeGrowth A L Q.level (U ∘ cellMap A t Q) (K*cellScale A t Q) w= | |
| if wordPoint A Q.level Q.pos w∈activeSet A (fullTree A root) (gridGrowth A t U K) L Q | |
| then gridGrowth A t U K (atLevel A 0 (wordPoint A Q.level Q.pos w)) else 0 := by | |
| rw [activeGrowth,pathGrowth_grid hA,pathHigh_activeSet hA t U K L hQ] | |
| split_ifs <;> rfl | |
| simp_rw [he] | |
| rw [sum_wordPoint A Q.level Q.pos (fun x => if x∈activeSet A (fullTree A root) (gridGrowth A t U K) L Q | |
| then gridGrowth A t U K (atLevel A 0 x) else 0),←Finset.sum_filter] | |
| congr 1 | |
| ext x | |
| simp only [activeSet,Finset.mem_filter,and_self_left] | |
| theorem active_grid_sum {A : ℕ} {Cp a₀ C₀ C₁ L : ℝ} (hA : 2≤A) | |
| (ha₀ : 0<a₀) (hC₀ : 0≤C₀) (hC₁ : 0≤C₁) | |
| (hrule : DescentRule A Cp a₀ C₀ C₁ L) (t : ℝ) (U : Plane → ℝ) (K : ℝ) | |
| {root Q : Cell} (hQ : Q∈fullTree A root) (E : ScaledWave Cp a₀) | |
| (hU : E.U=U ∘ cellMap A t Q) (hK : E.K=K*cellScale A t Q) | |
| (hbottom : a₀≤K*t) : | |
| (∑x∈activeSet A (fullTree A root) (gridGrowth A t U K) L Q, | |
| gridGrowth A t U K (atLevel A 0 x))≤ | |
| excursionCostConstant C₀ C₁ a₀*(gridGrowth A t U K Q+1)*(Q.points A).card := by | |
| have hAr : 0<(A:ℝ) := by exact_mod_cast (show 0<A by omega) | |
| have hbot : a₀≤E.K/(A:ℝ)^Q.level := by | |
| rw [hK,cellScale] | |
| have he : K*(t*(A:ℝ)^Q.level)/(A:ℝ)^Q.level=K*t := by field_simp | |
| rw [he] | |
| exact hbottom | |
| have hbound:=active_terminal_average hA ha₀ hC₀ hC₁ hrule Q.level E hbot | |
| rw [UnitWave.growth_zero,hU,hK,Fintype.expect_eq_sum_div_card,activeGrowth_sum (by omega) t U K L hQ] at hbound | |
| have hc : (0:ℝ)<Fintype.card (GridWord A Q.level) := by rw [gridWord_card]; positivity | |
| have hm:=(div_le_iff₀ hc).mp hbound | |
| simpa only [gridWord_card,Cell.card_points,Cell.side,gridGrowth] using hm | |
| end SharpNodal.Grid | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| def Cell.parent (A : ℕ) (Q : Cell) : Cell := ⟨Q.level+1,fun j =>Q.pos j/(A:ℤ)⟩ | |
| def cellDigit {A : ℕ} (hA : 0<A) (Q : Cell) : GridIndex A := fun j => | |
| ⟨(Q.pos j%(A:ℤ)).toNat,(Int.toNat_lt' hA).mpr (Int.emod_lt_of_pos _ (by exact_mod_cast hA))⟩ | |
| lemma childPos_parent {A : ℕ} (hA : 0<A) (Q : Cell) : | |
| childPos A (Q.parent A).pos (cellDigit hA Q)=Q.pos := by | |
| funext j | |
| have hAz : (A:ℤ)≠0 := by exact_mod_cast hA.ne' | |
| simp only [childPos,Cell.parent,cellDigit,Int.toNat_of_nonneg (Int.emod_nonneg _ hAz)] | |
| exact Int.ediv_mul_add_emod _ _ | |
| lemma cellMap_parent {A : ℕ} (hA : 0<A) (t : ℝ) (Q : Cell) : | |
| cellMap A t Q=cellMap A t (Q.parent A) ∘ rescaleMap (gridCenter A (cellDigit hA Q)) (A:ℝ)⁻¹ := by | |
| have hh:=cellMap_child hA t Q.level (Q.parent A).pos (cellDigit hA Q) | |
| rw [childPos_parent hA] at hh | |
| exact hh | |
| lemma cellScale_parent {A : ℕ} (hA : 0<A) (t : ℝ) (Q : Cell) : | |
| cellScale A t Q=cellScale A t (Q.parent A)/(A:ℝ) := | |
| cellScale_succ hA t Q.level (Q.parent A).pos Q.pos | |
| lemma Cell.subset_parent {A : ℕ} (hA : 0<A) (Q : Cell) : Q.points A⊆(Q.parent A).points A := by | |
| intro x hx | |
| apply (mem_square_div ((Q.parent A).side_pos hA)).mpr | |
| intro j | |
| have hh:=Q.div_of_mem hA hx (show Q.level≤Q.level+1 by omega) j | |
| simpa only [Cell.side,Cell.parent,Nat.cast_pow,Nat.add_sub_cancel_left,pow_one] using hh | |
| lemma Cell.parent_mem_fullTree {A : ℕ} (hA : 0<A) {root Q : Cell} | |
| (hQ : Q∈fullTree A root) (hn : Q.level<root.level) : Q.parent A∈fullTree A root := by | |
| obtain ⟨x,hx⟩:=Finset.card_pos.mp (by rw [Cell.card_points]; exact pow_pos (Q.side_pos hA) 2) | |
| exact (mem_fullTree hA).mpr ⟨by change Q.level+1≤root.level; omega, | |
| Cell.subset_of_intersection hA (by change Q.level+1≤root.level; omega) | |
| (Q.subset_parent hA hx) (((mem_fullTree hA).mp hQ).2 hx)⟩ | |
| lemma Cell.smallerAt_card_le {A : ℕ} (hA : 0<A) (F : Finset Cell) (Q : Cell) (x : Point) : | |
| (Q.smallerAt A F x).card≤Q.level := by | |
| have hm : MapsTo Cell.level (Q.smallerAt A F x : Set Cell) (Finset.range Q.level) := by | |
| intro R hR | |
| exact Finset.mem_range.mpr (Finset.mem_filter.mp hR).2.1 | |
| have hi : InjOn Cell.level (Q.smallerAt A F x : Set Cell) := by | |
| intro R hR S hS he | |
| exact Cell.equal_level_eq_of_intersection hA he (Finset.mem_filter.mp hR).2.2 (Finset.mem_filter.mp hS).2.2 | |
| simpa only [Finset.card_range] using Finset.card_le_card_of_injOn Cell.level hm hi | |
| theorem aligned_waves {A : ℕ} {Cp a₀ C₀ C₁ L : ℝ} (hA : 2≤A) | |
| (ha₀ : 0<a₀) (hL : 0≤L) (hrule : DescentRule A Cp a₀ C₀ C₁ L) | |
| (t : ℝ) (U : Plane → ℝ) (K : ℝ) (root : Cell) | |
| (D : ScaledWave Cp a₀) (hDU : D.U=U ∘ cellMap A t root) | |
| (hDK : D.K=K*cellScale A t root) (hbottom : a₀≤K*t) : | |
| ∀Q∈fullTree A root,∃E : ScaledWave Cp a₀, | |
| E.U=U ∘ cellMap A t Q ∧ E.K=K*cellScale A t Q := by | |
| have hApos : 0<A := by omega | |
| have hAr : (1:ℝ)≤A := by exact_mod_cast (show 1≤A by omega) | |
| have hall : ∀d : ℕ,∀Q∈fullTree A root,root.level-Q.level=d → | |
| ∃E : ScaledWave Cp a₀,E.U=U ∘ cellMap A t Q ∧ E.K=K*cellScale A t Q := by | |
| intro d | |
| induction d using Nat.strong_induction_on with | |
| | h d ih => | |
| intro Q hQ hd | |
| by_cases he : Q.level=root.level | |
| · obtain ⟨x,hx⟩:=Finset.card_pos.mp (by rw [Cell.card_points]; exact pow_pos (Q.side_pos hApos) 2) | |
| have hEq:=Cell.equal_level_eq_of_intersection hApos he hx (((mem_fullTree hApos).mp hQ).2 hx) | |
| subst Q | |
| exact ⟨D,hDU,hDK⟩ | |
| · have hlt : Q.level<root.level := by have := ((mem_fullTree hApos).mp hQ).1; omega | |
| have hP:=(Cell.parent_mem_fullTree hApos hQ hlt) | |
| obtain ⟨E,hEU,hEK⟩:=ih (root.level-(Q.parent A).level) (by dsimp only [Cell.parent]; omega) | |
| (Q.parent A) hP rfl | |
| have hnext : a₀≤E.K/(A:ℝ) := by | |
| rw [hEK,mul_div_assoc,←cellScale_parent hApos t Q,cellScale,←mul_assoc] | |
| exact hbottom.trans (le_mul_of_one_le_right (ha₀.le.trans hbottom) (one_le_pow₀ hAr)) | |
| let b : Plane := (L+1) • EuclideanSpace.single 0 1 | |
| have hb : L<‖b‖ := by simp [b,norm_smul,abs_of_pos (by linarith : 0<L+1)] | |
| obtain ⟨Es,b',hc,-,-⟩:=hrule E b hnext (Or.inr hb) | |
| refine ⟨Es (cellDigit hApos Q),?_,?_⟩ | |
| · rw [(hc _).2.1,hEU,cellMap_parent hApos t Q] | |
| rfl | |
| · rw [(hc _).2.2.1,hEK,cellScale_parent hApos t Q] | |
| ring | |
| intro Q hQ | |
| exact hall (root.level-Q.level) Q hQ rfl | |
| end SharpNodal.Grid | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| def offsetPos (A m : ℕ) (p q : Point) : Point := fun j =>p j*(A:ℤ)^m+q j | |
| lemma cellScale_offset {A : ℕ} (hA : 0<A) (t : ℝ) (n m : ℕ) (p q : Point) : | |
| cellScale A t ⟨n,offsetPos A m p q⟩=cellScale A t ⟨n+m,p⟩*((A:ℝ)⁻¹)^m := by | |
| have hAr : (A:ℝ)≠0 := by exact_mod_cast hA.ne' | |
| simp only [cellScale,pow_add,inv_pow] | |
| field_simp | |
| lemma cellMap_offset {A : ℕ} (hA : 0<A) (t : ℝ) (n m : ℕ) (p q : Point) : | |
| cellMap A t ⟨n,offsetPos A m p q⟩=cellMap A t ⟨n+m,p⟩ ∘ | |
| rescaleMap (extendedGridCenter (((A:ℝ)⁻¹)^m) q) (((A:ℝ)⁻¹)^m) := by | |
| have hAr : (A:ℝ)≠0 := by exact_mod_cast hA.ne' | |
| funext x | |
| ext j | |
| simp only [cellMap,cellScale,offsetPos,rescaleMap,extendedGridCenter, | |
| Function.comp_apply,PiLp.add_apply,PiLp.smul_apply,smul_eq_mul, | |
| Int.cast_add,Int.cast_mul,Int.cast_pow,Int.cast_natCast,pow_add,inv_pow] | |
| field_simp | |
| ring | |
| lemma offset_points_near {A : ℕ} (hA : 1≤A) (n m : ℕ) (p q : Point) | |
| (hy : ‖extendedGridCenter (((A:ℝ)⁻¹)^m) q‖+2000*((A:ℝ)⁻¹)^m<3) : | |
| (Cell.mk n (offsetPos A m p q)).points A⊆(Cell.mk (n+m) p).near A 4 := by | |
| have hAr : (1:ℝ)≤A := by exact_mod_cast hA | |
| have hArpos : (0:ℝ)<A := by linarith | |
| have hB : (1:ℝ)≤(A:ℝ)^m := one_le_pow₀ hAr | |
| have hBpos : (0:ℝ)<(A:ℝ)^m := by positivity | |
| have hrpos : (0:ℝ)<((A:ℝ)⁻¹)^m := by positivity | |
| have hq (j : Fin 2) : -4*(A:ℤ)^m≤q j ∧ q j+1≤5*(A:ℤ)^m := by | |
| have hc0 : |extendedGridCenter (((A:ℝ)⁻¹)^m) q j|≤‖extendedGridCenter (((A:ℝ)⁻¹)^m) q‖ := | |
| plane_component_norm_le _ j | |
| have hc : |extendedGridCenter (((A:ℝ)⁻¹)^m) q j|<3 := hc0.trans_lt (by linarith) | |
| have hl:=mul_lt_mul_of_pos_right (abs_lt.mp hc).1 hBpos | |
| have hu:=mul_lt_mul_of_pos_right (abs_lt.mp hc).2 hBpos | |
| have he : extendedGridCenter (((A:ℝ)⁻¹)^m) q j*(A:ℝ)^m= | |
| -(A:ℝ)^m/2+(q j:ℝ)+1/2 := by | |
| simp only [extendedGridCenter,inv_pow] | |
| field_simp | |
| ring | |
| rw [he] at hl hu | |
| have hh : -4*(A:ℝ)^m≤(q j:ℝ) ∧ (q j:ℝ)+1≤5*(A:ℝ)^m := by constructor <;> linarith | |
| exact_mod_cast hh | |
| intro x hx | |
| apply mem_neighborhood.mpr | |
| intro j | |
| have hx':=mem_square.mp hx j | |
| have hlow:=mul_le_mul_of_nonneg_right (hq j).1 (show (0:ℤ)≤(A:ℤ)^n by positivity) | |
| have hhigh:=mul_le_mul_of_nonneg_right (hq j).2 (show (0:ℤ)≤(A:ℤ)^n by positivity) | |
| dsimp only [Cell.side,offsetPos] at hx' ⊢ | |
| push_cast at hx' ⊢ | |
| rw [pow_add] | |
| constructor <;> nlinarith | |
| lemma parent_near_in_child {A : ℕ} (hA : 0<A) (n : ℕ) (p : Point) (i : GridIndex A) : | |
| (Cell.mk (n+1) p).near A 4⊆(Cell.mk n (childPos A p i)).near A (5*A) := by | |
| intro x hx | |
| apply mem_neighborhood.mpr | |
| intro j | |
| have hx':=mem_neighborhood.mp hx j | |
| have hi0 : (0:ℤ)≤(i j:ℕ) := Int.natCast_nonneg _ | |
| have hiA : ((i j:ℕ):ℤ)<A := by exact_mod_cast (i j).isLt | |
| have hAn : (0:ℤ)<(A:ℤ)^n := pow_pos (by exact_mod_cast hA) n | |
| dsimp only [Cell.side,childPos] at hx' ⊢ | |
| push_cast at hx' ⊢ | |
| rw [pow_succ] at hx' | |
| constructor <;> nlinarith | |
| lemma Cell.parent_near {A : ℕ} (hA : 0<A) (Q : Cell) : | |
| (Q.parent A).near A 4⊆Q.near A (5*A) := by | |
| have hh:=parent_near_in_child hA Q.level (Q.parent A).pos (cellDigit hA Q) | |
| rw [childPos_parent hA] at hh | |
| exact hh | |
| lemma side_card_comparison {A : ℕ} (hA : 1≤A) {Q P S : Cell} {m M : ℕ} | |
| (hQP : Q.level+1=P.level) (hPS : S.level+m=P.level) (hm : m≤M) : | |
| (Q.points A).card≤A^(2*M)*(S.points A).card := by | |
| simp only [Cell.card_points,Cell.side,←pow_mul,←pow_add] | |
| apply Nat.pow_le_pow_right hA | |
| omega | |
| lemma fieldGrowth_rescale (U : Plane → ℝ) (K : ℝ) (y : Plane) {r : ℝ} (hr : 0<r) : | |
| fieldGrowth (U ∘ rescaleMap y r) (K*r)= | |
| massExcess (centeredMass 0 U y (1000*r)) (centeredMass 0 U y r)/(K*r) := by | |
| have hh:=centered_excess_rescale (0:Plane) U y 0 hr 1000 1 | |
| simpa only [smul_zero,rescaleMap,smul_zero,add_zero,mul_one,mul_comm,fieldGrowth] using congrArg (fun v : ℝ =>v/(K*r)) hh | |
| lemma gridGrowth_child {A : ℕ} (hA : 0<A) (t : ℝ) (U : Plane → ℝ) (K : ℝ) (Q : Cell) : | |
| gridGrowth A t U K Q= | |
| massExcess (centeredMass 0 (U ∘ cellMap A t (Q.parent A)) (gridCenter A (cellDigit hA Q)) (1000*(A:ℝ)⁻¹)) | |
| (centeredMass 0 (U ∘ cellMap A t (Q.parent A)) (gridCenter A (cellDigit hA Q)) (A:ℝ)⁻¹)/ | |
| ((K*cellScale A t (Q.parent A))*(A:ℝ)⁻¹) := by | |
| have hAr : (0:ℝ)<A := by exact_mod_cast hA | |
| rw [gridGrowth,cellMap_parent hA t Q,cellScale_parent hA t Q] | |
| have he : U ∘ (cellMap A t (Q.parent A) ∘ rescaleMap (gridCenter A (cellDigit hA Q)) (A:ℝ)⁻¹)= | |
| (U ∘ cellMap A t (Q.parent A)) ∘ rescaleMap (gridCenter A (cellDigit hA Q)) (A:ℝ)⁻¹ := rfl | |
| rw [he,show K*(cellScale A t (Q.parent A)/(A:ℝ))=(K*cellScale A t (Q.parent A))*(A:ℝ)⁻¹ by ring] | |
| exact fieldGrowth_rescale _ _ _ (by positivity) | |
| end SharpNodal.Grid | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| def goodWordPoints (A n : ℕ) (p : Point) (P : GridWord A n → Prop) : Finset Point := | |
| (Finset.univ.filter P).image (wordPoint A n p) | |
| lemma goodWordPoints_subset (A n : ℕ) (p : Point) (P : GridWord A n → Prop) : | |
| goodWordPoints A n p P⊆(Cell.mk n p).points A := by | |
| intro x hx | |
| obtain ⟨w,-,rfl⟩:=Finset.mem_image.mp hx | |
| exact wordPoint_mem A n p w | |
| lemma goodWordPoints_card {A : ℕ} (hA : 0<A) (n : ℕ) (p : Point) (P : GridWord A n → Prop) | |
| (hp : (3:ℝ)/4≤𝔼 w : GridWord A n,if P w then (1:ℝ) else 0) : | |
| ((Cell.mk n p).points A).card ≤ 2*(goodWordPoints A n p P).card := by | |
| have hc : (0:ℝ)<Fintype.card (GridWord A n) := by | |
| rw [gridWord_card] | |
| exact_mod_cast pow_pos (pow_pos hA n) 2 | |
| have hs : (∑w : GridWord A n,if P w then (1:ℝ) else 0)=((Finset.univ.filter P).card:ℝ) := by | |
| rw [←Finset.sum_filter] | |
| simp only [Finset.sum_const,nsmul_eq_mul,mul_one] | |
| rw [Fintype.expect_eq_sum_div_card,hs] at hp | |
| have hh:=(le_div_iff₀ hc).mp hp | |
| have hh' : (Fintype.card (GridWord A n):ℝ)≤2*((Finset.univ.filter P).card:ℝ) := by linarith | |
| have hhN : Fintype.card (GridWord A n)≤2*(Finset.univ.filter P).card := by exact_mod_cast hh' | |
| simpa only [goodWordPoints,Finset.card_image_iff.mpr (wordPoint_injective A n p).injOn, | |
| Cell.card_points,Cell.side,gridWord_card] using hhN | |
| theorem entry_witness {A M : ℕ} {Cp a₀ L H : ℝ} (hA : 2≤A) | |
| (hpersist : ∀(D : UnitWave Cp a₀) (i : GridIndex A) (depth : ℕ), | |
| a₀≤D.K/(A:ℝ)^depth → D.growth 0≤H → | |
| H < massExcess (centeredMass 0 D.U (gridCenter A i) (1000*(A:ℝ)⁻¹)) | |
| (centeredMass 0 D.U (gridCenter A i) (A:ℝ)⁻¹)/(D.K*(A:ℝ)⁻¹) → | |
| depth≤M ∨ PersistentSquare A L D depth M) | |
| (t : ℝ) (U : Plane → ℝ) (K : ℝ) (root : Cell) (hbottom : a₀≤K*t) | |
| (hroot : gridGrowth A t U K root≤H) | |
| (hW : ∀Q∈fullTree A root,∃E : ScaledWave Cp a₀, | |
| E.U=U ∘ cellMap A t Q ∧ E.K=K*cellScale A t Q) | |
| (Q : Cell) (hQ : Q∈entries A (fullTree A root) (gridGrowth A t U K) L H) : | |
| ∃Y : Finset Point,Y⊆Q.near A (5*A) ∧ (Q.points A).card≤(2*A^(2*M))*Y.card ∧ | |
| ∀x∈Y,(Q.smallerAt A (entries A (fullTree A root) (gridGrowth A t U K) L H) x).card≤M+1 := by | |
| have hAp : 0<A := by omega | |
| have hAr : (0:ℝ)<A := by exact_mod_cast hAp | |
| have hQF:=entries_subset A (fullTree A root) (gridGrowth A t U K) L H hQ | |
| have hQhigh:=entry_high hQ | |
| have hlt : Q.level<root.level := by | |
| have hle:=((mem_fullTree hAp).mp hQF).1 | |
| by_contra hbad | |
| have he : Q.level=root.level := by omega | |
| obtain ⟨x,hx⟩:=Finset.card_pos.mp (by rw [Cell.card_points]; exact pow_pos (Q.side_pos hAp) 2) | |
| have hEq:=Cell.equal_level_eq_of_intersection hAp he hx (((mem_fullTree hAp).mp hQF).2 hx) | |
| rw [hEq] at hQhigh | |
| linarith | |
| let P:=Q.parent A | |
| have hPF : P∈fullTree A root := Cell.parent_mem_fullTree hAp hQF hlt | |
| have hPlow : gridGrowth A t U K P≤H := entry_parent_low hQ hPF rfl (Q.subset_parent hAp) | |
| obtain ⟨D,hDU,hDK⟩:=hW P hPF | |
| have hbot : a₀≤D.K/(A:ℝ)^P.level := by | |
| rw [hDK,cellScale] | |
| have he : K*(t*(A:ℝ)^P.level)/(A:ℝ)^P.level=K*t := by field_simp | |
| rwa [he] | |
| have hDlow : D.growth 0≤H := by simpa only [UnitWave.growth_zero,hDU,hDK,gridGrowth] using hPlow | |
| have hDhigh : H < massExcess (centeredMass 0 D.U (gridCenter A (cellDigit hAp Q)) (1000*(A:ℝ)⁻¹)) | |
| (centeredMass 0 D.U (gridCenter A (cellDigit hAp Q)) (A:ℝ)⁻¹)/(D.K*(A:ℝ)⁻¹) := by | |
| rw [hDU,hDK,←gridGrowth_child hAp t U K Q] | |
| exact hQhigh | |
| rcases hpersist D.toUnitWave (cellDigit hAp Q) P.level hbot hDlow hDhigh with hshallow|hp | |
| · refine ⟨Q.points A,square_subset_neighborhood _ _ _,?_,?_⟩ | |
| · have hpow : 1≤A^(2*M) := one_le_pow₀ (by omega) | |
| nlinarith | |
| · intro x _ | |
| exact (Q.smallerAt_card_le hAp _ x).trans (by dsimp only [P,Cell.parent] at hshallow; omega) | |
| · rcases hp with ⟨m,_hm2,hmM,hmd,p,hy,_hr,E,hEU,hEK,_hs,hprob⟩ | |
| let n:=P.level-m | |
| let S : Cell:=⟨n,offsetPos A m P.pos p⟩ | |
| have hP : (Cell.mk (n+m) P.pos)=P := Cell.ext (Nat.sub_add_cancel hmd) rfl | |
| have hmap : cellMap A t S=cellMap A t P ∘ | |
| rescaleMap (extendedGridCenter (((A:ℝ)⁻¹)^m) p) (((A:ℝ)⁻¹)^m) := by | |
| have hh:=cellMap_offset hAp t n m P.pos p | |
| rwa [hP] at hh | |
| have hscale : cellScale A t S=cellScale A t P*((A:ℝ)⁻¹)^m := by | |
| have hh:=cellScale_offset hAp t n m P.pos p | |
| rwa [hP] at hh | |
| have hEUg : E.U=U ∘ cellMap A t S := by rw [hEU,hDU,hmap]; rfl | |
| have hEKg : E.K=K*cellScale A t S := by rw [hEK,hDK,hscale]; ring | |
| let Y:=goodWordPoints A n S.pos (HighWavePath A L n E) | |
| have hY : Y⊆S.points A := goodWordPoints_subset A n S.pos (HighWavePath A L n E) | |
| have hSc : (S.points A).card≤2*Y.card := goodWordPoints_card hAp n S.pos _ hprob | |
| have hcomp:=side_card_comparison (by omega : 1≤A) (Q:=Q) (P:=P) (S:=S) rfl | |
| (show S.level+m=P.level from Nat.sub_add_cancel hmd) hmM | |
| refine ⟨Y,?_,?_,?_⟩ | |
| · have hh:=offset_points_near (by omega : 1≤A) n m P.pos p hy | |
| rw [hP] at hh | |
| exact hY.trans (hh.trans (Q.parent_near hAp)) | |
| · calc | |
| (Q.points A).card≤A^(2*M)*(S.points A).card := hcomp | |
| _≤A^(2*M)*(2*Y.card) := Nat.mul_le_mul_left _ hSc | |
| _=(2*A^(2*M))*Y.card := by ring | |
| · intro x hx | |
| obtain ⟨w,hw,rfl⟩:=Finset.mem_image.mp hx | |
| have hgood:=HighWavePath.raw (Finset.mem_filter.mp hw).2 | |
| rw [hEUg,hEKg,pathHigh_grid hAp] at hgood | |
| have hh:=smaller_entries_high_suffix hAp (fullTree A root) (gridGrowth A t U K) L H Q n | |
| (wordPoint A n S.pos w) (fun R _ =>hgood R) | |
| exact hh.trans (by dsimp only [n,P,Cell.parent] at hmd ⊢; omega) | |
| end SharpNodal.Grid | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| lemma gridChild_growth {A : ℕ} (hA : 0<A) (t : ℝ) (U : Plane → ℝ) (K : ℝ) (Q : Cell) | |
| {Cp a₀ : ℝ} (D E : ScaledWave Cp a₀) | |
| (hDU : D.U=U ∘ cellMap A t (Q.parent A)) (hDK : D.K=K*cellScale A t (Q.parent A)) | |
| (hc : GridChild A D E (cellDigit hA Q)) : E.growth 0=gridGrowth A t U K Q := by | |
| have hEU : E.U=U ∘ cellMap A t Q := by rw [hc.2.1,hDU,cellMap_parent hA t Q]; rfl | |
| have hEK : E.K=K*cellScale A t Q := by rw [hc.2.2.1,hDK,cellScale_parent hA t Q]; ring | |
| simp only [UnitWave.growth_zero,hEU,hEK,gridGrowth] | |
| def entryBound (A : ℕ) (C₀ C₁ L a₀ H : ℝ) : ℝ := | |
| (A:ℝ)^2*((1/2+1001*C₁)*(H+1001*(L+1)+C₀/a₀+1)+1001*(L+1)) | |
| lemma entryBound_nonneg (A : ℕ) {C₀ C₁ L a₀ H : ℝ} | |
| (hC₀ : 0≤C₀) (hC₁ : 0≤C₁) (hL : 0≤L) (ha₀ : 0<a₀) (hH : 0≤H) : | |
| 0≤entryBound A C₀ C₁ L a₀ H := by dsimp [entryBound]; positivity | |
| lemma entry_growth_grid {A : ℕ} {Cp a₀ C₀ C₁ L H : ℝ} (hA : 2≤A) | |
| (ha₀ : 0<a₀) (hC₀ : 0≤C₀) (hC₁ : 0≤C₁) (hL : 0≤L) | |
| (hrule : DescentRule A Cp a₀ C₀ C₁ L) (t : ℝ) (U : Plane → ℝ) (K : ℝ) (Q : Cell) | |
| (D : ScaledWave Cp a₀) (hDU : D.U=U ∘ cellMap A t (Q.parent A)) | |
| (hDK : D.K=K*cellScale A t (Q.parent A)) | |
| (hparent : gridGrowth A t U K (Q.parent A)≤H) (hbottom : a₀≤K*t) : | |
| gridGrowth A t U K Q≤entryBound A C₀ C₁ L a₀ H := by | |
| have hAp : 0<A := by omega | |
| have hAr : (1:ℝ)≤A := by exact_mod_cast (show 1≤A by omega) | |
| have hnext : a₀≤D.K/(A:ℝ) := by | |
| rw [hDK,mul_div_assoc,←cellScale_parent hAp t Q,cellScale,←mul_assoc] | |
| exact hbottom.trans (le_mul_of_one_le_right (ha₀.le.trans hbottom) (one_le_pow₀ hAr)) | |
| let b : Plane:=(L+1) • EuclideanSpace.single 0 1 | |
| have hb : L<‖b‖ := by simp [b,norm_smul,abs_of_pos (by linarith : 0<L+1)] | |
| obtain ⟨Es,b',hc,-,-⟩:=hrule D b hnext (Or.inr hb) | |
| have hlow : D.growth 0≤H := by simpa only [UnitWave.growth_zero,hDU,hDK,gridGrowth] using hparent | |
| have hh:=entry_growth_bound hA ha₀ hC₀ hC₁ hL hrule D hlow hnext (cellDigit hAp Q) (Es (cellDigit hAp Q)) (hc _) | |
| rw [gridChild_growth hAp t U K Q D (Es (cellDigit hAp Q)) hDU hDK (hc _)] at hh | |
| exact hh | |
| lemma entry_level_lt {A : ℕ} (hA : 0<A) {root Q : Cell} {N : Cell → ℝ} {L H : ℝ} | |
| (hroot : N root≤H) (hQ : Q∈entries A (fullTree A root) N L H) : Q.level<root.level := by | |
| have hQF:=entries_subset A (fullTree A root) N L H hQ | |
| have hle:=((mem_fullTree hA).mp hQF).1 | |
| by_contra hbad | |
| have he : Q.level=root.level := by omega | |
| obtain ⟨x,hx⟩:=Finset.card_pos.mp (by rw [Cell.card_points]; exact pow_pos (Q.side_pos hA) 2) | |
| have hEq:=Cell.equal_level_eq_of_intersection hA he hx (((mem_fullTree hA).mp hQF).2 hx) | |
| have hh:=entry_high hQ | |
| rw [hEq] at hh | |
| linarith | |
| theorem terminal_mean_grid {A M : ℕ} {Cp a₀ C₀ C₁ L H : ℝ} (hA : 2≤A) | |
| (ha₀ : 0<a₀) (hC₀ : 0≤C₀) (hC₁ : 0≤C₁) (hL : 0≤L) (hLH : L≤H) | |
| (hrule : DescentRule A Cp a₀ C₀ C₁ L) | |
| (hpersist : ∀(D : UnitWave Cp a₀) (i : GridIndex A) (depth : ℕ), | |
| a₀≤D.K/(A:ℝ)^depth → D.growth 0≤H → | |
| H < massExcess (centeredMass 0 D.U (gridCenter A i) (1000*(A:ℝ)⁻¹)) | |
| (centeredMass 0 D.U (gridCenter A i) (A:ℝ)⁻¹)/(D.K*(A:ℝ)⁻¹) → | |
| depth≤M ∨ PersistentSquare A L D depth M) | |
| (t : ℝ) (U : Plane → ℝ) (K : ℝ) (root : Cell) (hbottom : a₀≤K*t) | |
| (hroot : gridGrowth A t U K root≤H) | |
| (hW : ∀Q∈fullTree A root,∃E : ScaledWave Cp a₀, | |
| E.U=U ∘ cellMap A t Q ∧ E.K=K*cellScale A t Q) : | |
| (∑x∈root.points A,gridGrowth A t U K (atLevel A 0 x))≤ | |
| (H+excursionCostConstant C₀ C₁ a₀*(entryBound A C₀ C₁ L a₀ H+1)* | |
| packingConstant (5*A) (2*A^(2*M)) (M+1))*(root.points A).card := by | |
| have hAp : 0<A := by omega | |
| have hH : 0≤H := hL.trans hLH | |
| let C:=excursionCostConstant C₀ C₁ a₀*(entryBound A C₀ C₁ L a₀ H+1) | |
| have hcost:=excursionCostConstant_nonneg hC₀ hC₁ ha₀ | |
| have hB:=entryBound_nonneg A hC₀ hC₁ hL ha₀ hH | |
| have hC : 0≤C := mul_nonneg hcost (by linarith) | |
| have hN : ∀x∈root.points A,0≤gridGrowth A t U K (atLevel A 0 x) := by | |
| intro x hx | |
| obtain ⟨E,hEU,hEK⟩:=hW (atLevel A 0 x) (atLevel_mem_fullTree hAp hx (Nat.zero_le _)) | |
| have hh:=E.toUnitWave.growth_nonneg ha₀ 0 | |
| simpa only [UnitWave.growth_zero,hEU,hEK,gridGrowth] using hh | |
| have hlocal : ∀Q∈entries A (fullTree A root) (gridGrowth A t U K) L H, | |
| (∑x∈activeSet A (fullTree A root) (gridGrowth A t U K) L Q, | |
| gridGrowth A t U K (atLevel A 0 x))≤C*(Q.points A).card := by | |
| intro Q hQ | |
| have hQF:=entries_subset A (fullTree A root) (gridGrowth A t U K) L H hQ | |
| obtain ⟨E,hEU,hEK⟩:=hW Q hQF | |
| have hPF:=Cell.parent_mem_fullTree hAp hQF (entry_level_lt hAp hroot hQ) | |
| obtain ⟨D,hDU,hDK⟩:=hW (Q.parent A) hPF | |
| have hPlow:=entry_parent_low hQ hPF rfl (Q.subset_parent hAp) | |
| have hentry:=entry_growth_grid hA ha₀ hC₀ hC₁ hL hrule t U K Q D hDU hDK hPlow hbottom | |
| have hs:=active_grid_sum hA ha₀ hC₀ hC₁ hrule t U K hQF E hEU hEK hbottom | |
| exact hs.trans (mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left | |
| (add_le_add hentry le_rfl) hcost) (Nat.cast_nonneg _)) | |
| have hwit : ∀Q : Cell,∃Y : Finset Point,Q∈entries A (fullTree A root) (gridGrowth A t U K) L H → | |
| Y⊆Q.near A (5*A) ∧ (Q.points A).card≤(2*A^(2*M))*Y.card ∧ | |
| ∀x∈Y,(Q.smallerAt A (entries A (fullTree A root) (gridGrowth A t U K) L H) x).card≤M+1 := by | |
| intro Q | |
| by_cases hQ : Q∈entries A (fullTree A root) (gridGrowth A t U K) L H | |
| · obtain ⟨Y,hY⟩:=entry_witness hA hpersist t U K root hbottom hroot hW Q hQ | |
| exact ⟨Y,fun _ =>hY⟩ | |
| · exact ⟨∅,fun h =>(hQ h).elim⟩ | |
| choose Y hY using hwit | |
| exact terminal_mean_of_witnesses hA root (gridGrowth A t U K) hLH hH hC hN hlocal Y | |
| (fun Q hQ =>(hY Q hQ).1) (fun Q hQ =>(hY Q hQ).2.1) (fun Q hQ =>(hY Q hQ).2.2) | |
| end SharpNodal.Grid | |
| noncomputable section | |
| open scoped BigOperators Classical | |
| open Set | |
| namespace SharpNodal.Grid | |
| open Profiles | |
| lemma cellScale_root {A : ℕ} (hA : 0<A) (n : ℕ) : | |
| cellScale A ((A:ℝ)^n)⁻¹ ⟨n,0⟩=1 := by | |
| have h : (A:ℝ)^n≠0 := pow_ne_zero _ (by exact_mod_cast hA.ne') | |
| exact inv_mul_cancel₀ h | |
| lemma cellMap_root {A : ℕ} (hA : 0<A) (n : ℕ) : | |
| cellMap A ((A:ℝ)^n)⁻¹ ⟨n,0⟩=id := by | |
| funext x | |
| ext j | |
| norm_num [cellMap,cellScale_root hA n,rescaleMap,extendedGridCenter] | |
| theorem uniform_terminal_growth : ∃A : ℕ,10000<A ∧ | |
| ∀Cp : ℝ,0≤Cp → ∀a₀ : ℝ,0<a₀ → ∀Cinit : ℝ, | |
| ∃C : ℝ,0≤C ∧ ∀(D : ScaledWave Cp a₀) (n : ℕ), | |
| D.growth 0≤Cinit → a₀≤D.K/(A:ℝ)^n → | |
| (𝔼 w : GridWord A n,pathGrowth A n D.U D.K w)≤C := by | |
| obtain ⟨A,hA,C₁,hC₁,hdescent⟩:=actual_descent_rule | |
| refine ⟨A,hA,?_⟩ | |
| intro Cp hCp a₀ ha₀ Cinit | |
| obtain ⟨C₀,L,hC₀,hL,hdescent⟩:=hdescent Cp hCp | |
| have hC₀' : 0≤C₀ := by linarith | |
| have hrule:=hdescent a₀ ha₀ | |
| obtain ⟨H,hH,M,hpersist⟩:=uniform_persistence_alternative hCp ha₀ hC₀' hC₁.le hL.le hA hrule (max Cinit L) | |
| have hCH : Cinit≤H := (le_max_left Cinit L).trans ((le_max_right 1 (max Cinit L)).trans hH.le) | |
| have hLH : L≤H := (le_max_right Cinit L).trans ((le_max_right 1 (max Cinit L)).trans hH.le) | |
| have hH0 : 0≤H := hL.le.trans hLH | |
| let C := H+excursionCostConstant C₀ C₁ a₀*(entryBound A C₀ C₁ L a₀ H+1)* | |
| packingConstant (5*A) (2*A^(2*M)) (M+1) | |
| have hcost:=excursionCostConstant_nonneg hC₀' hC₁.le ha₀ | |
| have hB:=entryBound_nonneg A hC₀' hC₁.le hL.le ha₀ hH0 | |
| have hpack : (0:ℝ)≤packingConstant (5*A) (2*A^(2*M)) (M+1) := by positivity | |
| refine ⟨C,by dsimp [C]; positivity,?_⟩ | |
| intro D n hinit hbottom | |
| have hAp : 0<A := by omega | |
| let t : ℝ := ((A:ℝ)^n)⁻¹ | |
| let root : Cell := ⟨n,0⟩ | |
| have hscale : cellScale A t root=1 := cellScale_root hAp n | |
| have hmap : cellMap A t root=id := cellMap_root hAp n | |
| have hDU : D.U=D.U ∘ cellMap A t root := by rw [hmap]; rfl | |
| have hDK : D.K=D.K*cellScale A t root := by rw [hscale,mul_one] | |
| have hbottom' : a₀≤D.K*t := by simpa only [t,div_eq_mul_inv] using hbottom | |
| have hroot : gridGrowth A t D.U D.K root≤H := by | |
| simpa only [gridGrowth,←hDU,←hDK,←UnitWave.growth_zero] using hinit.trans hCH | |
| have hwaves:=aligned_waves (by omega : 2≤A) ha₀ hL.le hrule t D.U D.K root D hDU hDK hbottom' | |
| have hsum:=terminal_mean_grid (by omega : 2≤A) ha₀ hC₀' hC₁.le hL.le hLH hrule hpersist | |
| t D.U D.K root hbottom' hroot hwaves | |
| have hpath (w : GridWord A n) : pathGrowth A n D.U D.K w= | |
| gridGrowth A t D.U D.K (atLevel A 0 (wordPoint A n 0 w)) := by | |
| have hh:=pathGrowth_grid hAp t D.U D.K n 0 w | |
| rw [←hDU,←hDK] at hh | |
| exact hh | |
| rw [Fintype.expect_eq_sum_div_card] | |
| simp_rw [hpath] | |
| rw [sum_wordPoint A n 0 (fun x =>gridGrowth A t D.U D.K (atLevel A 0 x)),gridWord_card] | |
| have hcard : (0:ℝ)<((A^n)^2:ℕ) := by exact_mod_cast pow_pos (pow_pos hAp n) 2 | |
| apply (div_le_iff₀ hcard).mpr | |
| simpa only [C,root,Cell.card_points,Cell.side] using hsum | |
| end SharpNodal.Grid | |
| end | |
| end | |
| end OAI | |
Xet Storage Details
- Size:
- 40.6 kB
- Xet hash:
- af55d80594c041f716f65a1ef617871b0fbcfc6342b0f13a7e93030cc7e7084d
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.