
theorem Th27:
  for X being non empty set, Y being non empty Subset of ExtREAL,
  F being Function of X,Y holds Y c= REAL implies (F is bounded_above iff sup F
  in REAL)
proof
  let X be non empty set, Y be non empty Subset of ExtREAL, F be Function of X
  ,Y;
  assume
A1: Y c= REAL;
  hereby
    set x = the Element of X;
    X = dom F by FUNCT_2:def 1;
    then
A2: F.x in rng F by FUNCT_1:def 3;
    rng F c= Y by RELAT_1:def 19;
    then F.x in Y by A2;
    then
A3: not sup F = -infty by A1,Th26,XXREAL_0:12;
    assume a4: F is bounded_above;
    sup F in REAL or sup F in {-infty,+infty} by XBOOLE_0:def 3;
    hence sup F in REAL by a4,A3,TARSKI:def 2;
  end;
  assume sup F in REAL;
  hence thesis by XXREAL_0:9;
end;
