{
  "id": "3147",
  "ident": "NS.03147",
  "slug": "erdos-772",
  "title": "Erdős Problem 772",
  "status": "solved",
  "statement_status": "reviewed",
  "statement_md": "Let $k\\geq 1$ and $H_k(n)$ be the maximal $r$ such that if $A\\subset\\mathbb{N}$ has\n$\\lvert A\\rvert=n$ and $\\| 1_A\\ast 1_A\\|_\\infty \\leq k$ then $A$ contains a Sidon set of size at\nleast $r$.\n\nIs it true that $H_k(n)/n^{1/2}\\to \\infty$?\n\nThe answer is yes, and in fact $H_k(n) \\gg_k n^{2/3}$, proved by Alon and Erdős [AlEr85].",
  "subjects": [
    "math.CO",
    "math.NT",
    "msc:05",
    "msc:11"
  ],
  "tags": [
    "question",
    "formal_proof"
  ],
  "collection": "erdos",
  "source_url": null,
  "solved_on_platform": false,
  "needs_answer": false,
  "version": 1,
  "decl_name": "Erdos772.erdos_772.parts.i",
  "statement_lean": "theorem erdos_772.parts.i :\n    ∀ k ≥ 1, Tendsto (fun n : ℕ ↦ (H k n : ℝ) / √n) atTop atTop",
  "challenge_source": "/-\nCopyright 2025 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 772\n\n*References:*\n- [erdosproblems.com/772](https://www.erdosproblems.com/772)\n- [Er80e] Erdős, P., _Some applications of Ramsey's theorem to additive number theory_. European\n  J. Combin. (1980), 43-46.\n- [Er84d] Erdős, P., _Extremal problems in number theory, combinatorics and geometry_. Proceedings\n  of the International Congress of Mathematicians, Vol. 1, 2 (Warsaw, 1983) (1984), 51-70.\n- [AlEr85] Alon, Noga and Erdős, P., _An application of graph theory to additive number theory_.\n  European J. Combin. (1985), 201-203.\n-/\n\n@[expose] public section\n\nopen Filter Real AdditiveCombinatorics\n\nnamespace Erdos772\n\n/-- $H_k(n)$ is the maximal $r$ such that if $A\\subset\\mathbb{N}$ has $\\lvert A\\rvert=n$ and\n$\\| 1_A\\ast 1_A\\|_\\infty \\leq k$ then $A$ contains a Sidon set of size at least $r$.\n\nHere $1_A\\ast 1_A(m)$ counts the ordered pairs $(a,b)\\in A^2$ with $a+b=m$. (The value is\ntruncated at $n$, which only matters when no such $A$ exists.) -/\nnoncomputable def H (k n : ℕ) : ℕ :=\n  sSup {r | r ≤ n ∧ ∀ A : Finset ℕ, A.card = n → (∀ m, sumRep A m ≤ k) →\n    ∃ S ⊆ A, IsSidon (S : Set ℕ) ∧ r ≤ S.card}\n\nset_option linter.style.formal_proof_palomar false in\n/--\nLet $k\\geq 1$ and $H_k(n)$ be the maximal $r$ such that if $A\\subset\\mathbb{N}$ has\n$\\lvert A\\rvert=n$ and $\\| 1_A\\ast 1_A\\|_\\infty \\leq k$ then $A$ contains a Sidon set of size at\nleast $r$.\n\nIs it true that $H_k(n)/n^{1/2}\\to \\infty$?\n\nThe answer is yes, and in fact $H_k(n) \\gg_k n^{2/3}$, proved by Alon and Erdős [AlEr85].\n-/\n@[category research solved, question, AMS 5 11, formal_proof using lean4 at\n  \"https://github.com/plby/lean-proofs/blob/8822f7ddef30fadbd92e1c6ab4ed897af356af5e/src/latest/ErdosProblems/Erdos772.lean#L1040\"]\ntheorem erdos_772.parts.i :\n    ∀ k ≥ 1, Tendsto (fun n : ℕ ↦ (H k n : ℝ) / √n) atTop atTop := by\n  sorry\n\nset_option linter.style.formal_proof_palomar false in\n/--\nIs it true that $H_k(n) > n^{1/2+c}$ for some constant $c>0$?\n\nThe answer is yes, and in fact $H_k(n) \\gg_k n^{2/3}$, proved by Alon and Erdős [AlEr85].\n-/\n@[category research solved, question, AMS 5 11, formal_proof using lean4 at\n  \"https://github.com/plby/lean-proofs/blob/8822f7ddef30fadbd92e1c6ab4ed897af356af5e/src/latest/ErdosProblems/Erdos772.lean#L1040\"]\ntheorem erdos_772.parts.ii :\n    ∀ k ≥ 1, ∃ c > 0, ∀ᶠ n : ℕ in atTop, (n : ℝ) ^ (1 / 2 + c : ℝ) < H k n := by\n  sorry\n\n/-- Alon and Erdős [AlEr85] proved that $H_k(n) \\gg_k n^{2/3}$. -/\n@[category research solved, AMS 5 11]\ntheorem erdos_772.variants.alon_erdos (k : ℕ) (hk : 1 ≤ k) :\n    ∃ c > 0, ∀ᶠ n : ℕ in atTop, c * (n : ℝ) ^ (2 / 3 : ℝ) ≤ H k n := by\n  sorry\n\n/-- Erdős [Er84d] proved that $H_k(n) \\ll n^{2/3}$, where the implied constant is absolute.\n\nSince $1_A\\ast 1_A$ counts ordered pairs, the bound needs $k\\geq 4$: the construction of\nErdős has at most two unordered representations of each sum, hence at most four ordered ones,\nwhile $k\\leq 2$ forces $A$ itself to be Sidon and so $H_k(n)=n$. For $k=3$ the only collisions\nare $a+b=2c$, so the Sidon subsets of $A$ are its $3$-term-progression-free subsets, which have\nsize $n^{1-o(1)}$, and the bound fails there too. -/\n@[category research solved, AMS 5 11]\ntheorem erdos_772.variants.upper_bound :\n    ∃ C : ℝ, ∀ k ≥ 4, ∀ᶠ n : ℕ in atTop,\n      (H k n : ℝ) ≤ C * (n : ℝ) ^ (2 / 3 : ℝ) := by\n  sorry\n\nend Erdos772\n",
  "statement_hash": "5202e73218d0489b36ebe39963917bbbff60a84544292c71e63e90efc802b79f",
  "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."
}