Documentation

CslibFrontier.Foundations.Combinatorics.SimpleGraph.Cheeger

The normalized graph Laplacian and discrete Cheeger inequalities #

For a finite simple graph G : SimpleGraph V (not necessarily regular), this module formalizes Fan Chung's normalized Laplacian 𝓛_G = T^{-1/2} L T^{-1/2}, vertex-set volume vol(S), conductance (Cheeger constant) h_G, spectral gap λ_G = λ_1, explicit sweep-cut rounding, and both the general-degree normalized Cheeger inequality ([Chu97], Chapters 1–2) and the combinatorial-Laplacian Cheeger inequality ([Chu97], §2.5; [AM85]):

  1. Normalized Laplacian and Rayleigh quotient ([Chu97], §1.2, pp. 2–5):
    • SimpleGraph.degInvSqrtMatrix (T^{-1/2}, with convention T^{-1}(v, v) = 0 at isolated vertices d_v = 0) and SimpleGraph.normLapMatrix (𝓛_G = T^{-1/2} L T^{-1/2}), proved symmetric and positive semidefinite with kernel vector v ↦ √(d_v) and quadratic form f ⬝ᵥ (L *ᵥ f) = (1 / 2) ∑_{u, v : G.Adj u v} (f u - f v)².
    • SimpleGraph.normSpectralGap (λ_G, [Chu97], Eq. (1.2), p. 4): infimum of SimpleGraph.normRayleigh over f : V → ℝ with ∑ v, f v * d_v = 0 and 0 < ∑ v, f v ^ 2 * d_v (0 on edgeless graphs G = ⊥; equal to the second eigenvalue λ_1 of SimpleGraph.normLapMatrix when G has no isolated vertices, whereas isolated vertices contribute extra 0 eigenvalues to normLapMatrix while normRayleigh ignores d_v = 0 coordinates), satisfying 0 ≤ λ_G ≤ 2, λ_{K_n} = n / (n - 1) for 2 ≤ n (Example 1.1, p. 6), and λ_G ≤ 1 when two positive-degree vertices are nonadjacent (Lemma 1.7(iii), p. 7).
  2. Conductance, sweep-cut rounding, and normalized Cheeger inequality ([Chu97], §§2.2–2.3, pp. 24–28):
  3. Combinatorial Laplacian / Fiedler algebraic connectivity ([Chu97], §2.5, pp. 34–35; [AM85]):

For port-labeled d-regular multigraphs (Cslib.RotationMap), see CslibFrontier.Foundations.Combinatorics.Expander.Cheeger.

Main definitions #

Main results #

References #

Weighted medians and level-set co-area engine #

Volume and conductance (h_G) #

def SimpleGraph.vol {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] (S : Finset V) :

Volume vol(S) of a vertex subset S ⊆ V ([Chu97], §2.2, p. 24): sum of the degrees of the vertices in S.

Total volume vol(G) = ∑_{v ∈ V} d_v ([Chu97], §1.2, p. 5).

@[simp]
theorem SimpleGraph.vol_empty {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] :
G.vol ∅ = 0
@[simp]
theorem SimpleGraph.vol_singleton {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] (v : V) :
G.vol {v} = G.degree v
theorem SimpleGraph.vol_mono {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] {S T : Finset V} (hST : S ⊆ T) :
G.vol S ≤ G.vol T
theorem SimpleGraph.IsRegularOfDegree.vol_eq {V : Type u_1} [Fintype V] {G : SimpleGraph V} [DecidableRel G.Adj] {d : ℕ} (hd : G.IsRegularOfDegree d) (S : Finset V) :
G.vol S = d * S.card

In any loopless simple graph, every vertex u satisfies 2 * d_u ≤ vol(G), since each of the d_u neighbors of u lies outside {u} and has degree at least 1.

Every edge in G.interedges S Sᶜ starts in S, so #(G.interedges S Sᶜ) ≤ vol(S).

