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

Theorem wwlks2onv 26847
Description: If a length 3 string represents a walk of length 2, its components are vertices. (Contributed by Alexander van der Vekens, 19-Feb-2018.)
Hypothesis
Ref Expression
wwlks2onv.v  |-  V  =  (Vtx `  G )
Assertion
Ref Expression
wwlks2onv  |-  ( ( B  e.  U  /\  <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C ) )  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V ) )

Proof of Theorem wwlks2onv
Dummy variables  a 
c  w  b  g  n are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 2nn0 11309 . . . . . . . 8  |-  2  e.  NN0
2 wwlks2onv.v . . . . . . . . 9  |-  V  =  (Vtx `  G )
32wwlksnon 26738 . . . . . . . 8  |-  ( ( 2  e.  NN0  /\  G  e.  _V )  ->  ( 2 WWalksNOn  G )  =  ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) )
41, 3mpan 706 . . . . . . 7  |-  ( G  e.  _V  ->  (
2 WWalksNOn  G )  =  ( a  e.  V , 
c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `  0
)  =  a  /\  ( w `  2
)  =  c ) } ) )
54oveqd 6667 . . . . . 6  |-  ( G  e.  _V  ->  ( A ( 2 WWalksNOn  G
) C )  =  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C ) )
65eleq2d 2687 . . . . 5  |-  ( G  e.  _V  ->  ( <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C )  <->  <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C ) ) )
7 eqid 2622 . . . . . . 7  |-  ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } )  =  ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } )
87elmpt2cl 6876 . . . . . 6  |-  ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  ->  ( A  e.  V  /\  C  e.  V )
)
9 simprl 794 . . . . . . . 8  |-  ( ( ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  /\  B  e.  U )  /\  ( A  e.  V  /\  C  e.  V )
)  ->  A  e.  V )
10 eqeq2 2633 . . . . . . . . . . . . . . 15  |-  ( a  =  A  ->  (
( w `  0
)  =  a  <->  ( w `  0 )  =  A ) )
1110anbi1d 741 . . . . . . . . . . . . . 14  |-  ( a  =  A  ->  (
( ( w ` 
0 )  =  a  /\  ( w ` 
2 )  =  c )  <->  ( ( w `
 0 )  =  A  /\  ( w `
 2 )  =  c ) ) )
1211rabbidv 3189 . . . . . . . . . . . . 13  |-  ( a  =  A  ->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) }  =  { w  e.  (
2 WWalksN  G )  |  ( ( w `  0
)  =  A  /\  ( w `  2
)  =  c ) } )
13 eqeq2 2633 . . . . . . . . . . . . . . 15  |-  ( c  =  C  ->  (
( w `  2
)  =  c  <->  ( w `  2 )  =  C ) )
1413anbi2d 740 . . . . . . . . . . . . . 14  |-  ( c  =  C  ->  (
( ( w ` 
0 )  =  A  /\  ( w ` 
2 )  =  c )  <->  ( ( w `
 0 )  =  A  /\  ( w `
 2 )  =  C ) ) )
1514rabbidv 3189 . . . . . . . . . . . . 13  |-  ( c  =  C  ->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  A  /\  ( w `
 2 )  =  c ) }  =  { w  e.  (
2 WWalksN  G )  |  ( ( w `  0
)  =  A  /\  ( w `  2
)  =  C ) } )
16 ovex 6678 . . . . . . . . . . . . . 14  |-  ( 2 WWalksN  G )  e.  _V
1716rabex 4813 . . . . . . . . . . . . 13  |-  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  A  /\  ( w `
 2 )  =  C ) }  e.  _V
