reserve n for Nat,
        p,p1,p2 for Point of TOP-REAL n,
        x for Real;
reserve n,m for non zero Nat;
reserve i,j for Nat;
reserve f for PartFunc of REAL-NS m,REAL-NS n;
reserve g for PartFunc of REAL m,REAL n;
reserve h for PartFunc of REAL m,REAL;
reserve x for Point of REAL-NS m;
reserve y for Element of REAL m;
reserve X for set;

theorem Th31:
for m be non zero Nat, X be Subset of REAL m holds X is open iff
 for x be Element of REAL m st x in X holds
   ex r be Real st r>0 &
   {y where y is Element of REAL m: |. y-x .| < r} c= X
proof
   let m be non zero Nat,
       X be Subset of REAL m;
   hereby assume X is open;
    then consider VV0 be Subset of REAL-NS m such that
A1: X = VV0 & VV0 is open;
    let x be Element of REAL m;
    assume A2: x in X;
    reconsider V0=VV0 as Subset of TopSpaceNorm (REAL-NS m);
    reconsider v0=x as Point of (REAL-NS m ) by REAL_NS1:def 4;
     V0 is open by A1,NORMSP_2:16;
    then consider d0 be Real such that
A3: d0 >0 & {w where w is Point of (REAL-NS m ): ||.v0-w.|| < d0} c= V0
       by A2,A1,NORMSP_2:7;
    take d0;
    thus 0 < d0 by A3;
    thus {y where y is Element of REAL m: |. y-x .| < d0} c= X
    proof
     let z be object;
     assume z in {y where y is Element of REAL m: |. y-x .| < d0};
     then consider y be Element of REAL m such that
A4:  z=y & |. y-x .| < d0;
     reconsider w=y as Point of REAL-NS m by REAL_NS1:def 4;
      |. y-x .| = ||. w-v0 .|| by REAL_NS1:1,5;
     then ||. v0-w  .|| < d0 by A4,NORMSP_1:7;
     then
 w in {w1 where w1 is Point of REAL-NS m : ||.v0-w1.|| < d0};
     hence z in X by A4,A1,A3;
    end;
   end;
   assume
A5:for x be Element of REAL m st x in X holds ex r be Real st r>0
       & {y where y is Element of REAL m: |. y-x .| < r} c= X;
   reconsider VV0=X as Subset of REAL-NS m by REAL_NS1:def 4;
   reconsider V0=VV0 as Subset of TopSpaceNorm (REAL-NS m);
    for v be Point of REAL-NS m st v in V0
  ex r be Real st r>0 &
      {w where w is Point of REAL-NS m : ||.v-w.|| < r} c= V0
   proof
    let v be Point of REAL-NS m;
    assume A6: v in V0;
    reconsider x=v as Element of REAL m by REAL_NS1:def 4;
    consider d0 be Real such that
A7: d0 >0 & {y where y is Element of REAL m: |. y-x .| < d0 } c= X by A5,A6;
    take d0;
    thus 0 < d0 by A7;
    thus {w where w is Point of REAL-NS m : ||.v-w.|| < d0} c= V0
    proof
     let z be object;
     assume z in {w where w is Point of REAL-NS m : ||.v-w.|| < d0};
     then consider w be Point of REAL-NS m such that
A8:  z=w & ||. v-w .|| < d0;
     reconsider y=w as Element of REAL m by REAL_NS1:def 4;
      |. y-x .| = ||. w-v .|| by REAL_NS1:1,5;
     then |. y-x  .| < d0 by A8,NORMSP_1:7;
     then y in {t where t is Element of REAL m: |. t-x .| < d0};
     hence z in V0 by A8,A7;
    end;
   end;
   then V0 is open by NORMSP_2:7;
   then VV0 is open by NORMSP_2:16;
   hence X is open;
end;
