Users' Mathboxes Mathbox for Alexander van der Vekens < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  clwlkf1clwwlk Structured version   Unicode version

Theorem clwlkf1clwwlk 30520
Description: There is a one-to-one function between the set of closed walks (defined as words) of length n and the set of closed walks of length n (in an undirected simple graph). (Contributed by Alexander van der Vekens, 5-Jul-2018.)
Hypotheses
Ref Expression
clwlkfclwwlk.1  |-  A  =  ( 1st `  c
)
clwlkfclwwlk.2  |-  B  =  ( 2nd `  c
)
clwlkfclwwlk.c  |-  C  =  { c  e.  ( V ClWalks  E )  |  (
# `  A )  =  N }
clwlkfclwwlk.f  |-  F  =  ( c  e.  C  |->  ( B substr  <. 0 ,  ( # `  A
) >. ) )
Assertion
Ref Expression
clwlkf1clwwlk  |-  ( ( V USGrph  E  /\  V  e. 
Fin  /\  N  e.  Prime )  ->  F : C -1-1-> ( ( V ClWWalksN  E ) `  N
) )
Distinct variable groups:    E, c    N, c    V, c    C, c    F, c
Allowed substitution hints:    A( c)    B( c)

Proof of Theorem clwlkf1clwwlk
Dummy variables  i  w  u are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 clwlkfclwwlk.1 . . 3  |-  A  =  ( 1st `  c
)
2 clwlkfclwwlk.2 . . 3  |-  B  =  ( 2nd `  c
)
3 clwlkfclwwlk.c . . 3  |-  C  =  { c  e.  ( V ClWalks  E )  |  (
# `  A )  =  N }
4 clwlkfclwwlk.f . . 3  |-  F  =  ( c  e.  C  |->  ( B substr  <. 0 ,  ( # `  A
) >. ) )
51, 2, 3, 4clwlkfclwwlk 30514 . 2  |-  ( ( V USGrph  E  /\  V  e. 
Fin  /\  N  e.  Prime )  ->  F : C
--> ( ( V ClWWalksN  E ) `
 N ) )
6 simprl 755 . . . . . . 7  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  u  e.  C )
7 ovex 6114 . . . . . . 7  |-  ( ( 2nd `  u ) substr  <. 0 ,  ( # `  ( 1st `  u
) ) >. )  e.  _V
8 fveq2 5689 . . . . . . . . . 10  |-  ( c  =  u  ->  ( 2nd `  c )  =  ( 2nd `  u
) )
92, 8syl5eq 2485 . . . . . . . . 9  |-  ( c  =  u  ->  B  =  ( 2nd `  u
) )
10 fveq2 5689 . . . . . . . . . . . 12  |-  ( c  =  u  ->  ( 1st `  c )  =  ( 1st `  u
) )
111, 10syl5eq 2485 . . . . . . . . . . 11  |-  ( c  =  u  ->  A  =  ( 1st `  u
) )
1211fveq2d 5693 . . . . . . . . . 10  |-  ( c  =  u  ->  ( # `
 A )  =  ( # `  ( 1st `  u ) ) )
1312opeq2d 4064 . . . . . . . . 9  |-  ( c  =  u  ->  <. 0 ,  ( # `  A
) >.  =  <. 0 ,  ( # `  ( 1st `  u ) )
>. )
149, 13oveq12d 6107 . . . . . . . 8  |-  ( c  =  u  ->  ( B substr  <. 0 ,  (
# `  A ) >. )  =  ( ( 2nd `  u ) substr  <. 0 ,  ( # `  ( 1st `  u
) ) >. )
)
1514, 4fvmptg 5770 . . . . . . 7  |-  ( ( u  e.  C  /\  ( ( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  e.  _V )  ->  ( F `  u
)  =  ( ( 2nd `  u ) substr  <. 0 ,  ( # `  ( 1st `  u
) ) >. )
)
166, 7, 15sylancl 662 . . . . . 6  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( F `  u )  =  ( ( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
) )
17 simpr 461 . . . . . . . . 9  |-  ( ( u  e.  C  /\  w  e.  C )  ->  w  e.  C )
18 ovex 6114 . . . . . . . . 9  |-  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )  e.  _V
1917, 18jctir 538 . . . . . . . 8  |-  ( ( u  e.  C  /\  w  e.  C )  ->  ( w  e.  C  /\  ( ( 2nd `  w
) substr  <. 0 ,  (
# `  ( 1st `  w ) ) >.
)  e.  _V )
)
2019adantl 466 . . . . . . 7  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( w  e.  C  /\  (
( 2nd `  w
) substr  <. 0 ,  (
# `  ( 1st `  w ) ) >.
)  e.  _V )
)
21 fveq2 5689 . . . . . . . . . 10  |-  ( c  =  w  ->  ( 2nd `  c )  =  ( 2nd `  w
) )
222, 21syl5eq 2485 . . . . . . . . 9  |-  ( c  =  w  ->  B  =  ( 2nd `  w
) )
23 fveq2 5689 . . . . . . . . . . . 12  |-  ( c  =  w  ->  ( 1st `  c )  =  ( 1st `  w
) )
241, 23syl5eq 2485 . . . . . . . . . . 11  |-  ( c  =  w  ->  A  =  ( 1st `  w
) )
2524fveq2d 5693 . . . . . . . . . 10  |-  ( c  =  w  ->  ( # `
 A )  =  ( # `  ( 1st `  w ) ) )
2625opeq2d 4064 . . . . . . . . 9  |-  ( c  =  w  ->  <. 0 ,  ( # `  A
) >.  =  <. 0 ,  ( # `  ( 1st `  w ) )
>. )
2722, 26oveq12d 6107 . . . . . . . 8  |-  ( c  =  w  ->  ( B substr  <. 0 ,  (
# `  A ) >. )  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)
2827, 4fvmptg 5770 . . . . . . 7  |-  ( ( w  e.  C  /\  ( ( 2nd `  w
) substr  <. 0 ,  (
# `  ( 1st `  w ) ) >.
)  e.  _V )  ->  ( F `  w
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)
2920, 28syl 16 . . . . . 6  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( F `  w )  =  ( ( 2nd `  w
) substr  <. 0 ,  (
# `  ( 1st `  w ) ) >.
) )
3016, 29eqeq12d 2455 . . . . 5  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( ( F `  u )  =  ( F `  w )  <->  ( ( 2nd `  u ) substr  <. 0 ,  ( # `  ( 1st `  u ) )
>. )  =  (
( 2nd `  w
) substr  <. 0 ,  (
# `  ( 1st `  w ) ) >.
) ) )
311, 2, 3, 4clwlkfclwwlk1hashn 30511 . . . . . . . . . 10  |-  ( w  e.  C  ->  ( # `
 ( 1st `  w
) )  =  N )
3231eqcomd 2446 . . . . . . . . 9  |-  ( w  e.  C  ->  N  =  ( # `  ( 1st `  w ) ) )
3332adantl 466 . . . . . . . 8  |-  ( ( u  e.  C  /\  w  e.  C )  ->  N  =  ( # `  ( 1st `  w
) ) )
3433ad2antlr 726 . . . . . . 7  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  N  =  ( # `  ( 1st `  w ) ) )
35 prmnn 13764 . . . . . . . . . . 11  |-  ( N  e.  Prime  ->  N  e.  NN )
36353ad2ant3 1011 . . . . . . . . . 10  |-  ( ( V USGrph  E  /\  V  e. 
Fin  /\  N  e.  Prime )  ->  N  e.  NN )
3736adantr 465 . . . . . . . . 9  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  N  e.  NN )
3817adantl 466 . . . . . . . . 9  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  w  e.  C )
391, 2, 3, 4clwlkf1clwwlklem 30519 . . . . . . . . 9  |-  ( ( N  e.  NN  /\  u  e.  C  /\  w  e.  C )  ->  ( ( ( 2nd `  u ) substr  <. 0 ,  ( # `  ( 1st `  u ) )
>. )  =  (
( 2nd `  w
) substr  <. 0 ,  (
# `  ( 1st `  w ) ) >.
)  ->  A. i  e.  ( 0 ... N
) ( ( 2nd `  u ) `  i
)  =  ( ( 2nd `  w ) `
 i ) ) )
4037, 6, 38, 39syl3anc 1218 . . . . . . . 8  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )  ->  A. i  e.  ( 0 ... N ) ( ( 2nd `  u
) `  i )  =  ( ( 2nd `  w ) `  i
) ) )
4140imp 429 . . . . . . 7  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  A. i  e.  ( 0 ... N
) ( ( 2nd `  u ) `  i
)  =  ( ( 2nd `  w ) `
 i ) )
42 simpll1 1027 . . . . . . . 8  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  V USGrph  E )
43 elrabi 3112 . . . . . . . . . . . 12  |-  ( u  e.  { c  e.  ( V ClWalks  E )  |  ( # `  A
)  =  N }  ->  u  e.  ( V ClWalks  E ) )
44 clwlkswlks 30420 . . . . . . . . . . . 12  |-  ( u  e.  ( V ClWalks  E
)  ->  u  e.  ( V Walks  E ) )
4543, 44syl 16 . . . . . . . . . . 11  |-  ( u  e.  { c  e.  ( V ClWalks  E )  |  ( # `  A
)  =  N }  ->  u  e.  ( V Walks 
E ) )
4645, 3eleq2s 2533 . . . . . . . . . 10  |-  ( u  e.  C  ->  u  e.  ( V Walks  E ) )
47 elrabi 3112 . . . . . . . . . . . 12  |-  ( w  e.  { c  e.  ( V ClWalks  E )  |  ( # `  A
)  =  N }  ->  w  e.  ( V ClWalks  E ) )
48 clwlkswlks 30420 . . . . . . . . . . . 12  |-  ( w  e.  ( V ClWalks  E
)  ->  w  e.  ( V Walks  E ) )
4947, 48syl 16 . . . . . . . . . . 11  |-  ( w  e.  { c  e.  ( V ClWalks  E )  |  ( # `  A
)  =  N }  ->  w  e.  ( V Walks 
E ) )
5049, 3eleq2s 2533 . . . . . . . . . 10  |-  ( w  e.  C  ->  w  e.  ( V Walks  E ) )
5146, 50anim12i 566 . . . . . . . . 9  |-  ( ( u  e.  C  /\  w  e.  C )  ->  ( u  e.  ( V Walks  E )  /\  w  e.  ( V Walks  E ) ) )
5251ad2antlr 726 . . . . . . . 8  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  ( u  e.  ( V Walks  E )  /\  w  e.  ( V Walks  E ) ) )
531, 2, 3, 4clwlkfclwwlk1hashn 30511 . . . . . . . . . . 11  |-  ( u  e.  C  ->  ( # `
 ( 1st `  u
) )  =  N )
5453eqcomd 2446 . . . . . . . . . 10  |-  ( u  e.  C  ->  N  =  ( # `  ( 1st `  u ) ) )
5554adantr 465 . . . . . . . . 9  |-  ( ( u  e.  C  /\  w  e.  C )  ->  N  =  ( # `  ( 1st `  u
) ) )
5655ad2antlr 726 . . . . . . . 8  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  N  =  ( # `  ( 1st `  u ) ) )
57 usg2wlkeq 30286 . . . . . . . 8  |-  ( ( V USGrph  E  /\  (
u  e.  ( V Walks 
E )  /\  w  e.  ( V Walks  E ) )  /\  N  =  ( # `  ( 1st `  u ) ) )  ->  ( u  =  w  <->  ( N  =  ( # `  ( 1st `  w ) )  /\  A. i  e.  ( 0 ... N
) ( ( 2nd `  u ) `  i
)  =  ( ( 2nd `  w ) `
 i ) ) ) )
5842, 52, 56, 57syl3anc 1218 . . . . . . 7  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  ( u  =  w  <->  ( N  =  ( # `  ( 1st `  w ) )  /\  A. i  e.  ( 0 ... N
) ( ( 2nd `  u ) `  i
)  =  ( ( 2nd `  w ) `
 i ) ) ) )
5934, 41, 58mpbir2and 913 . . . . . 6  |-  ( ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  ( u  e.  C  /\  w  e.  C
) )  /\  (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )
)  ->  u  =  w )
6059ex 434 . . . . 5  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( (
( 2nd `  u
) substr  <. 0 ,  (
# `  ( 1st `  u ) ) >.
)  =  ( ( 2nd `  w ) substr  <. 0 ,  ( # `  ( 1st `  w
) ) >. )  ->  u  =  w ) )
6130, 60sylbid 215 . . . 4  |-  ( ( ( V USGrph  E  /\  V  e.  Fin  /\  N  e.  Prime )  /\  (
u  e.  C  /\  w  e.  C )
)  ->  ( ( F `  u )  =  ( F `  w )  ->  u  =  w ) )
6261ex 434 . . 3  |-  ( ( V USGrph  E  /\  V  e. 
Fin  /\  N  e.  Prime )  ->  ( (
u  e.  C  /\  w  e.  C )  ->  ( ( F `  u )  =  ( F `  w )  ->  u  =  w ) ) )
6362ralrimivv 2805 . 2  |-  ( ( V USGrph  E  /\  V  e. 
Fin  /\  N  e.  Prime )  ->  A. u  e.  C  A. w  e.  C  ( ( F `  u )  =  ( F `  w )  ->  u  =  w ) )
64 dff13 5969 . 2  |-  ( F : C -1-1-> ( ( V ClWWalksN  E ) `  N
)  <->  ( F : C
--> ( ( V ClWWalksN  E ) `
 N )  /\  A. u  e.  C  A. w  e.  C  (
( F `  u
)  =  ( F `
 w )  ->  u  =  w )
) )
655, 63, 64sylanbrc 664 1  |-  ( ( V USGrph  E  /\  V  e. 
Fin  /\  N  e.  Prime )  ->  F : C -1-1-> ( ( V ClWWalksN  E ) `  N
) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    <-> wb 184    /\ wa 369    /\ w3a 965    = wceq 1369    e. wcel 1756   A.wral 2713   {crab 2717   _Vcvv 2970   <.cop 3881   class class class wbr 4290    e. cmpt 4348   -->wf 5412   -1-1->wf1 5413   ` cfv 5416  (class class class)co 6089   1stc1st 6573   2ndc2nd 6574   Fincfn 7308   0cc0 9280   NNcn 10320   ...cfz 11435   #chash 12101   substr csubstr 12223   Primecprime 13761   USGrph cusg 23262   Walks cwalk 23403   ClWalks cclwlk 30409   ClWWalksN cclwwlkn 30411
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1591  ax-4 1602  ax-5 1670  ax-6 1708  ax-7 1728  ax-8 1758  ax-9 1760  ax-10 1775  ax-11 1780  ax-12 1792  ax-13 1943  ax-ext 2422  ax-rep 4401  ax-sep 4411  ax-nul 4419  ax-pow 4468  ax-pr 4529  ax-un 6370  ax-cnex 9336  ax-resscn 9337  ax-1cn 9338  ax-icn 9339  ax-addcl 9340  ax-addrcl 9341  ax-mulcl 9342  ax-mulrcl 9343  ax-mulcom 9344  ax-addass 9345  ax-mulass 9346  ax-distr 9347  ax-i2m1 9348  ax-1ne0 9349  ax-1rid 9350  ax-rnegex 9351  ax-rrecex 9352  ax-cnre 9353  ax-pre-lttri 9354  ax-pre-lttrn 9355  ax-pre-ltadd 9356  ax-pre-mulgt0 9357
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 966  df-3an 967  df-tru 1372  df-ex 1587  df-nf 1590  df-sb 1701  df-eu 2257  df-mo 2258  df-clab 2428  df-cleq 2434  df-clel 2437  df-nfc 2566  df-ne 2606  df-nel 2607  df-ral 2718  df-rex 2719  df-reu 2720  df-rmo 2721  df-rab 2722  df-v 2972  df-sbc 3185  df-csb 3287  df-dif 3329  df-un 3331  df-in 3333  df-ss 3340  df-pss 3342  df-nul 3636  df-if 3790  df-pw 3860  df-sn 3876  df-pr 3878  df-tp 3880  df-op 3882  df-uni 4090  df-int 4127  df-iun 4171  df-br 4291  df-opab 4349  df-mpt 4350  df-tr 4384  df-eprel 4630  df-id 4634  df-po 4639  df-so 4640  df-fr 4677  df-we 4679  df-ord 4720  df-on 4721  df-lim 4722  df-suc 4723  df-xp 4844  df-rel 4845  df-cnv 4846  df-co 4847  df-dm 4848  df-rn 4849  df-res 4850  df-ima 4851  df-iota 5379  df-fun 5418  df-fn 5419  df-f 5420  df-f1 5421  df-fo 5422  df-f1o 5423  df-fv 5424  df-riota 6050  df-ov 6092  df-oprab 6093  df-mpt2 6094  df-om 6475  df-1st 6575  df-2nd 6576  df-recs 6830  df-rdg 6864  df-1o 6918  df-2o 6919  df-oadd 6922  df-er 7099  df-map 7214  df-pm 7215  df-en 7309  df-dom 7310  df-sdom 7311  df-fin 7312  df-card 8107  df-cda 8335  df-pnf 9418  df-mnf 9419  df-xr 9420  df-ltxr 9421  df-le 9422  df-sub 9595  df-neg 9596  df-nn 10321  df-2 10378  df-n0 10578  df-z 10645  df-uz 10860  df-fz 11436  df-fzo 11547  df-hash 12102  df-word 12227  df-lsw 12228  df-substr 12231  df-dvds 13534  df-prm 13762  df-usgra 23264  df-wlk 23413  df-clwlk 30412  df-clwwlk 30413  df-clwwlkn 30414
This theorem is referenced by:  clwlkf1oclwwlk  30521
  Copyright terms: Public domain W3C validator