  reserve n,m,i for Nat,
          p,q for Point of TOP-REAL n,
          r,s for Real,
          R for real-valued FinSequence;

theorem Th11:
  r>0 implies Int ClosedHypercube(p,n|->r) = OpenHypercube(p,r)
proof
  assume r>0;
  set O=OpenHypercube(p,r);
  set C=ClosedHypercube(p,n |-> r);
  set TR=TOP-REAL n, R=n |-> r;
A1: Int C c= C by TOPS_1:16;
  consider e be Point of Euclid n such that
A2: p=e
    and
A3: OpenHypercube(p,r) = OpenHypercube(e,r) by Def1;
  set I=Intervals(e,r);
A4:O = product I by A3,EUCLID_9:def 4;
  thus Int C c= O
  proof
    let x be object;
A5:   len p =n by CARD_1:def 7;
    then
A6:   dom p = Seg n by FINSEQ_1:def 3;
    assume
A7:   x in Int C;
    then reconsider q=x as Point of TR;
A8:   dom p = dom I by A2,EUCLID_9:def 3;
A9: not q in Fr C by TOPS_1:39,A7,XBOOLE_0:3;
A10:for z be object st z in dom I holds q.z in I.z
    proof
       let z be object;
       assume
A11:     z in dom I;
       then
A12:     I.z = ].e.z-r,e.z+r.[ by A2,A8,EUCLID_9:def 3;
       reconsider z as Nat by A11;
A13:   R.z = r by FINSEQ_2:57,A8,A6,A11;
A14:   q.z in [.p.z - R.z,p.z+R.z.] by A1,A7,A8,A6,A11,Def2;
       then p.z - r <= q.z by A13,XXREAL_1:1;
       then
A15:   p.z - r < q.z by A13, A9, A1,A7,Th9,A8,A6,A11,XXREAL_0:1;
       q.z <= p.z + r by A14,A13,XXREAL_1:1;
       then q.z < p.z + r
         by A13,A9,A1,A7,Th9,A8,A6,A11,XXREAL_0:1;
       hence thesis by A15,A2,A12,XXREAL_1:4;
    end;
    len q = n by CARD_1:def 7;
    then dom q=dom p by A5,FINSEQ_3 :29;
    hence thesis by A10,CARD_3:9,A8,A4;
  end;
  let x be object;
  assume
A16:x in O;
  then reconsider q =x as Point of TR;
  len q = n by CARD_1:def 7;
  then
A17:dom q = Seg n by FINSEQ_1:def 3;
  for i st i in Seg n holds q.i in [. p.i - R.i,p.i+R.i .]
  proof
    let i;
A18:  dom PROJ(n,i) = [#]TR by FUNCT_2:def 1;
    assume
A19:  i in Seg n;
    then
A20: R.i = r by FINSEQ_2:57;
    PROJ(n,i).:O = ]. e.i - r, e.i + r .[ by A19,A2,Th2;
    then
A21: PROJ(n,i).q in ]. e.i - r, e.i + r .[ by A18,A16,FUNCT_1:def 6;
A22: PROJ(n,i).q = q/.i by TOPREALC:def 6;
A23: q/.i = q.i by A19, A17,PARTFUN1:def 6;
    then
A24: q.i <= p.i + R.i by A20,A22,A21,A2,XXREAL_1:4;
      q.i >= p.i - R.i by A20,A23,A22,A21,A2,XXREAL_1:4;
    hence thesis by A24,XXREAL_1:1;
  end;
  then
A25:q in C by Def2;
  assume not x in Int C;
  then q in C\Int C by A25,XBOOLE_0:def 5;
  then q in Fr C by TOPS_1:43;
  then consider i such that
A26: i in Seg n
    and
A27: q.i = p.i - R.i or q.i = p.i + R.i by Th9;
A28: dom PROJ(n,i) = [#]TR by FUNCT_2:def 1;
   PROJ(n,i).:O = ]. e.i - r, e.i + r .[ by A2,A26,Th2;
   then
A29: PROJ(n,i).q in ]. e.i - r, e.i + r .[ by A28,A16,FUNCT_1:def 6;
A30: R.i = r by A26,FINSEQ_2:57;
   PROJ(n,i).q = q/.i by TOPREALC:def 6;
   then q.i in ]. e.i - r, e.i + r .[ by A17,A26,PARTFUN1:def 6,A29;
   hence contradiction by A2,A30,XXREAL_1:4,A27;
   reconsider oo= O as Subset of TR;
end;
