reserve X,Y,Z for set,
  x,y,z for object,
  E for non empty set,
  A,B,C for Ordinal ,
  L,L1 for Sequence,
  f,f1,f2,h for Function,
  d,d1,d2,d9 for Element of E;
reserve f,g,h for (Function of VAR,E),
  u,v,w for (Element of E),
  x for Variable,
  a,b,c for object;

theorem Th11:
  E |= the_axiom_of_extensionality implies for u,v st for w holds
  w in u iff w in v holds u = v
proof
  assume
A1: E |= the_axiom_of_extensionality;
  All(x.0,All(x.1,All(x.2,x.2 'in' x.0 <=> x.2 'in' x.1) => x.0 '=' x.1))
= All(x.0,x.1,All(x.2,x.2 'in' x.0 <=> x.2 'in' x.1) => x.0 '=' x.1) by
ZF_LANG:7;
  then
A2: E |= All(x.1,All(x.2,x.2 'in' x.0 <=> x.2 'in' x.1) => x.0 '=' x.1) by A1,
ZF_MODEL:23,def 6;
A3: for f st for g st for x st g.x <> f.x holds x.2 = x holds g.x.2 in g.x.0
  iff g.x.2 in g.x.1 holds f.x.0 = f.x.1
  proof
    let f such that
A4: for g st for x st g.x <> f.x holds x.2 = x holds g.x.2 in g.x.0
    iff g.x.2 in g.x.1;
A5: now
      let g such that
A6:   for x st g.x <> f.x holds x.2 = x;
A7:   g.x.2 in g.x.1 iff E,g |= x.2 'in' x.1 by ZF_MODEL:13;
      g.x.2 in g.x.0 iff E,g |= x.2 'in' x.0 by ZF_MODEL:13;
      hence E,g |= x.2 'in' x.0 <=> x.2 'in' x.1 by A4,A6,A7,ZF_MODEL:19;
    end;
    E,f |= All(x.2,x.2 'in' x.0 <=> x.2 'in' x.1) => x.0 '=' x.1
     by A2,ZF_MODEL:23,def 5;
    then E,f |= All(x.2,x.2 'in' x.0 <=> x.2 'in' x.1) implies E,f |= x.0 '='
    x.1 by ZF_MODEL:18;
    hence thesis by A5,ZF_MODEL:12,16;
  end;
  for X,Y being Element of E st for Z being Element of E holds Z in X iff
  Z in Y holds X = Y
  proof
    set g = the (Function of VAR,E);
    let X,Y be Element of E such that
A8: for Z being Element of E holds Z in X iff Z in Y;
    set g0 = g+*(x.0,X);
A9: g0.x.0 = X by FUNCT_7:128;
A10: x.0 = 5+0 & x.1 = 5+1 by ZF_LANG:def 2;
    set f = g0+*(x.1,Y);
A11: x.2 = 5+2 by ZF_LANG:def 2;
A12: for h st for x st h.x <> f.x holds x.2 = x holds h.x.2 in h.x.0 iff h
    .x.2 in h.x.1
    proof
      let h;
      assume for x st h.x <> f.x holds x.2 = x;
      then
A13:  h.x.0 = f.x.0 & h.x.1 = f.x.1 by A10,A11;
      h.x.2 in X iff h.x.2 in Y by A8;
      hence thesis by A9,A13,FUNCT_7:32,128;
    end;
    f.x.1 = Y & f.x.0 = g0.x.0 by A10,FUNCT_7:32,128;
    hence thesis by A3,A9,A12;
  end;
  hence thesis;
end;
