The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V30. Combinatorics

Mathlib.Combinatorics.SimpleGraph.Extremal.Basic

20 declarations. Mathlib docs · Source

Extremal graph theory

This file introduces basic definitions for extremal graph theory, including extremal numbers.

Main definitions

  • SimpleGraph.IsExtremal is the predicate that G has the maximum number of edges of any simple graph, with fixed vertices, satisfying p.

  • SimpleGraph.extremalNumber is the maximum number of edges in a H-free simple graph on n vertices.

    If H is contained in all simple graphs on n vertices, then this is 0.

def SimpleGraph.IsExtremal E3 #

{V : Type u_1} → [Fintype V] → (G : SimpleGraph V) → [DecidableRel G.Adj] → (SimpleGraph V → Prop) → Prop

G is an extremal graph satisfying p if G has the maximum number of edges of any simple graph, with fixed vertices, satisfying p.

theorem SimpleGraph.IsExtremal.prop E1 #

∀ {V : Type u_1} [inst : Fintype V] {G : SimpleGraph V} [inst_1 : DecidableRel G.Adj] {p : SimpleGraph V → Prop},
  G.IsExtremal p → p G

theorem SimpleGraph.exists_isExtremal_iff_exists E1 #

∀ {V : Type u_1} [inst : Fintype V] (p : SimpleGraph V → Prop), (∃ G x, G.IsExtremal p) ↔ ∃ G, p G

If one simple graph satisfies p, then there exists an extremal graph satisfying p.

theorem SimpleGraph.exists_isExtremal_free E1 #

∀ {V : Type u_1} [inst : Fintype V] {W : Type u_2} {H : SimpleGraph W}, H ≠ ⊥ → ∃ G x, G.IsExtremal H.Free

If H has at least one edge, then there exists an extremal H.Free graph.

theorem SimpleGraph.IsExtremal.le_iff_eq E0 #

∀ {V : Type u_1} [inst : Fintype V] {G : SimpleGraph V} [inst_1 : DecidableRel G.Adj] {p : SimpleGraph V → Prop},
  G.IsExtremal p → ∀ {H : SimpleGraph V}, p H → (G ≤ H ↔ G = H)

def SimpleGraph.extremalNumber E3 #

ℕ → {W : Type u_1} → SimpleGraph W → ℕ

The extremal number of a natural number n and a simple graph H is the maximum number of edges in a H-free simple graph on n vertices.

If H is contained in all simple graphs on n vertices, then this is 0.

theorem SimpleGraph.extremalNumber_of_fintypeCard_eq E0 #

∀ {n : ℕ} {V : Type u_1} {W : Type u_2} {H : SimpleGraph W} [inst : Fintype V],
  Fintype.card V = n → SimpleGraph.extremalNumber n H = {G | H.Free G}.sup fun x ↦ x.edgeFinset.card

theorem SimpleGraph.card_edgeFinset_le_extremalNumber E1 #

∀ {V : Type u_1} {W : Type u_2} {G : SimpleGraph V} {H : SimpleGraph W} [inst : Fintype V]
  [inst_1 : DecidableRel G.Adj], H.Free G → G.edgeFinset.card ≤ SimpleGraph.extremalNumber (Fintype.card V) H

If G is H-free, then G has at most extremalNumber (card V) H edges.

theorem SimpleGraph.IsContained.of_extremalNumber_lt_card_edgeFinset E1 #

∀ {V : Type u_1} {W : Type u_2} {G : SimpleGraph V} {H : SimpleGraph W} [inst : Fintype V]
  [inst_1 : DecidableRel G.Adj], SimpleGraph.extremalNumber (Fintype.card V) H < G.edgeFinset.card → H.IsContained G

If G has more than extremalNumber (card V) H edges, then G contains a copy of H.

theorem SimpleGraph.extremalNumber_le_iff E0 #

∀ {V : Type u_1} {W : Type u_2} [inst : Fintype V] (H : SimpleGraph W) (m : ℕ),
  SimpleGraph.extremalNumber (Fintype.card V) H ≤ m ↔
    ∀ ⦃G : SimpleGraph V⦄ [inst_1 : DecidableRel G.Adj], H.Free G → G.edgeFinset.card ≤ m

extremalNumber (card V) H is at most x if and only if every H-free simple graph G has at most x edges.

theorem SimpleGraph.lt_extremalNumber_iff E0 #

∀ {V : Type u_1} {W : Type u_2} [inst : Fintype V] (H : SimpleGraph W) (m : ℕ),
  m < SimpleGraph.extremalNumber (Fintype.card V) H ↔ ∃ G x, H.Free G ∧ m < G.edgeFinset.card

