Metamath Proof Explorer


Theorem wlkiswwlks1

Description: The sequence of vertices in a walk is a walk as word in a pseudograph. (Contributed by Alexander van der Vekens, 20-Jul-2018) (Revised by AV, 9-Apr-2021)

Ref Expression
Assertion wlkiswwlks1 G UPGraph F Walks G P P WWalks G

Proof

Step Hyp Ref Expression
1 wlkn0 F Walks G P P
2 eqid Vtx G = Vtx G
3 eqid iEdg G = iEdg G
4 2 3 upgriswlk G UPGraph F Walks G P F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1
5 simpr G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P P
6 ffz0iswrd P : 0 F Vtx G P Word Vtx G
7 6 3ad2ant2 F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P Word Vtx G
8 7 ad2antlr G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P P Word Vtx G
9 upgruhgr G UPGraph G UHGraph
10 3 uhgrfun G UHGraph Fun iEdg G
11 funfn Fun iEdg G iEdg G Fn dom iEdg G
12 11 biimpi Fun iEdg G iEdg G Fn dom iEdg G
13 9 10 12 3syl G UPGraph iEdg G Fn dom iEdg G
14 13 ad2antlr F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F iEdg G Fn dom iEdg G
15 wrdsymbcl F Word dom iEdg G i 0 ..^ F F i dom iEdg G
16 15 ad4ant14 F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F F i dom iEdg G
17 fnfvelrn iEdg G Fn dom iEdg G F i dom iEdg G iEdg G F i ran iEdg G
18 14 16 17 syl2anc F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F iEdg G F i ran iEdg G
19 edgval Edg G = ran iEdg G
20 18 19 eleqtrrdi F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F iEdg G F i Edg G
21 eleq1 P i P i + 1 = iEdg G F i P i P i + 1 Edg G iEdg G F i Edg G
22 21 eqcoms iEdg G F i = P i P i + 1 P i P i + 1 Edg G iEdg G F i Edg G
23 20 22 syl5ibrcom F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F iEdg G F i = P i P i + 1 P i P i + 1 Edg G
24 23 ralimdva F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F iEdg G F i = P i P i + 1 i 0 ..^ F P i P i + 1 Edg G
25 24 ex F Word dom iEdg G P : 0 F Vtx G G UPGraph i 0 ..^ F iEdg G F i = P i P i + 1 i 0 ..^ F P i P i + 1 Edg G
26 25 com23 F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 G UPGraph i 0 ..^ F P i P i + 1 Edg G
27 26 3impia F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 G UPGraph i 0 ..^ F P i P i + 1 Edg G
28 27 impcom G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 i 0 ..^ F P i P i + 1 Edg G
29 lencl F Word dom iEdg G F 0
30 ffz0hash F 0 P : 0 F Vtx G P = F + 1
31 30 ex F 0 P : 0 F Vtx G P = F + 1
32 oveq1 P = F + 1 P 1 = F + 1 - 1
33 nn0cn F 0 F
34 pncan1 F F + 1 - 1 = F
35 33 34 syl F 0 F + 1 - 1 = F
36 32 35 sylan9eqr F 0 P = F + 1 P 1 = F
37 36 ex F 0 P = F + 1 P 1 = F
38 31 37 syld F 0 P : 0 F Vtx G P 1 = F
39 29 38 syl F Word dom iEdg G P : 0 F Vtx G P 1 = F
40 39 imp F Word dom iEdg G P : 0 F Vtx G P 1 = F
41 40 oveq2d F Word dom iEdg G P : 0 F Vtx G 0 ..^ P 1 = 0 ..^ F
42 41 raleqdv F Word dom iEdg G P : 0 F Vtx G i 0 ..^ P 1 P i P i + 1 Edg G i 0 ..^ F P i P i + 1 Edg G
43 42 3adant3 F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 i 0 ..^ P 1 P i P i + 1 Edg G i 0 ..^ F P i P i + 1 Edg G
44 43 adantl G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 i 0 ..^ P 1 P i P i + 1 Edg G i 0 ..^ F P i P i + 1 Edg G
45 28 44 mpbird G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 i 0 ..^ P 1 P i P i + 1 Edg G
46 45 adantr G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P i 0 ..^ P 1 P i P i + 1 Edg G
47 eqid Edg G = Edg G
48 2 47 iswwlks P WWalks G P P Word Vtx G i 0 ..^ P 1 P i P i + 1 Edg G
49 5 8 46 48 syl3anbrc G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P P WWalks G
50 49 ex G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P P WWalks G
51 50 ex G UPGraph F Word dom iEdg G P : 0 F Vtx G i 0 ..^ F iEdg G F i = P i P i + 1 P P WWalks G
52 4 51 sylbid G UPGraph F Walks G P P P WWalks G
53 1 52 mpdi G UPGraph F Walks G P P WWalks G