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

Theorem numclwwlkqhash 30828
Description: In a k-regular graph, the size of the set of walks of length n starting with a fixed vertex and ending not at this vertex is the difference between k to the power of n and the size of the set of walks of length n starting with this vertex and ending at this vertex. (Contributed by Alexander van der Vekens, 30-Sep-2018.)
Hypotheses
Ref Expression
numclwwlk.c  |-  C  =  ( n  e.  NN0  |->  ( ( V ClWWalksN  E ) `
 n ) )
numclwwlk.f  |-  F  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  ( C `  n )  |  ( w ` 
0 )  =  v } )
numclwwlk.g  |-  G  =  ( v  e.  V ,  n  e.  ( ZZ>=
`  2 )  |->  { w  e.  ( C `
 n )  |  ( ( w ` 
0 )  =  v  /\  ( w `  ( n  -  2
) )  =  ( w `  0 ) ) } )
numclwwlk.q  |-  Q  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  (
( V WWalksN  E ) `  n )  |  ( ( w `  0
)  =  v  /\  ( lastS  `  w )  =/=  v ) } )
Assertion
Ref Expression
numclwwlkqhash  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  ( X Q N ) )  =  ( ( K ^ N )  -  ( # `  ( X F N ) ) ) )
Distinct variable groups:    n, E    n, N    n, V    w, C    w, N    C, n, v, w    v, N    n, X, v, w    v, V   
w, E    w, V    w, F    w, Q    w, K    w, G    v, E
Allowed substitution hints:    Q( v, n)    F( v, n)    G( v, n)    K( v, n)

Proof of Theorem numclwwlkqhash
Dummy variable  f is distinct from all other variables.
StepHypRef Expression
1 nnnn0 10684 . . . . . 6  |-  ( N  e.  NN  ->  N  e.  NN0 )
21anim2i 569 . . . . 5  |-  ( ( X  e.  V  /\  N  e.  NN )  ->  ( X  e.  V  /\  N  e.  NN0 ) )
32adantl 466 . . . 4  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( X  e.  V  /\  N  e.  NN0 ) )
4 numclwwlk.c . . . . 5  |-  C  =  ( n  e.  NN0  |->  ( ( V ClWWalksN  E ) `
 n ) )
5 numclwwlk.f . . . . 5  |-  F  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  ( C `  n )  |  ( w ` 
0 )  =  v } )
6 numclwwlk.g . . . . 5  |-  G  =  ( v  e.  V ,  n  e.  ( ZZ>=
`  2 )  |->  { w  e.  ( C `
 n )  |  ( ( w ` 
0 )  =  v  /\  ( w `  ( n  -  2
) )  =  ( w `  0 ) ) } )
7 numclwwlk.q . . . . 5  |-  Q  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  (
( V WWalksN  E ) `  n )  |  ( ( w `  0
)  =  v  /\  ( lastS  `  w )  =/=  v ) } )
84, 5, 6, 7numclwwlkovq 30827 . . . 4  |-  ( ( X  e.  V  /\  N  e.  NN0 )  -> 
( X Q N )  =  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( w `
 0 )  =  X  /\  ( lastS  `  w
)  =/=  X ) } )
93, 8syl 16 . . 3  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( X Q N )  =  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( w `
 0 )  =  X  /\  ( lastS  `  w
)  =/=  X ) } )
109fveq2d 5790 . 2  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  ( X Q N ) )  =  ( # `  {
w  e.  ( ( V WWalksN  E ) `  N
)  |  ( ( w `  0 )  =  X  /\  ( lastS  `  w )  =/=  X
) } ) )
11 eqid 2451 . . 3  |-  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( w `
 0 )  =  X  /\  ( lastS  `  w
)  =/=  X ) }  =  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( w `
 0 )  =  X  /\  ( lastS  `  w
)  =/=  X ) }
12 eqid 2451 . . 3  |-  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) }  =  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) }
1311, 12clwlknclwlkdifnum 30714 . 2  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( w `
 0 )  =  X  /\  ( lastS  `  w
)  =/=  X ) } )  =  ( ( K ^ N
)  -  ( # `  { w  e.  ( ( V WWalksN  E ) `  N )  |  ( ( lastS  `  w )  =  ( w ` 
0 )  /\  (
w `  0 )  =  X ) } ) ) )
14 fvex 5796 . . . . . . . 8  |-  ( ( V ClWWalksN  E ) `  N
)  e.  _V
1514rabex 4538 . . . . . . 7  |-  { w  e.  ( ( V ClWWalksN  E ) `
 N )  |  ( w `  0
)  =  X }  e.  _V
1615a1i 11 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  { w  e.  (
( V ClWWalksN  E ) `  N )  |  ( w `  0 )  =  X }  e.  _V )
17 fvex 5796 . . . . . . 7  |-  ( ( V WWalksN  E ) `  N
)  e.  _V
1817rabex 4538 . . . . . 6  |-  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) }  e.  _V
1916, 18jctil 537 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) }  e.  _V  /\  { w  e.  ( ( V ClWWalksN  E ) `  N
)  |  ( w `
 0 )  =  X }  e.  _V ) )
