let f be PartFunc of REAL ,REAL ; :: thesis: for A, B, C being closed-interval Subset of REAL
for X being set st A c= X & f is_differentiable_on X & (f `| X) | A is continuous & inf A = inf B & sup B = inf C & sup C = sup A holds
( B c= A & C c= A & integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C) )

let A, B, C be closed-interval Subset of REAL ; :: thesis: for X being set st A c= X & f is_differentiable_on X & (f `| X) | A is continuous & inf A = inf B & sup B = inf C & sup C = sup A holds
( B c= A & C c= A & integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C) )

let X be set ; :: thesis: ( A c= X & f is_differentiable_on X & (f `| X) | A is continuous & inf A = inf B & sup B = inf C & sup C = sup A implies ( B c= A & C c= A & integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C) ) )
assume that
A1: A c= X and
A2: f is_differentiable_on X and
A3: (f `| X) | A is continuous and
A4: inf A = inf B and
A5: sup B = inf C and
A6: sup C = sup A ; :: thesis: ( B c= A & C c= A & integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C) )
X: A c= dom (f `| X) by A2, A1, FDIFF_1:def 8;
consider x being Real such that
A7: x in B by SUBSET_1:10;
( inf B <= x & x <= sup B ) by A7, INTEGRA2:1;
then A8: inf B <= sup B by XXREAL_0:2;
consider x being Real such that
A9: x in C by SUBSET_1:10;
( inf C <= x & x <= sup C ) by A9, INTEGRA2:1;
then A10: inf C <= sup C by XXREAL_0:2;
for x being set st x in B holds
x in A
proof
let x be set ; :: thesis: ( x in B implies x in A )
assume A11: x in B ; :: thesis: x in A
then reconsider x = x as Real ;
( inf B <= x & x <= sup B ) by A11, INTEGRA2:1;
then ( inf A <= x & x <= sup A ) by A4, A5, A6, A10, XXREAL_0:2;
hence x in A by INTEGRA2:1; :: thesis: verum
end;
hence A12: B c= A by TARSKI:def 3; :: thesis: ( C c= A & integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C) )
for x being set st x in C holds
x in A
proof
let x be set ; :: thesis: ( x in C implies x in A )
assume A13: x in C ; :: thesis: x in A
then reconsider x = x as Real ;
( inf C <= x & x <= sup C ) by A13, INTEGRA2:1;
then ( inf A <= x & x <= sup A ) by A4, A5, A6, A8, XXREAL_0:2;
hence x in A by INTEGRA2:1; :: thesis: verum
end;
hence A14: C c= A by TARSKI:def 3; :: thesis: integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C)
then B14: ( B c= dom (f `| X) & C c= dom (f `| X) ) by A12, X, XBOOLE_1:1;
( (f `| X) | A is continuous & (f `| X) | B is continuous & (f `| X) | C is continuous ) by A3, A12, A14, FCONT_1:17;
then A15: ( f `| X is_integrable_on A & f `| X is_integrable_on B & f `| X is_integrable_on C ) by Th11, X, B14;
A16: (f `| X) | A is bounded by A3, Th10, X;
then ( (f `| X) | B is bounded & (f `| X) | C is bounded ) by A12, A14, RFUNCT_1:91;
then ( integral (f `| X),A = (f . (sup A)) - (f . (inf A)) & integral (f `| X),B = (f . (sup B)) - (f . (inf B)) & integral (f `| X),C = (f . (sup C)) - (f . (inf C)) ) by A1, A2, A12, A14, A15, A16, Th13, XBOOLE_1:1;
hence integral (f `| X),A = (integral (f `| X),B) + (integral (f `| X),C) by A4, A5, A6; :: thesis: verum