Metamath Proof Explorer


Theorem clwwlknccat

Description: The concatenation of two words representing closed walks anchored at the same vertex represents a closed walk with a length which is the sum of the lengths of the two walks. The resulting walk is a "double loop", starting at the common vertex, coming back to the common vertex by the first walk, following the second walk and finally coming back to the common vertex again. (Contributed by AV, 24-Apr-2022)

Ref Expression
Assertion clwwlknccat A M ClWWalksN G B N ClWWalksN G A 0 = B 0 A ++ B M + N ClWWalksN G

Proof

Step Hyp Ref Expression
1 isclwwlkn A M ClWWalksN G A ClWWalks G A = M
2 isclwwlkn B N ClWWalksN G B ClWWalks G B = N
3 biid A 0 = B 0 A 0 = B 0
4 simpl A ClWWalks G A = M A ClWWalks G
5 simpl B ClWWalks G B = N B ClWWalks G
6 id A 0 = B 0 A 0 = B 0
7 clwwlkccat A ClWWalks G B ClWWalks G A 0 = B 0 A ++ B ClWWalks G
8 4 5 6 7 syl3an A ClWWalks G A = M B ClWWalks G B = N A 0 = B 0 A ++ B ClWWalks G
9 1 2 3 8 syl3anb A M ClWWalksN G B N ClWWalksN G A 0 = B 0 A ++ B ClWWalks G
10 eqid Vtx G = Vtx G
11 10 clwwlknwrd A M ClWWalksN G A Word Vtx G
12 10 clwwlknwrd B N ClWWalksN G B Word Vtx G
13 ccatlen A Word Vtx G B Word Vtx G A ++ B = A + B
14 11 12 13 syl2an A M ClWWalksN G B N ClWWalksN G A ++ B = A + B
15 clwwlknlen A M ClWWalksN G A = M
16 clwwlknlen B N ClWWalksN G B = N
17 15 16 oveqan12d A M ClWWalksN G B N ClWWalksN G A + B = M + N
18 14 17 eqtrd A M ClWWalksN G B N ClWWalksN G A ++ B = M + N
19 18 3adant3 A M ClWWalksN G B N ClWWalksN G A 0 = B 0 A ++ B = M + N
20 isclwwlkn A ++ B M + N ClWWalksN G A ++ B ClWWalks G A ++ B = M + N
21 9 19 20 sylanbrc A M ClWWalksN G B N ClWWalksN G A 0 = B 0 A ++ B M + N ClWWalksN G