 reserve a,b,x,r for Real;
 reserve y for set;
 reserve n for Element of NAT;
 reserve A for non empty closed_interval Subset of REAL;
 reserve f,g,f1,f2,g1,g2 for PartFunc of REAL,REAL;
 reserve Z for open Subset of REAL;

theorem
 A c= Z & Z = dom f & f=exp_R(#)(cos*exp_R) implies
 integral(f,A)=(sin*exp_R).(upper_bound A)-(sin*exp_R).(lower_bound A)
proof
 assume
A1:A c= Z & Z = dom f & f=exp_R(#)(cos*exp_R);
then Z = dom exp_R /\ dom (cos*exp_R) by VALUED_1:def 4;
then A2:Z c= dom exp_R & Z c= dom (cos*exp_R) by XBOOLE_1:18;
for y being object st y in Z holds y in dom (sin*exp_R)
   proof
   let y be object;
   assume y in Z;then
   y in dom exp_R & exp_R.y in dom sin by A2,SIN_COS:24,XREAL_0:def 1;
   hence thesis by FUNCT_1:11;
   end;
then A3:Z c= dom (sin*exp_R);
A4:cos*exp_R is_differentiable_on Z by A2,FDIFF_7:35;
exp_R is_differentiable_on Z by FDIFF_1:26,TAYLOR_1:16;
   then f|Z is continuous by A1,A4,FDIFF_1:21,25;then
f|A is continuous by A1,FCONT_1:16;
then A5:f is_integrable_on A & f|A is bounded by A1,INTEGRA5:10,11;
A6:sin*exp_R is_differentiable_on Z by A3,FDIFF_7:34;
A7:for x st x in Z holds f.x=exp_R.x * cos.(exp_R.x)
    proof
    let x;
    assume
A8:x in Z;
   then (exp_R(#)(cos*exp_R)).x=exp_R.x*(cos*exp_R).x by A1,VALUED_1:def 4
                         .=exp_R.x*cos.(exp_R.x) by A2,A8,FUNCT_1:12;
      hence thesis by A1;
   end;
A9:for x being Element of REAL st x in dom((sin*exp_R)`|Z)
holds ((sin*exp_R)`|Z).x = f.x
   proof
     let x be Element of REAL;
     assume x in dom((sin*exp_R)`|Z);then
A10: x in Z by A6,FDIFF_1:def 7; then
     ((sin*exp_R)`|Z).x=exp_R.x * cos.(exp_R.x) by A3,FDIFF_7:34
       .=f.x by A10,A7;
     hence thesis;
   end;
  dom((sin*exp_R)`|Z)=dom f by A1,A6,FDIFF_1:def 7;
  then ((sin*exp_R)`|Z)= f by A9,PARTFUN1:5;
  hence thesis by A1,A5,A3,FDIFF_7:34,INTEGRA5:13;
end;
