:: EXTREAL1 semantic presentation

theorem Th1: :: EXTREAL1:1
for b1 being R_eal st b1 <> +infty & b1 <> -infty holds
b1 is Real
proof end;

theorem Th2: :: EXTREAL1:2
-infty <' +infty
proof end;

theorem Th3: :: EXTREAL1:3
for b1, b2 being R_eal st b1 <' b2 holds
( b1 <> +infty & b2 <> -infty ) by SUPINF_1:20, SUPINF_1:21;

theorem Th4: :: EXTREAL1:4
for b1 being R_eal holds
( ( b1 = +infty implies - b1 = -infty ) & ( - b1 = -infty implies b1 = +infty ) & ( b1 = -infty implies - b1 = +infty ) & ( - b1 = +infty implies b1 = -infty ) )
proof end;

theorem Th5: :: EXTREAL1:5
for b1, b2 being R_eal holds b1 - (- b2) = b1 + b2
proof end;

theorem Th6: :: EXTREAL1:6
canceled;

theorem Th7: :: EXTREAL1:7
for b1, b2 being R_eal st b1 <> -infty & b2 <> +infty & b1 <=' b2 holds
( b1 <> +infty & b2 <> -infty )
proof end;

Lemma7: for b1 being R_eal st b1 in REAL holds
( b1 + -infty = -infty & b1 + +infty = +infty )
by SUPINF_1:2, SUPINF_1:6, SUPINF_2:def 2;

Lemma8: for b1, b2 being R_eal st b1 in REAL & b2 in REAL holds
b1 + b2 in REAL
proof end;

theorem Th8: :: EXTREAL1:8
for b1, b2, b3 being R_eal st ( not b1 = +infty or not b2 = -infty ) & ( not b1 = -infty or not b2 = +infty ) & not ( b2 = +infty & b3 = -infty ) & not ( b2 = -infty & b3 = +infty ) & not ( b1 = +infty & b3 = -infty ) & not ( b1 = -infty & b3 = +infty ) holds
(b1 + b2) + b3 = b1 + (b2 + b3)
proof end;

theorem Th9: :: EXTREAL1:9
for b1 being R_eal holds b1 + (- b1) = 0.
proof end;

theorem Th10: :: EXTREAL1:10
canceled;

theorem Th11: :: EXTREAL1:11
for b1, b2, b3 being R_eal st ( not b1 = +infty or not b2 = -infty ) & ( not b1 = -infty or not b2 = +infty ) & ( not b2 = +infty or not b3 = +infty ) & ( not b2 = -infty or not b3 = -infty ) & ( not b1 = +infty or not b3 = +infty ) & ( not b1 = -infty or not b3 = -infty ) holds
(b1 + b2) - b3 = b1 + (b2 - b3)
proof end;

