assume A0:
for x being set st x in F1() holds
ex y being set st
( y in F1() & P1[y,x] )
; contradiction
set n = card F1();
set x0 = the Element of F1();
defpred S1[ Nat, set , set ] means ( $2 in F1() implies ( $3 in F1() & P1[$3,$2] ) );
B0:
for m being Element of NAT st 1 <= m & m < (card F1()) + 1 holds
for x being set ex y being set st S1[m,x,y]
proof
let m be
Element of
NAT ;
( 1 <= m & m < (card F1()) + 1 implies for x being set ex y being set st S1[m,x,y] )
assume
( 1
<= m &
m < (card F1()) + 1 )
;
for x being set ex y being set st S1[m,x,y]
let x be
set ;
ex y being set st S1[m,x,y]
per cases
( x nin F1() or x in F1() )
;
suppose Z1:
x nin F1()
;
ex y being set st S1[m,x,y]consider y being
set ;
take
y
;
S1[m,x,y]thus
S1[
m,
x,
y]
by Z1;
verum end; suppose
x in F1()
;
ex y being set st S1[m,x,y]then consider y being
set such that Z2:
(
y in F1() &
P1[
y,
x] )
by A0;
take
y
;
S1[m,x,y]thus
S1[
m,
x,
y]
by Z2;
verum end; end;
end;
consider p being FinSequence such that
B1:
len p = (card F1()) + 1
and
BB:
( p . 1 = the Element of F1() or (card F1()) + 1 = 0 )
and
B2:
for i being Element of NAT st 1 <= i & i < (card F1()) + 1 holds
S1[i,p . i,p . (i + 1)]
from RECDEF_1:sch 3(B0);
defpred S2[ Nat] means ( $1 in dom p implies p . $1 in F1() );
S0:
S2[ 0 ]
by FINSEQ_3:27;
S1:
now let i be
Nat;
( S2[i] implies S2[i + 1] )assume S2:
S2[
i]
;
S2[i + 1]thus
S2[
i + 1]
verum end;
SK:
for i being Nat holds S2[i]
from NAT_1:sch 2(S0, S1);
C0:
rng p c= F1()
CC:
for i, j being Nat st 1 <= i & i < j & j <= (card F1()) + 1 holds
P1[p . j,p . i]
proof
let i,
j be
Nat;
( 1 <= i & i < j & j <= (card F1()) + 1 implies P1[p . j,p . i] )
assume Z0:
1
<= i
;
( not i < j or not j <= (card F1()) + 1 or P1[p . j,p . i] )
assume Z3:
i < j
;
( not j <= (card F1()) + 1 or P1[p . j,p . i] )
then
i + 1
<= j
by NAT_1:13;
then consider k being
Nat such that Z1:
j = (i + 1) + k
by NAT_1:10;
assume Z2:
j <= (card F1()) + 1
;
P1[p . j,p . i]
then
i <= (card F1()) + 1
by Z3, XXREAL_0:2;
then Z4:
i in dom p
by Z0, B1, FINSEQ_3:27;
defpred S3[
Nat]
means (
(i + 1) + $1
<= (card F1()) + 1 implies
P1[
p . ((i + 1) + $1),
p . i] );
R0:
S3[
0 ]
R1:
now let k be
Nat;
( S3[k] implies S3[k + 1] )assume G2:
S3[
k]
;
S3[k + 1]thus
S3[
k + 1]
verumproof
assume G0:
(i + 1) + (k + 1) <= (card F1()) + 1
;
P1[p . ((i + 1) + (k + 1)),p . i]
G4:
(i + 1) + (k + 1) = ((i + 1) + k) + 1
;
then G1:
(i + 1) + k < (card F1()) + 1
by G0, NAT_1:13;
G7:
p . i in F1()
by SK, Z4;
(i + 1) + k = 1
+ (i + k)
;
then G5:
1
<= (i + 1) + k
by NAT_1:11;
then
(i + 1) + k in dom p
by B1, G1, FINSEQ_3:27;
then G6:
(
p . ((i + 1) + k) in F1() &
(i + 1) + k is
Element of
NAT )
by SK;
then
(
p . ((i + 1) + (k + 1)) in F1() &
P1[
p . ((i + 1) + (k + 1)),
p . ((i + 1) + k)] )
by B2, G1, G4, G5;
hence
P1[
p . ((i + 1) + (k + 1)),
p . i]
by P2, G1, G2, G6, G7;
verum
end; end;
for
k being
Nat holds
S3[
k]
from NAT_1:sch 2(R0, R1);
hence
P1[
p . j,
p . i]
by Z1, Z2;
verum
end;
B3:
( dom p = Seg ((card F1()) + 1) & card (Seg ((card F1()) + 1)) = (card F1()) + 1 )
by B1, FINSEQ_1:def 3, FINSEQ_1:78;
card (rng p) c= card F1()
by C0, CARD_1:27;
then
( card (rng p) <= card F1() & card F1() < (card F1()) + 1 )
by NAT_1:19, NAT_1:40;
then
not dom p, rng p are_equipotent
by CARD_1:21, B3;
then
not p is one-to-one
by WELLORD2:def 4;
then consider i, j being set such that
D1:
( i in dom p & j in dom p & p . i = p . j & i <> j )
by FUNCT_1:def 8;
reconsider i = i, j = j as Nat by D1;
D2:
( 1 <= i & 1 <= j & i <= (card F1()) + 1 & j <= (card F1()) + 1 )
by B1, D1, FINSEQ_3:27;
p . i in rng p
by D1, FUNCT_1:def 5;
then D3:
p . i in F1()
by C0;
( i < j or j < i )
by D1, XXREAL_0:1;
then
P1[p . i,p . i]
by CC, D1, D2;
hence
contradiction
by P1, D3; verum