
theorem
  for S1,S2, T1,T2 being non empty RelStr st
  the RelStr of S1 = the RelStr of T1 & the RelStr of S2 = the RelStr of T2
  for f being Function of S1,S2, g being Function of T1,T2 st f = g
  for X being Subset of S1, Y being Subset of T1 st X = Y holds
  (f preserves_sup_of X implies g preserves_sup_of Y) &
  (f preserves_inf_of X implies g preserves_inf_of Y)
proof
  let S1,S2, T1,T2 be non empty RelStr such that
A1: the RelStr of S1 = the RelStr of T1 and
A2: the RelStr of S2 = the RelStr of T2;
  let f be Function of S1,S2, g be Function of T1,T2 such that
A3: f = g;
  let X be Subset of S1, Y be Subset of T1 such that
A4: X = Y;
  thus f preserves_sup_of X implies g preserves_sup_of Y
  proof
    assume
A5: ex_sup_of X,S1 implies ex_sup_of f.:X,S2 & sup (f.:X) = f.sup X;
    assume
A6: ex_sup_of Y,T1;
    hence ex_sup_of g.:Y,T2 by A1,A2,A3,A4,A5,YELLOW_0:14;
    sup (f.:X) = sup (g.: Y) by A1,A2,A3,A4,A5,A6,YELLOW_0:14,26;
    hence thesis by A1,A3,A4,A5,A6,YELLOW_0:14,26;
  end;
  assume
A7: ex_inf_of X,S1 implies ex_inf_of f.:X,S2 & inf (f.:X) = f.inf X;
  assume
A8: ex_inf_of Y,T1;
  hence ex_inf_of g.:Y,T2 by A1,A2,A3,A4,A7,YELLOW_0:14;
  inf (f.:X) = inf (g.:Y) by A1,A2,A3,A4,A7,A8,YELLOW_0:14,27;
  hence thesis by A1,A3,A4,A7,A8,YELLOW_0:14,27;
end;
