
theorem Th32:
  for I being non empty set
  for J being RelStr-yielding non-Empty reflexive-yielding ManySortedSet of I
  st for i being Element of I holds J.i is complete LATTICE
  for X being Subset of product J, i being Element of I holds
  (sup X).i = sup pi(X,i)
proof
  let I be non empty set;
  let J be RelStr-yielding non-Empty reflexive-yielding ManySortedSet of I;
  assume
A1: for i being Element of I holds J.i is complete LATTICE;
  then reconsider L = product J as complete LATTICE by Th31;
A2: L is complete;
  let X be Subset of product J, i be Element of I;
A3: sup X is_>=_than X by A2,YELLOW_0:32;
A4: (sup X).i is_>=_than pi(X,i)
  proof
    let a be Element of J.i;
    assume a in pi(X,i);
    then consider f being Function such that
A5: f in X and
A6: a = f.i by CARD_3:def 6;
    reconsider f as Element of product J by A5;
    sup X >= f by A3,A5;
    hence thesis by A6,Th28;
  end;
A7: J.i is complete LATTICE by A1;
  now
    let a be Element of J.i;
    assume
A8: a is_>=_than pi(X,i);
    set f = (sup X)+*(i,a);
A9: dom f = dom sup X by FUNCT_7:30;
A10: dom sup X = I by Th27;
    now
      let j be Element of I;
      j = i or j <> i;
      then f.j = (sup X).j or f.j = a & j = i by A10,FUNCT_7:31,32;
      hence f.j is Element of J.j;
    end;
    then reconsider f as Element of product J by A9,Th27;
    f is_>=_than X
    proof
      let g be Element of product J;
      assume
A11:  g in X;
      then
A12:  g <= sup X by A2,YELLOW_2:22;
A13:  g.i in pi(X,i) by A11,CARD_3:def 6;
      now
        let j be Element of I;
        j = i or j <> i;
        then f.j = (sup X).j or f.j = a & j = i by A10,FUNCT_7:31,32;
        hence f.j >= g.j by A8,A12,A13,Th28;
      end;
      hence thesis by Th28;
    end;
    then
A14: f >= sup X by A2,YELLOW_0:32;
    f.i = a by A10,FUNCT_7:31;
    hence (sup X).i <= a by A14,Th28;
  end;
  hence thesis by A4,A7,YELLOW_0:32;
end;
