
theorem  Th37:
for X1,X2 be non empty set, A be Subset of [:X1,X2:],
  f be PartFunc of [:X1,X2:],ExtREAL, x be Element of X1, y be Element of X2,
  F be Functional_Sequence of [:X1,X2:],ExtREAL
 st A c= dom f &
   (for n be Nat holds dom(F.n) = A)
 & (for z be Element of [:X1,X2:] st z in A holds
      (F#z) is convergent & lim(F#z) = f.z)
holds
( ex FX be with_the_same_dom Functional_Sequence of X1,ExtREAL
  st (for n be Nat holds FX.n = ProjPMap2(F.n,y))
   & (for x be Element of X1 st x in Y-section(A,y) holds
       FX#x is convergent & (ProjPMap2(f,y)).x = lim(FX#x)) ) &
( ex FY be with_the_same_dom Functional_Sequence of X2,ExtREAL
  st (for n be Nat holds FY.n = ProjPMap1(F.n,x))
   & (for y be Element of X2 st y in X-section(A,x) holds
       FY#y is convergent & (ProjPMap1(f,x)).y = lim(FY#y)) )
proof
    let X1,X2 be non empty set, A be Subset of [:X1,X2:],
    f be PartFunc of [:X1,X2:],ExtREAL, x be Element of X1, y be Element of X2,
    F be Functional_Sequence of [:X1,X2:],ExtREAL;
    assume that
A1:  A c= dom f and
A2:  for n be Nat holds dom(F.n) = A and
A3:  for x be Element of [:X1,X2:] st x in A
       holds (F#x) is convergent & lim(F#x) = f.x;

    set f1 = f|A;
A4: dom f1 = A by A1,RELAT_1:62;

    defpred P2[Element of NAT,object] means $2 = ProjPMap2(F.$1,y);

A5: for n be Element of NAT ex f be Element of PFuncs(X1,ExtREAL) st P2[n,f]
    proof
     let n be Element of NAT;
     reconsider f = ProjPMap2(F.n,y)
       as Element of PFuncs(X1,ExtREAL) by PARTFUN1:45;
     take f;
     thus thesis;
    end;

    thus ex FX be with_the_same_dom Functional_Sequence of X1,ExtREAL
      st (for n be Nat holds FX.n = ProjPMap2(F.n,y))
       & (for x be Element of X1 st x in Y-section(A,y) holds
            FX#x is convergent & (ProjPMap2(f,y)).x = lim(FX#x))
    proof
     consider FX be sequence of PFuncs(X1,ExtREAL) such that
A6:   for n be Element of NAT holds P2[n,FX.n] from FUNCT_2:sch 3(A5);

A7:  for n be Nat holds dom(FX.n) = Y-section(A,y)
     proof
      let n be Nat;
A8:   dom(F.n) = dom(f|A) by A2,A4;
      n is Element of NAT by ORDINAL1:def 12; then
      FX.n = ProjPMap2(F.n,y) by A6;
      hence dom(FX.n) = Y-section(A,y) by A4,A8,Def4;
     end;

     for m,n be Nat holds dom(FX.m) = dom(FX.n)
     proof
      let m,n be Nat;
      dom(FX.m) = Y-section(A,y) by A7;
      hence dom(FX.m) = dom(FX.n) by A7;
     end; then
     reconsider FX as with_the_same_dom Functional_Sequence of X1,ExtREAL
       by MESFUNC8:def 2;
     take FX;

     thus for n be Nat holds FX.n = ProjPMap2(F.n,y)
     proof
      let n be Nat;
      n is Element of NAT by ORDINAL1:def 12;
      hence FX.n = ProjPMap2(F.n,y) by A6;
     end;

     thus for x be Element of X1 st x in Y-section(A,y) holds
       FX#x is convergent & (ProjPMap2(f,y)).x = lim(FX#x)
     proof
      let x be Element of X1;
      reconsider z = [x,y] as Element of [:X1,X2:] by ZFMISC_1:def 2;
      assume x in Y-section(A,y); then
A13:   [x,y] in A by Th25; then
A14:  F#z is convergent & lim(F#z) = f.z by A3;

A15:  for n be Element of NAT holds (FX#x).n = (F#z).n
      proof
       let n be Element of NAT;
A16:   [x,y] in dom(F.n) by A2,A13;
       (FX#x).n = (FX.n).x by MESFUNC5:def 13; then
       (FX#x).n = ProjPMap2(F.n,y).x by A6; then
       (FX#x).n = (F.n).(x,y) by A16,Def4;
       hence (FX#x).n = (F#z).n by MESFUNC5:def 13;
      end;
      hence FX#x is convergent by A14,FUNCT_2:63;
      (ProjPMap2(f,y)).x = f.(x,y) by A1,A13,Def4;
      hence (ProjPMap2(f,y)).x = lim(FX#x) by A14,A15,FUNCT_2:63;
     end;
    end;

    defpred P1[Element of NAT,object] means $2 = ProjPMap1(F.$1,x);

A9: for n be Element of NAT ex f be Element of PFuncs(X2,ExtREAL) st P1[n,f]
    proof
     let n be Element of NAT;
     reconsider f = ProjPMap1(F.n,x)
       as Element of PFuncs(X2,ExtREAL) by PARTFUN1:45;
     take f;
     thus thesis;
    end;

    consider FY be sequence of PFuncs(X2,ExtREAL) such that
A10: for n be Element of NAT holds P1[n,FY.n] from FUNCT_2:sch 3(A9);

A11:for n be Nat holds dom(FY.n) = X-section(A,x)
    proof
     let n be Nat;
A12: dom(F.n) = dom(f|A) by A2,A4;
     n is Element of NAT by ORDINAL1:def 12; then
     FY.n = ProjPMap1(F.n,x) by A10;
     hence dom(FY.n) = X-section(A,x) by A4,A12,Def3;
    end;

    for m,n be Nat holds dom(FY.m) = dom(FY.n)
    proof
     let m,n be Nat;
     dom(FY.m) = X-section(A,x) by A11;
     hence dom(FY.m) = dom(FY.n) by A11;
    end; then
    reconsider FY as with_the_same_dom Functional_Sequence of X2,ExtREAL
      by MESFUNC8:def 2;
    take FY;
    thus for n be Nat holds FY.n = ProjPMap1(F.n,x)
    proof
     let n be Nat;
     n is Element of NAT by ORDINAL1:def 12;
     hence FY.n = ProjPMap1(F.n,x) by A10;
    end;

    thus for y be Element of X2 st y in X-section(A,x) holds
      FY#y is convergent & (ProjPMap1(f,x)).y = lim(FY#y)
    proof
     let y be Element of X2;
     reconsider z = [x,y] as Element of [:X1,X2:] by ZFMISC_1:def 2;
     assume y in X-section(A,x); then
A17:  [x,y] in A by Th25; then
A18: F#z is convergent & lim(F#z) = f.z by A3;

A19: for n be Element of NAT holds (FY#y).n = (F#z).n
     proof
      let n be Element of NAT;
A20:  [x,y] in dom(F.n) by A2,A17;
      (FY#y).n = (FY.n).y by MESFUNC5:def 13; then
      (FY#y).n = ProjPMap1(F.n,x).y by A10; then
      (FY#y).n = (F.n).(x,y) by A20,Def3;
      hence (FY#y).n = (F#z).n by MESFUNC5:def 13;
     end;
     hence FY#y is convergent by A18,FUNCT_2:63;
     (ProjPMap1(f,x)).y = f.(x,y) by A1,A17,Def3;
     hence (ProjPMap1(f,x)).y = lim(FY#y) by A18,A19,FUNCT_2:63;
    end;
end;
