
theorem
  for X be non empty set, f be PartFunc of X,ExtREAL, x be object holds
    f.x <= (max+f).x & f.x >= -(max-f).x
proof
    let X be non empty set, f be PartFunc of X,ExtREAL, x be object;
    per cases;
    suppose x in dom f; then
     x in dom(max+f) & x in dom(max-f) by MESFUNC2:def 2,def 3; then
A1:  (max+f).x = max(f.x,0) & (max-f).x = max(-f.x,0)
       by MESFUNC2:def 2,def 3;
     reconsider a = (max-f).x, b = -(f.x) as ExtReal;
     -b >= -a by A1,XXREAL_0:25,XXREAL_3:38;
     hence f.x <= (max+f).x & f.x >= -(max-f).x by A1,XXREAL_0:25;
    end;
    suppose A2: not x in dom f; then
     not x in dom(max+f) & not x in dom(max-f) by MESFUNC2:def 2,def 3; then
     f.x = 0 & (max+f).x = 0 & (max-f).x = 0 by A2,FUNCT_1:def 2;
     hence f.x <= (max+f).x & f.x >= -(max-f).x;
    end;
end;
