reserve V for Universe,
  a,b,x,y,z,x9,y9 for Element of V,
  X for Subclass of V,
  o,p,q,r,s,t,u,a1,a2,a3,A,B,C,D for set,
  K,L,M for Ordinal,
  n for Element of omega,
  fs for finite Subset of omega,
  e,g,h for Function,
  E for non empty set,
  f for Function of VAR,E,
  k,k1 for Element of NAT,
  v1,v2,v3 for Element of VAR,
  H,H9 for ZF-formula;

theorem Th9:
  X is closed_wrt_A1-A7 & a in X implies Funcs(fs,a) in X
proof
  defpred P[set] means Funcs($1,a) in X;
  assume that
A1: X is closed_wrt_A1-A7 and
A2: a in X;
A3: X is closed_wrt_A4 by A1;
A4: X is closed_wrt_A5 by A1;
A5: for o,B being set st o in fs & B c= fs & P[B] holds P[B \/ {o}]
  proof
    let o,B be set such that
A6: o in fs and
    B c= fs and
A7: Funcs(B,a) in X;
    per cases;
    suppose
      B meets {o};
      hence thesis by A7,ZFMISC_1:40,50;
    end;
    suppose
A8:   B misses {o};
      set r = {o};
      set A={{[x,y]}: x in r & y in a};
A9:   omega c= X & o in omega by A1,A6,Th7;
      then o in X;
      then reconsider p=o as Element of V;
A10:  Funcs({o},a)=A
      proof
        thus Funcs({o},a) c= A
        proof
          let q be object;
          assume q in Funcs({o},a);
          then consider g such that
A11:      q=g and
A12:      dom g={o} and
A13:      rng g c= a by FUNCT_2:def 2;
          o in dom g by A12,TARSKI:def 1;
          then
A14:      g.o in rng g by FUNCT_1:def 3;
          then reconsider s=g.o as Element of V by A2,A13,Th1;
          o in r & g={[p,s]} by A12,GRFUNC_1:7,TARSKI:def 1;
          hence thesis by A11,A13,A14;
        end;
        let q be object;
        assume q in A;
        then consider x,y such that
A15:    q={[x,y]} and
A16:    x in r and
A17:    y in a;
        reconsider g=q as Function by A15;
        rng g={y} by A15,RELAT_1:9;
        then
A18:    rng g c= a by A17,ZFMISC_1:31;
        x=o by A16,TARSKI:def 1;
        then dom g={o} by A15,RELAT_1:9;
        hence thesis by A18,FUNCT_2:def 2;
      end;
      reconsider x=Funcs(B,a) as Element of V by A7;
      {o} in X by A1,A9,Th2;
      then
A19:  Funcs({o},a) in X by A2,A3,A10;
      then reconsider y=Funcs({o},a) as Element of V;
      set Z={x9 \/ y9: x9 in x & y9 in y};
      Funcs(B \/ {o},a)=Z
      proof
        thus Funcs(B \/ {o},a) c= Z
        proof
          let q be object;
          assume q in Funcs(B \/ {o},a);
          then consider g such that
A20:      q=g and
A21:      dom g=B \/ {o} and
A22:      rng g c= a by FUNCT_2:def 2;
          set A=g|B;
          rng A c= rng g by RELAT_1:70;
          then
A23:      rng A c= a by A22;
          set C=g|{o};
          rng C c= rng g by RELAT_1:70;
          then
A24:      rng C c= a by A22;
          dom C=(B \/ {o}) /\ {o} by A21,RELAT_1:61
            .={o} by XBOOLE_1:21;
          then
A25:      C in y by A24,FUNCT_2:def 2;
          then reconsider y9=C as Element of V by A19,Th1;
          dom A=(B \/ {o}) /\ B by A21,RELAT_1:61
            .=B by XBOOLE_1:21;
          then
A26:      A in x by A23,FUNCT_2:def 2;
          then reconsider x9=A as Element of V by A7,Th1;
          g=(g|(B \/ {o})) by A21
            .=A \/ C by RELAT_1:78;
          then q=x9 \/ y9 by A20;
          hence thesis by A26,A25;
        end;
        let q be object;
        assume q in Z;
        then consider x9,y9 such that
A27:    q=x9 \/ y9 and
A28:    x9 in x and
A29:    y9 in y;
        consider e such that
A30:    x9=e and
A31:    dom e=B and
A32:    rng e c= a by A28,FUNCT_2:def 2;
        consider g such that
A33:    y9=g and
A34:    dom g={o} and
A35:    rng g c= a by A29,FUNCT_2:def 2;
        reconsider h=e \/ g as Function by A8,A31,A34,GRFUNC_1:13;
        rng h=rng e \/ rng g by RELAT_1:12;
        then
A36:    rng h c= a \/ a by A32,A35,XBOOLE_1:13;
        dom h=B \/ {o} by A31,A34,XTUPLE_0:23;
        hence thesis by A27,A30,A33,A36,FUNCT_2:def 2;
      end;
      hence thesis by A4,A7,A19;
    end;
  end;
  Funcs({},a)={{}} & {} in X by A1,Th3,FUNCT_5:57;
  then
A37: P[{}] by A1,Th2;
A38: fs is finite;
  thus P[fs] from FINSET_1:sch 2(A38,A37,A5);
end;
