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

Theorem wwlkextsur 24563
Description: Lemma 3 for wwlkextbij 24565. (Contributed by Alexander van der Vekens, 7-Aug-2018.)
Hypotheses
Ref Expression
wwlkextbij.d  |-  D  =  { w  e. Word  V  |  ( ( # `  w )  =  ( N  +  2 )  /\  ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) }
wwlkextbij.r  |-  R  =  { n  e.  V  |  { ( lastS  `  W
) ,  n }  e.  ran  E }
wwlkextbij.f  |-  F  =  ( t  e.  D  |->  ( lastS  `  t )
)
Assertion
Ref Expression
wwlkextsur  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  F : D -onto-> R )
Distinct variable groups:    t, D    n, E, w    t, N, w    t, R    n, V, t, w    n, W, t, w
Allowed substitution hints:    D( w, n)    R( w, n)    E( t)    F( w, t, n)    N( n)

Proof of Theorem wwlkextsur
Dummy variables  i 
d  r are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 wwlknprop 24518 . . 3  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  ( ( V  e.  _V  /\  E  e.  _V )  /\  ( N  e.  NN0  /\  W  e. Word  V ) ) )
2 simprl 755 . . 3  |-  ( ( ( V  e.  _V  /\  E  e.  _V )  /\  ( N  e.  NN0  /\  W  e. Word  V ) )  ->  N  e.  NN0 )
3 wwlkextbij.d . . . 4  |-  D  =  { w  e. Word  V  |  ( ( # `  w )  =  ( N  +  2 )  /\  ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) }
4 wwlkextbij.r . . . 4  |-  R  =  { n  e.  V  |  { ( lastS  `  W
) ,  n }  e.  ran  E }
5 wwlkextbij.f . . . 4  |-  F  =  ( t  e.  D  |->  ( lastS  `  t )
)
63, 4, 5wwlkextfun 24561 . . 3  |-  ( N  e.  NN0  ->  F : D
--> R )
71, 2, 63syl 20 . 2  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  F : D
--> R )
8 preq2 4113 . . . . . 6  |-  ( n  =  r  ->  { ( lastS  `  W ) ,  n }  =  { ( lastS  `  W ) ,  r } )
98eleq1d 2536 . . . . 5  |-  ( n  =  r  ->  ( { ( lastS  `  W ) ,  n }  e.  ran  E  <->  { ( lastS  `  W
) ,  r }  e.  ran  E ) )
109, 4elrab2 3268 . . . 4  |-  ( r  e.  R  <->  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )
11 wwlknext 24556 . . . . . . . . . . 11  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  r  e.  V  /\  { ( lastS  `  W
) ,  r }  e.  ran  E )  ->  ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) ) )
12113expb 1197 . . . . . . . . . 10  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) ) )
13 wwlknimp 24519 . . . . . . . . . . . . . 14  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  ( W  e. Word  V  /\  ( # `  W )  =  ( N  +  1 )  /\  A. i  e.  ( 0..^ N ) { ( W `  i ) ,  ( W `  ( i  +  1 ) ) }  e.  ran  E
) )
14 s1cl 12593 . . . . . . . . . . . . . . . . . . 19  |-  ( r  e.  V  ->  <" r ">  e. Word  V )
15 swrdccat1 12661 . . . . . . . . . . . . . . . . . . 19  |-  ( ( W  e. Word  V  /\  <" r ">  e. Word  V )  ->  (
( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. )  =  W )
1614, 15sylan2 474 . . . . . . . . . . . . . . . . . 18  |-  ( ( W  e. Word  V  /\  r  e.  V )  ->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. )  =  W )
1716ex 434 . . . . . . . . . . . . . . . . 17  |-  ( W  e. Word  V  ->  (
r  e.  V  -> 
( ( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. )  =  W ) )
1817adantr 465 . . . . . . . . . . . . . . . 16  |-  ( ( W  e. Word  V  /\  ( # `  W )  =  ( N  + 
1 ) )  -> 
( r  e.  V  ->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. )  =  W ) )
19 opeq2 4220 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( N  +  1 )  =  ( # `  W
)  ->  <. 0 ,  ( N  +  1 ) >.  =  <. 0 ,  ( # `  W
) >. )
2019eqcoms 2479 . . . . . . . . . . . . . . . . . . 19  |-  ( (
# `  W )  =  ( N  + 
1 )  ->  <. 0 ,  ( N  + 
1 ) >.  =  <. 0 ,  ( # `  W
) >. )
2120oveq2d 6311 . . . . . . . . . . . . . . . . . 18  |-  ( (
# `  W )  =  ( N  + 
1 )  ->  (
( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  ( ( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. ) )
2221eqeq1d 2469 . . . . . . . . . . . . . . . . 17  |-  ( (
# `  W )  =  ( N  + 
1 )  ->  (
( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  <-> 
( ( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. )  =  W ) )
2322adantl 466 . . . . . . . . . . . . . . . 16  |-  ( ( W  e. Word  V  /\  ( # `  W )  =  ( N  + 
1 ) )  -> 
( ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 )
>. )  =  W  <->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( # `  W
) >. )  =  W ) )
2418, 23sylibrd 234 . . . . . . . . . . . . . . 15  |-  ( ( W  e. Word  V  /\  ( # `  W )  =  ( N  + 
1 ) )  -> 
( r  e.  V  ->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
25243adant3 1016 . . . . . . . . . . . . . 14  |-  ( ( W  e. Word  V  /\  ( # `  W )  =  ( N  + 
1 )  /\  A. i  e.  ( 0..^ N ) { ( W `  i ) ,  ( W `  ( i  +  1 ) ) }  e.  ran  E )  ->  (
r  e.  V  -> 
( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
2613, 25syl 16 . . . . . . . . . . . . 13  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  ( r  e.  V  ->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
2726com12 31 . . . . . . . . . . . 12  |-  ( r  e.  V  ->  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
2827adantr 465 . . . . . . . . . . 11  |-  ( ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E )  ->  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
2928impcom 430 . . . . . . . . . 10  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  (
( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W )
30 lswccats1 12617 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( W  e. Word  V  /\  r  e.  V )  ->  ( lastS  `  ( W concat  <" r "> ) )  =  r )
3130eqcomd 2475 . . . . . . . . . . . . . . . . . . 19  |-  ( ( W  e. Word  V  /\  r  e.  V )  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) )
3231ex 434 . . . . . . . . . . . . . . . . . 18  |-  ( W  e. Word  V  ->  (
r  e.  V  -> 
r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
3332adantl 466 . . . . . . . . . . . . . . . . 17  |-  ( ( N  e.  NN0  /\  W  e. Word  V )  ->  ( r  e.  V  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
3433adantl 466 . . . . . . . . . . . . . . . 16  |-  ( ( ( V  e.  _V  /\  E  e.  _V )  /\  ( N  e.  NN0  /\  W  e. Word  V ) )  ->  ( r  e.  V  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
351, 34syl 16 . . . . . . . . . . . . . . 15  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  ( r  e.  V  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
3635imp 429 . . . . . . . . . . . . . 14  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  r  e.  V )  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) )
3736preq2d 4119 . . . . . . . . . . . . 13  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  r  e.  V )  ->  { ( lastS  `  W ) ,  r }  =  { ( lastS  `  W ) ,  ( lastS  `  ( W concat  <" r "> ) ) } )
3837eleq1d 2536 . . . . . . . . . . . 12  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  r  e.  V )  ->  ( { ( lastS  `  W ) ,  r }  e.  ran  E  <->  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )
3938biimpd 207 . . . . . . . . . . 11  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  r  e.  V )  ->  ( { ( lastS  `  W ) ,  r }  e.  ran  E  ->  { ( lastS  `  W ) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )
4039impr 619 . . . . . . . . . 10  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  { ( lastS  `  W ) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E )
4112, 29, 40jca32 535 . . . . . . . . 9  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  (
( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  (
( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) ) )
4235com12 31 . . . . . . . . . . 11  |-  ( r  e.  V  ->  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
4342adantr 465 . . . . . . . . . 10  |-  ( ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E )  ->  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
4443impcom 430 . . . . . . . . 9  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  r  =  ( lastS  `  ( W concat  <" r "> ) ) )
45 ovex 6320 . . . . . . . . . . 11  |-  ( W concat  <" r "> )  e.  _V
4645a1i 11 . . . . . . . . . 10  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  ( W concat  <" r "> )  e.  _V )
47 eleq1 2539 . . . . . . . . . . . . . . 15  |-  ( d  =  ( W concat  <" r "> )  ->  (
d  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  <->  ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) ) ) )
48 oveq1 6302 . . . . . . . . . . . . . . . . 17  |-  ( d  =  ( W concat  <" r "> )  ->  (
d substr  <. 0 ,  ( N  +  1 )
>. )  =  (
( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. ) )
4948eqeq1d 2469 . . . . . . . . . . . . . . . 16  |-  ( d  =  ( W concat  <" r "> )  ->  (
( d substr  <. 0 ,  ( N  +  1 ) >. )  =  W  <-> 
( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
50 fveq2 5872 . . . . . . . . . . . . . . . . . 18  |-  ( d  =  ( W concat  <" r "> )  ->  ( lastS  `  d )  =  ( lastS  `  ( W concat  <" r "> ) ) )
5150preq2d 4119 . . . . . . . . . . . . . . . . 17  |-  ( d  =  ( W concat  <" r "> )  ->  { ( lastS  `  W ) ,  ( lastS  `  d ) }  =  { ( lastS  `  W ) ,  ( lastS  `  ( W concat  <" r "> ) ) } )
5251eleq1d 2536 . . . . . . . . . . . . . . . 16  |-  ( d  =  ( W concat  <" r "> )  ->  ( { ( lastS  `  W ) ,  ( lastS  `  d
) }  e.  ran  E  <->  { ( lastS  `  W ) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )
5349, 52anbi12d 710 . . . . . . . . . . . . . . 15  |-  ( d  =  ( W concat  <" r "> )  ->  (
( ( d substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  d ) }  e.  ran  E
)  <->  ( ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) ) )
5447, 53anbi12d 710 . . . . . . . . . . . . . 14  |-  ( d  =  ( W concat  <" r "> )  ->  (
( d  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  (
( d substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  d
) }  e.  ran  E ) )  <->  ( ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  (
( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) ) ) )
5550eqeq2d 2481 . . . . . . . . . . . . . 14  |-  ( d  =  ( W concat  <" r "> )  ->  (
r  =  ( lastS  `  d
)  <->  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) )
5654, 55anbi12d 710 . . . . . . . . . . . . 13  |-  ( d  =  ( W concat  <" r "> )  ->  (
( ( d  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  d ) }  e.  ran  E
) )  /\  r  =  ( lastS  `  d ) )  <->  ( ( ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  (
( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )  /\  r  =  ( lastS  `  ( W concat  <" r "> ) ) ) ) )
5756bicomd 201 . . . . . . . . . . . 12  |-  ( d  =  ( W concat  <" r "> )  ->  (
( ( ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )  /\  r  =  ( lastS  `  ( W concat  <" r "> ) ) )  <->  ( (
d  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  d
) }  e.  ran  E ) )  /\  r  =  ( lastS  `  d ) ) ) )
5857adantl 466 . . . . . . . . . . 11  |-  ( ( ( W  e.  ( ( V WWalksN  E ) `  N )  /\  (
r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E ) )  /\  d  =  ( W concat  <" r "> ) )  ->  (
( ( ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )  /\  r  =  ( lastS  `  ( W concat  <" r "> ) ) )  <->  ( (
d  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  d
) }  e.  ran  E ) )  /\  r  =  ( lastS  `  d ) ) ) )
5958biimpd 207 . . . . . . . . . 10  |-  ( ( ( W  e.  ( ( V WWalksN  E ) `  N )  /\  (
r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E ) )  /\  d  =  ( W concat  <" r "> ) )  ->  (
( ( ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )  /\  r  =  ( lastS  `  ( W concat  <" r "> ) ) )  -> 
( ( d  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  d ) }  e.  ran  E
) )  /\  r  =  ( lastS  `  d ) ) ) )
6046, 59spcimedv 3202 . . . . . . . . 9  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  (
( ( ( W concat  <" r "> )  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( ( W concat  <" r "> ) substr  <. 0 ,  ( N  +  1 ) >. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  ( W concat  <" r "> ) ) }  e.  ran  E ) )  /\  r  =  ( lastS  `  ( W concat  <" r "> ) ) )  ->  E. d ( ( d  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  d
) }  e.  ran  E ) )  /\  r  =  ( lastS  `  d ) ) ) )
6141, 44, 60mp2and 679 . . . . . . . 8  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  E. d
( ( d  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  d ) }  e.  ran  E
) )  /\  r  =  ( lastS  `  d ) ) )
62 oveq1 6302 . . . . . . . . . . . . 13  |-  ( w  =  d  ->  (
w substr  <. 0 ,  ( N  +  1 )
>. )  =  (
d substr  <. 0 ,  ( N  +  1 )
>. ) )
6362eqeq1d 2469 . . . . . . . . . . . 12  |-  ( w  =  d  ->  (
( w substr  <. 0 ,  ( N  +  1 ) >. )  =  W  <-> 
( d substr  <. 0 ,  ( N  +  1 ) >. )  =  W ) )
64 fveq2 5872 . . . . . . . . . . . . . 14  |-  ( w  =  d  ->  ( lastS  `  w )  =  ( lastS  `  d ) )
6564preq2d 4119 . . . . . . . . . . . . 13  |-  ( w  =  d  ->  { ( lastS  `  W ) ,  ( lastS  `  w ) }  =  { ( lastS  `  W ) ,  ( lastS  `  d
) } )
6665eleq1d 2536 . . . . . . . . . . . 12  |-  ( w  =  d  ->  ( { ( lastS  `  W ) ,  ( lastS  `  w
) }  e.  ran  E  <->  { ( lastS  `  W ) ,  ( lastS  `  d
) }  e.  ran  E ) )
6763, 66anbi12d 710 . . . . . . . . . . 11  |-  ( w  =  d  ->  (
( ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E )  <->  ( (
d substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  d
) }  e.  ran  E ) ) )
6867elrab 3266 . . . . . . . . . 10  |-  ( d  e.  { w  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E
) }  <->  ( d  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  d ) }  e.  ran  E
) ) )
6968anbi1i 695 . . . . . . . . 9  |-  ( ( d  e.  { w  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E
) }  /\  r  =  ( lastS  `  d ) )  <->  ( ( d  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  d
) }  e.  ran  E ) )  /\  r  =  ( lastS  `  d ) ) )
7069exbii 1644 . . . . . . . 8  |-  ( E. d ( d  e. 
{ w  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) }  /\  r  =  ( lastS  `  d
) )  <->  E. d
( ( d  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  /\  ( ( d substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  d ) }  e.  ran  E
) )  /\  r  =  ( lastS  `  d ) ) )
7161, 70sylibr 212 . . . . . . 7  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  E. d
( d  e.  {
w  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  w
) }  e.  ran  E ) }  /\  r  =  ( lastS  `  d ) ) )
72 df-rex 2823 . . . . . . 7  |-  ( E. d  e.  { w  e.  ( ( V WWalksN  E
) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  +  1 ) >.
)  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E
) } r  =  ( lastS  `  d )  <->  E. d ( d  e. 
{ w  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) }  /\  r  =  ( lastS  `  d
) ) )
7371, 72sylibr 212 . . . . . 6  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  E. d  e.  { w  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) } r  =  ( lastS  `  d
) )
743wwlkextwrd 24560 . . . . . . . 8  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  D  =  { w  e.  (
( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) } )
7574adantr 465 . . . . . . 7  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  D  =  { w  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  + 
1 ) >. )  =  W  /\  { ( lastS  `  W ) ,  ( lastS  `  w ) }  e.  ran  E ) } )
7675rexeqdv 3070 . . . . . 6  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  ( E. d  e.  D  r  =  ( lastS  `  d
)  <->  E. d  e.  {
w  e.  ( ( V WWalksN  E ) `  ( N  +  1 ) )  |  ( ( w substr  <. 0 ,  ( N  +  1 )
>. )  =  W  /\  { ( lastS  `  W
) ,  ( lastS  `  w
) }  e.  ran  E ) } r  =  ( lastS  `  d )
) )
7773, 76mpbird 232 . . . . 5  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  E. d  e.  D  r  =  ( lastS  `  d ) )
78 fveq2 5872 . . . . . . . 8  |-  ( t  =  d  ->  ( lastS  `  t )  =  ( lastS  `  d ) )
79 fvex 5882 . . . . . . . 8  |-  ( lastS  `  d
)  e.  _V
8078, 5, 79fvmpt 5957 . . . . . . 7  |-  ( d  e.  D  ->  ( F `  d )  =  ( lastS  `  d ) )
8180eqeq2d 2481 . . . . . 6  |-  ( d  e.  D  ->  (
r  =  ( F `
 d )  <->  r  =  ( lastS  `  d ) ) )
8281rexbiia 2968 . . . . 5  |-  ( E. d  e.  D  r  =  ( F `  d )  <->  E. d  e.  D  r  =  ( lastS  `  d ) )
8377, 82sylibr 212 . . . 4  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  ( r  e.  V  /\  { ( lastS  `  W ) ,  r }  e.  ran  E
) )  ->  E. d  e.  D  r  =  ( F `  d ) )
8410, 83sylan2b 475 . . 3  |-  ( ( W  e.  ( ( V WWalksN  E ) `  N
)  /\  r  e.  R )  ->  E. d  e.  D  r  =  ( F `  d ) )
8584ralrimiva 2881 . 2  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  A. r  e.  R  E. d  e.  D  r  =  ( F `  d ) )
86 dffo3 6047 . 2  |-  ( F : D -onto-> R  <->  ( F : D --> R  /\  A. r  e.  R  E. d  e.  D  r  =  ( F `  d ) ) )
877, 85, 86sylanbrc 664 1  |-  ( W  e.  ( ( V WWalksN  E ) `  N
)  ->  F : D -onto-> R )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    <-> wb 184    /\ wa 369    /\ w3a 973    = wceq 1379   E.wex 1596    e. wcel 1767   A.wral 2817   E.wrex 2818   {crab 2821   _Vcvv 3118   {cpr 4035   <.cop 4039    |-> cmpt 4511   ran crn 5006   -->wf 5590   -onto->wfo 5592   ` cfv 5594  (class class class)co 6295   0cc0 9504   1c1 9505    + caddc 9507   2c2 10597   NN0cn0 10807  ..^cfzo 11804   #chash 12385  Word cword 12514   lastS clsw 12515   concat cconcat 12516   <"cs1 12517   substr csubstr 12518   WWalksN cwwlkn 24510
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1601  ax-4 1612  ax-5 1680  ax-6 1719  ax-7 1739  ax-8 1769  ax-9 1771  ax-10 1786  ax-11 1791  ax-12 1803  ax-13 1968  ax-ext 2445  ax-rep 4564  ax-sep 4574  ax-nul 4582  ax-pow 4631  ax-pr 4692  ax-un 6587  ax-cnex 9560  ax-resscn 9561  ax-1cn 9562  ax-icn 9563  ax-addcl 9564  ax-addrcl 9565  ax-mulcl 9566  ax-mulrcl 9567  ax-mulcom 9568  ax-addass 9569  ax-mulass 9570  ax-distr 9571  ax-i2m1 9572  ax-1ne0 9573  ax-1rid 9574  ax-rnegex 9575  ax-rrecex 9576  ax-cnre 9577  ax-pre-lttri 9578  ax-pre-lttrn 9579  ax-pre-ltadd 9580  ax-pre-mulgt0 9581
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 974  df-3an 975  df-tru 1382  df-ex 1597  df-nf 1600  df-sb 1712  df-eu 2279  df-mo 2280  df-clab 2453  df-cleq 2459  df-clel 2462  df-nfc 2617  df-ne 2664  df-nel 2665  df-ral 2822  df-rex 2823  df-reu 2824  df-rmo 2825  df-rab 2826  df-v 3120  df-sbc 3337  df-csb 3441  df-dif 3484  df-un 3486  df-in 3488  df-ss 3495  df-pss 3497  df-nul 3791  df-if 3946  df-pw 4018  df-sn 4034  df-pr 4036  df-tp 4038  df-op 4040  df-uni 4252  df-int 4289  df-iun 4333  df-br 4454  df-opab 4512  df-mpt 4513  df-tr 4547  df-eprel 4797  df-id 4801  df-po 4806  df-so 4807  df-fr 4844  df-we 4846  df-ord 4887  df-on 4888  df-lim 4889  df-suc 4890  df-xp 5011  df-rel 5012  df-cnv 5013  df-co 5014  df-dm 5015  df-rn 5016  df-res 5017  df-ima 5018  df-iota 5557  df-fun 5596  df-fn 5597  df-f 5598  df-f1 5599  df-fo 5600  df-f1o 5601  df-fv 5602  df-riota 6256  df-ov 6298  df-oprab 6299  df-mpt2 6300  df-om 6696  df-1st 6795  df-2nd 6796  df-recs 7054  df-rdg 7088  df-1o 7142  df-oadd 7146  df-er 7323  df-map 7434  df-pm 7435  df-en 7529  df-dom 7530  df-sdom 7531  df-fin 7532  df-card 8332  df-cda 8560  df-pnf 9642  df-mnf 9643  df-xr 9644  df-ltxr 9645  df-le 9646  df-sub 9819  df-neg 9820  df-nn 10549  df-2 10606  df-n0 10808  df-z 10877  df-uz 11095  df-fz 11685  df-fzo 11805  df-hash 12386  df-word 12522  df-lsw 12523  df-concat 12524  df-s1 12525  df-substr 12526  df-wwlk 24511  df-wwlkn 24512
This theorem is referenced by:  wwlkextbij0  24564
  Copyright terms: Public domain W3C validator