File size: 1,971 Bytes
d4317d7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
import OAI.MeasureTheory.Falconer.Recursion.BranchTransitions

namespace OAI

namespace PlanarFalconer

theorem BranchStep.width_decreases {A : ℕ → ℝ} {N q : ℕ} {sig : ℝ}
    (hN : 0 < N) (hq : 0 < q) (hsig : 0 < sig)
    {s u : BranchState} {label : BranchLabel} (h : BranchStep A N q sig s label u)
    (hs : s.Valid N sig) (hu : u.Valid N sig) :
    u.finish-u.start < s.finish-s.start := by
  have hn := h.nested hq hs
  have hsd := BranchState.valid_depths hs
  have hud := BranchState.valid_depths hu
  have hstrict : s.start < u.start ∨ u.finish < s.finish := by
    cases h with
    | suffix hw _ =>
      have hp := policyDepth_interior A hq (policyBlocks_nonempty hq hs.2 hw)
      exact Or.inr (by dsimp only [BranchState.finish]; omega)
    | low _ _ hg =>
      have hpos : 0 < sig*(N:ℝ) := mul_pos hsig (Nat.cast_pos.mpr hN)
      apply Or.inr
      apply (Nat.cast_lt (α := ℝ)).mp
      dsimp only [BranchState.finish]
      linarith
    | high hw _ _ _ =>
      have hp := policyDepth_interior A hq (policyBlocks_nonempty hq hs.2 hw)
      exact Or.inl (by dsimp only [BranchState.start]; omega)
    | near _ hp => exact Or.inl hp
    | far _ _ hm =>
      have hm := Finset.mem_Icc.mp hm
      exact Or.inl (by dsimp only [BranchState.start]; omega)
    | direct _ he => exact Or.inl he.anchor_gt
  omega

def branchPredecessor (A : ℕ → ℝ) (N q : ℕ) (sig : ℝ) (u s : BranchState) : Prop :=
  s.Valid N sig ∧ u.Valid N sig ∧ ∃ label, BranchStep A N q sig s label u

theorem branchPredecessor_wellFounded (A : ℕ → ℝ) {N q : ℕ} {sig : ℝ}
    (hN : 0 < N) (hq : 0 < q) (hsig : 0 < sig) :
    WellFounded (branchPredecessor A N q sig) := by
  apply Subrelation.wf (r := (measure (fun s : BranchState => s.finish-s.start)).rel) _
    (measure (fun s : BranchState => s.finish-s.start)).wf
  intro u s h
  obtain ⟨hs,hu,label,hstep⟩ := h
  exact hstep.width_decreases hN hq hsig hs hu

end PlanarFalconer

end OAI