reserve x for Real;
reserve p,q for Point of TOP-REAL 2;

theorem Th17:
  for B0 being Subset of TOP-REAL 2,K0 being Subset of (TOP-REAL 2
)|B0,f being Function of ((TOP-REAL 2)|B0)|K0,((TOP-REAL 2)|B0) st f=Sq_Circ|K0
& B0=NonZero TOP-REAL 2 & K0={p:(p`2<=p`1 & -p`1<=p`2 or p`2>=p`1 & p`2<=-p`1)
  & p<>0.TOP-REAL 2} holds f is continuous & K0 is closed
proof
  reconsider K5={p7 where p7 is Point of TOP-REAL 2:p7`2<=-p7`1 } as closed
  Subset of TOP-REAL 2 by JGRAPH_2:47;
  reconsider K4={p7 where p7 is Point of TOP-REAL 2: p7`1<=p7`2 } as closed
  Subset of TOP-REAL 2 by JGRAPH_2:46;
  reconsider K3={p7 where p7 is Point of TOP-REAL 2: -p7`1<=p7`2 } as closed
  Subset of TOP-REAL 2 by JGRAPH_2:47;
  reconsider K2={p7 where p7 is Point of TOP-REAL 2: p7`2<=p7`1 } as closed
  Subset of TOP-REAL 2 by JGRAPH_2:46;
  defpred P[Point of TOP-REAL 2] means ($1`2<=$1`1 & -$1`1<=$1`2 or $1`2>=$1`1
  & $1`2<=-$1`1);
  let B0 be Subset of TOP-REAL 2,K0 be Subset of (TOP-REAL 2)|B0,f being
  Function of ((TOP-REAL 2)|B0)|K0,((TOP-REAL 2)|B0);
  assume
A1: f=Sq_Circ|K0 & B0=NonZero TOP-REAL 2 & K0={p:(p`2<=p`1 & -p`1<=p`2
  or p`2>=p`1 & p`2<=-p`1) & p<>0.TOP-REAL 2};
  the carrier of (TOP-REAL 2)|B0 = B0 by PRE_TOPC:8;
  then reconsider K1=K0 as Subset of TOP-REAL 2 by XBOOLE_1:1;
  {p:P[p] & p<>0.TOP-REAL 2} c= NonZero TOP-REAL 2 from TopIncl;
  then
A2: ((TOP-REAL 2)|B0)|K0=(TOP-REAL 2)|K1 by A1,PRE_TOPC:7;
  defpred P[Point of TOP-REAL 2] means ($1`2<=$1`1 & -$1`1<=$1`2 or $1`2>=$1`1
  & $1`2<=-$1`1);
  reconsider K1={p7 where p7 is Point of TOP-REAL 2: P[p7]} as Subset of
  TOP-REAL 2 from JGRAPH_2:sch 1;
  defpred P[Point of TOP-REAL 2] means ($1`2<=$1`1 & -$1`1<=$1`2 or $1`2>=$1`1
  & $1`2<=-$1`1);
  {p: P[p] & p<>0.TOP-REAL 2} = {p7 where p7 is Point of TOP-REAL 2: P[p7
  ]} /\ (NonZero TOP-REAL 2) from TopInter;
  then
A3: K0=K1 /\ [#]((TOP-REAL 2)|B0) by A1,PRE_TOPC:def 5;
A4: K2 /\ K3 \/ K4 /\ K5 c= K1
  proof
    let x be object;
    assume
A5: x in K2 /\ K3 \/ K4 /\ K5;
    per cases by A5,XBOOLE_0:def 3;
    suppose
A6:   x in K2 /\ K3;
      then x in K3 by XBOOLE_0:def 4;
      then
A7:   ex p8 being Point of TOP-REAL 2 st p8=x & -p8`1<=p8`2;
      x in K2 by A6,XBOOLE_0:def 4;
      then ex p7 being Point of TOP-REAL 2 st p7=x & p7`2<=(p7`1);
      hence thesis by A7;
    end;
    suppose
A8:   x in K4 /\ K5;
      then x in K5 by XBOOLE_0:def 4;
      then
A9:   ex p8 being Point of TOP-REAL 2 st p8=x & p8`2<= -p8`1;
      x in K4 by A8,XBOOLE_0:def 4;
      then ex p7 being Point of TOP-REAL 2 st p7=x & p7`2>=(p7`1);
      hence thesis by A9;
    end;
  end;
A10: K2 /\ K3 is closed & K4 /\ K5 is closed by TOPS_1:8;
  K1 c= K2 /\ K3 \/ K4 /\ K5
  proof
    let x be object;
    assume x in K1;
    then ex p being Point of TOP-REAL 2 st p=x &( p`2<=p`1 & -p`1 <=p`2 or p`2
    >=p`1 & p`2<=-p`1);
    then x in K2 & x in K3 or x in K4 & x in K5;
    then x in K2 /\ K3 or x in K4 /\ K5 by XBOOLE_0:def 4;
    hence thesis by XBOOLE_0:def 3;
  end;
  then K1=K2 /\ K3 \/ K4 /\ K5 by A4;
  then K1 is closed by A10,TOPS_1:9;
  hence thesis by A1,A2,A3,Th15,PRE_TOPC:13;
end;
