
theorem Th10:
  for R being non empty RelStr holds R is well_founded iff for S
  being set st for x being Element of R st (the InternalRel of R)-Seg x c= S
  holds x in S holds the carrier of R c= S
proof
  let R be non empty RelStr;
  set c = the carrier of R, r = the InternalRel of R;
  hereby
    assume
A1: R is well_founded;
    let S be set such that
A2: for x being Element of c st r-Seg x c= S holds x in S;
    defpred P[set] means $1 in c & not $1 in S;
    assume not c c= S;
    then consider x being object such that
A3: x in c and
A4: not x in S;
    reconsider x as Element of R by A3;
A5: P[x] by A4;
    consider x0 being Element of R such that
A6: P[x0] and
A7: not ex y being Element of R st x0 <> y & P[y] & [y,x0] in r from
    WFMin(A5, A1);
    now
      assume not r-Seg x0 c= S;
      then consider z being object such that
A8:   z in r-Seg x0 and
A9:   not z in S;
A10:  x0 <> z by A8,WELLORD1:1;
A11:  [z, x0] in r by A8,WELLORD1:1;
      then reconsider z as Element of R by ZFMISC_1:87;
      z = z;
      hence contradiction by A7,A9,A10,A11;
    end;
    hence contradiction by A2,A6;
  end;
  assume
A12: for S being set st for x being Element of c st r-Seg x c= S holds x
  in S holds c c= S;
  assume not R is well_founded;
  then not r is_well_founded_in c;
  then consider Y being set such that
A13: Y c= c & Y <> {} and
A14: not ex a being object st a in Y & r-Seg a misses Y;
  now
    let x be Element of c such that
A15: r-Seg x c= c\Y;
    assume not x in c\Y;
    then x in Y by XBOOLE_0:def 5;
    then r-Seg x meets Y by A14;
    then ex z being object st z in r-Seg x & z in Y by XBOOLE_0:3;
    hence contradiction by A15,XBOOLE_0:def 5;
  end;
  then c c= c\Y by A12;
  hence contradiction by A13,XBOOLE_1:1,38;
end;
