reserve Y for TopStruct;
reserve X for non empty TopSpace;

theorem
  for A being Subset of X st A is dense holds A is discrete implies A is
  maximal_discrete
proof
  let A be Subset of X;
  assume
A1: A is dense;
  assume
A2: A is discrete;
  assume A is not maximal_discrete;
  then consider D being Subset of X such that
A3: D is discrete and
A4: A c= D and
A5: A <> D by A2;
  D \ A <> {} by A4,A5,Lm3;
  then consider a being object such that
A6: a in D \ A by XBOOLE_0:def 1;
  reconsider a as Point of X by A6;
  a in D by A6,XBOOLE_0:def 5;
  then consider G being Subset of X such that
A7: G is open and
A8: D /\ G = {a} by A3,Th26;
A9: now
    assume A /\ G = {a};
    then {a} c= A by XBOOLE_1:17;
    then a in A by ZFMISC_1:31;
    hence contradiction by A6,XBOOLE_0:def 5;
  end;
  A /\ G c= D /\ G by A4,XBOOLE_1:26;
  then A /\ G = {} or A /\ G = {a} by A8,ZFMISC_1:33;
  then A misses G or A /\ G = {a};
  then Cl A misses G by A7,A9,TSEP_1:36;
  then
A10: Cl A /\ G = {};
  now
    assume Cl A = the carrier of X;
    then G = {} by A10,XBOOLE_1:28;
    hence contradiction by A8;
  end;
  hence contradiction by A1,TOPS_3:def 2;
end;
