ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  rpexp Unicode version

Theorem rpexp 12085
Description: If two numbers  A and  B are relatively prime, then they are still relatively prime if raised to a power. (Contributed by Mario Carneiro, 24-Feb-2014.)
Assertion
Ref Expression
rpexp  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( ( A ^ N )  gcd  B
)  =  1  <->  ( A  gcd  B )  =  1 ) )

Proof of Theorem rpexp
Dummy variable  p is distinct from all other variables.
StepHypRef Expression
1 0exp 10490 . . . . . 6  |-  ( N  e.  NN  ->  (
0 ^ N )  =  0 )
21oveq1d 5857 . . . . 5  |-  ( N  e.  NN  ->  (
( 0 ^ N
)  gcd  0 )  =  ( 0  gcd  0 ) )
32eqeq1d 2174 . . . 4  |-  ( N  e.  NN  ->  (
( ( 0 ^ N )  gcd  0
)  =  1  <->  (
0  gcd  0 )  =  1 ) )
4 oveq1 5849 . . . . . . 7  |-  ( A  =  0  ->  ( A ^ N )  =  ( 0 ^ N
) )
5 oveq12 5851 . . . . . . 7  |-  ( ( ( A ^ N
)  =  ( 0 ^ N )  /\  B  =  0 )  ->  ( ( A ^ N )  gcd 
B )  =  ( ( 0 ^ N
)  gcd  0 ) )
64, 5sylan 281 . . . . . 6  |-  ( ( A  =  0  /\  B  =  0 )  ->  ( ( A ^ N )  gcd 
B )  =  ( ( 0 ^ N
)  gcd  0 ) )
76eqeq1d 2174 . . . . 5  |-  ( ( A  =  0  /\  B  =  0 )  ->  ( ( ( A ^ N )  gcd  B )  =  1  <->  ( ( 0 ^ N )  gcd  0 )  =  1 ) )
8 oveq12 5851 . . . . . 6  |-  ( ( A  =  0  /\  B  =  0 )  ->  ( A  gcd  B )  =  ( 0  gcd  0 ) )
98eqeq1d 2174 . . . . 5  |-  ( ( A  =  0  /\  B  =  0 )  ->  ( ( A  gcd  B )  =  1  <->  ( 0  gcd  0 )  =  1 ) )
107, 9bibi12d 234 . . . 4  |-  ( ( A  =  0  /\  B  =  0 )  ->  ( ( ( ( A ^ N
)  gcd  B )  =  1  <->  ( A  gcd  B )  =  1 )  <->  ( ( ( 0 ^ N )  gcd  0 )  =  1  <->  ( 0  gcd  0 )  =  1 ) ) )
113, 10syl5ibrcom 156 . . 3  |-  ( N  e.  NN  ->  (
( A  =  0  /\  B  =  0 )  ->  ( (
( A ^ N
)  gcd  B )  =  1  <->  ( A  gcd  B )  =  1 ) ) )
12113ad2ant3 1010 . 2  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( A  =  0  /\  B  =  0 )  ->  ( (
( A ^ N
)  gcd  B )  =  1  <->  ( A  gcd  B )  =  1 ) ) )
13 exprmfct 12070 . . . . . . 7  |-  ( ( ( A ^ N
)  gcd  B )  e.  ( ZZ>= `  2 )  ->  E. p  e.  Prime  p 
||  ( ( A ^ N )  gcd 
B ) )
14 simpl1 990 . . . . . . . . . . . . . . . . 17  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  A  e.  ZZ )
15 simpl3 992 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  N  e.  NN )
1615nnnn0d 9167 . . . . . . . . . . . . . . . . 17  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  N  e.  NN0 )
17 zexpcl 10470 . . . . . . . . . . . . . . . . 17  |-  ( ( A  e.  ZZ  /\  N  e.  NN0 )  -> 
( A ^ N
)  e.  ZZ )
1814, 16, 17syl2anc 409 . . . . . . . . . . . . . . . 16  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( A ^ N
)  e.  ZZ )
1918adantr 274 . . . . . . . . . . . . . . 15  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  ( A ^ N )  e.  ZZ )
20 simpl2 991 . . . . . . . . . . . . . . . 16  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  B  e.  ZZ )
2120adantr 274 . . . . . . . . . . . . . . 15  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  B  e.  ZZ )
22 gcddvds 11896 . . . . . . . . . . . . . . 15  |-  ( ( ( A ^ N
)  e.  ZZ  /\  B  e.  ZZ )  ->  ( ( ( A ^ N )  gcd 
B )  ||  ( A ^ N )  /\  ( ( A ^ N )  gcd  B
)  ||  B )
)
2319, 21, 22syl2anc 409 . . . . . . . . . . . . . 14  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( ( A ^ N )  gcd  B
)  ||  ( A ^ N )  /\  (
( A ^ N
)  gcd  B )  ||  B ) )
2423simpld 111 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( A ^ N
)  gcd  B )  ||  ( A ^ N
) )
25 prmz 12043 . . . . . . . . . . . . . . 15  |-  ( p  e.  Prime  ->  p  e.  ZZ )
2625adantl 275 . . . . . . . . . . . . . 14  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  p  e.  ZZ )
27 simpr 109 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  -.  ( A  =  0  /\  B  =  0 ) )
2814zcnd 9314 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  A  e.  CC )
29 expeq0 10486 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( A  e.  CC  /\  N  e.  NN )  ->  ( ( A ^ N )  =  0  <-> 
A  =  0 ) )
3028, 15, 29syl2anc 409 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( A ^ N )  =  0  <-> 
A  =  0 ) )
3130anbi1d 461 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( A ^ N )  =  0  /\  B  =  0 )  <->  ( A  =  0  /\  B  =  0 ) ) )
3227, 31mtbird 663 . . . . . . . . . . . . . . . . 17  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  -.  ( ( A ^ N )  =  0  /\  B  =  0 ) )
33 gcdn0cl 11895 . . . . . . . . . . . . . . . . 17  |-  ( ( ( ( A ^ N )  e.  ZZ  /\  B  e.  ZZ )  /\  -.  ( ( A ^ N )  =  0  /\  B  =  0 ) )  ->  ( ( A ^ N )  gcd 
B )  e.  NN )
3418, 20, 32, 33syl21anc 1227 . . . . . . . . . . . . . . . 16  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( A ^ N )  gcd  B
)  e.  NN )
3534nnzd 9312 . . . . . . . . . . . . . . 15  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( A ^ N )  gcd  B
)  e.  ZZ )
3635adantr 274 . . . . . . . . . . . . . 14  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( A ^ N
)  gcd  B )  e.  ZZ )
37 dvdstr 11768 . . . . . . . . . . . . . 14  |-  ( ( p  e.  ZZ  /\  ( ( A ^ N )  gcd  B
)  e.  ZZ  /\  ( A ^ N )  e.  ZZ )  -> 
( ( p  ||  ( ( A ^ N )  gcd  B
)  /\  ( ( A ^ N )  gcd 
B )  ||  ( A ^ N ) )  ->  p  ||  ( A ^ N ) ) )
3826, 36, 19, 37syl3anc 1228 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( p  ||  (
( A ^ N
)  gcd  B )  /\  ( ( A ^ N )  gcd  B
)  ||  ( A ^ N ) )  ->  p  ||  ( A ^ N ) ) )
3924, 38mpan2d 425 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  ->  p  ||  ( A ^ N
) ) )
40 simpr 109 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  p  e.  Prime )
41 simpll1 1026 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  A  e.  ZZ )
4215adantr 274 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  N  e.  NN )
43 prmdvdsexp 12080 . . . . . . . . . . . . 13  |-  ( ( p  e.  Prime  /\  A  e.  ZZ  /\  N  e.  NN )  ->  (
p  ||  ( A ^ N )  <->  p  ||  A
) )
4440, 41, 42, 43syl3anc 1228 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( A ^ N )  <->  p  ||  A
) )
4539, 44sylibd 148 . . . . . . . . . . 11  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  ->  p  ||  A ) )
4623simprd 113 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( A ^ N
)  gcd  B )  ||  B )
47 dvdstr 11768 . . . . . . . . . . . . 13  |-  ( ( p  e.  ZZ  /\  ( ( A ^ N )  gcd  B
)  e.  ZZ  /\  B  e.  ZZ )  ->  ( ( p  ||  ( ( A ^ N )  gcd  B
)  /\  ( ( A ^ N )  gcd 
B )  ||  B
)  ->  p  ||  B
) )
4826, 36, 21, 47syl3anc 1228 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( p  ||  (
( A ^ N
)  gcd  B )  /\  ( ( A ^ N )  gcd  B
)  ||  B )  ->  p  ||  B ) )
4946, 48mpan2d 425 . . . . . . . . . . 11  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  ->  p  ||  B ) )
5045, 49jcad 305 . . . . . . . . . 10  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  ->  (
p  ||  A  /\  p  ||  B ) ) )
51 dvdsgcd 11945 . . . . . . . . . . 11  |-  ( ( p  e.  ZZ  /\  A  e.  ZZ  /\  B  e.  ZZ )  ->  (
( p  ||  A  /\  p  ||  B )  ->  p  ||  ( A  gcd  B ) ) )
5226, 41, 21, 51syl3anc 1228 . . . . . . . . . 10  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( p  ||  A  /\  p  ||  B )  ->  p  ||  ( A  gcd  B ) ) )
53 nprmdvds1 12072 . . . . . . . . . . . . 13  |-  ( p  e.  Prime  ->  -.  p  ||  1 )
54 breq2 3986 . . . . . . . . . . . . . 14  |-  ( ( A  gcd  B )  =  1  ->  (
p  ||  ( A  gcd  B )  <->  p  ||  1
) )
5554notbid 657 . . . . . . . . . . . . 13  |-  ( ( A  gcd  B )  =  1  ->  ( -.  p  ||  ( A  gcd  B )  <->  -.  p  ||  1 ) )
5653, 55syl5ibrcom 156 . . . . . . . . . . . 12  |-  ( p  e.  Prime  ->  ( ( A  gcd  B )  =  1  ->  -.  p  ||  ( A  gcd  B ) ) )
5756necon2ad 2393 . . . . . . . . . . 11  |-  ( p  e.  Prime  ->  ( p 
||  ( A  gcd  B )  ->  ( A  gcd  B )  =/=  1
) )
5857adantl 275 . . . . . . . . . 10  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( A  gcd  B )  ->  ( A  gcd  B )  =/=  1 ) )
5950, 52, 583syld 57 . . . . . . . . 9  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  ->  ( A  gcd  B )  =/=  1 ) )
6059rexlimdva 2583 . . . . . . . 8  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( E. p  e. 
Prime  p  ||  ( ( A ^ N )  gcd  B )  -> 
( A  gcd  B
)  =/=  1 ) )
61 gcdn0cl 11895 . . . . . . . . . 10  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ )  /\  -.  ( A  =  0  /\  B  =  0 ) )  ->  ( A  gcd  B )  e.  NN )
62613adantl3 1145 . . . . . . . . 9  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( A  gcd  B
)  e.  NN )
63 eluz2b3 9542 . . . . . . . . . 10  |-  ( ( A  gcd  B )  e.  ( ZZ>= `  2
)  <->  ( ( A  gcd  B )  e.  NN  /\  ( A  gcd  B )  =/=  1 ) )
6463baib 909 . . . . . . . . 9  |-  ( ( A  gcd  B )  e.  NN  ->  (
( A  gcd  B
)  e.  ( ZZ>= ` 
2 )  <->  ( A  gcd  B )  =/=  1
) )
6562, 64syl 14 . . . . . . . 8  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( A  gcd  B )  e.  ( ZZ>= ` 
2 )  <->  ( A  gcd  B )  =/=  1
) )
6660, 65sylibrd 168 . . . . . . 7  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( E. p  e. 
Prime  p  ||  ( ( A ^ N )  gcd  B )  -> 
( A  gcd  B
)  e.  ( ZZ>= ` 
2 ) ) )
6713, 66syl5 32 . . . . . 6  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( A ^ N )  gcd 
B )  e.  (
ZZ>= `  2 )  -> 
( A  gcd  B
)  e.  ( ZZ>= ` 
2 ) ) )
68 exprmfct 12070 . . . . . . 7  |-  ( ( A  gcd  B )  e.  ( ZZ>= `  2
)  ->  E. p  e.  Prime  p  ||  ( A  gcd  B ) )
69 gcddvds 11896 . . . . . . . . . . . . . . 15  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ )  ->  ( ( A  gcd  B )  ||  A  /\  ( A  gcd  B ) 
||  B ) )
7041, 21, 69syl2anc 409 . . . . . . . . . . . . . 14  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( A  gcd  B
)  ||  A  /\  ( A  gcd  B ) 
||  B ) )
7170simpld 111 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  ( A  gcd  B )  ||  A )
72 iddvdsexp 11755 . . . . . . . . . . . . . 14  |-  ( ( A  e.  ZZ  /\  N  e.  NN )  ->  A  ||  ( A ^ N ) )
7341, 42, 72syl2anc 409 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  A  ||  ( A ^ N
) )
7462nnzd 9312 . . . . . . . . . . . . . . 15  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( A  gcd  B
)  e.  ZZ )
7574adantr 274 . . . . . . . . . . . . . 14  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  ( A  gcd  B )  e.  ZZ )
76 dvdstr 11768 . . . . . . . . . . . . . 14  |-  ( ( ( A  gcd  B
)  e.  ZZ  /\  A  e.  ZZ  /\  ( A ^ N )  e.  ZZ )  ->  (
( ( A  gcd  B )  ||  A  /\  A  ||  ( A ^ N ) )  -> 
( A  gcd  B
)  ||  ( A ^ N ) ) )
7775, 41, 19, 76syl3anc 1228 . . . . . . . . . . . . 13  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( ( A  gcd  B )  ||  A  /\  A  ||  ( A ^ N ) )  -> 
( A  gcd  B
)  ||  ( A ^ N ) ) )
7871, 73, 77mp2and 430 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  ( A  gcd  B )  ||  ( A ^ N ) )
79 dvdstr 11768 . . . . . . . . . . . . 13  |-  ( ( p  e.  ZZ  /\  ( A  gcd  B )  e.  ZZ  /\  ( A ^ N )  e.  ZZ )  ->  (
( p  ||  ( A  gcd  B )  /\  ( A  gcd  B ) 
||  ( A ^ N ) )  ->  p  ||  ( A ^ N ) ) )
8026, 75, 19, 79syl3anc 1228 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( p  ||  ( A  gcd  B )  /\  ( A  gcd  B ) 
||  ( A ^ N ) )  ->  p  ||  ( A ^ N ) ) )
8178, 80mpan2d 425 . . . . . . . . . . 11  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( A  gcd  B )  ->  p  ||  ( A ^ N
) ) )
8270simprd 113 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  ( A  gcd  B )  ||  B )
83 dvdstr 11768 . . . . . . . . . . . . 13  |-  ( ( p  e.  ZZ  /\  ( A  gcd  B )  e.  ZZ  /\  B  e.  ZZ )  ->  (
( p  ||  ( A  gcd  B )  /\  ( A  gcd  B ) 
||  B )  ->  p  ||  B ) )
8426, 75, 21, 83syl3anc 1228 . . . . . . . . . . . 12  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( p  ||  ( A  gcd  B )  /\  ( A  gcd  B ) 
||  B )  ->  p  ||  B ) )
8582, 84mpan2d 425 . . . . . . . . . . 11  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( A  gcd  B )  ->  p  ||  B ) )
8681, 85jcad 305 . . . . . . . . . 10  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( A  gcd  B )  ->  (
p  ||  ( A ^ N )  /\  p  ||  B ) ) )
87 dvdsgcd 11945 . . . . . . . . . . 11  |-  ( ( p  e.  ZZ  /\  ( A ^ N )  e.  ZZ  /\  B  e.  ZZ )  ->  (
( p  ||  ( A ^ N )  /\  p  ||  B )  ->  p  ||  ( ( A ^ N )  gcd 
B ) ) )
8826, 19, 21, 87syl3anc 1228 . . . . . . . . . 10  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
( p  ||  ( A ^ N )  /\  p  ||  B )  ->  p  ||  ( ( A ^ N )  gcd 
B ) ) )
89 breq2 3986 . . . . . . . . . . . . . 14  |-  ( ( ( A ^ N
)  gcd  B )  =  1  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  <->  p  ||  1
) )
9089notbid 657 . . . . . . . . . . . . 13  |-  ( ( ( A ^ N
)  gcd  B )  =  1  ->  ( -.  p  ||  ( ( A ^ N )  gcd  B )  <->  -.  p  ||  1 ) )
9153, 90syl5ibrcom 156 . . . . . . . . . . . 12  |-  ( p  e.  Prime  ->  ( ( ( A ^ N
)  gcd  B )  =  1  ->  -.  p  ||  ( ( A ^ N )  gcd 
B ) ) )
9291necon2ad 2393 . . . . . . . . . . 11  |-  ( p  e.  Prime  ->  ( p 
||  ( ( A ^ N )  gcd 
B )  ->  (
( A ^ N
)  gcd  B )  =/=  1 ) )
9392adantl 275 . . . . . . . . . 10  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( ( A ^ N )  gcd 
B )  ->  (
( A ^ N
)  gcd  B )  =/=  1 ) )
9486, 88, 933syld 57 . . . . . . . . 9  |-  ( ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0
) )  /\  p  e.  Prime )  ->  (
p  ||  ( A  gcd  B )  ->  (
( A ^ N
)  gcd  B )  =/=  1 ) )
9594rexlimdva 2583 . . . . . . . 8  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( E. p  e. 
Prime  p  ||  ( A  gcd  B )  -> 
( ( A ^ N )  gcd  B
)  =/=  1 ) )
96 eluz2b3 9542 . . . . . . . . . 10  |-  ( ( ( A ^ N
)  gcd  B )  e.  ( ZZ>= `  2 )  <->  ( ( ( A ^ N )  gcd  B
)  e.  NN  /\  ( ( A ^ N )  gcd  B
)  =/=  1 ) )
9796baib 909 . . . . . . . . 9  |-  ( ( ( A ^ N
)  gcd  B )  e.  NN  ->  ( (
( A ^ N
)  gcd  B )  e.  ( ZZ>= `  2 )  <->  ( ( A ^ N
)  gcd  B )  =/=  1 ) )
9834, 97syl 14 . . . . . . . 8  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( A ^ N )  gcd 
B )  e.  (
ZZ>= `  2 )  <->  ( ( A ^ N )  gcd 
B )  =/=  1
) )
9995, 98sylibrd 168 . . . . . . 7  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( E. p  e. 
Prime  p  ||  ( A  gcd  B )  -> 
( ( A ^ N )  gcd  B
)  e.  ( ZZ>= ` 
2 ) ) )
10068, 99syl5 32 . . . . . 6  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( A  gcd  B )  e.  ( ZZ>= ` 
2 )  ->  (
( A ^ N
)  gcd  B )  e.  ( ZZ>= `  2 )
) )
10167, 100impbid 128 . . . . 5  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( A ^ N )  gcd 
B )  e.  (
ZZ>= `  2 )  <->  ( A  gcd  B )  e.  (
ZZ>= `  2 ) ) )
102101, 98, 653bitr3d 217 . . . 4  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( A ^ N )  gcd 
B )  =/=  1  <->  ( A  gcd  B )  =/=  1 ) )
103 simp1 987 . . . . . . . . . 10  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  A  e.  ZZ )
104 simp3 989 . . . . . . . . . . 11  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  N  e.  NN )
105104nnnn0d 9167 . . . . . . . . . 10  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  N  e.  NN0 )
106103, 105, 17syl2anc 409 . . . . . . . . 9  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  ( A ^ N )  e.  ZZ )
107 simp2 988 . . . . . . . . 9  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  B  e.  ZZ )
108106, 107gcdcld 11901 . . . . . . . 8  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( A ^ N
)  gcd  B )  e.  NN0 )
109108nn0zd 9311 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( A ^ N
)  gcd  B )  e.  ZZ )
110 1zzd 9218 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  1  e.  ZZ )
111 zdceq 9266 . . . . . . 7  |-  ( ( ( ( A ^ N )  gcd  B
)  e.  ZZ  /\  1  e.  ZZ )  -> DECID  ( ( A ^ N
)  gcd  B )  =  1 )
112109, 110, 111syl2anc 409 . . . . . 6  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  -> DECID  ( ( A ^ N )  gcd  B
)  =  1 )
113103, 107gcdcld 11901 . . . . . . . 8  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  ( A  gcd  B )  e. 
NN0 )
114113nn0zd 9311 . . . . . . 7  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  ( A  gcd  B )  e.  ZZ )
115 zdceq 9266 . . . . . . 7  |-  ( ( ( A  gcd  B
)  e.  ZZ  /\  1  e.  ZZ )  -> DECID  ( A  gcd  B )  =  1 )
116114, 110, 115syl2anc 409 . . . . . 6  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  -> DECID  ( A  gcd  B
)  =  1 )
117 nebidc 2416 . . . . . 6  |-  (DECID  ( ( A ^ N )  gcd  B )  =  1  ->  (DECID  ( A  gcd  B )  =  1  ->  ( ( ( ( A ^ N
)  gcd  B )  =  1  <->  ( A  gcd  B )  =  1 )  <->  ( ( ( A ^ N )  gcd  B )  =/=  1  <->  ( A  gcd  B )  =/=  1 ) ) ) )
118112, 116, 117sylc 62 . . . . 5  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( ( ( A ^ N )  gcd 
B )  =  1  <-> 
( A  gcd  B
)  =  1 )  <-> 
( ( ( A ^ N )  gcd 
B )  =/=  1  <->  ( A  gcd  B )  =/=  1 ) ) )
119118adantr 274 . . . 4  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( ( A ^ N )  gcd  B )  =  1  <->  ( A  gcd  B )  =  1 )  <-> 
( ( ( A ^ N )  gcd 
B )  =/=  1  <->  ( A  gcd  B )  =/=  1 ) ) )
120102, 119mpbird 166 . . 3  |-  ( ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  /\  -.  ( A  =  0  /\  B  =  0 ) )  -> 
( ( ( A ^ N )  gcd 
B )  =  1  <-> 
( A  gcd  B
)  =  1 ) )
121120ex 114 . 2  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  ( -.  ( A  =  0  /\  B  =  0 )  ->  ( (
( A ^ N
)  gcd  B )  =  1  <->  ( A  gcd  B )  =  1 ) ) )
122 gcdmndc 11877 . . . 4  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ )  -> DECID  ( A  =  0  /\  B  =  0 ) )
123 exmiddc 826 . . . 4  |-  (DECID  ( A  =  0  /\  B  =  0 )  -> 
( ( A  =  0  /\  B  =  0 )  \/  -.  ( A  =  0  /\  B  =  0
) ) )
124122, 123syl 14 . . 3  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ )  ->  ( ( A  =  0  /\  B  =  0 )  \/  -.  ( A  =  0  /\  B  =  0
) ) )
1251243adant3 1007 . 2  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( A  =  0  /\  B  =  0 )  \/  -.  ( A  =  0  /\  B  =  0 ) ) )
12612, 121, 125mpjaod 708 1  |-  ( ( A  e.  ZZ  /\  B  e.  ZZ  /\  N  e.  NN )  ->  (
( ( A ^ N )  gcd  B
)  =  1  <->  ( A  gcd  B )  =  1 ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    /\ wa 103    <-> wb 104    \/ wo 698  DECID wdc 824    /\ w3a 968    = wceq 1343    e. wcel 2136    =/= wne 2336   E.wrex 2445   class class class wbr 3982   ` cfv 5188  (class class class)co 5842   CCcc 7751   0cc0 7753   1c1 7754   NNcn 8857   2c2 8908   NN0cn0 9114   ZZcz 9191   ZZ>=cuz 9466   ^cexp 10454    || cdvds 11727    gcd cgcd 11875   Primecprime 12039
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 105  ax-ia2 106  ax-ia3 107  ax-in1 604  ax-in2 605  ax-io 699  ax-5 1435  ax-7 1436  ax-gen 1437  ax-ie1 1481  ax-ie2 1482  ax-8 1492  ax-10 1493  ax-11 1494  ax-i12 1495  ax-bndl 1497  ax-4 1498  ax-17 1514  ax-i9 1518  ax-ial 1522  ax-i5r 1523  ax-13 2138  ax-14 2139  ax-ext 2147  ax-coll 4097  ax-sep 4100  ax-nul 4108  ax-pow 4153  ax-pr 4187  ax-un 4411  ax-setind 4514  ax-iinf 4565  ax-cnex 7844  ax-resscn 7845  ax-1cn 7846  ax-1re 7847  ax-icn 7848  ax-addcl 7849  ax-addrcl 7850  ax-mulcl 7851  ax-mulrcl 7852  ax-addcom 7853  ax-mulcom 7854  ax-addass 7855  ax-mulass 7856  ax-distr 7857  ax-i2m1 7858  ax-0lt1 7859  ax-1rid 7860  ax-0id 7861  ax-rnegex 7862  ax-precex 7863  ax-cnre 7864  ax-pre-ltirr 7865  ax-pre-ltwlin 7866  ax-pre-lttrn 7867  ax-pre-apti 7868  ax-pre-ltadd 7869  ax-pre-mulgt0 7870  ax-pre-mulext 7871  ax-arch 7872  ax-caucvg 7873
This theorem depends on definitions:  df-bi 116  df-stab 821  df-dc 825  df-3or 969  df-3an 970  df-tru 1346  df-fal 1349  df-nf 1449  df-sb 1751  df-eu 2017  df-mo 2018  df-clab 2152  df-cleq 2158  df-clel 2161  df-nfc 2297  df-ne 2337  df-nel 2432  df-ral 2449  df-rex 2450  df-reu 2451  df-rmo 2452  df-rab 2453  df-v 2728  df-sbc 2952  df-csb 3046  df-dif 3118  df-un 3120  df-in 3122  df-ss 3129  df-nul 3410  df-if 3521  df-pw 3561  df-sn 3582  df-pr 3583  df-op 3585  df-uni 3790  df-int 3825  df-iun 3868  df-br 3983  df-opab 4044  df-mpt 4045  df-tr 4081  df-id 4271  df-po 4274  df-iso 4275  df-iord 4344  df-on 4346  df-ilim 4347  df-suc 4349  df-iom 4568  df-xp 4610  df-rel 4611  df-cnv 4612  df-co 4613  df-dm 4614  df-rn 4615  df-res 4616  df-ima 4617  df-iota 5153  df-fun 5190  df-fn 5191  df-f 5192  df-f1 5193  df-fo 5194  df-f1o 5195  df-fv 5196  df-riota 5798  df-ov 5845  df-oprab 5846  df-mpo 5847  df-1st 6108  df-2nd 6109  df-recs 6273  df-frec 6359  df-1o 6384  df-2o 6385  df-er 6501  df-en 6707  df-sup 6949  df-pnf 7935  df-mnf 7936  df-xr 7937  df-ltxr 7938  df-le 7939  df-sub 8071  df-neg 8072  df-reap 8473  df-ap 8480  df-div 8569  df-inn 8858  df-2 8916  df-3 8917  df-4 8918  df-n0 9115  df-z 9192  df-uz 9467  df-q 9558  df-rp 9590  df-fz 9945  df-fzo 10078  df-fl 10205  df-mod 10258  df-seqfrec 10381  df-exp 10455  df-cj 10784  df-re 10785  df-im 10786  df-rsqrt 10940  df-abs 10941  df-dvds 11728  df-gcd 11876  df-prm 12040
This theorem is referenced by:  rpexp1i  12086  phiprmpw  12154  pockthlem  12286  logbgcd1irr  13525  logbgcd1irraplemexp  13526
  Copyright terms: Public domain W3C validator