Metamath Proof Explorer


Theorem clwlkcompim

Description: Implications for the properties of the components of a closed walk. (Contributed by Alexander van der Vekens, 24-Jun-2018) (Revised by AV, 17-Feb-2021)

Ref Expression
Hypotheses isclwlke.v 𝑉 = ( Vtx ‘ 𝐺 )
isclwlke.i 𝐼 = ( iEdg ‘ 𝐺 )
clwlkcomp.1 𝐹 = ( 1st𝑊 )
clwlkcomp.2 𝑃 = ( 2nd𝑊 )
Assertion clwlkcompim ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) → ( ( 𝐹 ∈ Word dom 𝐼𝑃 : ( 0 ... ( ♯ ‘ 𝐹 ) ) ⟶ 𝑉 ) ∧ ( ∀ 𝑘 ∈ ( 0 ..^ ( ♯ ‘ 𝐹 ) ) if- ( ( 𝑃𝑘 ) = ( 𝑃 ‘ ( 𝑘 + 1 ) ) , ( 𝐼 ‘ ( 𝐹𝑘 ) ) = { ( 𝑃𝑘 ) } , { ( 𝑃𝑘 ) , ( 𝑃 ‘ ( 𝑘 + 1 ) ) } ⊆ ( 𝐼 ‘ ( 𝐹𝑘 ) ) ) ∧ ( 𝑃 ‘ 0 ) = ( 𝑃 ‘ ( ♯ ‘ 𝐹 ) ) ) ) )

Proof

Step Hyp Ref Expression
1 isclwlke.v 𝑉 = ( Vtx ‘ 𝐺 )
2 isclwlke.i 𝐼 = ( iEdg ‘ 𝐺 )
3 clwlkcomp.1 𝐹 = ( 1st𝑊 )
4 clwlkcomp.2 𝑃 = ( 2nd𝑊 )
5 elfvex ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) → 𝐺 ∈ V )
6 clwlks ( ClWalks ‘ 𝐺 ) = { ⟨ 𝑓 , 𝑔 ⟩ ∣ ( 𝑓 ( Walks ‘ 𝐺 ) 𝑔 ∧ ( 𝑔 ‘ 0 ) = ( 𝑔 ‘ ( ♯ ‘ 𝑓 ) ) ) }
7 6 a1i ( 𝐺 ∈ V → ( ClWalks ‘ 𝐺 ) = { ⟨ 𝑓 , 𝑔 ⟩ ∣ ( 𝑓 ( Walks ‘ 𝐺 ) 𝑔 ∧ ( 𝑔 ‘ 0 ) = ( 𝑔 ‘ ( ♯ ‘ 𝑓 ) ) ) } )
8 7 eleq2d ( 𝐺 ∈ V → ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) ↔ 𝑊 ∈ { ⟨ 𝑓 , 𝑔 ⟩ ∣ ( 𝑓 ( Walks ‘ 𝐺 ) 𝑔 ∧ ( 𝑔 ‘ 0 ) = ( 𝑔 ‘ ( ♯ ‘ 𝑓 ) ) ) } ) )
9 elopaelxp ( 𝑊 ∈ { ⟨ 𝑓 , 𝑔 ⟩ ∣ ( 𝑓 ( Walks ‘ 𝐺 ) 𝑔 ∧ ( 𝑔 ‘ 0 ) = ( 𝑔 ‘ ( ♯ ‘ 𝑓 ) ) ) } → 𝑊 ∈ ( V × V ) )
10 9 anim2i ( ( 𝐺 ∈ V ∧ 𝑊 ∈ { ⟨ 𝑓 , 𝑔 ⟩ ∣ ( 𝑓 ( Walks ‘ 𝐺 ) 𝑔 ∧ ( 𝑔 ‘ 0 ) = ( 𝑔 ‘ ( ♯ ‘ 𝑓 ) ) ) } ) → ( 𝐺 ∈ V ∧ 𝑊 ∈ ( V × V ) ) )
11 10 ex ( 𝐺 ∈ V → ( 𝑊 ∈ { ⟨ 𝑓 , 𝑔 ⟩ ∣ ( 𝑓 ( Walks ‘ 𝐺 ) 𝑔 ∧ ( 𝑔 ‘ 0 ) = ( 𝑔 ‘ ( ♯ ‘ 𝑓 ) ) ) } → ( 𝐺 ∈ V ∧ 𝑊 ∈ ( V × V ) ) ) )
12 8 11 sylbid ( 𝐺 ∈ V → ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) → ( 𝐺 ∈ V ∧ 𝑊 ∈ ( V × V ) ) ) )
13 5 12 mpcom ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) → ( 𝐺 ∈ V ∧ 𝑊 ∈ ( V × V ) ) )
14 1 2 3 4 clwlkcomp ( ( 𝐺 ∈ V ∧ 𝑊 ∈ ( V × V ) ) → ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) ↔ ( ( 𝐹 ∈ Word dom 𝐼𝑃 : ( 0 ... ( ♯ ‘ 𝐹 ) ) ⟶ 𝑉 ) ∧ ( ∀ 𝑘 ∈ ( 0 ..^ ( ♯ ‘ 𝐹 ) ) if- ( ( 𝑃𝑘 ) = ( 𝑃 ‘ ( 𝑘 + 1 ) ) , ( 𝐼 ‘ ( 𝐹𝑘 ) ) = { ( 𝑃𝑘 ) } , { ( 𝑃𝑘 ) , ( 𝑃 ‘ ( 𝑘 + 1 ) ) } ⊆ ( 𝐼 ‘ ( 𝐹𝑘 ) ) ) ∧ ( 𝑃 ‘ 0 ) = ( 𝑃 ‘ ( ♯ ‘ 𝐹 ) ) ) ) ) )
15 13 14 syl ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) → ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) ↔ ( ( 𝐹 ∈ Word dom 𝐼𝑃 : ( 0 ... ( ♯ ‘ 𝐹 ) ) ⟶ 𝑉 ) ∧ ( ∀ 𝑘 ∈ ( 0 ..^ ( ♯ ‘ 𝐹 ) ) if- ( ( 𝑃𝑘 ) = ( 𝑃 ‘ ( 𝑘 + 1 ) ) , ( 𝐼 ‘ ( 𝐹𝑘 ) ) = { ( 𝑃𝑘 ) } , { ( 𝑃𝑘 ) , ( 𝑃 ‘ ( 𝑘 + 1 ) ) } ⊆ ( 𝐼 ‘ ( 𝐹𝑘 ) ) ) ∧ ( 𝑃 ‘ 0 ) = ( 𝑃 ‘ ( ♯ ‘ 𝐹 ) ) ) ) ) )
16 15 ibi ( 𝑊 ∈ ( ClWalks ‘ 𝐺 ) → ( ( 𝐹 ∈ Word dom 𝐼𝑃 : ( 0 ... ( ♯ ‘ 𝐹 ) ) ⟶ 𝑉 ) ∧ ( ∀ 𝑘 ∈ ( 0 ..^ ( ♯ ‘ 𝐹 ) ) if- ( ( 𝑃𝑘 ) = ( 𝑃 ‘ ( 𝑘 + 1 ) ) , ( 𝐼 ‘ ( 𝐹𝑘 ) ) = { ( 𝑃𝑘 ) } , { ( 𝑃𝑘 ) , ( 𝑃 ‘ ( 𝑘 + 1 ) ) } ⊆ ( 𝐼 ‘ ( 𝐹𝑘 ) ) ) ∧ ( 𝑃 ‘ 0 ) = ( 𝑃 ‘ ( ♯ ‘ 𝐹 ) ) ) ) )