definition
let c1, c2 be R_eal;
func c1 * c2 -> R_eal means :Def1: :: EXTREAL1:def 1
( ex b1, b2 being Real st
( a1 = b1 & a2 = b2 & a3 = b1 * b2 ) or ( ( ( 0. <' a1 & a2 = +infty ) or ( 0. <' a2 & a1 = +infty ) or ( a1 <' 0. & a2 = -infty ) or ( a2 <' 0. & a1 = -infty ) ) & a3 = +infty ) or ( ( ( a1 <' 0. & a2 = +infty ) or ( a2 <' 0. & a1 = +infty ) or ( 0. <' a1 & a2 = -infty ) or ( 0. <' a2 & a1 = -infty ) ) & a3 = -infty ) or ( ( a1 = 0. or a2 = 0. ) & a3 = 0. ) );
existence
ex b1 being R_eal st
( ex b2, b3 being Real st
( c1 = b2 & c2 = b3 & b1 = b2 * b3 ) or ( ( ( 0. <' c1 & c2 = +infty ) or ( 0. <' c2 & c1 = +infty ) or ( c1 <' 0. & c2 = -infty ) or ( c2 <' 0. & c1 = -infty ) ) & b1 = +infty ) or ( ( ( c1 <' 0. & c2 = +infty ) or ( c2 <' 0. & c1 = +infty ) or ( 0. <' c1 & c2 = -infty ) or ( 0. <' c2 & c1 = -infty ) ) & b1 = -infty ) or ( ( c1 = 0. or c2 = 0. ) & b1 = 0. ) )
proof end;
uniqueness
for b1, b2 being R_eal st ( ex b3, b4 being Real st
( c1 = b3 & c2 = b4 & b1 = b3 * b4 ) or ( ( ( 0. <' c1 & c2 = +infty ) or ( 0. <' c2 & c1 = +infty ) or ( c1 <' 0. & c2 = -infty ) or ( c2 <' 0. & c1 = -infty ) ) & b1 = +infty ) or ( ( ( c1 <' 0. & c2 = +infty ) or ( c2 <' 0. & c1 = +infty ) or ( 0. <' c1 & c2 = -infty ) or ( 0. <' c2 & c1 = -infty ) ) & b1 = -infty ) or ( ( c1 = 0. or c2 = 0. ) & b1 = 0. ) ) & ( ex b3, b4 being Real st
( c1 = b3 & c2 = b4 & b2 = b3 * b4 ) or ( ( ( 0. <' c1 & c2 = +infty ) or ( 0. <' c2 & c1 = +infty ) or ( c1 <' 0. & c2 = -infty ) or ( c2 <' 0. & c1 = -infty ) ) & b2 = +infty ) or ( ( ( c1 <' 0. & c2 = +infty ) or ( c2 <' 0. & c1 = +infty ) or ( 0. <' c1 & c2 = -infty ) or ( 0. <' c2 & c1 = -infty ) ) & b2 = -infty ) or ( ( c1 = 0. or c2 = 0. ) & b2 = 0. ) ) holds
b1 = b2
by SUPINF_1:31, SUPINF_2:def 1;
end;

:: deftheorem Def1 defines * EXTREAL1:def 1 :
for b1, b2, b3 being R_eal holds
( b3 = b1 * b2 iff ( ex b4, b5 being Real st
( b1 = b4 & b2 = b5 & b3 = b4 * b5 ) or ( ( ( 0. <' b1 & b2 = +infty ) or ( 0. <' b2 & b1 = +infty ) or ( b1 <' 0. & b2 = -infty ) or ( b2 <' 0. & b1 = -infty ) ) & b3 = +infty ) or ( ( ( b1 <' 0. & b2 = +infty ) or ( b2 <' 0. & b1 = +infty ) or ( 0. <' b1 & b2 = -infty ) or ( 0. <' b2 & b1 = -infty ) ) & b3 = -infty ) or ( ( b1 = 0. or b2 = 0. ) & b3 = 0. ) ) );

theorem Th12: :: EXTREAL1:12
canceled;

theorem Th13: :: EXTREAL1:13
for b1, b2 being R_eal
for b3, b4 being Real st b1 = b3 & b2 = b4 holds
b1 * b2 = b3 * b4
proof end;

Lemma13: for b1 being R_eal
for b2 being Real st b1 = b2 & 0 < b2 holds
0. <' b1
proof end;

Lemma14: for b1 being R_eal
for b2 being Real st b1 = b2 & b2 < 0 holds
b1 <' 0.
proof end;

theorem Th14: :: EXTREAL1:14
for b1, b2 being R_eal st ( ( 0. <=' b1 & 0. <' b2 ) or ( 0. <' b1 & 0. <=' b2 ) ) holds
0. <' b1 + b2
proof end;

theorem Th15: :: EXTREAL1:15
for b1, b2 being R_eal st ( ( b1 <=' 0. & b2 <' 0. ) or ( b1 <' 0. & b2 <=' 0. ) ) holds
b1 + b2 <' 0.
proof end;

theorem Th16: :: EXTREAL1:16
for b1 being R_eal holds
( not b1 in REAL or ( -infty <' b1 & b1 <' 0. ) or b1 = 0. or ( 0. <' b1 & b1 <' +infty ) )
proof end;

