Lax489179.DistanceProperties
Uniqueness and diagonal entries of shortest-path distances
concepts/Lax489179/DistanceProperties.lean · lax-489179
No public endorsements yet.
Loading review…
Sign in with ORCIDConcept map
Evidence
This concept declares 3 statements. Each proof establishes one of them relative to its assumptions.
1st statement diagonal_zero proven
2nd statement distance_unique proven
3rd statement matrix_length proven
Lemma
The distance specification has at most one answer for each ordered pair. In a graph with no negative cycle every diagonal answer is zero. An encoded by distance matrix contains exactly words.
Lean source view on GitHub
| 1 | import Lax489179.WeightedAPSP |
| 2 | |
| 3 | /-! |
| 4 | --- |
| 5 | title: Uniqueness and diagonal entries of shortest-path distances |
| 6 | type: lemma |
| 7 | --- |
| 8 | The distance specification has at most one answer for each ordered |
| 9 | pair. In a graph with no negative cycle every diagonal answer is zero. |
| 10 | An encoded by distance matrix contains exactly words. |
| 11 | -/ |
| 12 | |
| 13 | namespace Lax489179.DistanceProperties |
| 14 | |
| 15 | open WeightedAPSP |
| 16 | |
| 17 | axiom distance_unique (G : Graph) (u v : Fin G.vertices) (a b : Option ℤ) |
| 18 | (ha : Distance G u v a) (hb : Distance G u v b) : a = b |
| 19 | |
| 20 | axiom diagonal_zero (G : Graph) (h : NoNegativeCycle G) (v : Fin G.vertices) : |
| 21 | Distance G v v (some 0) |
| 22 | |
| 23 | axiom matrix_length (n : ℕ) (matrix : Fin n → Fin n → Option ℤ) : |
| 24 | (encodeMatrix n matrix).length = n * n |
| 25 | |
| 26 | end Lax489179.DistanceProperties |
| 27 |
Community review
Discussion
Ask a question or add context. Endorsements and structured flags are kept in the review panel above; your ORCID profile must share a public name.
0 comments