20 rusisusgra 30683 . . . . . . . . 9  |-  ( <. V ,  E >. RegUSGrph  K  ->  V USGrph  E )
21 usgrav 23402 . . . . . . . . 9  |-  ( V USGrph  E  ->  ( V  e. 
_V  /\  E  e.  _V ) )
22 simpll 753 . . . . . . . . . . 11  |-  ( ( ( V  e.  _V  /\  E  e.  _V )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  V  e.  _V )
23 simpr 461 . . . . . . . . . . . 12  |-  ( ( V  e.  _V  /\  E  e.  _V )  ->  E  e.  _V )
2423adantr 465 . . . . . . . . . . 11  |-  ( ( ( V  e.  _V  /\  E  e.  _V )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  E  e.  _V )
25 simpr 461 . . . . . . . . . . . 12  |-  ( ( X  e.  V  /\  N  e.  NN )  ->  N  e.  NN )
2625adantl 466 . . . . . . . . . . 11  |-  ( ( ( V  e.  _V  /\  E  e.  _V )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  N  e.  NN )
2722, 24, 263jca 1168 . . . . . . . . . 10  |-  ( ( ( V  e.  _V  /\  E  e.  _V )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  ( V  e.  _V  /\  E  e.  _V  /\  N  e.  NN ) )
2827ex 434 . . . . . . . . 9  |-  ( ( V  e.  _V  /\  E  e.  _V )  ->  ( ( X  e.  V  /\  N  e.  NN )  ->  ( V  e.  _V  /\  E  e.  _V  /\  N  e.  NN ) ) )
2920, 21, 283syl 20 . . . . . . . 8  |-  ( <. V ,  E >. RegUSGrph  K  ->  ( ( X  e.  V  /\  N  e.  NN )  ->  ( V  e.  _V  /\  E  e.  _V  /\  N  e.  NN ) ) )
3029adantr 465 . . . . . . 7  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  ->  ( ( X  e.  V  /\  N  e.  NN )  ->  ( V  e.  _V  /\  E  e.  _V  /\  N  e.  NN ) ) )
3130imp 429 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( V  e.  _V  /\  E  e.  _V  /\  N  e.  NN )
)
32 clwwlkvbij 30598 . . . . . 6  |-  ( ( V  e.  _V  /\  E  e.  _V  /\  N  e.  NN )  ->  E. f 
f : { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) } -1-1-onto-> { w  e.  ( ( V ClWWalksN  E ) `  N )  |  ( w `  0 )  =  X } )
3331, 32syl 16 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  E. f  f : { w  e.  (
( V WWalksN  E ) `  N )  |  ( ( lastS  `  w )  =  ( w ` 
0 )  /\  (
w `  0 )  =  X ) } -1-1-onto-> { w  e.  ( ( V ClWWalksN  E ) `  N )  |  ( w `  0 )  =  X } )
34 hasheqf1oi 12220 . . . . 5  |-  ( ( { w  e.  ( ( V WWalksN  E ) `  N )  |  ( ( lastS  `  w )  =  ( w ` 
0 )  /\  (
w `  0 )  =  X ) }  e.  _V  /\  { w  e.  ( ( V ClWWalksN  E ) `
 N )  |  ( w `  0
)  =  X }  e.  _V )  ->  ( E. f  f : { w  e.  (
( V WWalksN  E ) `  N )  |  ( ( lastS  `  w )  =  ( w ` 
0 )  /\  (
w `  0 )  =  X ) } -1-1-onto-> { w  e.  ( ( V ClWWalksN  E ) `  N )  |  ( w `  0 )  =  X }  ->  (
# `  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) } )  =  (
# `  { w  e.  ( ( V ClWWalksN  E ) `
 N )  |  ( w `  0
)  =  X }
) ) )
3519, 33, 34sylc 60 . . . 4  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) } )  =  (
# `  { w  e.  ( ( V ClWWalksN  E ) `
 N )  |  ( w `  0
)  =  X }
) )
361adantl 466 . . . . . . . 8  |-  ( ( X  e.  V  /\  N  e.  NN )  ->  N  e.  NN0 )
3736adantl 466 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  N  e.  NN0 )
384numclwwlkfvc 30805 . . . . . . 7  |-  ( N  e.  NN0  ->  ( C `
 N )  =  ( ( V ClWWalksN  E ) `
 N ) )
