File size: 4,085 Bytes
4a56cd6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
import OAI.MeasureTheory.Falconer.Angular.AngularLengthPartition

namespace OAI

namespace PlanarFalconer
open Set Metric

theorem angularLengthShell_cover {x : Fin 4 β†’ Plane} {a h : β„•}
    (hc : x ∈ angularLengthComparable)
    (hupper : max (dist (x 0) (x 1)) (dist (x 2) (x 3)) ≀ 2*(2:ℝ)^(-(a:ℝ)))
    (hfar : 16*(2:ℝ)^(-(h:ℝ)) < max (dist (x 0) (x 1)) (dist (x 2) (x 3))) :
    βˆƒ b ∈ Finset.Icc (a+9) (h+5), x ∈ angularLengthShell b := by
  let d := max (dist (x 0) (x 1)) (dist (x 2) (x 3))
  have hd : 0 < d := (by positivity : 0 < 16*(2:ℝ)^(-(h:ℝ))).trans hfar
  obtain ⟨n,hnlo,hnhi⟩ := exists_displacement_depth hd
  have hpow (k : ℝ) : (2:ℝ)^(k-(n:ℝ)-10) = (2:ℝ)^k*(2:ℝ)^(-((n:ℝ)+10)) := by
    rw [show k-(n:ℝ)-10 = k+(-((n:ℝ)+10)) by ring,Real.rpow_add (by norm_num : (0:ℝ) < 2)]
  have haexp : (2:ℝ)^(-(n:ℝ)-1) < (2:ℝ)^(1-(a:ℝ)) := by
    have he : (2:ℝ)^(1-(a:ℝ)) = 2*(2:ℝ)^(-(a:ℝ)) := by
      rw [sub_eq_add_neg,Real.rpow_add (by norm_num : (0:ℝ) < 2),Real.rpow_one]
    rw [he]
    exact hnlo.trans_le hupper
  have hhexp : (2:ℝ)^(4-(h:ℝ)) < (2:ℝ)^(-(n:ℝ)) := by
    have he : (2:ℝ)^(4-(h:ℝ)) = 16*(2:ℝ)^(-(h:ℝ)) := by
      rw [sub_eq_add_neg,Real.rpow_add (by norm_num : (0:ℝ) < 2)]
      norm_num
    rw [he]
    exact hfar.trans_le hnhi
  have haR := (Real.rpow_lt_rpow_left_iff (by norm_num : (1:ℝ) < 2)).mp haexp
  have hhR := (Real.rpow_lt_rpow_left_iff (by norm_num : (1:ℝ) < 2)).mp hhexp
  have haZ : (a:β„€)-2 < n := by exact_mod_cast (show (a:ℝ)-2 < (n:ℝ) by linarith)
  have hhZ : n < (h:β„€)-4 := by exact_mod_cast (show (n:ℝ) < (h:ℝ)-4 by linarith)
  have hb0 : 0 ≀ n+10 := by omega
  let b := (n+10).toNat
  have hbZ : (b:β„€) = n+10 := Int.toNat_of_nonneg hb0
  have hbR : (b:ℝ) = (n:ℝ)+10 := by exact_mod_cast hbZ
  refine ⟨b,Finset.mem_Icc.mpr ⟨by omega,by omega⟩,hc,?_,?_⟩
  Β· have he : (2:ℝ)^(-(n:ℝ)-1) = 512*(2:ℝ)^(-(b:ℝ)) := by
      rw [hbR,show -(n:ℝ)-1 = 9-(n:ℝ)-10 by ring,hpow]
      norm_num
    rw [← he]
    exact hnlo
  Β· have he : (2:ℝ)^(-(n:ℝ)) = 1024*(2:ℝ)^(-(b:ℝ)) := by
      rw [hbR,show -(n:ℝ) = 10-(n:ℝ)-10 by ring,hpow]
      norm_num
    rw [← he]
    exact hnhi

theorem parent_cell_displacement_bound (Q₁ Qβ‚‚ : DyadicSquare)
    (hQ₁ : Q₁.side = 1) (hQβ‚‚ : Qβ‚‚.side = 1) (a : β„•) (A B : CellPath)
    (hA : A.length = a) (hB : B.length = a) (x : Fin 4 β†’ Plane)
    (hxβ‚€ : x 0 ∈ (Q₁.descendant A).carrier) (hx₁ : x 1 ∈ (Q₁.descendant A).carrier)
    (hxβ‚‚ : x 2 ∈ (Qβ‚‚.descendant B).carrier) (hx₃ : x 3 ∈ (Qβ‚‚.descendant B).carrier) :
    max (dist (x 0) (x 1)) (dist (x 2) (x 3)) ≀ 2*(2:ℝ)^(-(a:ℝ)) := by
  have h1 := (Q₁.descendant A).dist_le
    (Q₁.descendant_side_pos (by rw [hQ₁]; norm_num) A).le hxβ‚€ hx₁
  have h2 := (Qβ‚‚.descendant B).dist_le
    (Qβ‚‚.descendant_side_pos (by rw [hQβ‚‚]; norm_num) B).le hxβ‚‚ hx₃
  rw [Q₁.descendant_side,hA,hQ₁] at h1
  rw [Qβ‚‚.descendant_side,hB,hQβ‚‚] at h2
  simp only [Real.rpow_neg (by norm_num : (0:ℝ) ≀ 2),Real.rpow_natCast,
    one_div] at *
  exact max_le h1 h2

theorem angular_far_max_displacement (Q₁ Qβ‚‚ : DyadicSquare)
    (hQ₁ : Q₁.side = 1) (hQβ‚‚ : Qβ‚‚.side = 1) (h : β„•) (row col : CellPath Γ— CellPath)
    (hr : row ∈ (dyadicPaths h) Γ—Λ’ (dyadicPaths h))
    (hc : col ∈ (dyadicPaths h) Γ—Λ’ (dyadicPaths h))
    (hfar : Β¬ angularNear Q₁ Qβ‚‚ h row col) (x : Fin 4 β†’ Plane)
    (hxβ‚€ : x 0 ∈ (Q₁.descendant row.1).carrier) (hx₁ : x 1 ∈ (Q₁.descendant col.1).carrier)
    (hxβ‚‚ : x 2 ∈ (Qβ‚‚.descendant row.2).carrier) (hx₃ : x 3 ∈ (Qβ‚‚.descendant col.2).carrier) :
    16*(2:ℝ)^(-(h:ℝ)) < max (dist (x 0) (x 1)) (dist (x 2) (x 3)) := by
  have hh := angular_far_displacement Q₁ Qβ‚‚ hQ₁ hQβ‚‚ h row col hr hc hfar
    (x 0) (x 1) (x 2) (x 3) hxβ‚€ hx₁ hxβ‚‚ hx₃
  simpa only [Real.rpow_neg (by norm_num : (0:ℝ) ≀ 2),Real.rpow_natCast,
    ← div_eq_mul_inv,lt_max_iff] using hh

end PlanarFalconer

end OAI