reserve m for Cardinal,
  A,B,C for Ordinal,
  x,y,z,X,Y,Z,W for set,
  f for Function;
reserve f,g for Function,
  L for Sequence,
  F for Cardinal-Function;

theorem Th40:
  X is epsilon-transitive & A in the_rank_of X implies ex Y st Y
  in X & the_rank_of Y = A
proof
  assume that
A1: X is epsilon-transitive and
A2: A in the_rank_of X;
  defpred P[Ordinal] means ex Y st A in $1 & Y in X & the_rank_of Y = $1;
  assume
A3: not thesis;
A4: ex B st P[B]
  proof
    assume
A5: for B,Y st A in B & Y in X holds the_rank_of Y <> B;
    X c= Rank A
    proof
      let x be object;
      reconsider xx=x as set by TARSKI:1;
      assume
A6:   x in X;
      then
A7:   the_rank_of xx <> A by A3;
      the_rank_of xx c= A by A5,A6,ORDINAL1:16;
      then the_rank_of xx c< A by A7;
      then the_rank_of xx in A by ORDINAL1:11;
      hence thesis by CLASSES1:66;
    end;
    then the_rank_of X c= A by CLASSES1:65;
    hence contradiction by A2,ORDINAL1:5;
  end;
  consider B such that
A8: P[B] and
A9: for C st P[C] holds B c= C from ORDINAL1:sch 1(A4);
  consider Y such that
A10: A in B and
A11: Y in X and
A12: the_rank_of Y = B by A8;
  Y c= Rank A
  proof
    let x be object;
            reconsider xx=x as set by TARSKI:1;
A13: Y c= X by A1,A11;
    assume
A14: x in Y;
    then the_rank_of xx in B by A12,CLASSES1:68;
    then not A in the_rank_of xx by A9,A14,A13,ORDINAL1:5;
    then
A15: the_rank_of xx c= A by ORDINAL1:16;
    the_rank_of xx <> A by A3,A14,A13;
    then the_rank_of xx c< A by A15;
    then the_rank_of xx in A by ORDINAL1:11;
    hence thesis by CLASSES1:66;
  end;
  then the_rank_of Y c= A by CLASSES1:65;
  hence contradiction by A10,A12,ORDINAL1:5;
end;
