reserve n   for Nat,
        r,s for Real,
        x,y for Element of REAL n,
        p,q for Point of TOP-REAL n,
        e   for Point of Euclid n;

theorem Th21:
  for cB being Subset-Family of TOP-REAL n st
  cB = union OpenHypercubesRAT(n) holds cB is quasi_basis
  proof
  let F be Subset-Family of TOP-REAL n;
  assume
A1: F = union OpenHypercubesRAT(n);
    F is quasi_basis
    proof
      now
        let x be object;
        assume
A2:     x in the topology of TOP-REAL n;
        then reconsider x1=x as Subset of TOP-REAL n;
A3:     x1 is open by A2;
        the TopStruct of TOP-REAL n = TopSpaceMetr Euclid n by EUCLID:def 8;
        then reconsider x2=x1 as Subset of TopSpaceMetr Euclid n;
A4:     x2 is open by A3,Th10;
        set Y = {t where t is Subset of TOP-REAL n: t in F & t c= x1};
A5:     Y is Subset-Family of TOP-REAL n
        proof
          Y c= bool the carrier of TOP-REAL n
          proof
            let t be object;
            assume t in Y;
            then consider t0 be Subset of TOP-REAL n such that
A6:         t=t0 and
            t0 in F and
            t0 c= x1;
            thus t in bool the carrier of TOP-REAL n by A6;
          end;
          hence thesis;
        end;
A7:     Y c= F
        proof
          let t be object;
          assume t in Y;
          then consider t0 be Subset of TOP-REAL n such that
A8:       t=t0 and
A9:       t0 in F and
          t0 c= x1;
          thus t in F by A8,A9;
        end;
        x = union Y
        proof
          reconsider x3=x as set by TARSKI:1;
A10:      x3 c= union Y
          proof
            let t be object;
            assume
A11:        t in x3;
            then t in x2;
            then reconsider t1 = t as Point of Euclid n;
            consider m1 being non zero Element of NAT such that
A12:        OpenHypercube(t1,1/m1) c= x2 by A4,A11,EUCLID_9:23;
            reconsider t2 = t1 as Point of TOP-REAL n by EUCLID:67;
            reconsider Invm1Div2 = 1/m1/2 as positive Real;
            consider e be Point of Euclid n such that
            t2 = e and
A13:        OpenHypercube(t2,1/m1/2) = OpenHypercube(e,1/m1/2)
               by TIETZE_2:def 1;
            consider q0 be Element of RAT n such that
A14:        q0 in OpenHypercube(t2,Invm1Div2) by A13,Th20;
            q0 in RAT n & RAT n is Subset of REAL n by NUMBERS:12,Th5;
            then reconsider q1 = q0 as Point of TOP-REAL n by EUCLID:22;
            reconsider r = Invm1Div2 * 2 as Real;
A15:        OpenHypercube(q1,r/2) c= OpenHypercube(t2,r) by A14,Th12;
            reconsider q2 = q1 as Point of Euclid n by EUCLID:67;
            set OO = OpenHypercube(q2,Invm1Div2);
A16:        now
              thus OpenHypercube(t2,r) = OpenHypercube(t2,1/m1);
              consider ez be Point of Euclid n such that
A17:          t2 = ez and
A18:          OpenHypercube(t2,1/m1) = OpenHypercube(ez,1/m1)
                 by TIETZE_2:def 1;
              thus OpenHypercube(t1,1/m1) = OpenHypercube(t2,1/m1) by A17,A18;
              thus OpenHypercube(t1,1/m1) c= x1 by A12;
            end;
            consider er be Point of Euclid n such that
A19:        q2 = er and
A20:        OpenHypercube(q1,Invm1Div2) = OpenHypercube(er,Invm1Div2)
                 by TIETZE_2:def 1;
A21:        Invm1Div2 = 1 / ( m1 * 2 ) by XCMPLX_1:78;
A22:        OO in union OpenHypercubesRAT(n)
            proof
              consider e be Point of Euclid n such that
A23:          q2 = e and
              OpenHypercube(q2,Invm1Div2) = OpenHypercube(e,Invm1Div2);
A24:          OO in OpenHypercubes(e) by A21,A23;
              OpenHypercubes(e) in OpenHypercubesRAT(n) by A23;
              hence thesis by A24,TARSKI:def 4;
            end;
            t in OO & OO in F & OO c= x1
               by A22,A1,A19,A20,A14,Th11,A15,A16;
            then t in OO & OO in Y;
            hence t in union Y by TARSKI:def 4;
          end;
          union Y c= x1
          proof
            let t be object;
            assume t in union Y;
            then consider Z be set such that
A25:        t in Z and
A26:        Z in Y by TARSKI:def 4;
            consider t0 be Subset of TOP-REAL n such that
A27:        Z = t0 and
            t0 in F and
A28:        t0 c= x1 by A26;
            thus t in x1 by A25,A27,A28;
          end;
          then x1 = union Y by A10;
          hence thesis;
        end;
        hence x in UniCl F by A5,A7,CANTOR_1:def 1;
      end;
      then the topology of TOP-REAL n c= UniCl F;
      hence thesis by CANTOR_1:def 2;
    end;
    hence thesis;
  end;
