Metamath Proof Explorer


Definition df-upwlks

Description: Define the set of all walks (in a pseudograph), called "simple walks" in the following.

According to Wikipedia ("Path (graph theory)", https://en.wikipedia.org/wiki/Path_(graph_theory) , 3-Oct-2017): "A walk of length k in a graph is an alternating sequence of vertices and edges, v0 , e0 , v1 , e1 , v2 , ... , v(k-1) , e(k-1) , v(k) which begins and ends with vertices. If the graph is undirected, then the endpoints of e(i) are v(i) and v(i+1)."

According to Bollobas: " A walk W in a graph is an alternating sequence of vertices and edges x0 , e1 , x1 , e2 , ... , e(l) , x(l) where e(i) = x(i-1)x(i), 0Bollobas p. 4.

Therefore, a walk can be represented by two mappings f from { 1 , ... , n } and p from { 0 , ... , n }, where f enumerates the (indices of the) edges, and p enumerates the vertices. So the walk is represented by the following sequence: p(0) e(f(1)) p(1) e(f(2)) ... p(n-1) e(f(n)) p(n).

Although this definition is also applicable for arbitrary hypergraphs, it allows only walks consisting of not proper hyperedges (i.e. edges connecting at most two vertices). Therefore, it should be used for pseudographs only. (Contributed by Alexander van der Vekens and Mario Carneiro, 4-Oct-2017) (Revised by AV, 28-Dec-2020)

Ref Expression
Assertion df-upwlks ⊢ UPWalks = g ∈ V ⟼ f p | f ∈ Word dom ⁡ iEdg ⁡ g ∧ p : 0 … f ⟶ Vtx ⁡ g ∧ ∀ k ∈ 0 ..^ f iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1

Detailed syntax breakdown

Step Hyp Ref Expression
0 cupwlks class UPWalks
1 vg setvar g
2 cvv class V
3 vf setvar f
4 vp setvar p
5 3 cv setvar f
6 ciedg class iEdg
7 1 cv setvar g
8 7 6 cfv class iEdg ⁡ g
9 8 cdm class dom ⁡ iEdg ⁡ g
10 9 cword class Word dom ⁡ iEdg ⁡ g
11 5 10 wcel wff f ∈ Word dom ⁡ iEdg ⁡ g
12 4 cv setvar p
13 cc0 class 0
14 cfz class …
15 chash class .
16 5 15 cfv class f
17 13 16 14 co class 0 … f
18 cvtx class Vtx
19 7 18 cfv class Vtx ⁡ g
20 17 19 12 wf wff p : 0 … f ⟶ Vtx ⁡ g
21 vk setvar k
22 cfzo class ..^
23 13 16 22 co class 0 ..^ f
24 21 cv setvar k
25 24 5 cfv class f ⁡ k
26 25 8 cfv class iEdg ⁡ g ⁡ f ⁡ k
27 24 12 cfv class p ⁡ k
28 caddc class +
29 c1 class 1
30 24 29 28 co class k + 1
31 30 12 cfv class p ⁡ k + 1
32 27 31 cpr class p ⁡ k p ⁡ k + 1
33 26 32 wceq wff iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1
34 33 21 23 wral wff ∀ k ∈ 0 ..^ f iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1
35 11 20 34 w3a wff f ∈ Word dom ⁡ iEdg ⁡ g ∧ p : 0 … f ⟶ Vtx ⁡ g ∧ ∀ k ∈ 0 ..^ f iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1
36 35 3 4 copab class f p | f ∈ Word dom ⁡ iEdg ⁡ g ∧ p : 0 … f ⟶ Vtx ⁡ g ∧ ∀ k ∈ 0 ..^ f iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1
37 1 2 36 cmpt class g ∈ V ⟼ f p | f ∈ Word dom ⁡ iEdg ⁡ g ∧ p : 0 … f ⟶ Vtx ⁡ g ∧ ∀ k ∈ 0 ..^ f iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1
38 0 37 wceq wff UPWalks = g ∈ V ⟼ f p | f ∈ Word dom ⁡ iEdg ⁡ g ∧ p : 0 … f ⟶ Vtx ⁡ g ∧ ∀ k ∈ 0 ..^ f iEdg ⁡ g ⁡ f ⁡ k = p ⁡ k p ⁡ k + 1