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

Theorem lgseisen 23754
Description: Eisenstein's lemma, an expression for  ( P  /L Q ) when  P ,  Q are distinct odd primes. (Contributed by Mario Carneiro, 18-Jun-2015.)
Hypotheses
Ref Expression
lgseisen.1  |-  ( ph  ->  P  e.  ( Prime  \  { 2 } ) )
lgseisen.2  |-  ( ph  ->  Q  e.  ( Prime  \  { 2 } ) )
lgseisen.3  |-  ( ph  ->  P  =/=  Q )
Assertion
Ref Expression
lgseisen  |-  ( ph  ->  ( Q  /L
P )  =  (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) ) )
Distinct variable groups:    x, P    ph, x    x, Q

Proof of Theorem lgseisen
Dummy variable  y is distinct from all other variables.
StepHypRef Expression
1 lgseisen.2 . . . . 5  |-  ( ph  ->  Q  e.  ( Prime  \  { 2 } ) )
21eldifad 3483 . . . 4  |-  ( ph  ->  Q  e.  Prime )
3 prmz 14233 . . . 4  |-  ( Q  e.  Prime  ->  Q  e.  ZZ )
42, 3syl 16 . . 3  |-  ( ph  ->  Q  e.  ZZ )
5 lgseisen.1 . . 3  |-  ( ph  ->  P  e.  ( Prime  \  { 2 } ) )
6 lgsval3 23715 . . 3  |-  ( ( Q  e.  ZZ  /\  P  e.  ( Prime  \  { 2 } ) )  ->  ( Q  /L P )  =  ( ( ( ( Q ^ ( ( P  -  1 )  /  2 ) )  +  1 )  mod 
P )  -  1 ) )
74, 5, 6syl2anc 661 . 2  |-  ( ph  ->  ( Q  /L
P )  =  ( ( ( ( Q ^ ( ( P  -  1 )  / 
2 ) )  +  1 )  mod  P
)  -  1 ) )
8 prmnn 14232 . . . . . . . . 9  |-  ( Q  e.  Prime  ->  Q  e.  NN )
92, 8syl 16 . . . . . . . 8  |-  ( ph  ->  Q  e.  NN )
10 oddprm 14351 . . . . . . . . . 10  |-  ( P  e.  ( Prime  \  {
2 } )  -> 
( ( P  - 
1 )  /  2
)  e.  NN )
115, 10syl 16 . . . . . . . . 9  |-  ( ph  ->  ( ( P  - 
1 )  /  2
)  e.  NN )
1211nnnn0d 10873 . . . . . . . 8  |-  ( ph  ->  ( ( P  - 
1 )  /  2
)  e.  NN0 )
139, 12nnexpcld 12334 . . . . . . 7  |-  ( ph  ->  ( Q ^ (
( P  -  1 )  /  2 ) )  e.  NN )
1413nnred 10571 . . . . . 6  |-  ( ph  ->  ( Q ^ (
( P  -  1 )  /  2 ) )  e.  RR )
15 neg1rr 10661 . . . . . . . 8  |-  -u 1  e.  RR
1615a1i 11 . . . . . . 7  |-  ( ph  -> 
-u 1  e.  RR )
17 neg1ne0 10662 . . . . . . . 8  |-  -u 1  =/=  0
1817a1i 11 . . . . . . 7  |-  ( ph  -> 
-u 1  =/=  0
)
19 fzfid 12086 . . . . . . . 8  |-  ( ph  ->  ( 1 ... (
( P  -  1 )  /  2 ) )  e.  Fin )
209nnred 10571 . . . . . . . . . . . 12  |-  ( ph  ->  Q  e.  RR )
215eldifad 3483 . . . . . . . . . . . . 13  |-  ( ph  ->  P  e.  Prime )
22 prmnn 14232 . . . . . . . . . . . . 13  |-  ( P  e.  Prime  ->  P  e.  NN )
2321, 22syl 16 . . . . . . . . . . . 12  |-  ( ph  ->  P  e.  NN )
2420, 23nndivred 10605 . . . . . . . . . . 11  |-  ( ph  ->  ( Q  /  P
)  e.  RR )
2524adantr 465 . . . . . . . . . 10  |-  ( (
ph  /\  x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) )  ->  ( Q  /  P )  e.  RR )
26 2re 10626 . . . . . . . . . . 11  |-  2  e.  RR
27 elfznn 11739 . . . . . . . . . . . . 13  |-  ( x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) )  ->  x  e.  NN )
2827adantl 466 . . . . . . . . . . . 12  |-  ( (
ph  /\  x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) )  ->  x  e.  NN )
2928nnred 10571 . . . . . . . . . . 11  |-  ( (
ph  /\  x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) )  ->  x  e.  RR )
30 remulcl 9594 . . . . . . . . . . 11  |-  ( ( 2  e.  RR  /\  x  e.  RR )  ->  ( 2  x.  x
)  e.  RR )
3126, 29, 30sylancr 663 . . . . . . . . . 10  |-  ( (
ph  /\  x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) )  ->  (
2  x.  x )  e.  RR )
3225, 31remulcld 9641 . . . . . . . . 9  |-  ( (
ph  /\  x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) )  ->  (
( Q  /  P
)  x.  ( 2  x.  x ) )  e.  RR )
3332flcld 11938 . . . . . . . 8  |-  ( (
ph  /\  x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) )  ->  ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x
) ) )  e.  ZZ )
3419, 33fsumzcl 13569 . . . . . . 7  |-  ( ph  -> 
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) )  e.  ZZ )
3516, 18, 34reexpclzd 12338 . . . . . 6  |-  ( ph  ->  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  e.  RR )
36 1re 9612 . . . . . . 7  |-  1  e.  RR
3736a1i 11 . . . . . 6  |-  ( ph  ->  1  e.  RR )
3823nnrpd 11280 . . . . . 6  |-  ( ph  ->  P  e.  RR+ )
39 lgseisen.3 . . . . . . 7  |-  ( ph  ->  P  =/=  Q )
40 eqid 2457 . . . . . . 7  |-  ( ( Q  x.  ( 2  x.  x ) )  mod  P )  =  ( ( Q  x.  ( 2  x.  x
) )  mod  P
)
41 eqid 2457 . . . . . . 7  |-  ( x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) )  |->  ( ( ( ( -u 1 ^ ( ( Q  x.  ( 2  x.  x ) )  mod 
P ) )  x.  ( ( Q  x.  ( 2  x.  x
) )  mod  P
) )  mod  P
)  /  2 ) )  =  ( x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) )  |->  ( ( ( ( -u 1 ^ ( ( Q  x.  ( 2  x.  x ) )  mod 
P ) )  x.  ( ( Q  x.  ( 2  x.  x
) )  mod  P
) )  mod  P
)  /  2 ) )
42 eqid 2457 . . . . . . 7  |-  ( ( Q  x.  ( 2  x.  y ) )  mod  P )  =  ( ( Q  x.  ( 2  x.  y
) )  mod  P
)
43 eqid 2457 . . . . . . 7  |-  (ℤ/n `  P
)  =  (ℤ/n `  P
)
44 eqid 2457 . . . . . . 7  |-  (mulGrp `  (ℤ/n `  P ) )  =  (mulGrp `  (ℤ/n `  P ) )
45 eqid 2457 . . . . . . 7  |-  ( ZRHom `  (ℤ/n `  P ) )  =  ( ZRHom `  (ℤ/n `  P
) )
465, 1, 39, 40, 41, 42, 43, 44, 45lgseisenlem4 23753 . . . . . 6  |-  ( ph  ->  ( ( Q ^
( ( P  - 
1 )  /  2
) )  mod  P
)  =  ( (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  mod  P ) )
47 modadd1 12036 . . . . . 6  |-  ( ( ( ( Q ^
( ( P  - 
1 )  /  2
) )  e.  RR  /\  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  e.  RR )  /\  ( 1  e.  RR  /\  P  e.  RR+ )  /\  (
( Q ^ (
( P  -  1 )  /  2 ) )  mod  P )  =  ( ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  mod 
P ) )  -> 
( ( ( Q ^ ( ( P  -  1 )  / 
2 ) )  +  1 )  mod  P
)  =  ( ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  +  1 )  mod  P ) )
4814, 35, 37, 38, 46, 47syl221anc 1239 . . . . 5  |-  ( ph  ->  ( ( ( Q ^ ( ( P  -  1 )  / 
2 ) )  +  1 )  mod  P
)  =  ( ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  +  1 )  mod  P ) )
49 peano2re 9770 . . . . . . 7  |-  ( (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  e.  RR  ->  (
( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  +  1 )  e.  RR )
5035, 49syl 16 . . . . . 6  |-  ( ph  ->  ( ( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) ) )  +  1 )  e.  RR )
51 df-neg 9827 . . . . . . . 8  |-  -u 1  =  ( 0  -  1 )
52 neg1cn 10660 . . . . . . . . . . . . . 14  |-  -u 1  e.  CC
5352a1i 11 . . . . . . . . . . . . 13  |-  ( ph  -> 
-u 1  e.  CC )
54 absexpz 13150 . . . . . . . . . . . . 13  |-  ( (
-u 1  e.  CC  /\  -u 1  =/=  0  /\  sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) )  e.  ZZ )  ->  ( abs `  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )  =  ( ( abs `  -u 1 ) ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) ) )
5553, 18, 34, 54syl3anc 1228 . . . . . . . . . . . 12  |-  ( ph  ->  ( abs `  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )  =  ( ( abs `  -u 1 ) ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) ) )
56 ax-1cn 9567 . . . . . . . . . . . . . . . 16  |-  1  e.  CC
5756absnegi 13244 . . . . . . . . . . . . . . 15  |-  ( abs `  -u 1 )  =  ( abs `  1
)
58 abs1 13142 . . . . . . . . . . . . . . 15  |-  ( abs `  1 )  =  1
5957, 58eqtri 2486 . . . . . . . . . . . . . 14  |-  ( abs `  -u 1 )  =  1
6059oveq1i 6306 . . . . . . . . . . . . 13  |-  ( ( abs `  -u 1
) ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  =  ( 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )
61 1exp 12198 . . . . . . . . . . . . . 14  |-  ( sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) )  e.  ZZ  ->  ( 1 ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) ) )  =  1 )
6234, 61syl 16 . . . . . . . . . . . . 13  |-  ( ph  ->  ( 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  =  1 )
6360, 62syl5eq 2510 . . . . . . . . . . . 12  |-  ( ph  ->  ( ( abs `  -u 1
) ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  =  1 )
6455, 63eqtrd 2498 . . . . . . . . . . 11  |-  ( ph  ->  ( abs `  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )  =  1 )
65 1le1 10198 . . . . . . . . . . 11  |-  1  <_  1
6664, 65syl6eqbr 4493 . . . . . . . . . 10  |-  ( ph  ->  ( abs `  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )  <_  1 )
67 absle 13160 . . . . . . . . . . 11  |-  ( ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  e.  RR  /\  1  e.  RR )  ->  ( ( abs `  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )  <_  1  <->  ( -u 1  <_  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  /\  ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  <_ 
1 ) ) )
6835, 36, 67sylancl 662 . . . . . . . . . 10  |-  ( ph  ->  ( ( abs `  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )  <_  1  <->  ( -u 1  <_  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  /\  ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  <_ 
1 ) ) )
6966, 68mpbid 210 . . . . . . . . 9  |-  ( ph  ->  ( -u 1  <_ 
( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  /\  ( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) ) )  <_  1
) )
7069simpld 459 . . . . . . . 8  |-  ( ph  -> 
-u 1  <_  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )
7151, 70syl5eqbrr 4490 . . . . . . 7  |-  ( ph  ->  ( 0  -  1 )  <_  ( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) ) ) )
72 0red 9614 . . . . . . . 8  |-  ( ph  ->  0  e.  RR )
7372, 37, 35lesubaddd 10170 . . . . . . 7  |-  ( ph  ->  ( ( 0  -  1 )  <_  ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  <->  0  <_  ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  +  1 ) ) )
7471, 73mpbid 210 . . . . . 6  |-  ( ph  ->  0  <_  ( ( -u 1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  +  1 ) )
7523nnred 10571 . . . . . . . . 9  |-  ( ph  ->  P  e.  RR )
76 peano2rem 9905 . . . . . . . . 9  |-  ( P  e.  RR  ->  ( P  -  1 )  e.  RR )
7775, 76syl 16 . . . . . . . 8  |-  ( ph  ->  ( P  -  1 )  e.  RR )
7869simprd 463 . . . . . . . 8  |-  ( ph  ->  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  <_  1 )
79 df-2 10615 . . . . . . . . . 10  |-  2  =  ( 1  +  1 )
80 eldifsni 4158 . . . . . . . . . . . 12  |-  ( P  e.  ( Prime  \  {
2 } )  ->  P  =/=  2 )
815, 80syl 16 . . . . . . . . . . 11  |-  ( ph  ->  P  =/=  2 )
8226a1i 11 . . . . . . . . . . . 12  |-  ( ph  ->  2  e.  RR )
83 prmuz2 14247 . . . . . . . . . . . . 13  |-  ( P  e.  Prime  ->  P  e.  ( ZZ>= `  2 )
)
84 eluzle 11118 . . . . . . . . . . . . 13  |-  ( P  e.  ( ZZ>= `  2
)  ->  2  <_  P )
8521, 83, 843syl 20 . . . . . . . . . . . 12  |-  ( ph  ->  2  <_  P )
8682, 75, 85leltned 9753 . . . . . . . . . . 11  |-  ( ph  ->  ( 2  <  P  <->  P  =/=  2 ) )
8781, 86mpbird 232 . . . . . . . . . 10  |-  ( ph  ->  2  <  P )
8879, 87syl5eqbrr 4490 . . . . . . . . 9  |-  ( ph  ->  ( 1  +  1 )  <  P )
8937, 37, 75ltaddsubd 10173 . . . . . . . . 9  |-  ( ph  ->  ( ( 1  +  1 )  <  P  <->  1  <  ( P  - 
1 ) ) )
9088, 89mpbid 210 . . . . . . . 8  |-  ( ph  ->  1  <  ( P  -  1 ) )
9135, 37, 77, 78, 90lelttrd 9757 . . . . . . 7  |-  ( ph  ->  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  <  ( P  -  1 ) )
9235, 37, 75ltaddsubd 10173 . . . . . . 7  |-  ( ph  ->  ( ( ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  +  1 )  <  P  <->  (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  <  ( P  - 
1 ) ) )
9391, 92mpbird 232 . . . . . 6  |-  ( ph  ->  ( ( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) ) )  +  1 )  <  P )
94 modid 12023 . . . . . 6  |-  ( ( ( ( ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  +  1 )  e.  RR  /\  P  e.  RR+ )  /\  ( 0  <_  (
( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  +  1 )  /\  ( ( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  -  1 )  /  2 ) ) ( |_ `  (
( Q  /  P
)  x.  ( 2  x.  x ) ) ) )  +  1 )  <  P ) )  ->  ( (
( -u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  +  1 )  mod 
P )  =  ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  +  1 ) )
9550, 38, 74, 93, 94syl22anc 1229 . . . . 5  |-  ( ph  ->  ( ( ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  +  1 )  mod  P
)  =  ( (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  +  1 ) )
9648, 95eqtrd 2498 . . . 4  |-  ( ph  ->  ( ( ( Q ^ ( ( P  -  1 )  / 
2 ) )  +  1 )  mod  P
)  =  ( (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) )  +  1 ) )
9796oveq1d 6311 . . 3  |-  ( ph  ->  ( ( ( ( Q ^ ( ( P  -  1 )  /  2 ) )  +  1 )  mod 
P )  -  1 )  =  ( ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  +  1 )  -  1 ) )
9835recnd 9639 . . . 4  |-  ( ph  ->  ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  e.  CC )
99 pncan 9845 . . . 4  |-  ( ( ( -u 1 ^
sum_ x  e.  (
1 ... ( ( P  -  1 )  / 
2 ) ) ( |_ `  ( ( Q  /  P )  x.  ( 2  x.  x ) ) ) )  e.  CC  /\  1  e.  CC )  ->  ( ( ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  +  1 )  -  1 )  =  ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )
10098, 56, 99sylancl 662 . . 3  |-  ( ph  ->  ( ( ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) )  +  1 )  -  1 )  =  ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )
10197, 100eqtrd 2498 . 2  |-  ( ph  ->  ( ( ( ( Q ^ ( ( P  -  1 )  /  2 ) )  +  1 )  mod 
P )  -  1 )  =  ( -u
1 ^ sum_ x  e.  ( 1 ... (
( P  -  1 )  /  2 ) ) ( |_ `  ( ( Q  /  P )  x.  (
2  x.  x ) ) ) ) )
1027, 101eqtrd 2498 1  |-  ( ph  ->  ( Q  /L
P )  =  (
-u 1 ^ sum_ x  e.  ( 1 ... ( ( P  - 
1 )  /  2
) ) ( |_
`  ( ( Q  /  P )  x.  ( 2  x.  x
) ) ) ) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    <-> wb 184    /\ wa 369    = wceq 1395    e. wcel 1819    =/= wne 2652    \ cdif 3468   {csn 4032   class class class wbr 4456    |-> cmpt 4515   ` cfv 5594  (class class class)co 6296   CCcc 9507   RRcr 9508   0cc0 9509   1c1 9510    + caddc 9512    x. cmul 9514    < clt 9645    <_ cle 9646    - cmin 9824   -ucneg 9825    / cdiv 10227   NNcn 10556   2c2 10606   ZZcz 10885   ZZ>=cuz 11106   RR+crp 11245   ...cfz 11697   |_cfl 11930    mod cmo 11999   ^cexp 12169   abscabs 13079   sum_csu 13520   Primecprime 14229  mulGrpcmgp 17268   ZRHomczrh 18664  ℤ/nczn 18667    /Lclgs 23695
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1619  ax-4 1632  ax-5 1705  ax-6 1748  ax-7 1791  ax-8 1821  ax-9 1823  ax-10 1838  ax-11 1843  ax-12 1855  ax-13 2000  ax-ext 2435  ax-rep 4568  ax-sep 4578  ax-nul 4586  ax-pow 4634  ax-pr 4695  ax-un 6591  ax-inf2 8075  ax-cnex 9565  ax-resscn 9566  ax-1cn 9567  ax-icn 9568  ax-addcl 9569  ax-addrcl 9570  ax-mulcl 9571  ax-mulrcl 9572  ax-mulcom 9573  ax-addass 9574  ax-mulass 9575  ax-distr 9576  ax-i2m1 9577  ax-1ne0 9578  ax-1rid 9579  ax-rnegex 9580  ax-rrecex 9581  ax-cnre 9582  ax-pre-lttri 9583  ax-pre-lttrn 9584  ax-pre-ltadd 9585  ax-pre-mulgt0 9586  ax-pre-sup 9587  ax-addf 9588  ax-mulf 9589
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 974  df-3an 975  df-tru 1398  df-fal 1401  df-ex 1614  df-nf 1618  df-sb 1741  df-eu 2287  df-mo 2288  df-clab 2443  df-cleq 2449  df-clel 2452  df-nfc 2607  df-ne 2654  df-nel 2655  df-ral 2812  df-rex 2813  df-reu 2814  df-rmo 2815  df-rab 2816  df-v 3111  df-sbc 3328  df-csb 3431  df-dif 3474  df-un 3476  df-in 3478  df-ss 3485  df-pss 3487  df-nul 3794  df-if 3945  df-pw 4017  df-sn 4033  df-pr 4035  df-tp 4037  df-op 4039  df-uni 4252  df-int 4289  df-iun 4334  df-br 4457  df-opab 4516  df-mpt 4517  df-tr 4551  df-eprel 4800  df-id 4804  df-po 4809  df-so 4810  df-fr 4847  df-se 4848  df-we 4849  df-ord 4890  df-on 4891  df-lim 4892  df-suc 4893  df-xp 5014  df-rel 5015  df-cnv 5016  df-co 5017  df-dm 5018  df-rn 5019  df-res 5020  df-ima 5021  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-isom 5603  df-riota 6258  df-ov 6299  df-oprab 6300  df-mpt2 6301  df-of 6539  df-om 6700  df-1st 6799  df-2nd 6800  df-supp 6918  df-tpos 6973  df-recs 7060  df-rdg 7094  df-1o 7148  df-2o 7149  df-oadd 7152  df-er 7329  df-ec 7331  df-qs 7335  df-map 7440  df-en 7536  df-dom 7537  df-sdom 7538  df-fin 7539  df-fsupp 7848  df-sup 7919  df-oi 7953  df-card 8337  df-cda 8565  df-pnf 9647  df-mnf 9648  df-xr 9649  df-ltxr 9650  df-le 9651  df-sub 9826  df-neg 9827  df-div 10228  df-nn 10557  df-2 10615  df-3 10616  df-4 10617  df-5 10618  df-6 10619  df-7 10620  df-8 10621  df-9 10622  df-10 10623  df-n0 10817  df-z 10886  df-dec 11001  df-uz 11107  df-q 11208  df-rp 11246  df-fz 11698  df-fzo 11822  df-fl 11932  df-mod 12000  df-seq 12111  df-exp 12170  df-hash 12409  df-cj 12944  df-re 12945  df-im 12946  df-sqrt 13080  df-abs 13081  df-clim 13323  df-sum 13521  df-dvds 13999  df-gcd 14157  df-prm 14230  df-phi 14308  df-pc 14373  df-struct 14646  df-ndx 14647  df-slot 14648  df-base 14649  df-sets 14650  df-ress 14651  df-plusg 14725  df-mulr 14726  df-starv 14727  df-sca 14728  df-vsca 14729  df-ip 14730  df-tset 14731  df-ple 14732  df-ds 14734  df-unif 14735  df-0g 14859  df-gsum 14860  df-imas 14925  df-qus 14926  df-mgm 15999  df-sgrp 16038  df-mnd 16048  df-mhm 16093  df-submnd 16094  df-grp 16184  df-minusg 16185  df-sbg 16186  df-mulg 16187  df-subg 16325  df-nsg 16326  df-eqg 16327  df-ghm 16392  df-cntz 16482  df-cmn 16927  df-abl 16928  df-mgp 17269  df-ur 17281  df-ring 17327  df-cring 17328  df-oppr 17399  df-dvdsr 17417  df-unit 17418  df-invr 17448  df-dvr 17459  df-rnghom 17491  df-drng 17525  df-field 17526  df-subrg 17554  df-lmod 17641  df-lss 17706  df-lsp 17745  df-sra 17945  df-rgmod 17946  df-lidl 17947  df-rsp 17948  df-2idl 18007  df-nzr 18033  df-rlreg 18058  df-domn 18059  df-idom 18060  df-cnfld 18548  df-zring 18616  df-zrh 18668  df-zn 18671  df-lgs 23696
This theorem is referenced by:  lgsquadlem2  23756
  Copyright terms: Public domain W3C validator