1812, 15, 7, 17ovmpt2 6796 . . . . . . . . . . . 12  |-  ( ( A  e.  V  /\  C  e.  V )  ->  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  =  {
w  e.  ( 2 WWalksN  G )  |  ( ( w `  0
)  =  A  /\  ( w `  2
)  =  C ) } )
1918eleq2d 2687 . . . . . . . . . . 11  |-  ( ( A  e.  V  /\  C  e.  V )  ->  ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  <->  <" A B C ">  e.  { w  e.  ( 2 WWalksN  G )  |  ( ( w `  0
)  =  A  /\  ( w `  2
)  =  C ) } ) )
20 fveq1 6190 . . . . . . . . . . . . . . 15  |-  ( w  =  <" A B C ">  ->  ( w `  0 )  =  ( <" A B C "> `  0
) )
2120eqeq1d 2624 . . . . . . . . . . . . . 14  |-  ( w  =  <" A B C ">  ->  ( ( w `  0
)  =  A  <->  ( <" A B C "> `  0 )  =  A ) )
22 fveq1 6190 . . . . . . . . . . . . . . 15  |-  ( w  =  <" A B C ">  ->  ( w `  2 )  =  ( <" A B C "> `  2
) )
2322eqeq1d 2624 . . . . . . . . . . . . . 14  |-  ( w  =  <" A B C ">  ->  ( ( w `  2
)  =  C  <->  ( <" A B C "> `  2 )  =  C ) )
2421, 23anbi12d 747 . . . . . . . . . . . . 13  |-  ( w  =  <" A B C ">  ->  ( ( ( w ` 
0 )  =  A  /\  ( w ` 
2 )  =  C )  <->  ( ( <" A B C "> `  0
)  =  A  /\  ( <" A B C "> `  2
)  =  C ) ) )
2524elrab 3363 . . . . . . . . . . . 12  |-  ( <" A B C ">  e.  {
w  e.  ( 2 WWalksN  G )  |  ( ( w `  0
)  =  A  /\  ( w `  2
)  =  C ) }  <->  ( <" A B C ">  e.  ( 2 WWalksN  G )  /\  ( ( <" A B C "> `  0
)  =  A  /\  ( <" A B C "> `  2
)  =  C ) ) )
26 wwlknbp2 26752 . . . . . . . . . . . . . . 15  |-  ( <" A B C ">  e.  ( 2 WWalksN  G )  ->  ( <" A B C ">  e. Word  (Vtx `  G )  /\  ( # `
 <" A B C "> )  =  ( 2  +  1 ) ) )
27 s3fv1 13637 . . . . . . . . . . . . . . . . . . 19  |-  ( B  e.  U  ->  ( <" A B C "> `  1
)  =  B )
2827eqcomd 2628 . . . . . . . . . . . . . . . . . 18  |-  ( B  e.  U  ->  B  =  ( <" A B C "> `  1
) )
2928adantl 482 . . . . . . . . . . . . . . . . 17  |-  ( ( ( <" A B C ">  e. Word  (Vtx
`  G )  /\  ( # `  <" A B C "> )  =  ( 2  +  1 ) )  /\  B  e.  U )  ->  B  =  ( <" A B C "> `  1
) )
30 1ex 10035 . . . . . . . . . . . . . . . . . . . . 21  |-  1  e.  _V
3130tpid2 4304 . . . . . . . . . . . . . . . . . . . 20  |-  1  e.  { 0 ,  1 ,  2 }
32 id 22 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( (
# `  <" A B C "> )  =  ( 2  +  1 )  ->  ( # `
 <" A B C "> )  =  ( 2  +  1 ) )
33 2p1e3 11151 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( 2  +  1 )  =  3
3432, 33syl6eq 2672 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( (
# `  <" A B C "> )  =  ( 2  +  1 )  ->  ( # `
 <" A B C "> )  =  3 )
