reserve y for set;
reserve x,a,b,c for Real;
reserve n for Element of NAT;
reserve Z for open Subset of REAL;
reserve f,f1,f2 for PartFunc of REAL,REAL;

theorem
  Z c= dom ((-1)(#)(f^)) & (for x st x in Z holds f.x=a+x & f.x <>0)
implies (-1)(#)(f^) is_differentiable_on Z & for x st x in Z holds (((-1)(#)(f^
  ))`|Z).x = 1/(a+x)^2
proof
  assume that
A1: Z c= dom ((-1)(#)(f^)) and
A2: for x st x in Z holds f.x=a+x & f.x <>0;
A3: dom (f^) c= dom f by RFUNCT_1:1;
  Z c= dom (f^) by A1,VALUED_1:def 5;
  then
A4: Z c= dom f by A3,XBOOLE_1:1;
  then
A5: f^ is_differentiable_on Z by A2,Th14;
  now
    let x;
    assume
A6: x in Z;
    hence (((-1)(#)(f^))`|Z).x =(-1)*diff((f^),x) by A1,A5,FDIFF_1:20
      .=(-1)*((f^)`|Z).x by A5,A6,FDIFF_1:def 7
      .=(-1)*(-1/(a+x)^2) by A2,A4,A6,Th14
      .=1/(a+x)^2;
  end;
  hence thesis by A1,A5,FDIFF_1:20;
end;
