reserve x,x0, r,r1,r2 for Real,
      th for Real,

  rr for set,

  rseq for Real_Sequence;

theorem
  cosec.:].-PI/2,0.[ is open
proof
  for x0 st x0 in ].-PI/2,0.[ holds diff(cosec,x0) < 0
  proof
    let x0;
    assume
A1: x0 in ].-PI/2,0.[;
    then x0 < 0 by XXREAL_1:4;
    then
A2: x0+2*PI < 0+2*PI by XREAL_1:8;
    ].-PI/2,0.[ \/ {-PI/2} = [.-PI/2,0.[ by XXREAL_1:131;
    then ].-PI/2,0.[ c= [.-PI/2,0.[ by XBOOLE_1:7;
    then ].-PI/2,0.[ c= ].-PI,0.[ by Lm3;
    then -PI < x0 by A1,XXREAL_1:4;
    then -PI+2*PI < x0+2*PI by XREAL_1:8;
    then x0+2*PI in ].PI,2*PI.[ by A2;
    then sin.(x0+2*PI) < 0 by COMPTRIG:9;
    then
A3: sin.x0 < 0 by SIN_COS:78;
    ].-PI/2,0.[ c= ].-PI/2,PI/2.[ by XXREAL_1:46;
    then cos.x0 > 0 by A1,COMPTRIG:11;
    then -(cos.x0/(sin.x0)^2) < -0 by A3;
    hence thesis by A1,Th7;
  end;
  then rng(cosec|].-PI/2,0.[) is open by Lm16,Th7,FDIFF_2:41;
  hence thesis by RELAT_1:115;
end;
