{
  "id": "2434",
  "ident": "NS.02434",
  "slug": "erdos-548",
  "title": "Erdős Problem 548",
  "status": "solved",
  "statement_status": "reviewed",
  "statement_md": "Let $n\\geq k+1$. Every graph on $n$ vertices with at least $\\frac{k-1}{2}n+1$ edges contains every tree on $k+1$ vertices.",
  "subjects": [
    "math.CO",
    "msc:05"
  ],
  "tags": [
    "formal_proof"
  ],
  "collection": "erdos",
  "source_url": null,
  "solved_on_platform": false,
  "needs_answer": false,
  "version": 1,
  "decl_name": "Erdos548.erdos_548",
  "statement_lean": "theorem erdos_548 (n k : ℕ) (hk : k + 1 ≤ n) (G : SimpleGraph (Fin n))\n    (H : ((k : ℚ) - 1) / 2 * n + 1 ≤ (G.edgeSet.ncard : ℚ))\n    (T : SimpleGraph (Fin (k + 1))) (hT : T.IsTree) : T.IsContained G",
  "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 548\n\n*References:*\n- [erdosproblems.com/548](https://www.erdosproblems.com/548)\n- [BrDo96] Brandt, Stephan and Dobson, Edward, *The Erdős-Sós conjecture for graphs of girth {$5$}*.\n  Discrete Math. (1996), 411-414.\n- [Er78] Erdős, Paul, *Problems and results in combinatorial analysis and combinatorial number\n  theory*. Proceedings of the Ninth Southeastern Conference on Combinatorics, Graph Theory, and\n  Computing (Florida Atlantic Univ., Boca Raton, Fla., 1978) (1978), 29-40.\n- [ErGa59] Erdős, P. and Gallai, T., *On maximal paths and circuits of graphs*. Acta Math. Acad.\n  Sci. Hungar. (1959), 337-356 (unbound insert).\n- [SaWo97] Saclé, Jean-François and Woźniak, Mariusz, *The Erdős-Sós conjecture for graphs without\n  {$C_4$}*. J. Combin. Theory Ser. B (1997), 367-372.\n- [WLL00] Wang, Min and Li, Guo-jun and Liu, Ai-de, *A result of Erdős-Sós conjecture*. Ars Combin.\n  (2000), 123-127.\n- [YiLi04] Yin, Jian-hua and Li, Jiong-sheng, *The Erdős-Sós conjecture for graphs whose complements\n  contain no {$C_4$}*. Acta Math. Appl. Sin. Engl. Ser. (2004), 397-400.\n-/\n\n@[expose] public section\n\nopen SimpleGraph\n\nnamespace Erdos548\n\nset_option linter.style.formal_proof_palomar false in\n/--\nLet $n\\geq k+1$. Every graph on $n$ vertices with at least $\\frac{k-1}{2}n+1$ edges contains every tree on $k+1$ vertices.\n-/\n@[category research solved, AMS 5,\n  formal_proof using lean4 at \"https://github.com/Jayyhk/erdos-lean/blob/4c355efbf8e90c2572aa8d0c8d6f3b4b43f011f4/problems/548/Erdos548.lean#L1182\"]\ntheorem erdos_548 (n k : ℕ) (hk : k + 1 ≤ n) (G : SimpleGraph (Fin n))\n    (H : ((k : ℚ) - 1) / 2 * n + 1 ≤ (G.edgeSet.ncard : ℚ))\n    (T : SimpleGraph (Fin (k + 1))) (hT : T.IsTree) : T.IsContained G := by\n  sorry\n\nend Erdos548",
  "statement_hash": "33b0748e3be052d198f6267c6720283e8ffdc027e2b17d697d67e69a9282909d",
  "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."
}