39 rabeq 3059 . . . . . . 7  |-  ( ( C `  N )  =  ( ( V ClWWalksN  E ) `  N
)  ->  { w  e.  ( C `  N
)  |  ( w `
 0 )  =  X }  =  {
w  e.  ( ( V ClWWalksN  E ) `  N
)  |  ( w `
 0 )  =  X } )
4037, 38, 393syl 20 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  { w  e.  ( C `  N )  |  ( w ` 
0 )  =  X }  =  { w  e.  ( ( V ClWWalksN  E ) `
 N )  |  ( w `  0
)  =  X }
)
4140eqcomd 2458 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  { w  e.  (
( V ClWWalksN  E ) `  N )  |  ( w `  0 )  =  X }  =  { w  e.  ( C `  N )  |  ( w ` 
0 )  =  X } )
4241fveq2d 5790 . . . 4  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  { w  e.  ( ( V ClWWalksN  E ) `
 N )  |  ( w `  0
)  =  X }
)  =  ( # `  { w  e.  ( C `  N )  |  ( w ` 
0 )  =  X } ) )
434, 5numclwwlkovf 30809 . . . . . . 7  |-  ( ( X  e.  V  /\  N  e.  NN0 )  -> 
( X F N )  =  { w  e.  ( C `  N
)  |  ( w `
 0 )  =  X } )
443, 43syl 16 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( X F N )  =  { w  e.  ( C `  N
)  |  ( w `
 0 )  =  X } )
4544eqcomd 2458 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  ->  { w  e.  ( C `  N )  |  ( w ` 
0 )  =  X }  =  ( X F N ) )
4645fveq2d 5790 . . . 4  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  { w  e.  ( C `  N
)  |  ( w `
 0 )  =  X } )  =  ( # `  ( X F N ) ) )
4735, 42, 463eqtrd 2495 . . 3  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) } )  =  (
# `  ( X F N ) ) )
4847oveq2d 6203 . 2  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( ( K ^ N )  -  ( # `
 { w  e.  ( ( V WWalksN  E
) `  N )  |  ( ( lastS  `  w
)  =  ( w `
 0 )  /\  ( w `  0
)  =  X ) } ) )  =  ( ( K ^ N )  -  ( # `
 ( X F N ) ) ) )
