{
  "id": "925",
  "ident": "NS.00925",
  "slug": "erdos-1188",
  "title": "Erdős Problem 1188",
  "status": "solved",
  "statement_status": "reviewed",
  "statement_md": "Call a set of distinct integers $1<n_1<\\cdots<n_k$ with associated congruence\nclasses $a_i\\pmod{n_i}$ a distinct covering system if every integer satisfies at\nleast one of these congruences. A minimal distinct covering system is one such\nthat no proper subset forms a covering system. Let $F(x)$ count the number of\nminimal distinct covering systems with all moduli in $[1,x]$. Estimate $F(x)$.\n\nThe estimate is `log(log F(x)) / log x → 1`.",
  "subjects": [
    "math.NT",
    "msc:11"
  ],
  "tags": [
    "formal_proof"
  ],
  "collection": "erdos",
  "source_url": "https://www.erdosproblems.com/1188",
  "solved_on_platform": false,
  "needs_answer": false,
  "version": 1,
  "decl_name": "Erdos1188.erdos_1188",
  "statement_lean": "theorem erdos_1188 :\n    Tendsto (fun x : ℕ => Real.log (Real.log (coveringCount x : ℝ)) / Real.log (x : ℝ))\n      atTop (𝓝 1)",
  "challenge_source": "/-\nCopyright 2026 The Formal Conjectures Authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    https://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n-/\nmodule\n\npublic import FormalConjecturesUtil\n\n/-!\n# Erdős Problem 1188\n\n*Reference:* [erdosproblems.com/1188](https://www.erdosproblems.com/1188)\n-/\n\n@[expose] public section\n\nnamespace Erdos1188\n\nopen Filter\nopen scoped Topology\n\n/-- A congruence class `(n, a)` represents `a (mod n)`. -/\nabbrev CongruenceClass := ℕ × ℕ\n\n/-- The modulus is `> 1` and the residue is reduced. -/\ndef ValidClass (c : CongruenceClass) : Prop := 2 ≤ c.1 ∧ c.2 < c.1\n\n/-- `z` lies in the class `(n, a)`. -/\ndef Satisfies (z : ℤ) (c : CongruenceClass) : Prop := z % (c.1 : ℤ) = (c.2 : ℤ)\n\n/-- Every integer satisfies some congruence of `S`. -/\ndef Covers (S : Finset CongruenceClass) : Prop := ∀ z : ℤ, ∃ c ∈ S, Satisfies z c\n\n/-- No two classes of `S` share a modulus. -/\ndef HasDistinctModuli (S : Finset CongruenceClass) : Prop :=\n  ∀ ⦃c₁⦄, c₁ ∈ S → ∀ ⦃c₂⦄, c₂ ∈ S → c₁.1 = c₂.1 → c₁ = c₂\n\n/-- A minimal distinct covering system: valid classes with distinct moduli that\ncover `ℤ`, with no proper subset already covering. -/\ndef IsMinimalDistinctCoveringSystem (S : Finset CongruenceClass) : Prop :=\n  (∀ c ∈ S, ValidClass c) ∧ HasDistinctModuli S ∧ Covers S ∧\n    ∀ T : Finset CongruenceClass, T ⊂ S → ¬ Covers T\n\n/-- All classes `(n, a)` with `2 ≤ n ≤ x` and `a < n`. -/\ndef ClassesUpTo (x : ℕ) : Finset CongruenceClass :=\n  (Finset.Icc 2 x).biUnion fun n => (Finset.range n).image fun a => (n, a)\n\nopen scoped Classical in\n/-- `F(x)`: the number of minimal distinct covering systems all of whose moduli\nlie in `[1, x]`. -/\nnoncomputable def coveringCount (x : ℕ) : ℕ :=\n  ((ClassesUpTo x).powerset.filter IsMinimalDistinctCoveringSystem).card\n\nset_option linter.style.formal_proof_palomar false in\n/--\nCall a set of distinct integers $1<n_1<\\cdots<n_k$ with associated congruence\nclasses $a_i\\pmod{n_i}$ a distinct covering system if every integer satisfies at\nleast one of these congruences. A minimal distinct covering system is one such\nthat no proper subset forms a covering system. Let $F(x)$ count the number of\nminimal distinct covering systems with all moduli in $[1,x]$. Estimate $F(x)$.\n\nThe estimate is `log(log F(x)) / log x → 1`.\n-/\n@[category research solved, AMS 11, formal_proof using lean4 at \"https://github.com/williamjblair/lean-proofs/blob/4f915a323443bfb1709a6805a013812016dca88a/starfleet/erdos-1188/Research/SparseAsymptotic.lean\"]\ntheorem erdos_1188 :\n    Tendsto (fun x : ℕ => Real.log (Real.log (coveringCount x : ℝ)) / Real.log (x : ℝ))\n      atTop (𝓝 1) := by\n  sorry\n\nend Erdos1188\n",
  "statement_hash": "4d1b9b6ac7cc4916b840c1671dfcdc29fb9ed63660612e47209f064b0f0bf07c",
  "toolchain": "leanprover/lean4:v4.33.1",
  "upstream_commit": "f9b3868d5ca994a7bf95039bcec05338c0c21e2f",
  "workspace": "formal-conjectures",
  "field": "math",
  "formalization": "formal",
  "verification": "lean-kernel",
  "license": "Apache-2.0",
  "attribution": "google-deepmind/formal-conjectures contributors",
  "metric_name": null,
  "metric_direction": null,
  "critiques": [],
  "public_partial_proofs": [],
  "research_threads": [],
  "instructions": "Read research_threads first: other people's public repositories and what they already tried. Write Solution.lean starting from challenge_source. Keep every definition identical, prove decl_name with exactly the same type, no sorry in its dependency closure, no new axioms, no native_decide, no metaprogramming. Submit with POST /api/v1/submissions."
}