extremalNumber (card V) H is greater than x if and only if there exists a H-free simple graph G with more than x edges.

theorem SimpleGraph.extremalNumber_le_iff_of_nonneg E1 #

∀ {V : Type u_1} {W : Type u_2} [inst : Fintype V] {R : Type u_3} [inst_1 : Semiring R] [inst_2 : LinearOrder R]
  [FloorSemiring R] (H : SimpleGraph W) {m : R},
  0 ≤ m →
    (↑(SimpleGraph.extremalNumber (Fintype.card V) H) ≤ m ↔
      ∀ ⦃G : SimpleGraph V⦄ [inst_4 : DecidableRel G.Adj], H.Free G → ↑G.edgeFinset.card ≤ m)

extremalNumber (card V) H is at most x if and only if every H-free simple graph G has at most x edges.

theorem SimpleGraph.lt_extremalNumber_iff_of_nonneg E1 #

∀ {V : Type u_1} {W : Type u_2} [inst : Fintype V] {R : Type u_3} [inst_1 : Semiring R] [inst_2 : LinearOrder R]
  [FloorSemiring R] (H : SimpleGraph W) {m : R},
  0 ≤ m → (m < ↑(SimpleGraph.extremalNumber (Fintype.card V) H) ↔ ∃ G x, H.Free G ∧ m < ↑G.edgeFinset.card)

extremalNumber (card V) H is greater than x if and only if there exists a H-free simple graph G with more than x edges.

theorem SimpleGraph.IsContained.extremalNumber_le E1 #

∀ {n : ℕ} {W : Type u_2} {H : SimpleGraph W} {W' : Type u_4} {H' : SimpleGraph W'},
  H'.IsContained H → SimpleGraph.extremalNumber n H' ≤ SimpleGraph.extremalNumber n H

If H contains a copy of H', then extremalNumber n H is at most extremalNumber n H.

theorem SimpleGraph.extremalNumber_congr E1 #

∀ {n₁ n₂ : ℕ} {W₁ : Type u_4} {W₂ : Type u_5} {H₁ : SimpleGraph W₁} {H₂ : SimpleGraph W₂},
  n₁ = n₂ → ∀ (e : H₁ ≃g H₂), SimpleGraph.extremalNumber n₁ H₁ = SimpleGraph.extremalNumber n₂ H₂

If H₁ ≃g H₂, then extremalNumber n H₁ equals extremalNumber n H₂.

theorem SimpleGraph.extremalNumber_congr_right E1 #

∀ {n : ℕ} {W₁ : Type u_4} {W₂ : Type u_5} {H₁ : SimpleGraph W₁} {H₂ : SimpleGraph W₂} (e : H₁ ≃g H₂),
  SimpleGraph.extremalNumber n H₁ = SimpleGraph.extremalNumber n H₂

If H₁ ≃g H₂, then extremalNumber n H₁ equals extremalNumber n H₂.

theorem SimpleGraph.isExtremal_free_iff E0 #

∀ {V : Type u_1} {W : Type u_2} {G : SimpleGraph V} {H : SimpleGraph W} [inst : Fintype V]
  [inst_1 : DecidableRel G.Adj],
  G.IsExtremal H.Free ↔ H.Free G ∧ G.edgeFinset.card = SimpleGraph.extremalNumber (Fintype.card V) H

H-free extremal graphs are H-free simple graphs having extremalNumber (card V) H many edges.

theorem SimpleGraph.card_edgeFinset_of_isExtremal_free E1 #

∀ {V : Type u_1} {W : Type u_2} {G : SimpleGraph V} {H : SimpleGraph W} [inst : Fintype V]
  [inst_1 : DecidableRel G.Adj], G.IsExtremal H.Free → G.edgeFinset.card = SimpleGraph.extremalNumber (Fintype.card V) H

theorem SimpleGraph.card_edgeFinset_deleteIncidenceSet_le_extremalNumber E1 #

∀ {V : Type u_1} {W : Type u_2} {G : SimpleGraph V} {H : SimpleGraph W} [inst : Fintype V] [inst_1 : DecidableRel G.Adj]
  [inst_2 : DecidableEq V],
  H.Free G → ∀ (v : V), (G.deleteIncidenceSet v).edgeFinset.card ≤ SimpleGraph.extremalNumber (Fintype.card V - 1) H

If G is H.Free, then G.deleteIncidenceSet v is also H.Free and has at most extremalNumber (card V-1) H many edges.

theorem SimpleGraph.extremalNumber_le_choose_two E1 #

∀ {n : ℕ} {W : Type u_2} {H : SimpleGraph W}, SimpleGraph.extremalNumber n H ≤ n.choose 2

The extremal number on n vertices is at most n.choose 2.