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

Theorem numclwwlk5 25919
Description: Statement 13 in [Huneke] p. 2: "Let p be a prime divisor of k-1; then f(p) = 1 (mod p) [for each vertex v]". (Contributed by Alexander van der Vekens, 7-Oct-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 } )
Assertion
Ref Expression
numclwwlk5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( # `  ( X F P ) )  mod  P )  =  1 )
Distinct variable groups:    n, E    n, V    w, C, n, v    n, X, v, w    v, V    w, E    w, V    w, F    w, P    v, E    v, K, w    P, n, v
Allowed substitution hints:    F( v, n)    K( n)

Proof of Theorem numclwwlk5
Dummy variables  m  u  z are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 simpl1 1033 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) )  ->  <. V ,  E >. RegUSGrph  K
)
2 simpr3 1038 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) )  -> 
2  ||  ( K  -  1 ) )
3 simpr1 1036 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) )  ->  X  e.  V )
4 numclwwlk.c . . . . . 6  |-  C  =  ( n  e.  NN0  |->  ( ( V ClWWalksN  E ) `
 n ) )
5 numclwwlk.f . . . . . 6  |-  F  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  ( C `  n )  |  ( w ` 
0 )  =  v } )
64, 5numclwwlk5lem 25918 . . . . 5  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  2  ||  ( K  -  1 )  /\  X  e.  V )  ->  ( ( # `  ( X F 2 ) )  mod  2 )  =  1 )
71, 2, 3, 6syl3anc 1292 . . . 4  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) )  -> 
( ( # `  ( X F 2 ) )  mod  2 )  =  1 )
87a1i 11 . . 3  |-  ( P  =  2  ->  (
( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) )  ->  ( ( # `
 ( X F 2 ) )  mod  2 )  =  1 ) )
9 eleq1 2537 . . . . 5  |-  ( P  =  2  ->  ( P  e.  Prime  <->  2  e.  Prime ) )
10 breq1 4398 . . . . 5  |-  ( P  =  2  ->  ( P  ||  ( K  - 
1 )  <->  2  ||  ( K  -  1
) ) )
119, 103anbi23d 1368 . . . 4  |-  ( P  =  2  ->  (
( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  <-> 
( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) ) )
1211anbi2d 718 . . 3  |-  ( P  =  2  ->  (
( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  <->  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  2  e.  Prime  /\  2  ||  ( K  -  1 ) ) ) ) )
13 oveq2 6316 . . . . . 6  |-  ( P  =  2  ->  ( X F P )  =  ( X F 2 ) )
1413fveq2d 5883 . . . . 5  |-  ( P  =  2  ->  ( # `
 ( X F P ) )  =  ( # `  ( X F 2 ) ) )
15 id 22 . . . . 5  |-  ( P  =  2  ->  P  =  2 )
1614, 15oveq12d 6326 . . . 4  |-  ( P  =  2  ->  (
( # `  ( X F P ) )  mod  P )  =  ( ( # `  ( X F 2 ) )  mod  2 ) )
1716eqeq1d 2473 . . 3  |-  ( P  =  2  ->  (
( ( # `  ( X F P ) )  mod  P )  =  1  <->  ( ( # `  ( X F 2 ) )  mod  2
)  =  1 ) )
188, 12, 173imtr4d 276 . 2  |-  ( P  =  2  ->  (
( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  ->  ( ( # `
 ( X F P ) )  mod 
P )  =  1 ) )
19 3simpa 1027 . . . . . . . 8  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  ->  ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E ) )
2019adantr 472 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E ) )
2120adantl 473 . . . . . 6  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E ) )
22 simprl3 1077 . . . . . 6  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  V  e.  Fin )
23 simprr1 1078 . . . . . 6  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  X  e.  V )
24 prmn2uzge3 14723 . . . . . . . . . 10  |-  ( ( P  e.  Prime  /\  P  =/=  2 )  ->  P  e.  ( ZZ>= `  3 )
)
2524ex 441 . . . . . . . . 9  |-  ( P  e.  Prime  ->  ( P  =/=  2  ->  P  e.  ( ZZ>= `  3 )
) )
26253ad2ant2 1052 . . . . . . . 8  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  ( P  =/=  2  ->  P  e.  ( ZZ>= `  3 )
) )
2726adantl 473 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( P  =/=  2  ->  P  e.  ( ZZ>= ` 
3 ) ) )
2827impcom 437 . . . . . 6  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  P  e.  ( ZZ>= `  3 )
)
29 fveq1 5878 . . . . . . . . . . . 12  |-  ( u  =  w  ->  (
u `  0 )  =  ( w ` 
0 ) )
3029eqeq1d 2473 . . . . . . . . . . 11  |-  ( u  =  w  ->  (
( u `  0
)  =  v  <->  ( w `  0 )  =  v ) )
31 fveq1 5878 . . . . . . . . . . . 12  |-  ( u  =  w  ->  (
u `  ( n  -  2 ) )  =  ( w `  ( n  -  2
) ) )
3231, 29eqeq12d 2486 . . . . . . . . . . 11  |-  ( u  =  w  ->  (
( u `  (
n  -  2 ) )  =  ( u `
 0 )  <->  ( w `  ( n  -  2 ) )  =  ( w `  0 ) ) )
3330, 32anbi12d 725 . . . . . . . . . 10  |-  ( u  =  w  ->  (
( ( u ` 
0 )  =  v  /\  ( u `  ( n  -  2
) )  =  ( u `  0 ) )  <->  ( ( w `
 0 )  =  v  /\  ( w `
 ( n  - 
2 ) )  =  ( w `  0
) ) ) )
3433cbvrabv 3030 . . . . . . . . 9  |-  { u  e.  ( C `  n
)  |  ( ( u `  0 )  =  v  /\  (
u `  ( n  -  2 ) )  =  ( u ` 
0 ) ) }  =  { w  e.  ( C `  n
)  |  ( ( w `  0 )  =  v  /\  (
w `  ( n  -  2 ) )  =  ( w ` 
0 ) ) }
3534a1i 11 . . . . . . . 8  |-  ( ( v  e.  V  /\  n  e.  ( ZZ>= ` 
2 ) )  ->  { u  e.  ( C `  n )  |  ( ( u `
 0 )  =  v  /\  ( u `
 ( n  - 
2 ) )  =  ( u `  0
) ) }  =  { w  e.  ( C `  n )  |  ( ( w `
 0 )  =  v  /\  ( w `
 ( n  - 
2 ) )  =  ( w `  0
) ) } )
3635mpt2eq3ia 6375 . . . . . . 7  |-  ( v  e.  V ,  n  e.  ( ZZ>= `  2 )  |->  { u  e.  ( C `  n )  |  ( ( u `
 0 )  =  v  /\  ( u `
 ( n  - 
2 ) )  =  ( u `  0
) ) } )  =  ( v  e.  V ,  n  e.  ( ZZ>= `  2 )  |->  { w  e.  ( C `  n )  |  ( ( w `
 0 )  =  v  /\  ( w `
 ( n  - 
2 ) )  =  ( w `  0
) ) } )
37 fveq2 5879 . . . . . . . . . . . 12  |-  ( u  =  w  ->  ( lastS  `  u )  =  ( lastS  `  w ) )
3837neeq1d 2702 . . . . . . . . . . 11  |-  ( u  =  w  ->  (
( lastS  `  u )  =/=  v  <->  ( lastS  `  w )  =/=  v ) )
3930, 38anbi12d 725 . . . . . . . . . 10  |-  ( u  =  w  ->  (
( ( u ` 
0 )  =  v  /\  ( lastS  `  u
)  =/=  v )  <-> 
( ( w ` 
0 )  =  v  /\  ( lastS  `  w
)  =/=  v ) ) )
4039cbvrabv 3030 . . . . . . . . 9  |-  { u  e.  ( ( V WWalksN  E
) `  n )  |  ( ( u `
 0 )  =  v  /\  ( lastS  `  u
)  =/=  v ) }  =  { w  e.  ( ( V WWalksN  E
) `  n )  |  ( ( w `
 0 )  =  v  /\  ( lastS  `  w
)  =/=  v ) }
4140a1i 11 . . . . . . . 8  |-  ( ( v  e.  V  /\  n  e.  NN0 )  ->  { u  e.  (
( V WWalksN  E ) `  n )  |  ( ( u `  0
)  =  v  /\  ( lastS  `  u )  =/=  v ) }  =  { w  e.  (
( V WWalksN  E ) `  n )  |  ( ( w `  0
)  =  v  /\  ( lastS  `  w )  =/=  v ) } )
4241mpt2eq3ia 6375 . . . . . . 7  |-  ( v  e.  V ,  n  e.  NN0  |->  { u  e.  ( ( V WWalksN  E
) `  n )  |  ( ( u `
 0 )  =  v  /\  ( lastS  `  u
)  =/=  v ) } )  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  ( ( V WWalksN  E
) `  n )  |  ( ( w `
 0 )  =  v  /\  ( lastS  `  w
)  =/=  v ) } )
43 eqeq2 2482 . . . . . . . . . 10  |-  ( z  =  v  ->  (
( u `  0
)  =  z  <->  ( u `  0 )  =  v ) )
4443anbi1d 719 . . . . . . . . 9  |-  ( z  =  v  ->  (
( ( u ` 
0 )  =  z  /\  ( u `  ( m  -  2
) )  =/=  (
u `  0 )
)  <->  ( ( u `
 0 )  =  v  /\  ( u `
 ( m  - 
2 ) )  =/=  ( u `  0
) ) ) )
4544rabbidv 3022 . . . . . . . 8  |-  ( z  =  v  ->  { u  e.  ( C `  m
)  |  ( ( u `  0 )  =  z  /\  (
u `  ( m  -  2 ) )  =/=  ( u ` 
0 ) ) }  =  { u  e.  ( C `  m
)  |  ( ( u `  0 )  =  v  /\  (
u `  ( m  -  2 ) )  =/=  ( u ` 
0 ) ) } )
46 fveq2 5879 . . . . . . . . . 10  |-  ( m  =  n  ->  ( C `  m )  =  ( C `  n ) )
47 oveq1 6315 . . . . . . . . . . . . 13  |-  ( m  =  n  ->  (
m  -  2 )  =  ( n  - 
2 ) )
4847fveq2d 5883 . . . . . . . . . . . 12  |-  ( m  =  n  ->  (
u `  ( m  -  2 ) )  =  ( u `  ( n  -  2
) ) )
4948neeq1d 2702 . . . . . . . . . . 11  |-  ( m  =  n  ->  (
( u `  (
m  -  2 ) )  =/=  ( u `
 0 )  <->  ( u `  ( n  -  2 ) )  =/=  (
u `  0 )
) )
5049anbi2d 718 . . . . . . . . . 10  |-  ( m  =  n  ->  (
( ( u ` 
0 )  =  v  /\  ( u `  ( m  -  2
) )  =/=  (
u `  0 )
)  <->  ( ( u `
 0 )  =  v  /\  ( u `
 ( n  - 
2 ) )  =/=  ( u `  0
) ) ) )
5146, 50rabeqbidv 3026 . . . . . . . . 9  |-  ( m  =  n  ->  { u  e.  ( C `  m
)  |  ( ( u `  0 )  =  v  /\  (
u `  ( m  -  2 ) )  =/=  ( u ` 
0 ) ) }  =  { u  e.  ( C `  n
)  |  ( ( u `  0 )  =  v  /\  (
u `  ( n  -  2 ) )  =/=  ( u ` 
0 ) ) } )
5231, 29neeq12d 2704 . . . . . . . . . . 11  |-  ( u  =  w  ->  (
( u `  (
n  -  2 ) )  =/=  ( u `
 0 )  <->  ( w `  ( n  -  2 ) )  =/=  (
w `  0 )
) )
5330, 52anbi12d 725 . . . . . . . . . 10  |-  ( u  =  w  ->  (
( ( u ` 
0 )  =  v  /\  ( u `  ( n  -  2
) )  =/=  (
u `  0 )
)  <->  ( ( w `
 0 )  =  v  /\  ( w `
 ( n  - 
2 ) )  =/=  ( w `  0
) ) ) )
5453cbvrabv 3030 . . . . . . . . 9  |-  { u  e.  ( C `  n
)  |  ( ( u `  0 )  =  v  /\  (
u `  ( n  -  2 ) )  =/=  ( u ` 
0 ) ) }  =  { w  e.  ( C `  n
)  |  ( ( w `  0 )  =  v  /\  (
w `  ( n  -  2 ) )  =/=  ( w ` 
0 ) ) }
5551, 54syl6eq 2521 . . . . . . . 8  |-  ( m  =  n  ->  { u  e.  ( C `  m
)  |  ( ( u `  0 )  =  v  /\  (
u `  ( m  -  2 ) )  =/=  ( u ` 
0 ) ) }  =  { w  e.  ( C `  n
)  |  ( ( w `  0 )  =  v  /\  (
w `  ( n  -  2 ) )  =/=  ( w ` 
0 ) ) } )
5645, 55cbvmpt2v 6390 . . . . . . 7  |-  ( z  e.  V ,  m  e.  NN0  |->  { u  e.  ( C `  m
)  |  ( ( u `  0 )  =  z  /\  (
u `  ( m  -  2 ) )  =/=  ( u ` 
0 ) ) } )  =  ( v  e.  V ,  n  e.  NN0  |->  { w  e.  ( C `  n
)  |  ( ( w `  0 )  =  v  /\  (
w `  ( n  -  2 ) )  =/=  ( w ` 
0 ) ) } )
574, 5, 36, 42, 56numclwwlk3 25916 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E )  /\  ( V  e.  Fin  /\  X  e.  V  /\  P  e.  ( ZZ>= ` 
3 ) ) )  ->  ( # `  ( X F P ) )  =  ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  +  ( K ^ ( P  - 
2 ) ) ) )
5821, 22, 23, 28, 57syl13anc 1294 . . . . 5  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  ( # `
 ( X F P ) )  =  ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  +  ( K ^ ( P  - 
2 ) ) ) )
5958oveq1d 6323 . . . 4  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  (
( # `  ( X F P ) )  mod  P )  =  ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  +  ( K ^ ( P  - 
2 ) ) )  mod  P ) )
60 rusgraprop 25736 . . . . . . . . . . . . 13  |-  ( <. V ,  E >. RegUSGrph  K  ->  ( V USGrph  E  /\  K  e.  NN0  /\  A. v  e.  V  (
( V VDeg  E ) `  v )  =  K ) )
61 nn0z 10984 . . . . . . . . . . . . . 14  |-  ( K  e.  NN0  ->  K  e.  ZZ )
62613ad2ant2 1052 . . . . . . . . . . . . 13  |-  ( ( V USGrph  E  /\  K  e. 
NN0  /\  A. v  e.  V  ( ( V VDeg  E ) `  v
)  =  K )  ->  K  e.  ZZ )
6360, 62syl 17 . . . . . . . . . . . 12  |-  ( <. V ,  E >. RegUSGrph  K  ->  K  e.  ZZ )
6463zred 11063 . . . . . . . . . . 11  |-  ( <. V ,  E >. RegUSGrph  K  ->  K  e.  RR )
65 peano2rem 9961 . . . . . . . . . . 11  |-  ( K  e.  RR  ->  ( K  -  1 )  e.  RR )
6664, 65syl 17 . . . . . . . . . 10  |-  ( <. V ,  E >. RegUSGrph  K  ->  ( K  -  1 )  e.  RR )
67663ad2ant1 1051 . . . . . . . . 9  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  ->  ( K  -  1 )  e.  RR )
6867adantr 472 . . . . . . . 8  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( K  -  1 )  e.  RR )
69 rusisusgra 25738 . . . . . . . . . . . . . . 15  |-  ( <. V ,  E >. RegUSGrph  K  ->  V USGrph  E )
70 usgrav 25144 . . . . . . . . . . . . . . . 16  |-  ( V USGrph  E  ->  ( V  e. 
_V  /\  E  e.  _V ) )
7170simprd 470 . . . . . . . . . . . . . . 15  |-  ( V USGrph  E  ->  E  e.  _V )
7269, 71syl 17 . . . . . . . . . . . . . 14  |-  ( <. V ,  E >. RegUSGrph  K  ->  E  e.  _V )
7372anim1i 578 . . . . . . . . . . . . 13  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  ->  ( E  e. 
_V  /\  V  e.  Fin ) )
7473ancomd 458 . . . . . . . . . . . 12  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V  e.  Fin )  ->  ( V  e. 
Fin  /\  E  e.  _V ) )
75743adant2 1049 . . . . . . . . . . 11  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  ->  ( V  e.  Fin  /\  E  e.  _V ) )
76 prmm2nn0 14724 . . . . . . . . . . . . 13  |-  ( P  e.  Prime  ->  ( P  -  2 )  e. 
NN0 )
7776anim2i 579 . . . . . . . . . . . 12  |-  ( ( X  e.  V  /\  P  e.  Prime )  -> 
( X  e.  V  /\  ( P  -  2 )  e.  NN0 )
)
78773adant3 1050 . . . . . . . . . . 11  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  ( X  e.  V  /\  ( P  -  2
)  e.  NN0 )
)
794, 5numclwwlkffin 25889 . . . . . . . . . . 11  |-  ( ( ( V  e.  Fin  /\  E  e.  _V )  /\  ( X  e.  V  /\  ( P  -  2 )  e.  NN0 )
)  ->  ( X F ( P  - 
2 ) )  e. 
Fin )
8075, 78, 79syl2an 485 . . . . . . . . . 10  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( X F ( P  -  2 ) )  e.  Fin )
81 hashcl 12576 . . . . . . . . . 10  |-  ( ( X F ( P  -  2 ) )  e.  Fin  ->  ( # `
 ( X F ( P  -  2 ) ) )  e. 
NN0 )
8280, 81syl 17 . . . . . . . . 9  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( # `  ( X F ( P  - 
2 ) ) )  e.  NN0 )
8382nn0red 10950 . . . . . . . 8  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( # `  ( X F ( P  - 
2 ) ) )  e.  RR )
8468, 83remulcld 9689 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( K  - 
1 )  x.  ( # `
 ( X F ( P  -  2 ) ) ) )  e.  RR )
