AFTD Auto-Formalizing Theoretical Domains

op1957_induced_complement_min_degree

theoremverified

Deleting a set I from a finite graph of minimum degree at least d+|I| leaves an induced graph of minimum degree at least d.

Statement

theorem op1957_induced_complement_min_degree
    {V : Type*} [Fintype V] [DecidableEq V]
    (G : SimpleGraph V) [DecidableRel G.Adj] (I : Finset V) (d : ℕ)
    (hdegree : ∀ v, d+I.card ≤ (G.neighborFinset v).card) :
    ∀ v : {v : V | v ∉ I}, d ≤ ((G.induce {v | v ∉ I}).neighborFinset v).card
Source
OP-1957 independence-number reduction
Verified
29 Nov 2026
Axioms
Classical.choiceQuot.soundpropext
Used by 3

The proof, explained

To show that every vertex v outside I retains degree at least d in the induced subgraph G[V \ I], we express its induced degree as the number of original neighbors outside I, namely |N_G(v) \ I|. Since deleting I removes at most |I| neighbors from N_G(v), the remaining degree is at least |N_G(v)| - |I|. Because every vertex in G originally has degree at least d + |I|, the induced degree is at least (d + |I|) - |I| = d.

  1. Fix an arbitrary vertex v outside I and define S = V \ I.

    Assuming classical logic, we fix an arbitrary vertex v in the subtype of vertices not belonging to I, and define S to be the set of all vertices outside I.

    lines 8–10

      classical
      intro v
      let S : Set V := {v | v ∉ I}
  2. The set S corresponds to the finset univ \ I.

    By extensionality, an element w belongs to S if and only if it is not in I, which coincides with membership in the complement of I within the universe.

    lines 11–13

      have hS : S.toFinset = Finset.univ \ I := by
        ext w
        simp [S]
  3. The degree of v in the induced subgraph G[S] equals |N_G(v) ∩ (univ \ I)|.

    The embedding from the induced subgraph into G maps the neighborhood of v in G[S] bijectively to N_G(v) ∩ S. Taking the cardinality of both sides preserves equality, and because embeddings preserve finset size, the degree in G[S] equals |N_G(v) ∩ S|. Rewriting S as univ \ I yields the claim.

    lines 14–17

    uses G.map_neighborFinset_induce, congrArg, Finset.card_map

      have hmap := G.map_neighborFinset_induce (s:=S) v
      have hh := congrArg Finset.card hmap
      simp only [Finset.card_map] at hh
      rw [hS] at hh
  4. The degree of v in G[S] equals |N_G(v) \ I|.

    Intersecting any finset of vertices with univ \ I is identical to removing I from that finset. Substituting this set identity simplifies the cardinality of the induced neighborhood to |N_G(v) \ I|.

    lines 18–20

      have heq : G.neighborFinset v.val ∩ (Finset.univ \ I) = G.neighborFinset v.val \ I := by
        ext w; simp
      rw [heq] at hh
  5. |N_G(v) \ I| + |N_G(v) ∩ I| = |N_G(v)|, where |N_G(v) ∩ I| ≤ |I| and |N_G(v)| ≥ d + |I|.

    Partitioning the neighborhood N_G(v) into those vertices disjoint from I and those in I decomposes its size into a sum of two cardinalities. The intersection N_G(v) ∩ I is a subset of I and thus has size at most |I|. Finally, by the theorem's minimum degree assumption, the full neighborhood has size at least d + |I|.

    lines 21–23

    uses Finset.card_sdiff_add_card_inter, Finset.card_le_card, Finset.inter_subset_right

      have hsplit := Finset.card_sdiff_add_card_inter (G.neighborFinset v.val) I
      have hcap : (G.neighborFinset v.val ∩ I).card ≤ I.card := Finset.card_le_card Finset.inter_subset_right
      have hd := hdegree v.val
  6. The degree of v in the induced subgraph is at least d. automation

    Rewriting the goal in terms of the induced subgraph on S, the degree of v is |N_G(v) \ I|. Combining |N_G(v) \ I| = |N_G(v)| - |N_G(v) ∩ I| with |N_G(v) ∩ I| ≤ |I| and |N_G(v)| ≥ d + |I| implies |N_G(v) \ I| ≥ d, which is verified by linear integer arithmetic.

    lines 24–25

      change d ≤ ((G.induce S).neighborFinset v).card
      omega
G.map_neighborFinset_induce
Under the canonical inclusion of an induced subgraph on s into the ambient graph G, the image of the neighbor finset of a vertex v ∈ s is the intersection of its neighbor finset in G with s.
congrArg
Applying a function to both sides of an equality preserves the equality.
Finset.card_map
Mapping a finset along an injective function preserves its cardinality.
Finset.card_sdiff_add_card_inter
For any two finite sets s and t, the cardinality of s \ t plus the cardinality of s ∩ t equals the cardinality of s.
Finset.card_le_card
If a finite set s is a subset of a finite set t, then |s| ≤ |t|.
Finset.inter_subset_right
The intersection of two sets is a subset of the second set: s₁ ∩ s₂ ⊆ s₂.

Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.

Lean source view module on GitHub

set_option maxHeartbeats 1500000theorem op1957_induced_complement_min_degree    {V : Type*} [Fintype V] [DecidableEq V]    (G : SimpleGraph V) [DecidableRel G.Adj] (I : Finset V) (d : ℕ)    (hdegree : ∀ v, d+I.card ≤ (G.neighborFinset v).card) :    ∀ v : {v : V | v ∉ I}, d ≤ ((G.induce {v | v ∉ I}).neighborFinset v).card := by  classical  intro v  let S : Set V := {v | v ∉ I}  have hS : S.toFinset = Finset.univ \ I := by    ext w    simp [S]  have hmap := G.map_neighborFinset_induce (s:=S) v  have hh := congrArg Finset.card hmap  simp only [Finset.card_map] at hh  rw [hS] at hh  have heq : G.neighborFinset v.val ∩ (Finset.univ \ I) = G.neighborFinset v.val \ I := by    ext w; simp  rw [heq] at hh  have hsplit := Finset.card_sdiff_add_card_inter (G.neighborFinset v.val) I  have hcap : (G.neighborFinset v.val ∩ I).card ≤ I.card := Finset.card_le_card Finset.inter_subset_right  have hd := hdegree v.val  change d ≤ ((G.induce S).neighborFinset v).card  omega
See it in the graphDiscuss this resultChallenge it