reserve x,x0, r, s, h for Real,

  n for Element of NAT,
  rr, y for set,
  Z for open Subset of REAL,

  f, f1, f2 for PartFunc of REAL,REAL;

theorem Th75:
  -1 <= r & r <= 1 implies diff(arctan,r) = 1/(1+r^2)
proof
  set g = arctan;
  set f = tan|].-PI/2,PI/2.[;
  set x = arctan.r;
  assume that
A1: -1 <= r and
A2: r <= 1;
A3: (sin.x)^2 + (cos.x)^2 = 1 by SIN_COS:28;
A4: f is_differentiable_on ].-PI/2,PI/2.[ by Lm1,FDIFF_2:16;
A5: now
A6: for x0 st x0 in ].-PI/2,PI/2.[ holds 1/(cos.x0)^2 > 0
    proof
      let x0;
      assume x0 in ].-PI/2,PI/2.[;
      then 0 < cos.x0 by COMPTRIG:11;
      then (cos.x0)^2 > 0;
      then 1/(cos.x0)^2 > 0 /(cos.x0)^2;
      hence thesis;
    end;
    let x0 such that
A7: x0 in ].-PI/2,PI/2.[;
    diff(f,x0) = (f`|].-PI/2,PI/2.[).x0 by A4,A7,FDIFF_1:def 7
      .= (tan`|].-PI/2,PI/2.[).x0 by Lm1,FDIFF_2:16
      .= diff(tan,x0) by A7,Lm1,FDIFF_1:def 7
      .= 1/(cos.x0)^2 by A7,Lm3;
    hence 0 < diff(f,x0) by A7,A6;
  end;
A8: r in [.-1,1.] by A1,A2,XXREAL_1:1;
  then
A9: x in [.-PI/4,PI/4.] by Th49;
  x = arctan r;
  then
A10: r = tan x by A1,A2,Th51
    .= sin x/cos x by SIN_COS4:def 1;
  dom f = dom tan /\ ].-PI/2,PI/2.[ by RELAT_1:61;
  then
A11: ].-PI/2,PI/2.[ c= dom f by Th1,XBOOLE_1:19;
A12: f|].-PI/2,PI/2.[ = f by RELAT_1:72;
A13: [.-PI/4,PI/4.] c= ].-PI/2,PI/2.[ by Lm7,Lm8,XXREAL_2:def 12;
  then cos x <> 0 by A9,COMPTRIG:11;
  then r * cos x = sin x by A10,XCMPLX_1:87;
  then
A14: 1 = (cos x)^2 * ( r^2 + 1 ) by A3;
  f is_differentiable_on ].-PI/2,PI/2.[ by Lm1,FDIFF_2:16;
  then diff(f,x) = (f`|].-PI/2,PI/2.[).x by A9,A13,FDIFF_1:def 7
    .= (tan`|].-PI/2,PI/2.[).x by Lm1,FDIFF_2:16
    .= diff(tan,x) by A9,A13,Lm1,FDIFF_1:def 7
    .= 1/(cos x)^2 by A9,A13,Lm3;
  then diff(g,r) = 1/(1/(cos x)^2) by A8,A4,A5,A12,A11,Th23,FDIFF_2:48
    .= 1/(r^2+1) by A14,XCMPLX_1:73;
  hence thesis;
end;