theorem Th17: :: EXTREAL1:17
for b1, b2 being R_eal holds b1 * b2 = b2 * b1
proof end;

definition
let c1, c2 be R_eal;
redefine func * as c1 * c2 -> R_eal;
commutativity
for b1, b2 being R_eal holds b1 * b2 = b2 * b1
by Th17;
end;

theorem Th18: :: EXTREAL1:18
for b1 being R_eal
for b2 being Real st b1 = b2 holds
( 0 < b2 iff 0. <' b1 ) by Lemma13, SUPINF_1:16, SUPINF_2:def 1;

theorem Th19: :: EXTREAL1:19
for b1 being R_eal
for b2 being Real st b1 = b2 holds
( b2 < 0 iff b1 <' 0. ) by Lemma14, SUPINF_1:16, SUPINF_2:def 1;

theorem Th20: :: EXTREAL1:20
for b1, b2 being R_eal st ( ( 0. <' b1 & 0. <' b2 ) or ( b1 <' 0. & b2 <' 0. ) ) holds
0. <' b1 * b2
proof end;

theorem Th21: :: EXTREAL1:21
for b1, b2 being R_eal st ( ( 0. <' b1 & b2 <' 0. ) or ( b1 <' 0. & 0. <' b2 ) ) holds
b1 * b2 <' 0.
proof end;

theorem Th22: :: EXTREAL1:22
for b1, b2 being R_eal holds
( b1 * b2 = 0. iff ( b1 = 0. or b2 = 0. ) )
proof end;

theorem Th23: :: EXTREAL1:23
for b1, b2, b3 being R_eal holds (b1 * b2) * b3 = b1 * (b2 * b3)
proof end;

theorem Th24: :: EXTREAL1:24
- 0. = 0.
proof end;

theorem Th25: :: EXTREAL1:25
for b1 being R_eal holds
( ( 0. <' b1 implies - b1 <' 0. ) & ( - b1 <' 0. implies 0. <' b1 ) & ( b1 <' 0. implies 0. <' - b1 ) & ( 0. <' - b1 implies b1 <' 0. ) ) by Th24, SUPINF_2:17;

theorem Th26: :: EXTREAL1:26
for b1, b2 being R_eal holds
( - (b1 * b2) = b1 * (- b2) & - (b1 * b2) = (- b1) * b2 )
proof end;

theorem Th27: :: EXTREAL1:27
for b1, b2 being R_eal st b1 <> +infty & b1 <> -infty & b1 * b2 = +infty & not b2 = +infty holds
b2 = -infty
proof end;

theorem Th28: :: EXTREAL1:28
for b1, b2 being R_eal st b1 <> +infty & b1 <> -infty & b1 * b2 = -infty & not b2 = +infty holds
b2 = -infty
proof end;

Lemma23: for b1, b2, b3 being R_eal st b1 <> +infty & b1 <> -infty holds
b1 * (b2 + b3) = (b1 * b2) + (b1 * b3)
proof end;

theorem Th29: :: EXTREAL1:29
for b1, b2, b3 being R_eal st ( ( b1 <> +infty & b1 <> -infty ) or ( b2 = -infty & b3 = +infty ) or ( b2 <' 0. & b3 <' 0. ) or b2 = 0. or b3 = 0. or ( 0. <' b2 & 0. <' b3 ) or ( b2 = +infty & b3 = -infty ) ) holds
b1 * (b2 + b3) = (b1 * b2) + (b1 * b3)
proof end;

theorem Th30: :: EXTREAL1:30
for b1, b2, b3 being R_eal holds
( ( b1 = +infty & b2 = +infty ) or ( b1 = -infty & b2 = -infty ) or not b3 <> +infty or not b3 <> -infty or b3 * (b1 - b2) = (b3 * b1) - (b3 * b2) )
proof end;

definition
let c1, c2 be R_eal;
assume E24: ( ( ( not c1 = -infty & not c1 = +infty ) or ( not c2 = -infty & not c2 = +infty ) ) & c2 <> 0. ) ;
func c1 / c2 -> R_eal means :Def2: :: EXTREAL1:def 2
( ex b1, b2 being Real st
( a1 = b1 & a2 = b2 & a3 = b1 / b2 ) or ( ( ( a1 = +infty & 0. <' a2 ) or ( a1 = -infty & a2 <' 0. ) ) & a3 = +infty ) or ( ( ( a1 = -infty & 0. <' a2 ) or ( a1 = +infty & a2 <' 0. ) ) & a3 = -infty ) or ( ( a2 = -infty or a2 = +infty ) & a3 = 0. ) );
existence
ex b1 being R_eal st
( ex b2, b3 being Real st
( c1 = b2 & c2 = b3 & b1 = b2 / b3 ) or ( ( ( c1 = +infty & 0. <' c2 ) or ( c1 = -infty & c2 <' 0. ) ) & b1 = +infty ) or ( ( ( c1 = -infty & 0. <' c2 ) or ( c1 = +infty & c2 <' 0. ) ) & b1 = -infty ) or ( ( c2 = -infty or c2 = +infty ) & b1 = 0. ) )
proof end;
uniqueness
for b1, b2 being R_eal st ( ex b3, b4 being Real st
( c1 = b3 & c2 = b4 & b1 = b3 / b4 ) or ( ( ( c1 = +infty & 0. <' c2 ) or ( c1 = -infty & c2 <' 0. ) ) & b1 = +infty ) or ( ( ( c1 = -infty & 0. <' c2 ) or ( c1 = +infty & c2 <' 0. ) ) & b1 = -infty ) or ( ( c2 = -infty or c2 = +infty ) & b1 = 0. ) ) & ( ex b3, b4 being Real st
( c1 = b3 & c2 = b4 & b2 = b3 / b4 ) or ( ( ( c1 = +infty & 0. <' c2 ) or ( c1 = -infty & c2 <' 0. ) ) & b2 = +infty ) or ( ( ( c1 = -infty & 0. <' c2 ) or ( c1 = +infty & c2 <' 0. ) ) & b2 = -infty ) or ( ( c2 = -infty or c2 = +infty ) & b2 = 0. ) ) holds
b1 = b2
by E24, SUPINF_1:31;
end;

:: deftheorem Def2 defines / EXTREAL1:def 2 :
for b1, b2 being R_eal st ( ( not b1 = -infty & not b1 = +infty ) or ( not b2 = -infty & not b2 = +infty ) ) & b2 <> 0. holds
for b3 being R_eal holds
( b3 = b1 / b2 iff ( ex b4, b5 being Real st
( b1 = b4 & b2 = b5 & b3 = b4 / b5 ) or ( ( ( b1 = +infty & 0. <' b2 ) or ( b1 = -infty & b2 <' 0. ) ) & b3 = +infty ) or ( ( ( b1 = -infty & 0. <' b2 ) or ( b1 = +infty & b2 <' 0. ) ) & b3 = -infty ) or ( ( b2 = -infty or b2 = +infty ) & b3 = 0. ) ) );

theorem Th31: :: EXTREAL1:31
canceled;

theorem Th32: :: EXTREAL1:32
for b1, b2 being R_eal st b2 <> 0. holds
for b3, b4 being Real st b1 = b3 & b2 = b4 holds
b1 / b2 = b3 / b4
proof end;

theorem Th33: :: EXTREAL1:33
for b1, b2 being R_eal st b1 <> -infty & b1 <> +infty & ( b2 = -infty or b2 = +infty ) holds
b1 / b2 = 0. by Def2, SUPINF_2:19;

theorem Th34: :: EXTREAL1:34
for b1 being R_eal st b1 <> -infty & b1 <> +infty & b1 <> 0. holds
b1 / b1 = 1
proof end;

definition
let c1 be R_eal;
func |.c1.| -> R_eal equals :Def3: :: EXTREAL1:def 3
a1 if 0. <=' a1
otherwise - a1;
coherence
( ( 0. <=' c1 implies c1 is R_eal ) & ( not 0. <=' c1 implies - c1 is R_eal ) )
;
consistency
for b1 being R_eal holds verum
;
end;

:: deftheorem Def3 defines |. EXTREAL1:def 3 :
for b1 being R_eal holds
( ( 0. <=' b1 implies |.b1.| = b1 ) & ( not 0. <=' b1 implies |.b1.| = - b1 ) );

theorem Th35: :: EXTREAL1:35
canceled;

theorem Th36: :: EXTREAL1:36
for b1 being R_eal st 0. <' b1 holds
|.b1.| = b1 by Def3;

theorem Th37: :: EXTREAL1:37
for b1 being R_eal st b1 <' 0. holds
|.b1.| = - b1 by Def3;

theorem Th38: :: EXTREAL1:38
for b1, b2 being Real holds R_EAL (b1 * b2) = (R_EAL b1) * (R_EAL b2)
proof end;

theorem Th39: :: EXTREAL1:39
for b1, b2 being Real st b2 <> 0 holds
R_EAL (b1 / b2) = (R_EAL b1) / (R_EAL b2)
proof end;

theorem Th40: :: EXTREAL1:40
for b1, b2 being R_eal st b1 <=' b2 & b1 <' +infty & -infty <' b2 holds
0. <=' b2 - b1
proof end;

theorem Th41: :: EXTREAL1:41
for b1, b2 being R_eal st b1 <' b2 & b1 <' +infty & -infty <' b2 holds
0. <' b2 - b1
proof end;

theorem Th42: :: EXTREAL1:42
for b1, b2, b3 being R_eal st b1 <=' b2 & 0. <=' b3 holds
b1 * b3 <=' b2 * b3
proof end;

theorem Th43: :: EXTREAL1:43
for b1, b2, b3 being R_eal st b1 <=' b2 & b3 <=' 0. holds
b2 * b3 <=' b1 * b3
proof end;

theorem Th44: :: EXTREAL1:44
for b1, b2, b3 being R_eal st b1 <' b2 & 0. <' b3 & b3 <> +infty holds
b1 * b3 <' b2 * b3
proof end;

theorem Th45: :: EXTREAL1:45
for b1, b2, b3 being R_eal st b1 <' b2 & b3 <' 0. & b3 <> -infty holds
b2 * b3 <' b1 * b3
proof end;

theorem Th46: :: EXTREAL1:46
for b1, b2 being R_eal st b1 is Real & b2 is Real holds
( b1 <' b2 iff ex b3, b4 being Real st
( b3 = b1 & b4 = b2 & b3 < b4 ) )
proof end;

theorem Th47: :: EXTREAL1:47
for b1, b2, b3 being R_eal st b1 <> -infty & b2 <> +infty & b1 <=' b2 & 0. <' b3 holds
b1 / b3 <=' b2 / b3
proof end;

theorem Th48: :: EXTREAL1:48
for b1, b2, b3 being R_eal st b1 <=' b2 & 0. <' b3 & b3 <> +infty holds
b1 / b3 <=' b2 / b3
proof end;

theorem Th49: :: EXTREAL1:49
for b1, b2, b3 being R_eal st b1 <> -infty & b2 <> +infty & b1 <=' b2 & b3 <' 0. holds
b2 / b3 <=' b1 / b3
proof end;

theorem Th50: :: EXTREAL1:50
for b1, b2, b3 being R_eal st b1 <=' b2 & b3 <' 0. & b3 <> -infty holds
b2 / b3 <=' b1 / b3
proof end;

theorem Th51: :: EXTREAL1:51
for b1, b2, b3 being R_eal st b1 <' b2 & 0. <' b3 & b3 <> +infty holds
b1 / b3 <' b2 / b3
proof end;

theorem Th52: :: EXTREAL1:52
for b1, b2, b3 being R_eal st b1 <' b2 & b3 <' 0. & b3 <> -infty holds
b2 / b3 <' b1 / b3
proof end;