File size: 3,656 Bytes
92416a2 | 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 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 | import Mathlib
import OAI.Computability.VertexCover.Analysis.RestrictionSum
namespace OAI
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
section
namespace VertexCover.Restriction
theorem choose_step (d h : ℕ) (hd : 0 < d) (hh : 0 < h) :
(d:ℝ)*((d-1).choose (h-1):ℝ) = (h:ℝ)*(d.choose h:ℝ) := by
have he := Nat.add_one_mul_choose_eq (d-1) (h-1)
rw [Nat.sub_add_cancel hd, Nat.sub_add_cancel hh] at he
exact_mod_cast he.trans (Nat.mul_comm _ _)
theorem batch_pair_scale (d h : ℕ) (hd : 4 ≤ d) (hh : 3 ≤ h) :
(d:ℝ)*((d-2).choose (h-2):ℝ) ≤ 2*(h:ℝ)*((d-1).choose (h-1):ℝ) := by
have he := choose_step (d-1) (h-1) (by omega) (by omega)
have hed : d-1-1 = d-2 := by omega
have heh : h-1-1 = h-2 := by omega
rw [hed, heh, Nat.cast_sub (by omega : 1 ≤ d), Nat.cast_sub (by omega : 1 ≤ h)] at he
norm_num only [Nat.cast_one] at he
have hdR : (4:ℝ) ≤ d := by exact_mod_cast hd
have hC1 : (0:ℝ) ≤ (d-1).choose (h-1) := Nat.cast_nonneg _
have hC2 : (0:ℝ) ≤ (d-2).choose (h-2) := Nat.cast_nonneg _
nlinarith [mul_nonneg (by linarith : (0:ℝ) ≤ d-2) hC2]
theorem batch_triple_scale (d h : ℕ) (hd : 4 ≤ d) (hh : 3 ≤ h) :
(d:ℝ)^2*((d-3).choose (h-3):ℝ) ≤ 4*(h:ℝ)^2*((d-1).choose (h-1):ℝ) := by
have he := choose_step (d-2) (h-2) (by omega) (by omega)
have hed : d-2-1 = d-3 := by omega
have heh : h-2-1 = h-3 := by omega
rw [hed, heh, Nat.cast_sub (by omega : 2 ≤ d), Nat.cast_sub (by omega : 2 ≤ h)] at he
norm_num only [Nat.cast_ofNat] at he
have hdR : (4:ℝ) ≤ d := by exact_mod_cast hd
have hhR : (0:ℝ) ≤ h := Nat.cast_nonneg _
have hC2 : (0:ℝ) ≤ (d-2).choose (h-2) := Nat.cast_nonneg _
have hC3 : (0:ℝ) ≤ (d-3).choose (h-3) := Nat.cast_nonneg _
have hl : (d:ℝ)*((d-3).choose (h-3):ℝ) ≤ 2*(h:ℝ)*((d-2).choose (h-2):ℝ) := by
nlinarith [mul_nonneg (by linarith : (0:ℝ) ≤ d-4) hC3]
have hl' := mul_le_mul_of_nonneg_left hl (Nat.cast_nonneg d : (0:ℝ) ≤ d)
have hp := mul_le_mul_of_nonneg_left (batch_pair_scale d h hd hh) (by positivity : (0:ℝ) ≤ 2*h)
nlinarith
end VertexCover.Restriction
namespace VertexCover.LabelCover
open VertexCover.Restriction
open EnergyForm.Projection
open scoped BigOperators
theorem privateProjection_batch_lower (Φ : LabelCover) {d h : ℕ}
(hd : 4 ≤ d) (hh : 3 ≤ h) (ν : ℝ)
(hscale : 16*(h:ℝ)+32*(h:ℝ)^2 ≤ ν*d/2)
(A : Finset (Φ.Coordinate d → ℝ)) (hA : A.Nonempty)
(henergy : ν*d ≤ (Φ.restrictionForm d).energy (Φ.restrictionFunction A hA)) :
(d.choose h:ℝ)*ν*h/2 ≤
∑ J ∈ batches d h, ∑ j ∈ J,
(Φ.restrictionForm d).energy (Φ.privateProjection J j (Φ.restrictionFunction A hA)) := by
have hb := Φ.privateProjection_batch_bound hh A hA
have hC1 : (0:ℝ) ≤ (d-1).choose (h-1) := Nat.cast_nonneg _
have hl := mul_le_mul_of_nonneg_left henergy hC1
have hs := mul_le_mul_of_nonneg_left hscale hC1
have hp := batch_pair_scale d h hd hh
have ht := batch_triple_scale d h hd hh
have he := choose_step d h (by omega) (by omega)
have he' : ((d-1).choose (h-1):ℝ)*ν*d = (d.choose h:ℝ)*ν*h := by
calc
_ = ν*((d:ℝ)*((d-1).choose (h-1):ℝ)) := by ring
_ = _ := by rw [he]; ring
nlinarith
end VertexCover.LabelCover
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end
end OAI
|