reserve a,b,c for set;

theorem Th18:
  for A being set st A is mutually-disjoint & for a st a in A ex x
  ,y being Real st x < y & ].x,y.[ c= a holds A is countable
proof
  defpred P[object,object] means ex D1 being set st D1 = $1 & $2 in D1;
  let A be set such that
A1: for a,b st a in A & b in A & a <> b holds a misses b;
  assume
A2: a in A implies ex x,y being Real st x < y & ].x,y.[ c= a;
A3: now
    let a be object;
     reconsider aa=a as set by TARSKI:1;
    assume a in A;
    then consider x,y being Real such that
A4: x < y and
A5: ].x,y.[ c= aa by A2;
    consider q being Rational such that
A6: x < q and
A7: q < y by A4,RAT_1:7;
A8: q in RAT by RAT_1:def 2;
    q in ].x,y.[ by A6,A7,XXREAL_1:4;
    hence ex q being object st q in RAT & P[a,q] by A5,A8;
  end;
  consider f being Function such that
A9: dom f = A & rng f c= RAT and
A10: for a being object st a in A holds P[a,f.a] from FUNCT_1:sch 6(A3);
  f is one-to-one
  proof
    let a,b be object;
    assume that
A11: a in dom f and
A12: b in dom f and
A13: f.a = f.b and
A14: a <> b;
     reconsider a,b as set by TARSKI:1;
     P[b,f.b] by A12,A9,A10;
     then
A15: f.a in b by A13;
     P[a,f.a] by A11,A9,A10;
     then
A16: f.a in a;
    a misses b by A11,A12,A14,A1,A9;
    hence thesis by A16,A15,XBOOLE_0:3;
  end;
  then card A c= card RAT by A9,CARD_1:10;
  hence thesis by Th17;
end;
