defpred S1[ set , set ] means ( ( P1[$1] implies $2 = F3($1) ) & ( P2[$1] implies $2 = F4($1) ) );
defpred S2[ set ] means ( P1[$1] or P2[$1] );
consider Y being set such that
A2:
for x being set holds
( x in Y iff ( x in F1() & S2[x] ) )
from XBOOLE_0:sch 1();
A3:
for x being set st x in Y holds
ex y being set st S1[x,y]
proof
let x be
set ;
( x in Y implies ex y being set st S1[x,y] )
assume A4:
x in Y
;
ex y being set st S1[x,y]
then reconsider a9 =
x as
Element of
F1()
by A2;
now per cases
( P1[a9] or P2[a9] )
by A2, A4;
suppose A5:
P1[
a9]
;
ex y being Element of F2() ex y being set st S1[x,y]take y =
F3(
a9);
ex y being set st S1[x,y]now per cases
( P2[a9] or not P2[a9] )
;
suppose
P2[
a9]
;
ex y being set st S1[x,y]then
F3(
a9)
= F4(
a9)
by A1, A5;
hence
ex
y being
set st
S1[
x,
y]
;
verum end; suppose
P2[
a9]
;
ex y being set st S1[x,y]hence
ex
y being
set st
S1[
x,
y]
;
verum end; end; end; hence
ex
y being
set st
S1[
x,
y]
;
verum end; suppose A6:
P2[
a9]
;
ex y being Element of F2() ex y being set st S1[x,y]take y =
F4(
a9);
ex y being set st S1[x,y]now per cases
( P1[a9] or not P1[a9] )
;
suppose
P1[
a9]
;
ex y being set st S1[x,y]then
F3(
a9)
= F4(
a9)
by A1, A6;
hence
ex
y being
set st
S1[
x,
y]
;
verum end; suppose
P1[
a9]
;
ex y being set st S1[x,y]hence
ex
y being
set st
S1[
x,
y]
;
verum end; end; end; hence
ex
y being
set st
S1[
x,
y]
;
verum end; end; end;
hence
ex
y being
set st
S1[
x,
y]
;
verum
end;
consider f being Function such that
A7:
( dom f = Y & ( for x being set st x in Y holds
S1[x,f . x] ) )
from CLASSES1:sch 1(A3);
A8:
Y c= F1()
rng f c= F2()
then reconsider q = f as PartFunc of F1(),F2() by A8, A7, RELSET_1:4;
take
q
; ( ( for c being Element of F1() holds
( c in dom q iff ( P1[c] or P2[c] ) ) ) & ( for c being Element of F1() st c in dom q holds
( ( P1[c] implies q . c = F3(c) ) & ( P2[c] implies q . c = F4(c) ) ) ) )
thus
for c being Element of F1() holds
( c in dom q iff ( P1[c] or P2[c] ) )
by A2, A7; for c being Element of F1() st c in dom q holds
( ( P1[c] implies q . c = F3(c) ) & ( P2[c] implies q . c = F4(c) ) )
let e be Element of F1(); ( e in dom q implies ( ( P1[e] implies q . e = F3(e) ) & ( P2[e] implies q . e = F4(e) ) ) )
assume
e in dom q
; ( ( P1[e] implies q . e = F3(e) ) & ( P2[e] implies q . e = F4(e) ) )
hence
( ( P1[e] implies q . e = F3(e) ) & ( P2[e] implies q . e = F4(e) ) )
by A7; verum