4910, 13, 483eqtrd 2495 1  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  /\  ( X  e.  V  /\  N  e.  NN ) )  -> 
( # `  ( X Q N ) )  =  ( ( K ^ N )  -  ( # `  ( X F N ) ) ) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    /\ wa 369    /\ w3a 965    = wceq 1370   E.wex 1587    e. wcel 1758    =/= wne 2642   {crab 2797   _Vcvv 3065   <.cop 3978   class class class wbr 4387    |-> cmpt 4445   -1-1-onto->wf1o 5512   ` cfv 5513  (class class class)co 6187    |-> cmpt2 6189   Fincfn 7407   0cc0 9380    - cmin 9693   NNcn 10420   2c2 10469   NN0cn0 10677   ZZ>=cuz 10959   ^cexp 11963   #chash 12201   lastS clsw 12321   USGrph cusg 23396   WWalksN cwwlkn 30447   ClWWalksN cclwwlkn 30549   RegUSGrph crusgra 30675
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1592  ax-4 1603  ax-5 1671  ax-6 1710  ax-7 1730  ax-8 1760  ax-9 1762  ax-10 1777  ax-11 1782  ax-12 1794  ax-13 1952  ax-ext 2430  ax-rep 4498  ax-sep 4508  ax-nul 4516  ax-pow 4565  ax-pr 4626  ax-un 6469  ax-inf2 7945  ax-cnex 9436  ax-resscn 9437  ax-1cn 9438  ax-icn 9439  ax-addcl 9440  ax-addrcl 9441  ax-mulcl 9442  ax-mulrcl 9443  ax-mulcom 9444  ax-addass 9445  ax-mulass 9446  ax-distr 9447  ax-i2m1 9448  ax-1ne0 9449  ax-1rid 9450  ax-rnegex 9451  ax-rrecex 9452  ax-cnre 9453  ax-pre-lttri 9454  ax-pre-lttrn 9455  ax-pre-ltadd 9456  ax-pre-mulgt0 9457  ax-pre-sup 9458
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 966  df-3an 967  df-tru 1373  df-fal 1376  df-ex 1588  df-nf 1591  df-sb 1703  df-eu 2264  df-mo 2265  df-clab 2437  df-cleq 2443  df-clel 2446  df-nfc 2599  df-ne 2644  df-nel 2645  df-ral 2798  df-rex 2799  df-reu 2800  df-rmo 2801  df-rab 2802  df-v 3067  df-sbc 3282  df-csb 3384  df-dif 3426  df-un 3428  df-in 3430  df-ss 3437  df-pss 3439  df-nul 3733  df-if 3887  df-pw 3957  df-sn 3973  df-pr 3975  df-tp 3977  df-op 3979  df-uni 4187  df-int 4224  df-iun 4268  df-disj 4358  df-br 4388  df-opab 4446  df-mpt 4447  df-tr 4481  df-eprel 4727  df-id 4731  df-po 4736  df-so 4737  df-fr 4774  df-se 4775  df-we 4776  df-ord 4817  df-on 4818  df-lim 4819  df-suc 4820  df-xp 4941  df-rel 4942  df-cnv 4943  df-co 4944  df-dm 4945  df-rn 4946  df-res 4947  df-ima 4948  df-iota 5476  df-fun 5515  df-fn 5516  df-f 5517  df-f1 5518  df-fo 5519  df-f1o 5520  df-fv 5521  df-isom 5522  df-riota 6148  df-ov 6190  df-oprab 6191  df-mpt2 6192  df-om 6574  df-1st 6674  df-2nd 6675  df-recs 6929  df-rdg 6963  df-1o 7017  df-2o 7018  df-oadd 7021  df-er 7198  df-map 7313  df-pm 7314  df-en 7408  df-dom 7409  df-sdom 7410  df-fin 7411  df-sup 7789  df-oi 7822  df-card 8207  df-cda 8435  df-pnf 9518  df-mnf 9519  df-xr 9520  df-ltxr 9521  df-le 9522  df-sub 9695  df-neg 9696  df-div 10092  df-nn 10421  df-2 10478  df-3 10479  df-n0 10678  df-z 10745  df-uz 10960  df-rp 11090  df-xadd 11188  df-fz 11536  df-fzo 11647  df-seq 11905  df-exp 11964  df-hash 12202  df-word 12328  df-lsw 12329  df-concat 12330  df-s1 12331  df-substr 12332  df-cj 12687  df-re 12688  df-im 12689  df-sqr 12823  df-abs 12824  df-clim 13065  df-sum 13263  df-usgra 23398  df-nbgra 23464  df-wlk 23547  df-vdgr 23696  df-wwlk 30448  df-wwlkn 30449  df-clwwlk 30551  df-clwwlkn 30552  df-rgra 30676  df-rusgra 30677
This theorem is referenced by:  numclwwlk2  30835
  Copyright terms: Public domain W3C validator