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

theorem Th7:
  Z c= dom (f1/(f2+f1)) & f1=#Z 2 & (for x st x in Z holds f2.x=1 &
x<>0) implies f1/(f2+f1) is_differentiable_on Z & for x st x in Z holds ((f1/(
  f2+f1))`|Z).x =2*x/(1+x^2)^2
proof
  assume that
A1: Z c= dom (f1/(f2+f1)) and
A2: f1=#Z 2 and
A3: for x st x in Z holds f2.x=1 & x<>0;
A4: Z c= dom f1 /\ (dom (f2+f1) \ (f2+f1)"{0}) by A1,RFUNCT_1:def 1;
  then
A5: Z c= dom (f2+f1) by XBOOLE_1:1;
A6: for x st x in Z holds f1 is_differentiable_in x by A2,TAYLOR_1:2;
  Z c= dom f1 by A4,XBOOLE_1:18;
  then
A7: f1 is_differentiable_on Z by A6,FDIFF_1:9;
A8: for x st x in Z holds (f1`|Z).x=2*x
  proof
    let x;
    2 * (x #Z (2-1))=2 * x by PREPOWER:35;
    then
A9: diff(f1,x) =2 * x by A2,TAYLOR_1:2;
    assume x in Z;
    hence thesis by A7,A9,FDIFF_1:def 7;
  end;
A10: for x st x in Z holds f2.x=1^2 by A3;
  then
A11: f2+f1 is_differentiable_on Z by A2,A5,FDIFF_4:17;
A12: for x st x in Z holds (f2+f1).x <> 0
  proof
    let x;
A13: 1+x^2>0+0 by XREAL_1:8,63;
    assume
A14: x in Z;
    then (f2+f1).x=f2.x+f1.x by A5,VALUED_1:def 1
      .=1+f1.x by A3,A14
      .=1+x #Z 2 by A2,TAYLOR_1:def 1
      .=1+x |^2 by PREPOWER:36
      .=1+x^2 by NEWTON:81;
    hence thesis by A13;
  end;
  then
A15: f1/(f2+f1) is_differentiable_on Z by A11,A7,FDIFF_2:21;
  for x st x in Z holds ((f1/(f2+f1))`|Z).x =2*x/(1+x^2)^2
  proof
    let x;
A16: f1 is_differentiable_in x by A2,TAYLOR_1:2;
A17: f1.x=x #Z 2 by A2,TAYLOR_1:def 1
      .=x |^2 by PREPOWER:36
      .=x^2 by NEWTON:81;
    assume
A18: x in Z;
    then
A19: (f2+f1).x=f2.x+f1.x by A5,VALUED_1:def 1
      .=1+f1.x by A3,A18
      .=1+x #Z 2 by A2,TAYLOR_1:def 1
      .=1+x |^2 by PREPOWER:36
      .=1+x^2 by NEWTON:81;
    f2+f1 is_differentiable_in x & (f2+f1).x<>0 by A11,A12,A18,FDIFF_1:9;
    then
    diff(f1/(f2+f1),x) =(diff(f1,x)*(f2+f1).x - diff(f2+f1,x)*f1.x)/((f2+
    f1).x)^2 by A16,FDIFF_2:14
      .=((f1`|Z).x * (f2+f1).x-diff(f2+f1,x) * f1.x)/((f2+f1).x)^2 by A7,A18,
FDIFF_1:def 7
      .= ((f1`|Z).x * (f2+f1).x-((f2+f1)`|Z).x * f1.x)/((f2+f1).x)^2 by A11,A18
,FDIFF_1:def 7
      .=((2*x)*(f2+f1).x-((f2+f1)`|Z).x * f1.x)/((f2+f1).x)^2 by A8,A18
      .=((2*x)*(1+x^2)-(2*x)*x^2)/(1+x^2)^2 by A2,A10,A5,A18,A17,A19,FDIFF_4:17
      .=2*x/(1+x^2)^2;
    hence thesis by A15,A18,FDIFF_1:def 7;
  end;
  hence thesis by A11,A7,A12,FDIFF_2:21;
end;
