Skip to main content
AlexKontorovich/PrimeNumberTheoremAnd
Source indexedtheorem · leanprover/lean4:v4.32.0

FKS2.corollary_24_row10

PrimeNumberTheoremAnd.IEANTN.FKS2Cor24Row10 · PrimeNumberTheoremAnd/IEANTN/FKS2Cor24Row10.lean:121 to 152

Source documentation

FKS2 Corollary 24, row 10 (table7 entry (x ↦ x^{-1/50}, Icc 1 1358.6)): Eπ x ≤ x^{-1/50} whenever log x ∈ [1, 1358.6]. For x > 0 this splits into the four segments above; for x ≤ 0 (possible since log is even) Eπ x ≤ 0 < x^{-1/50}.

Exact Lean statement

theorem corollary_24_row10 :
    ∀ x, Real.log x ∈ Set.Icc (1:ℝ) 1358.6 → Eπ x ≤ x ^ (-(1:ℝ)/50)

Complete declaration

Lean source

Canonical source
Full Lean sourceLean 4
theorem corollary_24_row10 :     x, Real.log x  Set.Icc (1:) 1358.6  Eπ x  x ^ (-(1:)/50) := by  intro x hlog  obtain hlo, hhi := hlog  rcases lt_trichotomy x 0 with hxneg | hx0 | hxpos  · -- x < 0: `Eπ x ≤ 0 < x^{-1/50}`    have hLpos : (0:) < Real.log x := by linarith    have hEle0 : Eπ x  0 := by      unfold Eπ      apply div_nonpos_of_nonneg_of_nonpos (abs_nonneg _)      exact le_of_lt (div_neg_of_neg_of_pos hxneg hLpos)    have hRpos : (0:) < x ^ (-(1:)/50) := by      rw [Real.rpow_def_of_neg hxneg]      apply mul_pos (Real.exp_pos _)      apply Real.cos_pos_of_mem_Ioo      constructor <;> nlinarith [Real.pi_pos, Real.pi_le_four]    linarith  · -- x = 0: `log 0 = 0` contradicts `1 ≤ log x`    exfalso; rw [hx0, Real.log_zero] at hlo; linarith  · -- x > 0: dispatch to the four segments    have cvt :  a b : , a  Real.log x  Real.log x  b         x  Set.Icc (Real.exp a) (Real.exp b) := by      intro a b ha hb      exact by rw [ Real.exp_log hxpos]; exact Real.exp_le_exp.mpr ha,             by rw [ Real.exp_log hxpos]; exact Real.exp_le_exp.mpr hb    rcases le_total (Real.log x) 4 with h1 | h1    · exact floor_trusted_row10 x (cvt 1 4 hlo h1)    · rcases le_total (Real.log x) 10 with h2 | h2      · exact floor_row10 x (cvt 4 10 h1 h2)      · rcases le_total (Real.log x) 1358 with h3 | h3        · exact mid_row10 x (cvt 10 1358 h2 h3)        · exact sliver_row10 x (cvt 1358 1358.6 h3 hhi)