3534oveq2d 6666 . . . . . . . . . . . . . . . . . . . . 21  |-  ( (
# `  <" A B C "> )  =  ( 2  +  1 )  ->  (
0..^ ( # `  <" A B C "> ) )  =  ( 0..^ 3 ) )
36 fzo0to3tp 12554 . . . . . . . . . . . . . . . . . . . . 21  |-  ( 0..^ 3 )  =  {
0 ,  1 ,  2 }
3735, 36syl6eq 2672 . . . . . . . . . . . . . . . . . . . 20  |-  ( (
# `  <" A B C "> )  =  ( 2  +  1 )  ->  (
0..^ ( # `  <" A B C "> ) )  =  {
0 ,  1 ,  2 } )
3831, 37syl5eleqr 2708 . . . . . . . . . . . . . . . . . . 19  |-  ( (
# `  <" A B C "> )  =  ( 2  +  1 )  ->  1  e.  ( 0..^ ( # `  <" A B C "> )
) )
39 wrdsymbcl 13318 . . . . . . . . . . . . . . . . . . . 20  |-  ( (
<" A B C ">  e. Word  (Vtx `  G )  /\  1  e.  ( 0..^ ( # `  <" A B C "> )
) )  ->  ( <" A B C "> `  1
)  e.  (Vtx `  G ) )
4039, 2syl6eleqr 2712 . . . . . . . . . . . . . . . . . . 19  |-  ( (
<" A B C ">  e. Word  (Vtx `  G )  /\  1  e.  ( 0..^ ( # `  <" A B C "> )
) )  ->  ( <" A B C "> `  1
)  e.  V )
4138, 40sylan2 491 . . . . . . . . . . . . . . . . . 18  |-  ( (
<" A B C ">  e. Word  (Vtx `  G )  /\  ( # `
 <" A B C "> )  =  ( 2  +  1 ) )  -> 
( <" A B C "> `  1
)  e.  V )
4241adantr 481 . . . . . . . . . . . . . . . . 17  |-  ( ( ( <" A B C ">  e. Word  (Vtx
`  G )  /\  ( # `  <" A B C "> )  =  ( 2  +  1 ) )  /\  B  e.  U )  ->  ( <" A B C "> `  1
)  e.  V )
4329, 42eqeltrd 2701 . . . . . . . . . . . . . . . 16  |-  ( ( ( <" A B C ">  e. Word  (Vtx
`  G )  /\  ( # `  <" A B C "> )  =  ( 2  +  1 ) )  /\  B  e.  U )  ->  B  e.  V )
4443ex 450 . . . . . . . . . . . . . . 15  |-  ( (
<" A B C ">  e. Word  (Vtx `  G )  /\  ( # `
 <" A B C "> )  =  ( 2  +  1 ) )  -> 
( B  e.  U  ->  B  e.  V ) )
4526, 44syl 17 . . . . . . . . . . . . . 14  |-  ( <" A B C ">  e.  ( 2 WWalksN  G )  ->  ( B  e.  U  ->  B  e.  V ) )
4645adantr 481 . . . . . . . . . . . . 13  |-  ( (
<" A B C ">  e.  ( 2 WWalksN  G )  /\  (
( <" A B C "> `  0
)  =  A  /\  ( <" A B C "> `  2
)  =  C ) )  ->  ( B  e.  U  ->  B  e.  V ) )
4746a1i 11 . . . . . . . . . . . 12  |-  ( ( A  e.  V  /\  C  e.  V )  ->  ( ( <" A B C ">  e.  ( 2 WWalksN  G )  /\  ( ( <" A B C "> `  0
)  =  A  /\  ( <" A B C "> `  2
)  =  C ) )  ->  ( B  e.  U  ->  B  e.  V ) ) )
4825, 47syl5bi 232 . . . . . . . . . . 11  |-  ( ( A  e.  V  /\  C  e.  V )  ->  ( <" A B C ">  e.  { w  e.  ( 2 WWalksN  G )  |  ( ( w `  0
)  =  A  /\  ( w `  2
)  =  C ) }  ->  ( B  e.  U  ->  B  e.  V ) ) )
4919, 48sylbid 230 . . . . . . . . . 10  |-  ( ( A  e.  V  /\  C  e.  V )  ->  ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  ->  ( B  e.  U  ->  B  e.  V ) ) )
5049impd 447 . . . . . . . . 9  |-  ( ( A  e.  V  /\  C  e.  V )  ->  ( ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  /\  B  e.  U )  ->  B  e.  V ) )
5150impcom 446 . . . . . . . 8  |-  ( ( ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  /\  B  e.  U )  /\  ( A  e.  V  /\  C  e.  V )
)  ->  B  e.  V )
52 simprr 796 . . . . . . . 8  |-  ( ( ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  /\  B  e.  U )  /\  ( A  e.  V  /\  C  e.  V )
)  ->  C  e.  V )
539, 51, 523jca 1242 . . . . . . 7  |-  ( ( ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  /\  B  e.  U )  /\  ( A  e.  V  /\  C  e.  V )
)  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V ) )
5453exp31 630 . . . . . 6  |-  ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  ->  ( B  e.  U  ->  ( ( A  e.  V  /\  C  e.  V
)  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V ) ) ) )
558, 54mpid 44 . . . . 5  |-  ( <" A B C ">  e.  ( A ( a  e.  V ,  c  e.  V  |->  { w  e.  ( 2 WWalksN  G )  |  ( ( w `
 0 )  =  a  /\  ( w `
 2 )  =  c ) } ) C )  ->  ( B  e.  U  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V )
) )
566, 55syl6bi 243 . . . 4  |-  ( G  e.  _V  ->  ( <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C )  -> 
( B  e.  U  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V
) ) ) )
5756com23 86 . . 3  |-  ( G  e.  _V  ->  ( B  e.  U  ->  (
<" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C )  -> 
( A  e.  V  /\  B  e.  V  /\  C  e.  V
) ) ) )
5857impd 447 . 2  |-  ( G  e.  _V  ->  (
( B  e.  U  /\  <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C ) )  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V ) ) )
59 df-wwlksnon 26724 . . . . . . . . . 10  |- WWalksNOn  =  ( n  e.  NN0 , 
g  e.  _V  |->  ( a  e.  (Vtx `  g ) ,  b  e.  (Vtx `  g
)  |->  { w  e.  ( n WWalksN  g )  |  ( ( w `
 0 )  =  a  /\  ( w `
 n )  =  b ) } ) )
