let A, B be Subset of ExtREAL; :: thesis: for a being Real st 0 < a & B = { (a * r) where r is R_eal : r in A } holds
( sup B = a * (sup A) & inf B = a * (inf A) )

let a be Real; :: thesis: ( 0 < a & B = { (a * r) where r is R_eal : r in A } implies ( sup B = a * (sup A) & inf B = a * (inf A) ) )
assume that
A1: 0 < a and
A2: B = { (a * r) where r is R_eal : r in A } ; :: thesis: ( sup B = a * (sup A) & inf B = a * (inf A) )
now :: thesis: for x being ExtReal st x in B holds
x <= a * (sup A)
let x be ExtReal; :: thesis: ( x in B implies x <= a * (sup A) )
assume x in B ; :: thesis: x <= a * (sup A)
then consider r being R_eal such that
A3: ( x = a * r & r in A ) by A2;
sup A is UpperBound of A by XXREAL_2:def 3;
then r <= sup A by A3, XXREAL_2:def 1;
hence x <= a * (sup A) by A3, A1, XXREAL_3:71; :: thesis: verum
end;
then A4: a * (sup A) is UpperBound of B by XXREAL_2:def 1;
for x being UpperBound of B holds a * (sup A) <= x
proof
let x be UpperBound of B; :: thesis: a * (sup A) <= x
assume not a * (sup A) <= x ; :: thesis: contradiction
then x / a < (a * (sup A)) / a by A1, XXREAL_3:80;
then A5: x / a < sup A by A1, XXREAL_3:88;
for r being ExtReal st r in A holds
r <= x / a
proof
let r be ExtReal; :: thesis: ( r in A implies r <= x / a )
assume r in A ; :: thesis: r <= x / a
then a * r in B by A2;
then (a * r) / a <= x / a by A1, XXREAL_2:def 1, XXREAL_3:79;
hence r <= x / a by A1, XXREAL_3:88; :: thesis: verum
end;
then x / a is UpperBound of A by XXREAL_2:def 1;
hence contradiction by A5, XXREAL_2:def 3; :: thesis: verum
end;
hence sup B = a * (sup A) by A4, XXREAL_2:def 3; :: thesis: inf B = a * (inf A)
now :: thesis: for x being ExtReal st x in B holds
a * (inf A) <= x
let x be ExtReal; :: thesis: ( x in B implies a * (inf A) <= x )
assume x in B ; :: thesis: a * (inf A) <= x
then consider r being R_eal such that
A6: ( x = a * r & r in A ) by A2;
inf A is LowerBound of A by XXREAL_2:def 4;
then inf A <= r by A6, XXREAL_2:def 2;
hence a * (inf A) <= x by A6, A1, XXREAL_3:71; :: thesis: verum
end;
then A7: a * (inf A) is LowerBound of B by XXREAL_2:def 2;
for x being LowerBound of B holds x <= a * (inf A)
proof
let x be LowerBound of B; :: thesis: x <= a * (inf A)
assume x > a * (inf A) ; :: thesis: contradiction
then (a * (inf A)) / a < x / a by A1, XXREAL_3:80;
then A8: inf A < x / a by A1, XXREAL_3:88;
for r being ExtReal st r in A holds
x / a <= r
proof
let r be ExtReal; :: thesis: ( r in A implies x / a <= r )
assume r in A ; :: thesis: x / a <= r
then a * r in B by A2;
then x / a <= (a * r) / a by A1, XXREAL_2:def 2, XXREAL_3:79;
hence x / a <= r by A1, XXREAL_3:88; :: thesis: verum
end;
then x / a is LowerBound of A by XXREAL_2:def 2;
hence contradiction by A8, XXREAL_2:def 4; :: thesis: verum
end;
hence inf B = a * (inf A) by A7, XXREAL_2:def 4; :: thesis: verum