noncomputable def SimpleGraph.setConductance {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (S : Finset V) :

Set conductance h_G(S) = |E(S, Sᶜ)| / min(vol S, vol Sᶜ) ([Chu97], §2.2, Eq. (2.1), p. 24).

theorem SimpleGraph.setConductance_def {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (S : Finset V) :
G.setConductance S = ↑(G.interedges S Sᶜ).card / ↑(min (G.vol S) (G.vol Sᶜ))
noncomputable def SimpleGraph.conductance {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :

Cheeger constant (conductance) h_G ([Chu97], §2.2, Eq. (2.2), p. 24): infimum of |E(S, Sᶜ)| / vol(S) over vertex subsets S with 0 < vol(S) and 2 * vol(S) ≤ vol(G) (0 on edgeless graphs G = ⊥). Equivalent to inf_{0 < min(vol S, vol Sᶜ)} h_G(S) via conductance_eq_iInf_setConductance.

theorem SimpleGraph.conductance_def {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :
G.conductance = ⨅ (S : { S : Finset V // 0 < G.vol S ∧ 2 * G.vol S ≤ G.totalVol }), ↑(G.interedges (↑S) (↑S)ᶜ).card / ↑(G.vol ↑S)
theorem SimpleGraph.conductance_mul_vol_le {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] {S : Finset V} (hS : 2 * G.vol S ≤ G.totalVol) :
G.conductance * ↑(G.vol S) ≤ ↑(G.interedges S Sᶜ).card

Equivalence with [Chu97], Eq. (2.2): h_G = ⨅_{0 < min(vol S, vol Sᶜ)} h_G(S).

theorem SimpleGraph.le_conductance_iff {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (hG : G ≠ ⊥) {c : ℝ} :
c ≤ G.conductance ↔ ∀ (S : Finset V), 0 < G.vol S → 2 * G.vol S ≤ G.totalVol → c * ↑(G.vol S) ≤ ↑(G.interedges S Sᶜ).card

For every finite simple graph, h_G ≤ 1 (witnessed by a singleton positive-degree vertex when G ≠ ⊥).

For any connected simple graph on at least two vertices, 2 / vol(G) ≤ h_G ([Chu97], §2.3, p. 28).

theorem SimpleGraph.connected_iff_conductance_pos {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] [Nontrivial V] (hiso : ∀ (v : V), 0 < G.degree v) :

On at least two vertices with no isolated vertices, G is connected iff 0 < h_G ([Chu97], §2.2, p. 24).

Normalized Laplacian 𝓛_G and normalized spectral gap λ_G #

noncomputable def SimpleGraph.degInvSqrtMatrix {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :

Inverse-square-root degree matrix T^{-1/2} ([Chu97], §1.2, p. 2), with convention T^{-1/2}(v, v) = 0 at isolated vertices d_v = 0 (since Real.sqrt 0 = 0 and 0⁻¹ = 0).

noncomputable def SimpleGraph.normLapMatrix {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :

Normalized Laplacian matrix 𝓛_G = T^{-1/2} L T^{-1/2} ([Chu97], §1.2, p. 2).

theorem SimpleGraph.normLapMatrix_apply {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (u v : V) :
G.normLapMatrix u v = if u = v then if G.degree v = 0 then 0 else 1 else if G.Adj u v then -(√(↑(G.degree u) * ↑(G.degree v)))⁻¹ else 0

Entrywise formula for 𝓛_G ([Chu97], §1.2, p. 2): 1 on the diagonal when d_v ≠ 0, -1 / √(d_u d_v) when G.Adj u v, and 0 otherwise.

𝓛_G is positive semidefinite ([Chu97], §1.2, p. 3).

For a d-regular graph with 0 < d, 𝓛_G = I - (1 / d) A ([Chu97], §1.2, p. 3).

T^{1/2} 1 = (v ↦ √(d_v)) lies in the kernel of 𝓛_G ([Chu97], §1.2, p. 4).

theorem SimpleGraph.dotProduct_mulVec_lapMatrix {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (f : V → ℝ) :
f ⬝ᵥ (lapMatrix ℝ G).mulVec f = (∑ e ∈ G.interedges Finset.univ Finset.univ, (f e.1 - f e.2) ^ 2) / 2

Combinatorial Dirichlet identity: f ⬝ᵥ (L *ᵥ f) = (1 / 2) ∑_{e ∈ interedges univ univ} (f e.1 - f e.2)².

theorem SimpleGraph.dotProduct_mulVec_normLapMatrix_mul_sqrt {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (f : V → ℝ) :
((fun (v : V) => √↑(G.degree v) * f v) ⬝ᵥ G.normLapMatrix.mulVec fun (v : V) => √↑(G.degree v) * f v) = f ⬝ᵥ (lapMatrix ℝ G).mulVec f

Change-of-variables identity ([Chu97], Eq. (1.1), p. 3): when g v = √(d_v) * f v, g ⬝ᵥ (𝓛_G *ᵥ g) = f ⬝ᵥ (L *ᵥ f).

noncomputable def SimpleGraph.normRayleigh {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (f : V → ℝ) :

Normalized Rayleigh quotient R_G(f) = (f ⬝ᵥ L f) / ∑_v f(v)² d_v ([Chu97], Eq. (1.1), p. 3).

theorem SimpleGraph.normRayleigh_def {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (f : V → ℝ) :
G.normRayleigh f = f ⬝ᵥ (lapMatrix ℝ G).mulVec f / ∑ v : V, f v ^ 2 * ↑(G.degree v)
noncomputable def SimpleGraph.normSpectralGap {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :

Normalized spectral gap λ_G ([Chu97], Eq. (1.2), p. 4): infimum of G.normRayleigh f over f : V → ℝ orthogonal to degrees (∑ v, f v * d_v = 0) with 0 < ∑ v, f v ^ 2 * d_v (0 on edgeless graphs G = ⊥). When G has no isolated vertices, normSpectralGap equals the second eigenvalue λ_1 of G.normLapMatrix; isolated vertices contribute additional 0 eigenvalues to G.normLapMatrix while G.normRayleigh ignores d_v = 0 coordinates.

theorem SimpleGraph.normSpectralGap_def {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :
G.normSpectralGap = ⨅ (f : { f : V → ℝ // ∑ v : V, f v * ↑(G.degree v) = 0 ∧ 0 < ∑ v : V, f v ^ 2 * ↑(G.degree v) }), G.normRayleigh ↑f
theorem SimpleGraph.normSpectralGap_le_normRayleigh {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] {f : V → ℝ} (horth : ∑ v : V, f v * ↑(G.degree v) = 0) (hpos : 0 < ∑ v : V, f v ^ 2 * ↑(G.degree v)) :
theorem SimpleGraph.le_normSpectralGap_iff {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] (hG : G ≠ ⊥) {c : ℝ} :
c ≤ G.normSpectralGap ↔ ∀ (f : V → ℝ), ∑ v : V, f v * ↑(G.degree v) = 0 → 0 < ∑ v : V, f v ^ 2 * ↑(G.degree v) → c ≤ G.normRayleigh f

λ_G ≤ 2 for every finite simple graph ([Chu97], Lemma 1.7(v), p. 7).

For the complete graph K_n (⊤ : SimpleGraph V) on n ≥ 2 vertices, λ_{K_n} = n / (n - 1) ([Chu97], Example 1.1 & Lemma 1.7(ii), p. 6).

theorem SimpleGraph.normSpectralGap_le_one_of_ne_top {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] {a b : V} (hab : a ≠ b) (hnadj : ¬G.Adj a b) (hda : 0 < G.degree a) (hdb : 0 < G.degree b) :

If G contains two distinct nonadjacent positive-degree vertices, then λ_G ≤ 1 ([Chu97], Lemma 1.7(iii), p. 7).

Normalized Cheeger inequality and sweep-cut rounding #

Upper bound of Cheeger's inequality ([Chu97], §2.3, Lemma 2.1, p. 25): λ_G ≤ 2 h_G for every finite simple graph G.

theorem SimpleGraph.exists_sweep_cut_le {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] {f : V → ℝ} (horth : ∑ v : V, f v * ↑(G.degree v) = 0) (hpos : 0 < ∑ v : V, f v ^ 2 * ↑(G.degree v)) :
∃ (S : Finset V), ((∃ (t : ℝ), S = {v : V | G.degree v ≠ 0 ∧ t ≤ f v}) ∨ ∃ (t : ℝ), S = {v : V | G.degree v ≠ 0 ∧ f v ≤ t}) ∧ 0 < G.vol S ∧ 2 * G.vol S ≤ G.totalVol ∧ 1 - √(1 - G.setConductance S ^ 2) ≤ G.normRayleigh f ∧ G.setConductance S ≤ √(2 * G.normRayleigh f)

Explicit sweep-cut rounding ([Chu97], §2.3, proof of Theorems 2.2 and 2.3, pp. 26–28): for every f : V → ℝ with ∑ v, f v * d_v = 0 and 0 < ∑ v, f v ^ 2 * d_v, there exists an explicit threshold cut S (either {v | d_v ≠ 0 ∧ t ≤ f v} or {v | d_v ≠ 0 ∧ f v ≤ t}) with 0 < vol(S), 2 * vol(S) ≤ vol(G), 1 - √(1 - h_G(S)²) ≤ R_G(f), and h_G(S) ≤ √(2 R_G(f)).

Strengthened Cheeger lower bound ([Chu97], §2.3, Theorem 2.3, p. 27): 1 - √(1 - h_G²) ≤ λ_G for every finite simple graph G.

Cheeger lower bound ([Chu97], §2.3, Theorem 2.2, p. 26): h_G² / 2 ≤ λ_G for every finite simple graph G.

Strict Cheeger lower bound ([Chu97], §2.3, Theorem 2.2, pp. 26–27): whenever 0 < h_G, h_G² / 2 < λ_G.

Strict Cheeger lower bound for connected graphs ([Chu97], §2.3, Theorem 2.2, p. 26): for any connected graph G on at least two vertices, h_G² / 2 < λ_G.

On at least two vertices with no isolated vertices, G is connected iff 0 < λ_G ([Chu97], Lemma 1.7(iv), p. 7).

Combinatorial Laplacian (h'_G and λ'_1, [Chu97], §2.5; [AM85]) #

noncomputable def SimpleGraph.isoperimetricNum {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :

Isoperimetric number (modified Cheeger constant) h'_G = inf_{0 < |S| ≤ |V| / 2} |E(S, Sᶜ)| / |S| ([Chu97], §2.5, p. 34; [AM85]). Equals 0 when |V| ≤ 1.

theorem SimpleGraph.isoperimetricNum_def {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :
G.isoperimetricNum = ⨅ (S : { S : Finset V // S.Nonempty ∧ 2 * S.card ≤ Fintype.card V }), ↑(G.interedges (↑S) (↑S)ᶜ).card / ↑(↑S).card
noncomputable def SimpleGraph.algConnectivity {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :

Algebraic connectivity (Fiedler value) λ'_1 = inf_{∑ f = 0, f ≠ 0} (f ⬝ᵥ L f) / (f ⬝ᵥ f) ([Chu97], §2.5, p. 34; [AM85]). Equals 0 when |V| ≤ 1.

theorem SimpleGraph.algConnectivity_def {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] :
G.algConnectivity = ⨅ (f : { f : V → ℝ // ∑ v : V, f v = 0 ∧ ∃ (v : V), f v ≠ 0 }), ↑f ⬝ᵥ (lapMatrix ℝ G).mulVec ↑f / ↑f ⬝ᵥ ↑f
theorem SimpleGraph.le_isoperimetricNum_iff {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] [Nontrivial V] {c : ℝ} :
c ≤ G.isoperimetricNum ↔ ∀ (S : Finset V), S.Nonempty → 2 * S.card ≤ Fintype.card V → c * ↑S.card ≤ ↑(G.interedges S Sᶜ).card
theorem SimpleGraph.algConnectivity_le_rayleigh {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] {f : V → ℝ} (horth : ∑ v : V, f v = 0) (hne : ∃ (v : V), f v ≠ 0) :

Combinatorial Cheeger upper bound ([Chu97], §2.5, p. 35; [AM85]): λ'_1 ≤ 2 h'_G for every finite simple graph G.

theorem SimpleGraph.exists_card_sweep_cut_le {V : Type u_1} [Fintype V] (G : SimpleGraph V) [DecidableRel G.Adj] [DecidableEq V] {f : V → ℝ} (horth : ∑ v : V, f v = 0) (hne : ∃ (v : V), f v ≠ 0) :
∃ (S : Finset V), ((∃ (t : ℝ), S = {v : V | t ≤ f v}) ∨ ∃ (t : ℝ), S = {v : V | f v ≤ t}) ∧ S.Nonempty ∧ 2 * S.card ≤ Fintype.card V ∧ (↑(G.interedges S Sᶜ).card / ↑S.card) ^ 2 ≤ 2 * ↑G.maxDegree * (f ⬝ᵥ (lapMatrix ℝ G).mulVec f / f ⬝ᵥ f)

Explicit cardinality sweep-cut rounding ([Chu97], §2.5, p. 35; [AM85]): for every nonzero f : V → ℝ with ∑ v, f v = 0, there is a sweep threshold cut S ({v | t ≤ f v} or {v | f v ≤ t}) with S.Nonempty, 2 * #S ≤ Fintype.card V, and (#(G.interedges S Sᶜ) / #S : ℝ) ^ 2 ≤ 2 * G.maxDegree * ((f ⬝ᵥ (G.lapMatrix ℝ *ᵥ f)) / (f ⬝ᵥ f)).

Combinatorial Cheeger lower bound (product form) ([Chu97], §2.5, p. 35; [AM85]): (h'_G)² ≤ 2 Δ λ'_1 for every finite simple graph G.

Combinatorial Cheeger lower bound (ratio form) ([Chu97], §2.5, p. 35; [AM85]): when 0 < G.maxDegree, (h'_G)² / (2 Δ) ≤ λ'_1.

For a d-regular graph with 0 < d, h_G = h'_G / d.

For a d-regular graph with 0 < d, λ_G = λ'_1 / d.