pith. machine review for the scientific record. sign in

IndisputableMonolith.Gravity.GalacticTimescale

IndisputableMonolith/Gravity/GalacticTimescale.lean · 106 lines · 7 declarations

show as:
view math explainer →

open module explainer GitHub source

Explainer status: pending

   1import Mathlib
   2import IndisputableMonolith.Constants
   3import IndisputableMonolith.Foundation.PhiForcing
   4-- import IndisputableMonolith.Numerics.Interval.PhiBounds  -- [not in public release]
   5-- import IndisputableMonolith.Numerics.Interval.GalacticBounds  -- [not in public release]
   6
   7namespace IndisputableMonolith
   8namespace Gravity
   9namespace GalacticTimescale
  10
  11open Real
  12open Constants
  13open Numerics
  14
  15noncomputable section
  16
  17/-- The characteristic galactic memory timescale τ★ in seconds. -/
  18def tau_star_s : ℝ := 133e6 * 365.25 * 24 * 3600
  19
  20/-- The fundamental RS tick in seconds (SI calibration). -/
  21def tau0_SI : ℝ := 7.3e-15
  22
  23/-- The φ-ladder rung function: τ_N = τ₀ · φ^N -/
  24def phi_rung_time (N : ℝ) : ℝ := tau0_SI * phi ^ N
  25
  26/-- The log-base-φ of the timescale ratio: N = log_φ(τ★/τ₀) -/
  27def N_galactic : ℝ := Real.log (tau_star_s / tau0_SI) / Real.log phi
  28
  29/-- **THEOREM: N_galactic Approximation** -/
  30theorem N_galactic_approx : 140 < N_galactic ∧ N_galactic < 145 := by
  31  have h_ratio_val : tau_star_s / tau0_SI = (galactic_ratio_rational : ℝ) := by
  32    unfold tau_star_s tau0_SI galactic_ratio_rational
  33    norm_num
  34  have hlog_phi : 0 < Real.log phi := Real.log_pos Constants.one_lt_phi
  35
  36  constructor
  37  · unfold N_galactic
  38    rw [h_ratio_val]
  39    apply (lt_div_iff₀ hlog_phi).mpr
  40    rw [← Real.log_rpow Constants.phi_pos]
  41    apply Real.log_lt_log (Real.rpow_pos_of_pos Constants.phi_pos 140)
  42    exact phi_pow_140_lt_ratio
  43  · unfold N_galactic
  44    rw [h_ratio_val]
  45    apply (div_lt_iff₀ hlog_phi).mpr
  46    rw [← Real.log_rpow Constants.phi_pos]
  47    apply Real.log_lt_log
  48    · have h_pos : (0 : ℝ) < (galactic_ratio_rational : ℝ) := by norm_num [galactic_ratio_rational]
  49      exact h_pos
  50    · exact ratio_lt_phi_pow_145
  51
  52/-- **THEOREM: τ★ Lies on the φ-Ladder** -/
  53theorem tau_star_is_phi_rung :
  54   ∃ N : ℤ, |tau_star_s - phi_rung_time N| < 0.1 * tau_star_s := by
  55  use 142
  56  unfold phi_rung_time
  57  let ratio := tau_star_s / tau0_SI
  58  have h_ratio_val : tau_star_s / tau0_SI = (galactic_ratio_rational : ℝ) := by
  59    unfold tau_star_s tau0_SI galactic_ratio_rational
  60    norm_num
  61
  62  have h_in_142 := phi_pow_142_in_interval
  63
  64  rw [abs_lt]
  65  constructor
  66  · -- tau_star - tau0 * phi^142 > -0.1 * tau_star <=> 0.9 * tau_star < tau0 * phi^142
  67    have h_lo : (0.9 * galactic_ratio_rational : ℝ) < goldenRatio ^ (142 : ℝ) := by
  68      calc (0.9 * galactic_ratio_rational : ℝ) < (phi_pow_142_interval.lo : ℝ) := by
  69             exact_mod_cast ratio_0_9_lt_phi_pow_142
  70        _ ≤ goldenRatio ^ (142 : ℝ) := h_in_142.1
  71    have h_scale : 0.9 * tau_star_s < tau0_SI * goldenRatio ^ (142 : ℝ) := by
  72      unfold tau_star_s tau0_SI at h_ratio_val ⊢
  73      rw [← lt_div_iff₀ (by norm_num : (0 : ℝ) < 7.3e-15)] at h_lo
  74      -- ratio = tau_star / tau0
  75      have h_r : tau_star_s / tau0_SI = (galactic_ratio_rational : ℝ) := by
  76        unfold tau_star_s tau0_SI galactic_ratio_rational; norm_num
  77      rw [← h_r] at h_lo
  78      linarith
  79    linarith
  80  · -- tau_star - tau0 * phi^142 < 0.1 * tau_star <=> tau0 * phi^142 > 0.9 * tau_star (already checked)
  81    -- wait, tau_star - tau0 * phi^142 < 0.1 * tau_star <=> 1.1 * tau_star > tau0 * phi^142
  82    have h_hi : goldenRatio ^ (142 : ℝ) < (1.1 * galactic_ratio_rational : ℝ) := by
  83      calc goldenRatio ^ (142 : ℝ) ≤ (phi_pow_142_interval.hi : ℝ) := h_in_142.2
  84        _ < (1.1 * galactic_ratio_rational : ℝ) := by
  85             exact_mod_cast phi_pow_142_lt_ratio_1_1
  86    have h_scale : tau0_SI * goldenRatio ^ (142 : ℝ) < 1.1 * tau_star_s := by
  87      unfold tau_star_s tau0_SI at h_ratio_val ⊢
  88      rw [← lt_div_iff₀ (by norm_num : (0 : ℝ) < 7.3e-15)] at h_hi
  89      have h_r : tau_star_s / tau0_SI = (galactic_ratio_rational : ℝ) := by
  90        unfold tau_star_s tau0_SI galactic_ratio_rational; norm_num
  91      rw [← h_r] at h_hi
  92      linarith
  93    linarith
  94
  95def galactic_status : List (String × String) :=
  96  [ ("N_galactic approx", "PROVEN")
  97  , ("tau_star is phi rung", "PROVEN")
  98  ]
  99
 100#eval galactic_status
 101
 102end
 103end GalacticTimescale
 104end Gravity
 105end IndisputableMonolith
 106

source mirrored from github.com/jonwashburn/shape-of-logic