Lean / Reader
Lean reader

DeskStatementAudit.lean

56 lines7 declarationsno sorryimports Solution Mathlib.Data.Finset.Max

Lean 4 Web has Mathlib, so it can check files that import only Mathlib. This one also imports Solution, which it does not have: you can read it there, but it will not check. Build the project itself to check it.

  1. import Solution
  2. import Mathlib.Data.Finset.Max
  3. open scoped BigOperators
  4. open Finset
  5. noncomputable section
  6. namespace DeskAudit
  7. def powerMagnitude (n : ℕ) (z : ℕ → ℂ) (k : ℕ) : ℝ :=
  8. ‖∑ i ∈ Icc 1 n, z i ^ k‖
  9. def magnitudes (n : ℕ) (z : ℕ → ℂ) : Finset ℝ :=
  10. (Icc 2 (n + 1)).image (powerMagnitude n z)
  11. theorem magnitudes_nonempty {n : ℕ} (hn : 2 ≤ n) (z : ℕ → ℂ) :
  12. (magnitudes n z).Nonempty :=
  13. ⟨powerMagnitude n z 2, mem_image_of_mem _ (mem_Icc.mpr ⟨le_rfl, by omega⟩)⟩
  14. def publishedQuestion : Prop :=
  15. ∃ C : ℝ, C > 1 ∧
  16. ∀ (n : ℕ) (hn : 2 ≤ n), ∃ z : ℕ → ℂ,
  17. z 1 = 1 ∧ (∀ i ∈ Icc 1 n, 1 ≤ ‖z i‖) ∧
  18. (magnitudes n z).max' (magnitudes_nonempty hn z) < C ^ (-(n : ℝ))
  19. theorem pointwise_iff_max {n : ℕ} (hn : 2 ≤ n) (z : ℕ → ℂ) (bound : ℝ) :
  20. (∀ k ∈ Icc 2 (n + 1), powerMagnitude n z k < bound) ↔
  21. (magnitudes n z).max' (magnitudes_nonempty hn z) < bound := by
  22. rw [Finset.max'_lt_iff]
  23. constructor
  24. · intro h y hy
  25. obtain ⟨k, hk, rfl⟩ := Finset.mem_image.mp hy
  26. exact h k hk
  27. · intro h k hk
  28. exact h _ (Finset.mem_image_of_mem _ hk)
  29. theorem formal_statement_iff_published :
  30. Erdos973.Palomar.OriginalStatement ↔ publishedQuestion := by
  31. constructor
  32. · rintro ⟨C, hC, hall⟩
  33. refine ⟨C, hC, fun n hn => ?_⟩
  34. obtain ⟨z, hOne, hExt, hBound⟩ := hall n hn
  35. exact ⟨z, hOne, hExt, (pointwise_iff_max hn z _).mp hBound⟩
  36. · rintro ⟨C, hC, hall⟩
  37. refine ⟨C, hC, fun n hn => ?_⟩
  38. obtain ⟨z, hOne, hExt, hBound⟩ := hall n hn
  39. exact ⟨z, hOne, hExt, (pointwise_iff_max hn z _).mpr hBound⟩
  40. theorem negative_answer : ¬ publishedQuestion :=
  41. fun h => Erdos973.Palomar.not_erdos_973 (formal_statement_iff_published.mpr h)
  42. #print axioms DeskAudit.negative_answer
  43. end DeskAudit