let n, m be Element of NAT ; :: thesis: for r being Real
for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 holds
card X <= [\r/]

defpred S1[ Nat] means for n, m being Element of NAT
for r being Real
for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & $1 = [\r/] holds
card X <= [\r/];
A1: for n being Nat st S1[n] holds
S1[n + 1]
proof
let n be Nat; :: thesis: ( S1[n] implies S1[n + 1] )
assume A2: S1[n] ; :: thesis: S1[n + 1]
now :: thesis: for m being Element of NAT
for r being Real
for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & n + 1 = [\r/] holds
card X <= [\r/]
let m be Element of NAT ; :: thesis: for r being Real
for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & n + 1 = [\r/] holds
card b5 <= [\b4/]

let r be Real; :: thesis: for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & n + 1 = [\r/] holds
card b4 <= [\b3/]

let X be finite set ; :: thesis: ( X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & n + 1 = [\r/] implies card b3 <= [\b2/] )
set r1 = r - 1;
set X1 = { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } ;
set X2 = { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ;
A3: 0 + n <= 1 + n by XREAL_1:6;
assume A4: X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } ; :: thesis: ( r >= 0 & n + 1 = [\r/] implies card b3 <= [\b2/] )
now :: thesis: for x being object st x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } holds
x in X
let x be object ; :: thesis: ( x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } implies b1 in X )
assume A5: x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ; :: thesis: b1 in X
per cases ( x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } or x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ) by A5, XBOOLE_0:def 3;
suppose x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } ; :: thesis: b1 in X
then consider p being prime Element of NAT such that
A6: F1(p,m) = x and
A7: p <= r - 1 and
A8: P1[p,m] ;
(- 1) + r <= 0 + r by XREAL_1:6;
then p <= r by A7, XXREAL_0:2;
hence x in X by A4, A6, A8; :: thesis: verum
end;
suppose x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ; :: thesis: b1 in X
then ex p being prime Element of NAT st
( F1(p,m) = x & r - 1 < p & p <= r & P1[p,m] ) ;
hence x in X by A4; :: thesis: verum
end;
end;
end;
then A9: { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } c= X ;
assume r >= 0 ; :: thesis: ( n + 1 = [\r/] implies card b3 <= [\b2/] )
now :: thesis: for x being object st x in X holds
x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) }
let x be object ; :: thesis: ( x in X implies x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } )
assume x in X ; :: thesis: x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) }
then consider p being prime Element of NAT such that
A10: ( F1(p,m) = x & p <= r & P1[p,m] ) by A4;
( ( F1(p,m) = x & p <= r - 1 & P1[p,m] ) or ( F1(p,m) = x & r - 1 < p & p <= r & P1[p,m] ) ) by A10;
then ( x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } or x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ) ;
hence x in { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } by XBOOLE_0:def 3; :: thesis: verum
end;
then X c= { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ;
then A11: X = { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } \/ { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } by A9, XBOOLE_0:def 10;
then reconsider X1 = { F1(p,m) where p is prime Element of NAT : ( p <= r - 1 & P1[p,m] ) } as finite set by FINSET_1:1, XBOOLE_1:7;
assume A12: n + 1 = [\r/] ; :: thesis: card b3 <= [\b2/]
then A13: n = [\r/] + (- 1)
.= [\(r + (- 1))/] by INT_1:28
.= [\(r - 1)/] ;
then A14: r - 1 >= 0 by INT_1:def 6;
then A15: card X1 <= [\(r - 1)/] by A2, A13;
per cases ( for x being object holds not x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } or ex x being set st x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ) ;
suppose for x being object holds not x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ; :: thesis: card b3 <= [\b2/]
then { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } = {} by XBOOLE_0:def 1;
hence card X <= [\r/] by A12, A13, A11, A15, A3, XXREAL_0:2; :: thesis: verum
end;
suppose A16: ex x being set st x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ; :: thesis: card b3 <= [\b2/]
then consider x being set such that
A17: x in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } ;
A18: now :: thesis: not { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } <> {x}
assume { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } <> {x} ; :: thesis: contradiction
then consider y being object such that
A19: y in { F1(p,m) where p is prime Element of NAT : ( r - 1 < p & p <= r & P1[p,m] ) } and
A20: y <> x by A16, ZFMISC_1:35;
consider p1 being prime Element of NAT such that
A21: F1(p1,m) = x and
A22: ( r - 1 < p1 & p1 <= r ) and
P1[p1,m] by A17;
A23: p1 = [\r/] by A22, INT_1:def 6;
ex p2 being prime Element of NAT st
( F1(p2,m) = y & r - 1 < p2 & p2 <= r & P1[p2,m] ) by A19;
hence contradiction by A20, A21, A23, INT_1:def 6; :: thesis: verum
end;
end;
end;
end;
hence S1[n + 1] ; :: thesis: verum
end;
A24: S1[ 0 ]
proof
let n, m be Element of NAT ; :: thesis: for r being Real
for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & 0 = [\r/] holds
card X <= [\r/]

let r be Real; :: thesis: for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & 0 = [\r/] holds
card X <= [\r/]

let X be finite set ; :: thesis: ( X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 & 0 = [\r/] implies card X <= [\r/] )
assume A25: X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } ; :: thesis: ( not r >= 0 or not 0 = [\r/] or card X <= [\r/] )
assume r >= 0 ; :: thesis: ( not 0 = [\r/] or card X <= [\r/] )
assume A26: 0 = [\r/] ; :: thesis: card X <= [\r/]
then r - 1 < 0 by INT_1:def 6;
then A27: (r - 1) + 1 < 0 + 1 by XREAL_1:6;
now :: thesis: for x being object holds not x in X
let x be object ; :: thesis: not x in X
assume x in X ; :: thesis: contradiction
then consider p being prime Element of NAT such that
F1(p,m) = x and
A28: p <= r and
P1[p,m] by A25;
p < 1 by A27, A28, XXREAL_0:2;
hence contradiction by INT_2:def 4; :: thesis: verum
end;
hence card X <= [\r/] by A26, CARD_1:27, XBOOLE_0:def 1; :: thesis: verum
end;
A29: for n being Nat holds S1[n] from NAT_1:sch 2(A24, A1);
let r be Real; :: thesis: for X being finite set st X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 holds
card X <= [\r/]

let X be finite set ; :: thesis: ( X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } & r >= 0 implies card X <= [\r/] )
assume that
A30: X = { F1(p,m) where p is prime Element of NAT : ( p <= r & P1[p,m] ) } and
A31: r >= 0 ; :: thesis: card X <= [\r/]
[\r/] is Element of NAT by A31, INT_1:53;
hence card X <= [\r/] by A29, A30, A31; :: thesis: verum