MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  wlkiswwlks1 Structured version   Visualization version   GIF version

Theorem wlkiswwlks1 26747
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.)
Assertion
Ref Expression
wlkiswwlks1 (𝐺 ∈ UPGraph → (𝐹(Walks‘𝐺)𝑃𝑃 ∈ (WWalks‘𝐺)))

Proof of Theorem wlkiswwlks1
Dummy variable 𝑖 is distinct from all other variables.
StepHypRef Expression
1 wlkn0 26510 . 2 (𝐹(Walks‘𝐺)𝑃𝑃 ≠ ∅)
2 eqid 2621 . . . 4 (Vtx‘𝐺) = (Vtx‘𝐺)
3 eqid 2621 . . . 4 (iEdg‘𝐺) = (iEdg‘𝐺)
42, 3upgriswlk 26531 . . 3 (𝐺 ∈ UPGraph → (𝐹(Walks‘𝐺)𝑃 ↔ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})))
5 simpr 477 . . . . . 6 (((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) ∧ 𝑃 ≠ ∅) → 𝑃 ≠ ∅)
6 ffz0iswrd 13327 . . . . . . . 8 (𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) → 𝑃 ∈ Word (Vtx‘𝐺))
763ad2ant2 1082 . . . . . . 7 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))}) → 𝑃 ∈ Word (Vtx‘𝐺))
87ad2antlr 763 . . . . . 6 (((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) ∧ 𝑃 ≠ ∅) → 𝑃 ∈ Word (Vtx‘𝐺))
9 upgruhgr 25991 . . . . . . . . . . . . . . . . . 18 (𝐺 ∈ UPGraph → 𝐺 ∈ UHGraph )
103uhgrfun 25955 . . . . . . . . . . . . . . . . . 18 (𝐺 ∈ UHGraph → Fun (iEdg‘𝐺))
11 funfn 5916 . . . . . . . . . . . . . . . . . . 19 (Fun (iEdg‘𝐺) ↔ (iEdg‘𝐺) Fn dom (iEdg‘𝐺))
1211biimpi 206 . . . . . . . . . . . . . . . . . 18 (Fun (iEdg‘𝐺) → (iEdg‘𝐺) Fn dom (iEdg‘𝐺))
139, 10, 123syl 18 . . . . . . . . . . . . . . . . 17 (𝐺 ∈ UPGraph → (iEdg‘𝐺) Fn dom (iEdg‘𝐺))
1413ad2antlr 763 . . . . . . . . . . . . . . . 16 ((((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) ∧ 𝐺 ∈ UPGraph ) ∧ 𝑖 ∈ (0..^(#‘𝐹))) → (iEdg‘𝐺) Fn dom (iEdg‘𝐺))
15 wrdsymbcl 13313 . . . . . . . . . . . . . . . . 17 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑖 ∈ (0..^(#‘𝐹))) → (𝐹𝑖) ∈ dom (iEdg‘𝐺))
1615ad4ant14 1292 . . . . . . . . . . . . . . . 16 ((((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) ∧ 𝐺 ∈ UPGraph ) ∧ 𝑖 ∈ (0..^(#‘𝐹))) → (𝐹𝑖) ∈ dom (iEdg‘𝐺))
17 fnfvelrn 6354 . . . . . . . . . . . . . . . 16 (((iEdg‘𝐺) Fn dom (iEdg‘𝐺) ∧ (𝐹𝑖) ∈ dom (iEdg‘𝐺)) → ((iEdg‘𝐺)‘(𝐹𝑖)) ∈ ran (iEdg‘𝐺))
1814, 16, 17syl2anc 693 . . . . . . . . . . . . . . 15 ((((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) ∧ 𝐺 ∈ UPGraph ) ∧ 𝑖 ∈ (0..^(#‘𝐹))) → ((iEdg‘𝐺)‘(𝐹𝑖)) ∈ ran (iEdg‘𝐺))
19 edgval 25935 . . . . . . . . . . . . . . 15 (Edg‘𝐺) = ran (iEdg‘𝐺)
2018, 19syl6eleqr 2711 . . . . . . . . . . . . . 14 ((((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) ∧ 𝐺 ∈ UPGraph ) ∧ 𝑖 ∈ (0..^(#‘𝐹))) → ((iEdg‘𝐺)‘(𝐹𝑖)) ∈ (Edg‘𝐺))
21 eleq1 2688 . . . . . . . . . . . . . . 15 ({(𝑃𝑖), (𝑃‘(𝑖 + 1))} = ((iEdg‘𝐺)‘(𝐹𝑖)) → ({(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺) ↔ ((iEdg‘𝐺)‘(𝐹𝑖)) ∈ (Edg‘𝐺)))
2221eqcoms 2629 . . . . . . . . . . . . . 14 (((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))} → ({(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺) ↔ ((iEdg‘𝐺)‘(𝐹𝑖)) ∈ (Edg‘𝐺)))
2320, 22syl5ibrcom 237 . . . . . . . . . . . . 13 ((((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) ∧ 𝐺 ∈ UPGraph ) ∧ 𝑖 ∈ (0..^(#‘𝐹))) → (((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))} → {(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
2423ralimdva 2961 . . . . . . . . . . . 12 (((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) ∧ 𝐺 ∈ UPGraph ) → (∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))} → ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
2524ex 450 . . . . . . . . . . 11 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) → (𝐺 ∈ UPGraph → (∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))} → ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺))))
2625com23 86 . . . . . . . . . 10 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) → (∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))} → (𝐺 ∈ UPGraph → ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺))))
27263impia 1260 . . . . . . . . 9 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))}) → (𝐺 ∈ UPGraph → ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
2827impcom 446 . . . . . . . 8 ((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) → ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺))
29 lencl 13319 . . . . . . . . . . . . . 14 (𝐹 ∈ Word dom (iEdg‘𝐺) → (#‘𝐹) ∈ ℕ0)
30 ffz0hash 13226 . . . . . . . . . . . . . . . 16 (((#‘𝐹) ∈ ℕ0𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) → (#‘𝑃) = ((#‘𝐹) + 1))
3130ex 450 . . . . . . . . . . . . . . 15 ((#‘𝐹) ∈ ℕ0 → (𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) → (#‘𝑃) = ((#‘𝐹) + 1)))
32 oveq1 6654 . . . . . . . . . . . . . . . . 17 ((#‘𝑃) = ((#‘𝐹) + 1) → ((#‘𝑃) − 1) = (((#‘𝐹) + 1) − 1))
33 nn0cn 11299 . . . . . . . . . . . . . . . . . 18 ((#‘𝐹) ∈ ℕ0 → (#‘𝐹) ∈ ℂ)
34 pncan1 10451 . . . . . . . . . . . . . . . . . 18 ((#‘𝐹) ∈ ℂ → (((#‘𝐹) + 1) − 1) = (#‘𝐹))
3533, 34syl 17 . . . . . . . . . . . . . . . . 17 ((#‘𝐹) ∈ ℕ0 → (((#‘𝐹) + 1) − 1) = (#‘𝐹))
3632, 35sylan9eqr 2677 . . . . . . . . . . . . . . . 16 (((#‘𝐹) ∈ ℕ0 ∧ (#‘𝑃) = ((#‘𝐹) + 1)) → ((#‘𝑃) − 1) = (#‘𝐹))
3736ex 450 . . . . . . . . . . . . . . 15 ((#‘𝐹) ∈ ℕ0 → ((#‘𝑃) = ((#‘𝐹) + 1) → ((#‘𝑃) − 1) = (#‘𝐹)))
3831, 37syld 47 . . . . . . . . . . . . . 14 ((#‘𝐹) ∈ ℕ0 → (𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) → ((#‘𝑃) − 1) = (#‘𝐹)))
3929, 38syl 17 . . . . . . . . . . . . 13 (𝐹 ∈ Word dom (iEdg‘𝐺) → (𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) → ((#‘𝑃) − 1) = (#‘𝐹)))
4039imp 445 . . . . . . . . . . . 12 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) → ((#‘𝑃) − 1) = (#‘𝐹))
4140oveq2d 6663 . . . . . . . . . . 11 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) → (0..^((#‘𝑃) − 1)) = (0..^(#‘𝐹)))
4241raleqdv 3142 . . . . . . . . . 10 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺)) → (∀𝑖 ∈ (0..^((#‘𝑃) − 1)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺) ↔ ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
43423adant3 1080 . . . . . . . . 9 ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))}) → (∀𝑖 ∈ (0..^((#‘𝑃) − 1)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺) ↔ ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
4443adantl 482 . . . . . . . 8 ((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) → (∀𝑖 ∈ (0..^((#‘𝑃) − 1)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺) ↔ ∀𝑖 ∈ (0..^(#‘𝐹)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
4528, 44mpbird 247 . . . . . . 7 ((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) → ∀𝑖 ∈ (0..^((#‘𝑃) − 1)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺))
4645adantr 481 . . . . . 6 (((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) ∧ 𝑃 ≠ ∅) → ∀𝑖 ∈ (0..^((#‘𝑃) − 1)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺))
47 eqid 2621 . . . . . . 7 (Edg‘𝐺) = (Edg‘𝐺)
482, 47iswwlks 26722 . . . . . 6 (𝑃 ∈ (WWalks‘𝐺) ↔ (𝑃 ≠ ∅ ∧ 𝑃 ∈ Word (Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^((#‘𝑃) − 1)){(𝑃𝑖), (𝑃‘(𝑖 + 1))} ∈ (Edg‘𝐺)))
495, 8, 46, 48syl3anbrc 1245 . . . . 5 (((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) ∧ 𝑃 ≠ ∅) → 𝑃 ∈ (WWalks‘𝐺))
5049ex 450 . . . 4 ((𝐺 ∈ UPGraph ∧ (𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))})) → (𝑃 ≠ ∅ → 𝑃 ∈ (WWalks‘𝐺)))
5150ex 450 . . 3 (𝐺 ∈ UPGraph → ((𝐹 ∈ Word dom (iEdg‘𝐺) ∧ 𝑃:(0...(#‘𝐹))⟶(Vtx‘𝐺) ∧ ∀𝑖 ∈ (0..^(#‘𝐹))((iEdg‘𝐺)‘(𝐹𝑖)) = {(𝑃𝑖), (𝑃‘(𝑖 + 1))}) → (𝑃 ≠ ∅ → 𝑃 ∈ (WWalks‘𝐺))))
524, 51sylbid 230 . 2 (𝐺 ∈ UPGraph → (𝐹(Walks‘𝐺)𝑃 → (𝑃 ≠ ∅ → 𝑃 ∈ (WWalks‘𝐺))))
531, 52mpdi 45 1 (𝐺 ∈ UPGraph → (𝐹(Walks‘𝐺)𝑃𝑃 ∈ (WWalks‘𝐺)))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wb 196  wa 384  w3a 1037   = wceq 1482  wcel 1989  wne 2793  wral 2911  c0 3913  {cpr 4177   class class class wbr 4651  dom cdm 5112  ran crn 5113  Fun wfun 5880   Fn wfn 5881  wf 5882  cfv 5886  (class class class)co 6647  cc 9931  0cc0 9933  1c1 9934   + caddc 9936  cmin 10263  0cn0 11289  ...cfz 12323  ..^cfzo 12461  #chash 13112  Word cword 13286  Vtxcvtx 25868  iEdgciedg 25869  Edgcedg 25933   UHGraph cuhgr 25945   UPGraph cupgr 25969  Walkscwlks 26486  WWalkscwwlks 26711
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1721  ax-4 1736  ax-5 1838  ax-6 1887  ax-7 1934  ax-8 1991  ax-9 1998  ax-10 2018  ax-11 2033  ax-12 2046  ax-13 2245  ax-ext 2601  ax-rep 4769  ax-sep 4779  ax-nul 4787  ax-pow 4841  ax-pr 4904  ax-un 6946  ax-cnex 9989  ax-resscn 9990  ax-1cn 9991  ax-icn 9992  ax-addcl 9993  ax-addrcl 9994  ax-mulcl 9995  ax-mulrcl 9996  ax-mulcom 9997  ax-addass 9998  ax-mulass 9999  ax-distr 10000  ax-i2m1 10001  ax-1ne0 10002  ax-1rid 10003  ax-rnegex 10004  ax-rrecex 10005  ax-cnre 10006  ax-pre-lttri 10007  ax-pre-lttrn 10008  ax-pre-ltadd 10009  ax-pre-mulgt0 10010
This theorem depends on definitions:  df-bi 197  df-or 385  df-an 386  df-ifp 1013  df-3or 1038  df-3an 1039  df-tru 1485  df-ex 1704  df-nf 1709  df-sb 1880  df-eu 2473  df-mo 2474  df-clab 2608  df-cleq 2614  df-clel 2617  df-nfc 2752  df-ne 2794  df-nel 2897  df-ral 2916  df-rex 2917  df-reu 2918  df-rmo 2919  df-rab 2920  df-v 3200  df-sbc 3434  df-csb 3532  df-dif 3575  df-un 3577  df-in 3579  df-ss 3586  df-pss 3588  df-nul 3914  df-if 4085  df-pw 4158  df-sn 4176  df-pr 4178  df-tp 4180  df-op 4182  df-uni 4435  df-int 4474  df-iun 4520  df-br 4652  df-opab 4711  df-mpt 4728  df-tr 4751  df-id 5022  df-eprel 5027  df-po 5033  df-so 5034  df-fr 5071  df-we 5073  df-xp 5118  df-rel 5119  df-cnv 5120  df-co 5121  df-dm 5122  df-rn 5123  df-res 5124  df-ima 5125  df-pred 5678  df-ord 5724  df-on 5725  df-lim 5726  df-suc 5727  df-iota 5849  df-fun 5888  df-fn 5889  df-f 5890  df-f1 5891  df-fo 5892  df-f1o 5893  df-fv 5894  df-riota 6608  df-ov 6650  df-oprab 6651  df-mpt2 6652  df-om 7063  df-1st 7165  df-2nd 7166  df-wrecs 7404  df-recs 7465  df-rdg 7503  df-1o 7557  df-2o 7558  df-oadd 7561  df-er 7739  df-map 7856  df-pm 7857  df-en 7953  df-dom 7954  df-sdom 7955  df-fin 7956  df-card 8762  df-cda 8987  df-pnf 10073  df-mnf 10074  df-xr 10075  df-ltxr 10076  df-le 10077  df-sub 10265  df-neg 10266  df-nn 11018  df-2 11076  df-n0 11290  df-xnn0 11361  df-z 11375  df-uz 11685  df-fz 12324  df-fzo 12462  df-hash 13113  df-word 13294  df-edg 25934  df-uhgr 25947  df-upgr 25971  df-wlks 26489  df-wwlks 26716
This theorem is referenced by:  wlklnwwlkln1  26748  wlkiswwlks  26756  wlkiswwlkupgr  26758  elwspths2spth  26856
  Copyright terms: Public domain W3C validator