85643ad2ant1 1051 . . . . . . . 8  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  ->  K  e.  RR )
86763ad2ant2 1052 . . . . . . . 8  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  ( P  -  2 )  e.  NN0 )
87 reexpcl 12327 . . . . . . . 8  |-  ( ( K  e.  RR  /\  ( P  -  2
)  e.  NN0 )  ->  ( K ^ ( P  -  2 ) )  e.  RR )
8885, 86, 87syl2an 485 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( K ^ ( P  -  2 ) )  e.  RR )
89 prmnn 14704 . . . . . . . . . 10  |-  ( P  e.  Prime  ->  P  e.  NN )
9089nnrpd 11362 . . . . . . . . 9  |-  ( P  e.  Prime  ->  P  e.  RR+ )
91903ad2ant2 1052 . . . . . . . 8  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  P  e.  RR+ )
9291adantl 473 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  ->  P  e.  RR+ )
9384, 88, 923jca 1210 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  e.  RR  /\  ( K ^ ( P  -  2 ) )  e.  RR  /\  P  e.  RR+ ) )
9493adantl 473 . . . . 5  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  (
( ( K  - 
1 )  x.  ( # `
 ( X F ( P  -  2 ) ) ) )  e.  RR  /\  ( K ^ ( P  - 
2 ) )  e.  RR  /\  P  e.  RR+ ) )
95 modaddabs 12168 . . . . . 6  |-  ( ( ( ( K  - 
1 )  x.  ( # `
 ( X F ( P  -  2 ) ) ) )  e.  RR  /\  ( K ^ ( P  - 
2 ) )  e.  RR  /\  P  e.  RR+ )  ->  ( ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  mod  P )  +  ( ( K ^ ( P  - 
2 ) )  mod 
P ) )  mod 
P )  =  ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  +  ( K ^ ( P  - 
2 ) ) )  mod  P ) )
9695eqcomd 2477 . . . . 5  |-  ( ( ( ( K  - 
1 )  x.  ( # `
 ( X F ( P  -  2 ) ) ) )  e.  RR  /\  ( K ^ ( P  - 
2 ) )  e.  RR  /\  P  e.  RR+ )  ->  ( ( ( ( K  - 
1 )  x.  ( # `
 ( X F ( P  -  2 ) ) ) )  +  ( K ^
( P  -  2 ) ) )  mod 
P )  =  ( ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  mod  P )  +  ( ( K ^ ( P  - 
2 ) )  mod 
P ) )  mod 
P ) )
9794, 96syl 17 . . . 4  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  (
( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  +  ( K ^ ( P  - 
2 ) ) )  mod  P )  =  ( ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  -  2 ) ) ) )  mod 
P )  +  ( ( K ^ ( P  -  2 ) )  mod  P ) )  mod  P ) )
98893ad2ant2 1052 . . . . . . . . . . 11  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  P  e.  NN )
9998adantl 473 . . . . . . . . . 10  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  ->  P  e.  NN )
100 peano2zm 11004 . . . . . . . . . . . . 13  |-  ( K  e.  ZZ  ->  ( K  -  1 )  e.  ZZ )
10163, 100syl 17 . . . . . . . . . . . 12  |-  ( <. V ,  E >. RegUSGrph  K  ->  ( K  -  1 )  e.  ZZ )
1021013ad2ant1 1051 . . . . . . . . . . 11  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  ->  ( K  -  1 )  e.  ZZ )
103102adantr 472 . . . . . . . . . 10  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( K  -  1 )  e.  ZZ )
10482nn0zd 11061 . . . . . . . . . 10  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( # `  ( X F ( P  - 
2 ) ) )  e.  ZZ )
10599, 103, 1043jca 1210 . . . . . . . . 9  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( P  e.  NN  /\  ( K  -  1 )  e.  ZZ  /\  ( # `  ( X F ( P  - 
2 ) ) )  e.  ZZ ) )
106 simpr3 1038 . . . . . . . . 9  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  ->  P  ||  ( K  - 
1 ) )
107 mulmoddvds 14441 . . . . . . . . 9  |-  ( ( P  e.  NN  /\  ( K  -  1
)  e.  ZZ  /\  ( # `  ( X F ( P  - 
2 ) ) )  e.  ZZ )  -> 
( P  ||  ( K  -  1 )  ->  ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  mod  P )  =  0 ) )
108105, 106, 107sylc 61 . . . . . . . 8  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  mod  P )  =  0 )
109633ad2ant1 1051 . . . . . . . . . 10  |-  ( (
<. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  ->  K  e.  ZZ )
110 simp2 1031 . . . . . . . . . 10  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  P  e.  Prime )
111109, 110anim12ci 577 . . . . . . . . 9  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( P  e.  Prime  /\  K  e.  ZZ ) )
112 powm2modprm 14833 . . . . . . . . 9  |-  ( ( P  e.  Prime  /\  K  e.  ZZ )  ->  ( P  ||  ( K  - 
1 )  ->  (
( K ^ ( P  -  2 ) )  mod  P )  =  1 ) )
113111, 106, 112sylc 61 . . . . . . . 8  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( K ^
( P  -  2 ) )  mod  P
)  =  1 )
114108, 113oveq12d 6326 . . . . . . 7  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  mod  P )  +  ( ( K ^ ( P  - 
2 ) )  mod 
P ) )  =  ( 0  +  1 ) )
115114oveq1d 6323 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  -  2 ) ) ) )  mod 
P )  +  ( ( K ^ ( P  -  2 ) )  mod  P ) )  mod  P )  =  ( ( 0  +  1 )  mod 
P ) )
116 0p1e1 10743 . . . . . . . . . 10  |-  ( 0  +  1 )  =  1
117116oveq1i 6318 . . . . . . . . 9  |-  ( ( 0  +  1 )  mod  P )  =  ( 1  mod  P
)
11889nnred 10646 . . . . . . . . . 10  |-  ( P  e.  Prime  ->  P  e.  RR )
119 prmgt1 14722 . . . . . . . . . 10  |-  ( P  e.  Prime  ->  1  < 
P )
120 1mod 12162 . . . . . . . . . 10  |-  ( ( P  e.  RR  /\  1  <  P )  -> 
( 1  mod  P
)  =  1 )
121118, 119, 120syl2anc 673 . . . . . . . . 9  |-  ( P  e.  Prime  ->  ( 1  mod  P )  =  1 )
122117, 121syl5eq 2517 . . . . . . . 8  |-  ( P  e.  Prime  ->  ( ( 0  +  1 )  mod  P )  =  1 )
1231223ad2ant2 1052 . . . . . . 7  |-  ( ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) )  ->  (
( 0  +  1 )  mod  P )  =  1 )
124123adantl 473 . . . . . 6  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( 0  +  1 )  mod  P
)  =  1 )
125115, 124eqtrd 2505 . . . . 5  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  -  2 ) ) ) )  mod 
P )  +  ( ( K ^ ( P  -  2 ) )  mod  P ) )  mod  P )  =  1 )
126125adantl 473 . . . 4  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  (
( ( ( ( K  -  1 )  x.  ( # `  ( X F ( P  - 
2 ) ) ) )  mod  P )  +  ( ( K ^ ( P  - 
2 ) )  mod 
P ) )  mod 
P )  =  1 )
12759, 97, 1263eqtrd 2509 . . 3  |-  ( ( P  =/=  2  /\  ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) ) )  ->  (
( # `  ( X F P ) )  mod  P )  =  1 )
128127ex 441 . 2  |-  ( P  =/=  2  ->  (
( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  ->  ( ( # `
 ( X F P ) )  mod 
P )  =  1 ) )
12918, 128pm2.61ine 2726 1  |-  ( ( ( <. V ,  E >. RegUSGrph  K  /\  V FriendGrph  E  /\  V  e.  Fin )  /\  ( X  e.  V  /\  P  e.  Prime  /\  P  ||  ( K  -  1 ) ) )  -> 
( ( # `  ( X F P ) )  mod  P )  =  1 )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    /\ wa 376    /\ w3a 1007    = wceq 1452    e. wcel 1904    =/= wne 2641   A.wral 2756   {crab 2760   _Vcvv 3031   <.cop 3965   class class class wbr 4395    |-> cmpt 4454   ` cfv 5589  (class class class)co 6308    |-> cmpt2 6310   Fincfn 7587   RRcr 9556   0cc0 9557   1c1 9558    + caddc 9560    x. cmul 9562    < clt 9693    - cmin 9880   NNcn 10631   2c2 10681   3c3 10682   NN0cn0 10893   ZZcz 10961   ZZ>=cuz 11182   RR+crp 11325    mod cmo 12129   ^cexp 12310   #chash 12553   lastS clsw 12704    || cdvds 14382   Primecprime 14701   USGrph cusg 25136   WWalksN cwwlkn 25485   ClWWalksN cclwwlkn 25556   VDeg cvdg 25700   RegUSGrph crusgra 25730   FriendGrph cfrgra 25795
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1677  ax-4 1690  ax-5 1766  ax-6 1813  ax-7 1859  ax-8 1906  ax-9 1913  ax-10 1932  ax-11 1937  ax-12 1950  ax-13 2104  ax-ext 2451  ax-rep 4508  ax-sep 4518  ax-nul 4527  ax-pow 4579  ax-pr 4639  ax-un 6602  ax-inf2 8164  ax-cnex 9613  ax-resscn 9614  ax-1cn 9615  ax-icn 9616  ax-addcl 9617  ax-addrcl 9618  ax-mulcl 9619  ax-mulrcl 9620  ax-mulcom 9621  ax-addass 9622  ax-mulass 9623  ax-distr 9624  ax-i2m1 9625  ax-1ne0 9626  ax-1rid 9627  ax-rnegex 9628  ax-rrecex 9629  ax-cnre 9630  ax-pre-lttri 9631  ax-pre-lttrn 9632  ax-pre-ltadd 9633  ax-pre-mulgt0 9634  ax-pre-sup 9635
This theorem depends on definitions:  df-bi 190  df-or 377  df-an 378  df-3or 1008  df-3an 1009  df-tru 1455  df-fal 1458  df-ex 1672  df-nf 1676  df-sb 1806  df-eu 2323  df-mo 2324  df-clab 2458  df-cleq 2464  df-clel 2467  df-nfc 2601  df-ne 2643  df-nel 2644  df-ral 2761  df-rex 2762  df-reu 2763  df-rmo 2764  df-rab 2765  df-v 3033  df-sbc 3256  df-csb 3350  df-dif 3393  df-un 3395  df-in 3397  df-ss 3404  df-pss 3406  df-nul 3723  df-if 3873  df-pw 3944  df-sn 3960  df-pr 3962  df-tp 3964  df-op 3966  df-uni 4191  df-int 4227  df-iun 4271  df-disj 4367  df-br 4396  df-opab 4455  df-mpt 4456  df-tr 4491  df-eprel 4750  df-id 4754  df-po 4760  df-so 4761  df-fr 4798  df-se 4799  df-we 4800  df-xp 4845  df-rel 4846  df-cnv 4847  df-co 4848  df-dm 4849  df-rn 4850  df-res 4851  df-ima 4852  df-pred 5387  df-ord 5433  df-on 5434  df-lim 5435  df-suc 5436  df-iota 5553  df-fun 5591  df-fn 5592  df-f 5593  df-f1 5594  df-fo 5595  df-f1o 5596  df-fv 5597  df-isom 5598  df-riota 6270  df-ov 6311  df-oprab 6312  df-mpt2 6313  df-om 6712  df-1st 6812  df-2nd 6813  df-wrecs 7046  df-recs 7108  df-rdg 7146  df-1o 7200  df-2o 7201  df-oadd 7204  df-er 7381  df-map 7492  df-pm 7493  df-en 7588  df-dom 7589  df-sdom 7590  df-fin 7591  df-sup 7974  df-inf 7975  df-oi 8043  df-card 8391  df-cda 8616  df-pnf 9695  df-mnf 9696  df-xr 9697  df-ltxr 9698  df-le 9699  df-sub 9882  df-neg 9883  df-div 10292  df-nn 10632  df-2 10690  df-3 10691  df-n0 10894  df-z 10962  df-uz 11183  df-rp 11326  df-xadd 11433  df-fz 11811  df-fzo 11943  df-fl 12061  df-mod 12130  df-seq 12252  df-exp 12311  df-hash 12554  df-word 12711  df-lsw 12712  df-concat 12713  df-s1 12714  df-substr 12715  df-s2 13003  df-cj 13239  df-re 13240  df-im 13241  df-sqrt 13375  df-abs 13376  df-clim 13629  df-sum 13830  df-dvds 14383  df-gcd 14548  df-prm 14702  df-phi 14793  df-usgra 25139  df-nbgra 25227  df-wlk 25315  df-wwlk 25486  df-wwlkn 25487  df-clwwlk 25558  df-clwwlkn 25559  df-vdgr 25701  df-rgra 25731  df-rusgra 25732  df-frgra 25796
This theorem is referenced by:  numclwwlk6  25920
  Copyright terms: Public domain W3C validator