AFTD Auto-Formalizing Theoretical Domains

four_block_anticomplete_shores_separator_bound

theoremverified

In a finite four-block partition with A and B together of size L, C nonempty and anticomplete to D, suppose every separator has size at least L. For any disjoint anticomplete sets Q,W with D intersecting Q, the number of D vertices in Q or W plus the number of B vertices in W is at most the size of D.

Statement

theorem four_block_anticomplete_shores_separator_bound
    {V : Type*} [Fintype V] [DecidableEq V] (G : SimpleGraph V)
    (A B C D : Finset V)
    (hAB : Disjoint A B) (hAC : Disjoint A C) (hAD : Disjoint A D)
    (hBC : Disjoint B C) (hBD : Disjoint B D) (hCD : Disjoint C D)
    (hcover : A ∪ B ∪ C ∪ D = Finset.univ)
    (hC : C.Nonempty) (L : ℕ) (hsizeAB : A.card+B.card=L)
    (hnoCD : ∀ c ∈ C, ∀ d ∈ D, ¬ G.Adj c d)
    (hsep : ∀ X U V' : Finset V, U.Nonempty → V'.Nonempty →
      Disjoint X U → Disjoint X V' → Disjoint U V' → X ∪ U ∪ V' = Finset.univ →
      (∀ u ∈ U, ∀ v ∈ V', ¬ G.Adj u v) → L ≤ X.card)
    (Q W : Finset V) (hQW : Disjoint Q W)
    (hcross : ∀ q ∈ Q, ∀ w ∈ W, ¬ G.Adj q w)
    (hQD : (D ∩ Q).Nonempty) :
    (D ∩ Q).card + (B ∩ W).card + (D ∩ W).card ≤ D.card
Source
OP-1957: strengthened separator for arbitrary-sized four-block bridge shores.
Verified
24 Nov 2026
Axioms
Classical.choiceQuot.soundpropext
Used by 7

The proof, explained

The proof constructs a tripartite partition of the vertex set into a separator X := A ∪ (B \ W) ∪ (D \ (Q ∪ W)) and two shores U := C ∪ (B ∩ W) ∪ (D ∩ W) and V := D ∩ Q. The anticompleteness assumptions between C and D and between Q and W ensure that there are no edges between U and V, so the separator hypothesis implies |X| ≥ L. Decomposing the cardinalities of B and D and comparing |X| with |A| + |B| = L then yields the upper bound by linear arithmetic.

  1. Define a candidate separator X and two shores U and V partitioning the graph.

    Set X := A ∪ (B \ W) ∪ (D \ (Q ∪ W)), U := C ∪ (B ∩ W) ∪ (D ∩ W), and V := D ∩ Q. The strategy is to show that X separates U from V in G, so that the separator lower bound hypothesis applies.

    lines 16–19

      classical
      let X := A ∪ (B \ W) ∪ (D \ (Q ∪ W))
      let U := C ∪ (B ∩ W) ∪ (D ∩ W)
      let V := D ∩ Q
  2. Both shores U and V are nonempty.

    Since C is nonempty (by hypothesis hC), choosing any element c ∈ C gives c ∈ U, showing U is nonempty. The shore V = D ∩ Q is nonempty directly by the hypothesis hQD.

    lines 20–23

      have hUne : U.Nonempty := by
        obtain ⟨c,hc⟩ := hC
        exact ⟨c, by simp [U,hc]⟩
      have hVne : V.Nonempty := hQD
  3. The candidate separator X is disjoint from the shore U.

    Suppose, for contradiction, that some vertex v belongs to both X and U. Then v lies in one of the three constituents of X (A, B \ W, or D \ (Q ∪ W)) and in one of the three constituents of U (C, B ∩ W, or D ∩ W). In each of the nine cases, this contradicts either the assumed pairwise disjointness of A, B, C, D, or the conflicting membership conditions regarding W or Q ∪ W.

    lines 24–37

    uses Finset.disjoint_left.mpr, Finset.mem_union, Finset.mem_sdiff, Finset.mem_inter, Finset.disjoint_left.mp, Or.inr

      have hXU : Disjoint X U := by
        apply Finset.disjoint_left.mpr
        intro v hv hu
        simp only [X, U, Finset.mem_union, Finset.mem_sdiff, Finset.mem_inter] at hv hu
        rcases hv with (hv | hv) | hv <;> rcases hu with (hu | hu) | hu
        · exact Finset.disjoint_left.mp hAC hv hu
        · exact Finset.disjoint_left.mp hAB hv hu.1
        · exact Finset.disjoint_left.mp hAD hv hu.1
        · exact Finset.disjoint_left.mp hBC hv.1 hu
        · exact hv.2 hu.2
        · exact Finset.disjoint_left.mp hBD hv.1 hu.1
        · exact Finset.disjoint_left.mp hCD hu hv.1
        · exact Finset.disjoint_left.mp hBD hu.1 hv.1
        · exact hv.2 (Or.inr hu.2)
  4. The candidate separator X is disjoint from the shore V.

    Suppose, for contradiction, that some vertex v belongs to both X and V = D ∩ Q. If v ∈ A or v ∈ B \ W, this contradicts the disjointness of A or B with D. If v ∈ D \ (Q ∪ W), this contradicts v ∈ Q.

    lines 38–45

    uses Finset.disjoint_left.mpr, Finset.mem_union, Finset.mem_sdiff, Finset.mem_inter, Finset.disjoint_left.mp, Or.inl

      have hXV : Disjoint X V := by
        apply Finset.disjoint_left.mpr
        intro v hv hu
        simp only [X, V, Finset.mem_union, Finset.mem_sdiff, Finset.mem_inter] at hv hu
        rcases hv with (hv | hv) | hv
        · exact Finset.disjoint_left.mp hAD hv hu.1
        · exact Finset.disjoint_left.mp hBD hv.1 hu.1
        · exact hv.2 (Or.inl hu.2)
  5. The two shores U and V are disjoint.

    Suppose, for contradiction, that some vertex v belongs to both U and V = D ∩ Q. If v ∈ C or v ∈ B ∩ W, this contradicts the disjointness of C or B with D. If v ∈ D ∩ W, this contradicts the hypothesis hQW that Q and W are disjoint.

    lines 46–53

    uses Finset.disjoint_left.mpr, Finset.mem_union, Finset.mem_inter, Finset.disjoint_left.mp

      have hUV : Disjoint U V := by
        apply Finset.disjoint_left.mpr
        intro v hv hu
        simp only [U, V, Finset.mem_union, Finset.mem_inter] at hv hu
        rcases hv with (hv | hv) | hv
        · exact Finset.disjoint_left.mp hCD hv hu.1
        · exact Finset.disjoint_left.mp hBD hv.1 hu.1
        · exact Finset.disjoint_left.mp hQW hu.2 hv.2
  6. The sets X, U, and V together cover the entire vertex set: X ∪ U ∪ V = univ.

    By the covering hypothesis hcover, every vertex v lies in A, B, C, or D. If v ∈ A, then v ∈ X. If v ∈ B, case analysis on whether v ∈ W places v in U or X. If v ∈ C, then v ∈ U. If v ∈ D, case analysis on v ∈ Q and v ∈ W places v into V, U, or X. Hence every vertex belongs to X ∪ U ∪ V.

    lines 54–66

    uses Finset.eq_univ_iff_forall.mpr, Finset.mem_univ, Finset.mem_union, or_assoc

      have hXUV : X ∪ U ∪ V = Finset.univ := by
        apply Finset.eq_univ_iff_forall.mpr
        intro v
        have hall : v ∈ A ∨ v ∈ B ∨ v ∈ C ∨ v ∈ D := by
          have h : v ∈ A ∪ B ∪ C ∪ D := by rw [hcover]; exact Finset.mem_univ v
          simpa only [Finset.mem_union, or_assoc] using h
        rcases hall with ha | hb | hc | hd
        · simp [X,ha]
        · by_cases hw : v ∈ W <;> simp [X,U,hb,hw]
        · simp [U,hc]
        · by_cases hq : v ∈ Q
          · simp [V,hd,hq]
          · by_cases hw : v ∈ W <;> simp [X,U,hd,hq,hw]
  7. There are no edges in G between U and V.

    Let u ∈ U and v ∈ V = D ∩ Q, and suppose they are adjacent. If u ∈ C, this contradicts the hypothesis hnoCD that C and D are anticomplete. If u ∈ B ∩ W or u ∈ D ∩ W, then u ∈ W and v ∈ Q, which contradicts the hypothesis hcross that Q and W are anticomplete.

    lines 67–73

    uses Finset.mem_union, Finset.mem_inter

      have hanti : ∀ u ∈ U, ∀ v ∈ V, ¬ G.Adj u v := by
        intro u hu v hv huv
        simp only [U,V,Finset.mem_union,Finset.mem_inter] at hu hv
        rcases hu with (hu | hu) | hu
        · exact hnoCD u hu v hv.1 huv
        · exact hcross v hv.2 u hu.2 huv.symm
        · exact hcross v hv.2 u hu.2 huv.symm
  8. The candidate separator X has size at least L: L ≤ |X|.

    Because U and V are nonempty, mutually disjoint from each other and from X, cover the remainder of the graph, and have no edges between them, the separator hypothesis hsep applies to (X, U, V) and yields L ≤ |X|.

    line 74

      have hcut := hsep X U V hUne hVne hXU hXV hUV hXUV hanti
  9. The size of X is bounded above by |A| + |B \ W| + |D \ (Q ∪ W)|.

    By definition X = A ∪ (B \ W) ∪ (D \ (Q ∪ W)). Subadditivity of cardinality across unions bounds |X| by the sum of the cardinalities of its three constituent subsets.

    lines 75–76

    uses Finset.card_union_le, Nat.add_le_add_right

      have hXcard : X.card ≤ A.card + (B \ W).card + (D \ (Q ∪ W)).card :=
        (Finset.card_union_le _ _).trans (Nat.add_le_add_right (Finset.card_union_le _ _) _)
  10. The sizes of B and D decompose as |B| = |B \ W| + |B ∩ W| and |D| = |D \ (Q ∪ W)| + |D ∩ Q| + |D ∩ W|.

    Decomposing B relative to W gives |B| = |B \ W| + |B ∩ W|. Decomposing D relative to Q ∪ W gives |D| = |D \ (Q ∪ W)| + |D ∩ (Q ∪ W)|. Since intersection distributes over union and D ∩ Q is disjoint from D ∩ W (as Q and W are disjoint), |D ∩ (Q ∪ W)| splits into |D ∩ Q| + |D ∩ W|.

    lines 77–84

    uses Finset.card_sdiff_add_card_inter, Finset.inter_union_distrib_left, Finset.disjoint_of_subset_left, Finset.inter_subset_right, Finset.disjoint_of_subset_right, Finset.card_union_of_disjoint

      have hBcard := Finset.card_sdiff_add_card_inter B W
      have hDcard := Finset.card_sdiff_add_card_inter D (Q ∪ W)
      have hDinter : D ∩ (Q ∪ W) = (D ∩ Q) ∪ (D ∩ W) := by
        exact Finset.inter_union_distrib_left D Q W
      have hDdis : Disjoint (D ∩ Q) (D ∩ W) := by
        exact Finset.disjoint_of_subset_left Finset.inter_subset_right
          (Finset.disjoint_of_subset_right Finset.inter_subset_right hQW)
      rw [hDinter, Finset.card_union_of_disjoint hDdis] at hDcard
  11. The desired inequality |D ∩ Q| + |B ∩ W| + |D ∩ W| ≤ |D| holds. automation

    Combining L = |A| + |B| with L ≤ |X| and the upper bound on |X| gives |A| + |B \ W| + |B ∩ W| ≤ |A| + |B \ W| + |D \ (Q ∪ W)|, which simplifies to |B ∩ W| ≤ |D \ (Q ∪ W)|. Substituting |D \ (Q ∪ W)| = |D| - |D ∩ Q| - |D ∩ W| and rearranging yields the result. Linear arithmetic closes the goal.

    line 85

      omega
Finset.disjoint_left.mpr
Two finite sets are disjoint if no element of the first belongs to the second.
Finset.disjoint_left.mp
If two finite sets are disjoint, an element of the first cannot belong to the second.
Finset.mem_union
An element belongs to the union of two sets if and only if it belongs to the first or to the second.
Finset.mem_sdiff
An element belongs to the set difference s \ t if and only if it belongs to s and not to t.
Finset.mem_inter
An element belongs to the intersection of two sets if and only if it belongs to both.
Or.inr
If a proposition B holds, then A ∨ B holds.
Or.inl
If a proposition A holds, then A ∨ B holds.
Finset.eq_univ_iff_forall.mpr
A finite set equals the universal set if every element of the underlying type belongs to it.
Finset.mem_univ
Every element of a finite type belongs to the universal finset.
or_assoc
Associativity of propositional disjunction: (A ∨ B) ∨ C ↔ A ∨ B ∨ C.
Finset.card_union_le
The cardinality of the union of two finite sets is at most the sum of their cardinalities.
Nat.add_le_add_right
Adding the same natural number to both sides of an inequality preserves the inequality.
Finset.card_sdiff_add_card_inter
The cardinality of s \ t plus the cardinality of s ∩ t equals the cardinality of s.
Finset.inter_union_distrib_left
Intersection distributes over union from the left: s ∩ (t ∪ u) = (s ∩ t) ∪ (s ∩ u).
Finset.disjoint_of_subset_left
If s ⊆ u and u is disjoint from t, then s is disjoint from t.
Finset.inter_subset_right
The intersection s₁ ∩ s₂ is a subset of s₂.
Finset.disjoint_of_subset_right
If t ⊆ u and s is disjoint from u, then s is disjoint from t.
Finset.card_union_of_disjoint
The cardinality of the union of two disjoint finite sets is the sum of their cardinalities.

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

theorem four_block_anticomplete_shores_separator_bound    {V : Type*} [Fintype V] [DecidableEq V] (G : SimpleGraph V)    (A B C D : Finset V)    (hAB : Disjoint A B) (hAC : Disjoint A C) (hAD : Disjoint A D)    (hBC : Disjoint B C) (hBD : Disjoint B D) (hCD : Disjoint C D)    (hcover : A ∪ B ∪ C ∪ D = Finset.univ)    (hC : C.Nonempty) (L : ℕ) (hsizeAB : A.card+B.card=L)    (hnoCD : ∀ c ∈ C, ∀ d ∈ D, ¬ G.Adj c d)    (hsep : ∀ X U V' : Finset V, U.Nonempty → V'.Nonempty →      Disjoint X U → Disjoint X V' → Disjoint U V' → X ∪ U ∪ V' = Finset.univ →      (∀ u ∈ U, ∀ v ∈ V', ¬ G.Adj u v) → L ≤ X.card)    (Q W : Finset V) (hQW : Disjoint Q W)    (hcross : ∀ q ∈ Q, ∀ w ∈ W, ¬ G.Adj q w)    (hQD : (D ∩ Q).Nonempty) :    (D ∩ Q).card + (B ∩ W).card + (D ∩ W).card ≤ D.card := by  classical  let X := A ∪ (B \ W) ∪ (D \ (Q ∪ W))  let U := C ∪ (B ∩ W) ∪ (D ∩ W)  let V := D ∩ Q  have hUne : U.Nonempty := by    obtain ⟨c,hc⟩ := hC    exact ⟨c, by simp [U,hc]⟩  have hVne : V.Nonempty := hQD  have hXU : Disjoint X U := by    apply Finset.disjoint_left.mpr    intro v hv hu    simp only [X, U, Finset.mem_union, Finset.mem_sdiff, Finset.mem_inter] at hv hu    rcases hv with (hv | hv) | hv <;> rcases hu with (hu | hu) | hu    · exact Finset.disjoint_left.mp hAC hv hu    · exact Finset.disjoint_left.mp hAB hv hu.1    · exact Finset.disjoint_left.mp hAD hv hu.1    · exact Finset.disjoint_left.mp hBC hv.1 hu    · exact hv.2 hu.2    · exact Finset.disjoint_left.mp hBD hv.1 hu.1    · exact Finset.disjoint_left.mp hCD hu hv.1    · exact Finset.disjoint_left.mp hBD hu.1 hv.1    · exact hv.2 (Or.inr hu.2)  have hXV : Disjoint X V := by    apply Finset.disjoint_left.mpr    intro v hv hu    simp only [X, V, Finset.mem_union, Finset.mem_sdiff, Finset.mem_inter] at hv hu    rcases hv with (hv | hv) | hv    · exact Finset.disjoint_left.mp hAD hv hu.1    · exact Finset.disjoint_left.mp hBD hv.1 hu.1    · exact hv.2 (Or.inl hu.2)  have hUV : Disjoint U V := by    apply Finset.disjoint_left.mpr    intro v hv hu    simp only [U, V, Finset.mem_union, Finset.mem_inter] at hv hu    rcases hv with (hv | hv) | hv    · exact Finset.disjoint_left.mp hCD hv hu.1    · exact Finset.disjoint_left.mp hBD hv.1 hu.1    · exact Finset.disjoint_left.mp hQW hu.2 hv.2  have hXUV : X ∪ U ∪ V = Finset.univ := by    apply Finset.eq_univ_iff_forall.mpr    intro v    have hall : v ∈ A ∨ v ∈ B ∨ v ∈ C ∨ v ∈ D := by      have h : v ∈ A ∪ B ∪ C ∪ D := by rw [hcover]; exact Finset.mem_univ v      simpa only [Finset.mem_union, or_assoc] using h    rcases hall with ha | hb | hc | hd    · simp [X,ha]    · by_cases hw : v ∈ W <;> simp [X,U,hb,hw]    · simp [U,hc]    · by_cases hq : v ∈ Q      · simp [V,hd,hq]      · by_cases hw : v ∈ W <;> simp [X,U,hd,hq,hw]  have hanti : ∀ u ∈ U, ∀ v ∈ V, ¬ G.Adj u v := by    intro u hu v hv huv    simp only [U,V,Finset.mem_union,Finset.mem_inter] at hu hv    rcases hu with (hu | hu) | hu    · exact hnoCD u hu v hv.1 huv    · exact hcross v hv.2 u hu.2 huv.symm    · exact hcross v hv.2 u hu.2 huv.symm  have hcut := hsep X U V hUne hVne hXU hXV hUV hXUV hanti  have hXcard : X.card ≤ A.card + (B \ W).card + (D \ (Q ∪ W)).card :=    (Finset.card_union_le _ _).trans (Nat.add_le_add_right (Finset.card_union_le _ _) _)  have hBcard := Finset.card_sdiff_add_card_inter B W  have hDcard := Finset.card_sdiff_add_card_inter D (Q ∪ W)  have hDinter : D ∩ (Q ∪ W) = (D ∩ Q) ∪ (D ∩ W) := by    exact Finset.inter_union_distrib_left D Q W  have hDdis : Disjoint (D ∩ Q) (D ∩ W) := by    exact Finset.disjoint_of_subset_left Finset.inter_subset_right      (Finset.disjoint_of_subset_right Finset.inter_subset_right hQW)  rw [hDinter, Finset.card_union_of_disjoint hDdis] at hDcard  omega
See it in the graphDiscuss this resultChallenge it