let m, n, r be Nat; ( n > 1 & ( for i being Nat st i < n holds
( (ArProg (m,r)) . i is odd & (ArProg (m,r)) . i is prime ) ) implies for p being Prime st p < n holds
p divides r )
assume A0:
n > 1
; ( ex i being Nat st
( i < n & not ( (ArProg (m,r)) . i is odd & (ArProg (m,r)) . i is prime ) ) or for p being Prime st p < n holds
p divides r )
assume A1:
for i being Nat st i < n holds
( (ArProg (m,r)) . i is odd & (ArProg (m,r)) . i is prime )
; for p being Prime st p < n holds
p divides r
let p be Prime; ( p < n implies p divides r )
assume ZZ:
p < n
; p divides r
per cases
( r = 0 or r <> 0 )
;
suppose Z2:
r <> 0
;
p divides rZz:
n <= m
deffunc H1(
Nat)
-> Element of
NAT =
((ArProg (m,r)) . $1) mod p;
BD:
p < m
by ZZ, Zz, XXREAL_0:2;
JJ:
for
i being
Nat st
0 <= i &
i < n holds
H1(
i)
<> 0
reconsider w =
p - 1 as
Nat ;
reconsider Sw =
Seg w as non
empty finite set ;
deffunc H2(
Nat)
-> Element of
Sw =
In (
(((ArProg (m,r)) . $1) mod p),
Sw);
ex
f being
Function of
({0} \/ (Seg w)),
Sw st
for
x being
Element of
{0} \/ (Seg w) holds
f . x = H2(
x)
from FUNCT_2:sch 4();
then consider f being
Function of
({0} \/ (Seg w)),
Sw such that CC:
for
x being
Element of
{0} \/ (Seg w) holds
f . x = H2(
x)
;
set B =
Seg w;
set A =
{0} \/ (Seg w);
not
0 in Seg w
by FINSEQ_1:1;
then P2:
card ({0} \/ (Seg w)) =
(card (Seg w)) + 1
by CARD_2:41
.=
w + 1
;
reconsider cB =
card (Seg w),
cA =
card ({0} \/ (Seg w)) as
Nat ;
cB < cA
by P2, NAT_1:13;
then
card (Segm cB) in card (Segm cA)
by NAT_1:41;
then consider xx1,
xx2 being
object such that C3:
(
xx1 in {0} \/ (Seg w) &
xx2 in {0} \/ (Seg w) &
xx1 <> xx2 &
f . xx1 = f . xx2 )
by FINSEQ_4:65;
reconsider xx1 =
xx1,
xx2 =
xx2 as
Nat by C3;
ex
n1,
n2 being
Nat st
(
n1 in {0} \/ (Seg w) &
n2 in {0} \/ (Seg w) &
n1 < n2 &
f . n1 = f . n2 )
then consider x2,
x1 being
Nat such that C3:
(
x2 in {0} \/ (Seg w) &
x1 in {0} \/ (Seg w) &
x2 < x1 &
f . x2 = f . x1 )
;
(ArProg (m,r)) . x1 = m + (x1 * r)
by NUMBER06:7;
then H2:
((ArProg (m,r)) . x1) - ((ArProg (m,r)) . x2) = (m + (x1 * r)) - (m + (x2 * r))
by NUMBER06:7;
k1:
(
x1 in {0} or
x1 in Seg w )
by C3, XBOOLE_0:def 3;
then K1:
(
x1 = 0 or ( 1
<= x1 &
x1 <= p - 1 ) )
by FINSEQ_1:1;
K2:
x1 <= p - 1
by k1, FINSEQ_1:1;
(
x2 in {0} or
x2 in Seg w )
by C3, XBOOLE_0:def 3;
then WW:
x2 <= p - 1
by FINSEQ_1:1;
J3:
p - 1
< (p - 1) + 1
by NAT_1:13;
x1 - x2 <= x1 - 0
by XREAL_1:13;
then
x1 - x2 <= w
by K2, XXREAL_0:2;
then T1:
x1 - x2 < p
by J3, XXREAL_0:2;
x1 < p
by K1, J3, XXREAL_0:2;
then
x1 < n
by ZZ, XXREAL_0:2;
then O1:
((ArProg (m,r)) . x1) mod p <> 0
by JJ;
((ArProg (m,r)) . x1) mod p < w + 1
by NAT_D:1;
then O2:
((ArProg (m,r)) . x1) mod p <= w
by NAT_1:13;
Ja:
0 + 1
<= ((ArProg (m,r)) . x1) mod p
by O1, NAT_1:13;
x2 < p
by WW, J3, XXREAL_0:2;
then
(
0 <= x2 &
x2 < n )
by ZZ, XXREAL_0:2;
then O1:
((ArProg (m,r)) . x2) mod p <> 0
by JJ;
((ArProg (m,r)) . x2) mod p < w + 1
by NAT_D:1;
then O3:
((ArProg (m,r)) . x2) mod p <= w
by NAT_1:13;
Jb:
0 + 1
<= ((ArProg (m,r)) . x2) mod p
by O1, NAT_1:13;
f . x1 = In (
(((ArProg (m,r)) . x1) mod p),
Sw)
by C3, CC;
then C4:
f . x1 = ((ArProg (m,r)) . x1) mod p
by Ja, SUBSET_1:def 8, O2, FINSEQ_1:1;
f . x2 = In (
(((ArProg (m,r)) . x2) mod p),
Sw)
by C3, CC;
then
f . x2 = ((ArProg (m,r)) . x2) mod p
by Jb, SUBSET_1:def 8, O3, FINSEQ_1:1;
then SS:
p divides (x1 - x2) * r
by H2, C3, C4, INT_4:23;
x1 - x2 > x2 - x2
by C3, XREAL_1:9;
then
not
p divides x1 - x2
by T1, NAT_D:7;
hence
p divides r
by SS, NAT_6:7;
verum end; end;