theorem
  f is nonnegative implies (0 <= r implies r(#)f is nonnegative) & (r <=
  0 implies r(#)f is nonpositive)
proof
  assume
A1: f is nonnegative;
  hereby
    assume
A2: 0 <= r;
    now
      let x be object such that
A3:   x in dom(r(#)f);
      0 <= f.x by A1,Th51;
      then 0*r <= r*f.x by A2;
      hence 0 <= (r(#)f).x by A3,VALUED_1:def 5;
    end;
    hence r(#)f is nonnegative by Th52;
  end;
  assume
A4: r <= 0;
  now
    let x be object such that
A5: x in dom(r(#)f);
    0 <= f.x by A1,Th51;
    then r*f.x <= r*0 by A4;
    hence (r(#)f).x <= 0 by A5,VALUED_1:def 5;
  end;
  hence thesis by Th54;
end;
