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

theorem Th3:
  q in OpenHypercube(p,r)
    iff
  for i st i in Seg n holds q.i in ]. p.i - r,p.i +r .[
proof
A1: len q = n by CARD_1:def 7;
  thus q in OpenHypercube(p,r) implies for i st i in Seg n holds
      q.i in ]. p.i-r,p.i+r .[
    proof
      assume
A2:     q in OpenHypercube(p,r);
      let i such that
A3:     i in Seg n;
      set P=PROJ(n,i);
      dom P = the carrier of TOP-REAL n by FUNCT_2:def 1;
      then
A4:     P.q in P.:OpenHypercube(p,r) by A2,FUNCT_1:def 6;
A5:   P.q = q/.i by TOPREALC:def 6;
      len q = n by CARD_1:def 7;
      then dom q = Seg n by FINSEQ_1:def 3;
      then q/.i = q.i by A3,PARTFUN1:def 6;
      hence thesis by A5,Th2,A3,A4;
    end;
  assume
A6: for i st i in Seg n holds q.i in ]. p.i - r,p.i+r .[;
  consider e be Point of Euclid n such that
A7: p=e
  and
A8: OpenHypercube(p,r) = OpenHypercube(e,r) by Def1;
  set I= Intervals(e,r);
A9: dom I = dom e by EUCLID_9:def 3;
  len p = n by CARD_1:def 7;
  then
A10: dom p = dom q by A1, FINSEQ_3:29;
A11: dom q = Seg n by A1,FINSEQ_1:def 3;
A12: now
      let x be object;
      assume
A13:    x in dom q;
      then reconsider i= x as Nat;
      q.i in ]. p.i - r,p.i+r .[ by A6,A13,A11;
      hence q.x in I.x by EUCLID_9:def 3,A7,A13,A10;
    end;
  product I = OpenHypercube(p,r) by A8,EUCLID_9:def 4;
  hence thesis by A12,A7,A10,A9,CARD_3:9;
end;
