import PoincareLib.Geometry.RicciFlow.Surgery.Control.Basic /-! # Coverage by the prescribed surgery epochs Definition 15.7 assigns entry zero to [0,1/32) and the later entries to successive dyadic intervals. Their half-open convention includes every nonnegative time, including the dyadic endpoints. -/ set_option autoImplicit false namespace PoincareMT theorem exists_surgeryEpochEntry {t : ℝ} (ht : 0 ≤ t) : ∃ j : ℕ, t ∈ surgeryEpochEntry j := by by_cases hsmall : t < 1 / 32 · exact ⟨0, by simpa [surgeryEpochEntry, surgeryEpochStart] using And.intro ht hsmall⟩ · have hlarge : 1 ≤ 32 * t := by linarith obtain ⟨j, hlo, hhi⟩ := exists_nat_pow_near hlarge (by norm_num : (1 : ℝ) < 2) refine ⟨j + 1, ?_⟩ simp only [surgeryEpochEntry, Nat.add_one_ne_zero, if_false, Nat.add_sub_cancel, surgeryEpochStart, Set.mem_Ico] constructor <;> linarith end PoincareMT