6059reldmmpt2 6771 . . . . . . . . 9  |-  Rel  dom WWalksNOn
6160ovprc2 6685 . . . . . . . 8  |-  ( -.  G  e.  _V  ->  ( 2 WWalksNOn  G )  =  (/) )
6261oveqd 6667 . . . . . . 7  |-  ( -.  G  e.  _V  ->  ( A ( 2 WWalksNOn  G
) C )  =  ( A (/) C ) )
63 0ov 6682 . . . . . . 7  |-  ( A
(/) C )  =  (/)
6462, 63syl6eq 2672 . . . . . 6  |-  ( -.  G  e.  _V  ->  ( A ( 2 WWalksNOn  G
) C )  =  (/) )
6564eleq2d 2687 . . . . 5  |-  ( -.  G  e.  _V  ->  (
<" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C )  <->  <" A B C ">  e.  (/) ) )
66 noel 3919 . . . . . 6  |-  -.  <" A B C ">  e.  (/)
6766pm2.21i 116 . . . . 5  |-  ( <" A B C ">  e.  (/)  ->  ( B  e.  U  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V
) ) )
6865, 67syl6bi 243 . . . 4  |-  ( -.  G  e.  _V  ->  (
<" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C )  -> 
( B  e.  U  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V
) ) ) )
6968com23 86 . . 3  |-  ( -.  G  e.  _V  ->  ( B  e.  U  -> 
( <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C )  -> 
( A  e.  V  /\  B  e.  V  /\  C  e.  V
) ) ) )
7069impd 447 . 2  |-  ( -.  G  e.  _V  ->  ( ( B  e.  U  /\  <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C ) )  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V ) ) )
7158, 70pm2.61i 176 1  |-  ( ( B  e.  U  /\  <" A B C ">  e.  ( A ( 2 WWalksNOn  G
) C ) )  ->  ( A  e.  V  /\  B  e.  V  /\  C  e.  V ) )
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    -> wi 4    /\ wa 384    /\ w3a 1037    = wceq 1483    e. wcel 1990   {crab 2916   _Vcvv 3200   (/)c0 3915   {ctp 4181   ` cfv 5888  (class class class)co 6650    |-> cmpt2 6652   0cc0 9936   1c1 9937    + caddc 9939   2c2 11070   3c3 11071   NN0cn0 11292  ..^cfzo 12465   #chash 13117  Word cword 13291   <"cs3 13587  Vtxcvtx 25874   WWalksN cwwlksn 26718   WWalksNOn cwwlksnon 26719
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1722  ax-4 1737  ax-5 1839  ax-6 1888  ax-7 1935  ax-8 1992  ax-9 1999  ax-10 2019  ax-11 2034  ax-12 2047  ax-13 2246  ax-ext 2602  ax-rep 4771  ax-sep 4781  ax-nul 4789  ax-pow 4843  ax-pr 4906  ax-un 6949  ax-cnex 9992  ax-resscn 9993  ax-1cn 9994  ax-icn 9995  ax-addcl 9996  ax-addrcl 9997  ax-mulcl 9998  ax-mulrcl 9999  ax-mulcom 10000  ax-addass 10001  ax-mulass 10002  ax-distr 10003  ax-i2m1 10004  ax-1ne0 10005  ax-1rid 10006  ax-rnegex 10007  ax-rrecex 10008  ax-cnre 10009  ax-pre-lttri 10010  ax-pre-lttrn 10011  ax-pre-ltadd 10012  ax-pre-mulgt0 10013
This theorem depends on definitions:  df-bi 197  df-or 385  df-an 386  df-3or 1038  df-3an 1039  df-tru 1486  df-ex 1705  df-nf 1710  df-sb 1881  df-eu 2474  df-mo 2475  df-clab 2609  df-cleq 2615  df-clel 2618  df-nfc 2753  df-ne 2795  df-nel 2898  df-ral 2917  df-rex 2918  df-reu 2919  df-rab 2921  df-v 3202  df-sbc 3436  df-csb 3534  df-dif 3577  df-un 3579  df-in 3581  df-ss 3588  df-pss 3590  df-nul 3916  df-if 4087  df-pw 4160  df-sn 4178  df-pr 4180  df-tp 4182  df-op 4184  df-uni 4437  df-int 4476  df-iun 4522  df-br 4654  df-opab 4713  df-mpt 4730  df-tr 4753  df-id 5024  df-eprel 5029  df-po 5035  df-so 5036  df-fr 5073  df-we 5075  df-xp 5120  df-rel 5121  df-cnv 5122  df-co 5123  df-dm 5124  df-rn 5125  df-res 5126  df-ima 5127  df-pred 5680  df-ord 5726  df-on 5727  df-lim 5728  df-suc 5729  df-iota 5851  df-fun 5890  df-fn 5891  df-f 5892  df-f1 5893  df-fo 5894  df-f1o 5895  df-fv 5896  df-riota 6611  df-ov 6653  df-oprab 6654  df-mpt2 6655  df-om 7066  df-1st 7168  df-2nd 7169  df-wrecs 7407  df-recs 7468  df-rdg 7506  df-1o 7560  df-oadd 7564  df-er 7742  df-map 7859  df-pm 7860  df-en 7956  df-dom 7957  df-sdom 7958  df-fin 7959  df-card 8765  df-pnf 10076  df-mnf 10077  df-xr 10078  df-ltxr 10079  df-le 10080  df-sub 10268  df-neg 10269  df-nn 11021  df-2 11079  df-3 11080  df-n0 11293  df-z 11378  df-uz 11688  df-fz 12327  df-fzo 12466  df-hash 13118  df-word 13299  df-concat 13301  df-s1 13302  df-s2 13593  df-s3 13594  df-wwlks 26722  df-wwlksn 26723  df-wwlksnon 26724
This theorem is referenced by:  frgr2wwlkeqm  27195
  Copyright terms: Public domain W3C validator