Numbering finite graphs and the size of their encoding
Lax323828.GraphEncoding · concepts/Lax323828/GraphEncoding.lean · lax-323828
No public endorsements yet.
Loading review…
Sign in with ORCIDNatural Language Statement
Theorem
A bijective numbering of the vertices of a finite simple graph gives a Boolean adjacency matrix on with the same clique number. Its binary encoding has exactly bits. These facts connect abstract consistency graphs to the input representation used by approximation algorithms.
Concept map
Evidence
Lean source view on GitHub
| 1 | import Lax323828.Graphs |
| 2 | |
| 3 | /-! |
| 4 | --- |
| 5 | title: Numbering finite graphs and the size of their encoding |
| 6 | type: theorem |
| 7 | --- |
| 8 | A bijective numbering of the vertices of a finite simple graph gives a |
| 9 | Boolean adjacency matrix on with the same clique number. |
| 10 | Its binary encoding has exactly bits. These facts connect abstract |
| 11 | consistency graphs to the input representation used by approximation |
| 12 | algorithms. |
| 13 | -/ |
| 14 | |
| 15 | namespace Lax323828.GraphEncoding |
| 16 | |
| 17 | open Graphs |
| 18 | |
| 19 | /-- Transfer adjacency along the vertex numbering `e` to obtain a Boolean matrix. -/ |
| 20 | def numbered {α : Type} {n : ℕ} (G : SimpleGraph α) [DecidableRel G.Adj] |
| 21 | (e : Fin n ≃ α) : Graph n where |
| 22 | adjacent u v := decide (G.Adj (e u) (e v)) |
| 23 | loopless v := decide_eq_false (G.loopless.irrefl (e v)) |
| 24 | symmetric u v := decide_eq_decide.mpr (G.adj_comm (e u) (e v)) |
| 25 | |
| 26 | /-- Relabeling the vertices preserves the largest clique size. -/ |
| 27 | axiom cliqueNumber_numbered {α : Type} [Fintype α] {n : ℕ} |
| 28 | (G : SimpleGraph α) [DecidableRel G.Adj] (e : Fin n ≃ α) : |
| 29 | (numbered G e).cliqueNumber = G.cliqueNum |
| 30 | |
| 31 | /-- The encoding contains the unary vertex count, one separator, and `n²` matrix entries. -/ |
| 32 | axiom encoding_length {n : ℕ} (G : Graph n) : |
| 33 | G.encode.length = n + 1 + n * n |
| 34 | |
| 35 | end Lax323828.GraphEncoding |
| 36 |
Discussion
Ask a question or add context. Endorsements and structured flags are kept in the review panel above.
0 comments