Development/AbelianVarietyTheory/Definitions/GlobalTwisting/PairRowIffQdRows.lean
151have h1 := Real.log_le_log (Real.rpow_pos_of_pos hx _) h.1152rw [Real.log_rpow hx] at h1153calc Real.log s.x / s.J = 1 / s.J * Real.log s.x := by ring154_ ≤ _ := h1155156theorem PairWin.rpow_inv_le {s : Scale} {Y C : ℝ} (h : PairWin s Y) (hJ : s.J ≤ C) : s.x ^ (1 / C) ≤ Y :=157(Real.rpow_le_rpow_of_exponent_le s.one_lt_alt.le158(one_div_le_one_div_of_le (lt_of_lt_of_le one_pos s.one_le_J) hJ)).trans h.1159160theorem PairWin.z_log_sq_le {s : Scale} {Y : ℝ} (h : PairWin s Y) :161Y ^ (s.eps / 5) * Real.log Y ^ 2 ≤ s.x ^ (s.eps / 5) * Real.log s.x ^ 2 := by162have h0 : 0 ≤ Real.log Y := Real.log_nonneg h.one_lt.le163have h1 := h.rpow_le (a := s.eps / 5) (by linarith [s.eps_pos])164exact mul_le_mul h1 (pow_le_pow_left₀ h0 h.log_le 2) (sq_nonneg _)165(Real.rpow_nonneg (by linarith [s.one_lt_alt]) _)166167theorem four_mul_QS_div {R : Ranks} (H : Host R) : 4 * (H.QS / 4) = H.QS :=168Nat.mul_div_cancel' (Dvd.dvd.trans ⟨2 ^ R.e, by ring⟩ H.tower_dvd)169170theorem pairRow_iff_rowq (Y eps : ℝ) {R : Ranks} (H : Host R) : PairRow Y eps H ↔ Rowq Y eps (H.QS / 4) H.q H.d := by171have e : (4 : ℝ) * ((H.QS / 4 : ℕ) : ℝ) = H.QS := by exact_mod_cast four_mul_QS_div H172unfold PairRow Rowq173rw [e]174175namespace HostVal176177variable {s : Scale} {C8 : ℝ} {R : Ranks} {H : Host R}178179theorem split_tie (h : HostVal s C8 H) : ⌊s.x ^ (s.ez / 5)⌋₊ ≤ H.splitBound := h.2.2.2.2.2.2.2.1180181theorem J_le (h : HostVal s C8 H) : s.J ≤ C8 := h.2.2.2.2.2.2.2.2.1182183theorem o_le (h : HostVal s C8 H) : (R.o : ℝ) ≤ C8 := h.2.2.2.2.2.2.2.2.2.1184185theorem QS_le (h : HostVal s C8 H) : (H.QS : ℝ) ≤ C8 * R.n := h.2.2.2.2.2.2.2.2.2.2186187theorem one_le (h : HostVal s C8 H) : 1 ≤ C8 := s.one_le_J.trans h.J_le188189theorem eps_div_le_ez (h : HostVal s C8 H) : s.eps / C8 ≤ s.ez :=190div_le_div_of_nonneg_left s.eps_pos.le (lt_of_lt_of_le one_pos s.one_le_J) h.J_le191192theorem log_cond_le (h : HostVal s C8 H) :193Real.log ((H.QS : ℝ) * H.q * H.d) ≤ 2 * s.x ^ (s.eps / 5) * Real.log s.x ^ 2 := by194obtain ⟨Y, hY, hr⟩ := h.1195have := hY.z_log_sq_le196linarith [hr.2.2.2.2.2.2.2.2.2.2]197198theorem d_le (h : HostVal s C8 H) : (H.d : ℝ) ≤ GlobalTheoryTheory.X2 s.x s.eps := by199obtain ⟨Y, hY, hr⟩ := h.1200exact hr.2.2.2.2.2.2.2.1.trans (Real.exp_le_exp.2 hY.z_log_sq_le)