reserve a,b,r for Real;
reserve A for non empty set;
reserve X,x for set;
reserve f,g,F,G for PartFunc of REAL,REAL;
reserve n for Element of NAT;

theorem
  b <= a & [. b,a .] c= X & X c= dom f & X c= dom g & f|X is continuous &
  g|X is continuous & F is_integral_of f,X & G is_integral_of g,X implies
  (F.a)*(G.a) - (F.b)*(G.b) = integral(f(#)G,b,a)+ integral(F(#)g,b,a)
proof
  assume that
A1: b <= a and
A2: [. b,a .] c= X;
  assume that
A3: X c= dom f and
A4: X c= dom g and
A5: f|X is continuous and
A6: g|X is continuous and
A7: F is_integral_of f,X & G is_integral_of g,X;
A8: [. b,a .] c= dom f by A2,A3;
A9: [. b,a .] =[' b,a '] by A1,INTEGRA5:def 3;
  then f|[' b,a '] is continuous by A2,A5,FCONT_1:16;
  then
A10: f is_integrable_on [' b,a '] by A8,A9,INTEGRA5:17;
A11: [. b,a .] c= dom g by A2,A4;
  then
A12: g|[' b,a '] is bounded by A2,A6,A9,FCONT_1:16,INTEGRA5:10;
  g|[' b,a '] is continuous by A2,A6,A9,FCONT_1:16;
  then
A13: g is_integrable_on [' b,a '] by A11,A9,INTEGRA5:17;
  f|[' b,a '] is bounded by A2,A5,A8,A9,FCONT_1:16,INTEGRA5:10;
  hence thesis by A1,A2,A3,A4,A7,A9,A10,A13,A12,Th21;
end;
