Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

§3.3 — LP rounding gives a vertex cover of at most twice the minimum size

Proved
MatousekLP.Integrality.vertex_cover_lp_rounding

by mikedeng1 · Oct 3, 2026 · Mathlib 0df444a (Lean v4.33.1)

approximation-algorithmslinear-programmingp2o-batch-b23bp2o-gran-per-chapterp2o-plan-bookp2o-v1vertex-cover

Let G=(V,E)G = (V, E)G=(V,E) be a finite graph (not necessarily bipartite), and let x∗x^*x∗ be an optimal solution of the LP relaxation (3.3),

minimize ∑v∈Vxvsubject to xu+xv≥1 ({u,v}∈E),0≤xv≤1 (v∈V).\text{minimize } \sum_{v \in V} x_v \quad \text{subject to } x_u + x_v \ge 1 \ (\{u,v\} \in E), \quad 0 \le x_v \le 1 \ (v \in V).minimize v∈V∑​xv​subject to xu​+xv​≥1 ({u,v}∈E),0≤xv​≤1 (v∈V).

Define SLP={v∈V:xv∗≥12}S_{LP} = \{ v \in V : x^*_v \ge \tfrac12 \}SLP​={v∈V:xv∗​≥21​} and let SOPTS_{OPT}SOPT​ be a vertex cover of GGG of the minimum possible size. Then SLPS_{LP}SLP​ is a vertex cover of GGG, and

∣SLP∣≤2⋅∣SOPT∣.|S_{LP}| \le 2 \cdot |S_{OPT}| .∣SLP​∣≤2⋅∣SOPT​∣.

This is the analysis of the LP-rounding 2-approximation algorithm for minimum vertex cover.

Formalization Note Vertex covers are Mathlib's SimpleGraph.IsVertexCover; minimality of SOPTS_{OPT}SOPT​ is the hypothesis that no vertex cover has fewer elements.

Preamble
import Mathlib
import Definitions.Def_MatousekLP_Integrality_VertexCoverLP
Formal statement
namespace MatousekLP.Integrality

theorem vertex_cover_lp_rounding {V : Type*} [Fintype V] (G : SimpleGraph V)
    (xstar : V → ℝ) (hx : IsVCRelaxOptimal G xstar)
    (SOPT : Finset V) (hcov : G.IsVertexCover (SOPT : Set V))
    (hmin : ∀ C : Finset V, G.IsVertexCover (C : Set V) → SOPT.card ≤ C.card) :
    G.IsVertexCover {v | 1 / 2 ≤ xstar v} ∧
      (Finset.univ.filter (fun v => 1 / 2 ≤ xstar v)).card ≤ 2 * SOPT.card := by sorry

end MatousekLP.Integrality
Source
Matoušek & Gärtner, Understanding and Using Linear Programming, Springer 2007, §3.3, p. 38, claim |S_LP| ≤ 2·|S_OPT| (LP relaxation (3.3): p. 37)
Human review
  • Endorsed by Shuze Chen · Oct 5, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 5, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me