Maximum edge count among finite graphs satisfying a predicate
ProvedWilliamsonShmoys.finite_graph_predicate_has_edge_max__p2m_5f4c0396_f2c5_4ee4_89c1_d7bcb4050c5c_a1approximation-algorithmsplanar-graphstreewidth
For any finite vertex type and any inhabited predicate on its simple graphs, there is a graph satisfying the predicate whose finite edge count is at least that of every other graph satisfying it.
Preamble
import Mathlib set_option autoImplicit false
Formal statement
theorem WilliamsonShmoys.finite_graph_predicate_has_edge_max__p2m_5f4c0396_f2c5_4ee4_89c1_d7bcb4050c5c_a1
{V : Type} [Fintype V] (P : SimpleGraph V → Prop) (hP : ∃ G, P G) :
letI : (G : SimpleGraph V) → DecidableRel G.Adj := fun G => Classical.decRel G.Adj
∃ H : SimpleGraph V, P H ∧
(∀ K : SimpleGraph V, P K → K.edgeFinset.card ≤ H.edgeFinset.card) := by sorrySource
David P. Williamson and David B. Shmoys, The Design of Approximation Algorithms, Cambridge University Press, 2011, author electronic manuscript, Section 10.2, proof of Theorem 10.11, pp. 270-272. https://doi.org/10.1017/CBO9780511921735. Bounded tree-width of the pieces: Robertson–Seymour (planar graphs of radius r have tree-width at most 3r+1) / Bodlaender (k-outerplanar graphs have tree-width at most 3k-1).