:: PROB_4 semantic presentation

Lemma1: for b1, b2, b3 being set st b3 c= b2 holds
b1 \ b3 = (b1 \ b2) \/ (b1 /\ (b2 \ b3))
proof end;

definition
let c1 be set ;
let c2 be SigmaField of c1;
let c3 be SetSequence of c2;
let c4 be Nat;
redefine func . as c3 . c4 -> Element of a2;
coherence
c3 . c4 is Element of c2
by PROB_1:def 9;
end;

theorem Th1: :: PROB_4:1
for b1 being set
for b2 being SigmaField of b1
for b3 being SetSequence of b2 holds rng b3 c= b2
proof end;

theorem Th2: :: PROB_4:2
for b1 being set
for b2 being SigmaField of b1
for b3 being Function holds
( b3 is SetSequence of b2 iff b3 is Function of NAT ,b2 )
proof end;

scheme :: PROB_4:sch 1
s1{ F1() -> set , F2() -> SigmaField of F1(), F3( set ) -> Element of F2() } :
ex b1 being SetSequence of F2() st
for b2 being Nat holds b1 . b2 = F3(b2)
proof end;

registration
let c1 be set ;
cluster disjoint_valued Relation of NAT , bool a1;
existence
ex b1 being SetSequence of c1 st b1 is disjoint_valued
proof end;
end;

registration
let c1 be set ;
let c2 be SigmaField of c1;
cluster disjoint_valued SetSequence of a2;
existence
ex b1 being SetSequence of c2 st b1 is disjoint_valued
proof end;
end;

theorem Th3: :: PROB_4:3
for b1 being set
for b2, b3 being Subset of b1 ex b4 being SetSequence of b1 st
( b4 . 0 = b2 & b4 . 1 = b3 & ( for b5 being Nat st b5 > 1 holds
b4 . b5 = {} ) )
proof end;

theorem Th4: :: PROB_4:4
for b1 being set
for b2 being SetSequence of b1
for b3, b4 being Subset of b1 st b3 misses b4 & b2 . 0 = b3 & b2 . 1 = b4 & ( for b5 being Nat st b5 > 1 holds
b2 . b5 = {} ) holds
( b2 is disjoint_valued & Union b2 = b3 \/ b4 )
proof end;

theorem Th5: :: PROB_4:5
for b1 being set
for b2 being non empty set holds
( b2 is SigmaField of b1 iff ( b2 c= bool b1 & ( for b3 being SetSequence of b1 st ( for b4 being Nat holds b3 . b4 in b2 ) holds
Union b3 in b2 ) & ( for b3 being Subset of b1 st b3 in b2 holds
b3 ` in b2 ) ) )
proof end;

theorem Th6: :: PROB_4:6
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4, b5 being Event of b2 holds b3 . (b4 \ b5) = (b3 . (b4 \/ b5)) - (b3 . b5)
proof end;

theorem Th7: :: PROB_4:7
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4, b5 being Event of b2 st b4 c= b5 & b3 . b5 = 0 holds
b3 . b4 = 0
proof end;

theorem Th8: :: PROB_4:8
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being SetSequence of b2
for b4 being Probability of b2 holds
( ( for b5 being Nat holds b4 . (b3 . b5) = 0 ) iff b4 . (Union b3) = 0 )
proof end;

theorem Th9: :: PROB_4:9
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being SetSequence of b2
for b4 being Probability of b2 holds
( ( for b5 being set st b5 in rng b3 holds
b4 . b5 = 0 ) iff b4 . (union (rng b3)) = 0 )
proof end;

definition
let c1 be set ;
let c2 be SigmaField of c1;
func SF2SFS c2 -> sigma_Field_Subset of a1 equals :: PROB_4:def 1
a2;
coherence
c2 is sigma_Field_Subset of c1
by TOPGEN_4:62;
end;

:: deftheorem Def1 defines SF2SFS PROB_4:def 1 :
for b1 being set
for b2 being SigmaField of b1 holds SF2SFS b2 = b2;

definition
let c1 be set ;
let c2 be sigma_Field_Subset of c1;
func SFS2SF c2 -> SigmaField of a1 equals :: PROB_4:def 2
a2;
coherence
c2 is SigmaField of c1
by TOPGEN_4:62;
end;

:: deftheorem Def2 defines SFS2SF PROB_4:def 2 :
for b1 being set
for b2 being sigma_Field_Subset of b1 holds SFS2SF b2 = b2;

theorem Th10: :: PROB_4:10
for b1 being Function of NAT , REAL
for b2 being Function of NAT , ExtREAL st b1 = b2 holds
Partial_Sums b1 = Ser b2
proof end;

theorem Th11: :: PROB_4:11
for b1 being Function of NAT , REAL
for b2 being Function of NAT , ExtREAL st b1 = b2 & b1 is bounded_above holds
sup b1 = sup (rng b2)
proof end;

theorem Th12: :: PROB_4:12
for b1 being Function of NAT , REAL
for b2 being Function of NAT , ExtREAL st b1 = b2 & b1 is bounded_below holds
inf b1 = inf (rng b2)
proof end;

theorem Th13: :: PROB_4:13
for b1 being Function of NAT , REAL
for b2 being Function of NAT , ExtREAL st b1 = b2 & b1 is nonnegative & b1 is summable holds
Sum b1 = SUM b2
proof end;

theorem Th14: :: PROB_4:14
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds b3 is sigma_Measure of SF2SFS b2
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
func P2M c3 -> sigma_Measure of SF2SFS a2 equals :: PROB_4:def 3
a3;
coherence
c3 is sigma_Measure of SF2SFS c2
by Th14;
end;

:: deftheorem Def3 defines P2M PROB_4:def 3 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds P2M b3 = b3;

theorem Th15: :: PROB_4:15
for b1 being non empty set
for b2 being sigma_Field_Subset of b1
for b3 being sigma_Measure of b2 st b3 . b1 = R_EAL 1 holds
b3 is Probability of SFS2SF b2
proof end;

definition
let c1 be non empty set ;
let c2 be sigma_Field_Subset of c1;
let c3 be sigma_Measure of c2;
assume E17: c3 . c1 = R_EAL 1 ;
func M2P c3 -> Probability of SFS2SF a2 equals :: PROB_4:def 4
a3;
coherence
c3 is Probability of SFS2SF c2
by E17, Th15;
end;

:: deftheorem Def4 defines M2P PROB_4:def 4 :
for b1 being non empty set
for b2 being sigma_Field_Subset of b1
for b3 being sigma_Measure of b2 st b3 . b1 = R_EAL 1 holds
M2P b3 = b3;

Lemma17: for b1 being set
for b2 being SetSequence of b1 st b2 is non-decreasing holds
for b3 being Nat holds (Partial_Union b2) . b3 = b2 . b3
proof end;

theorem Th16: :: PROB_4:16
for b1 being set
for b2 being SetSequence of b1 st b2 is non-decreasing holds
Partial_Union b2 = b2
proof end;

theorem Th17: :: PROB_4:17
for b1 being set
for b2 being SetSequence of b1 st b2 is non-decreasing holds
( (Partial_Diff_Union b2) . 0 = b2 . 0 & ( for b3 being Nat holds (Partial_Diff_Union b2) . (b3 + 1) = (b2 . (b3 + 1)) \ (b2 . b3) ) )
proof end;

theorem Th18: :: PROB_4:18
for b1 being set
for b2 being SetSequence of b1 st b2 is non-decreasing holds
for b3 being Nat holds b2 . (b3 + 1) = ((Partial_Diff_Union b2) . (b3 + 1)) \/ (b2 . b3)
proof end;

theorem Th19: :: PROB_4:19
for b1 being set
for b2 being SetSequence of b1 st b2 is non-decreasing holds
for b3 being Nat holds (Partial_Diff_Union b2) . (b3 + 1) misses b2 . b3
proof end;

theorem Th20: :: PROB_4:20
for b1 being set
for b2 being SigmaField of b1
for b3 being SetSequence of b2 st b3 is non-decreasing holds
@Partial_Union b3 = b3
proof end;

theorem Th21: :: PROB_4:21
for b1 being set
for b2 being SigmaField of b1
for b3 being SetSequence of b2 st b3 is non-decreasing holds
( (@Partial_Diff_Union b3) . 0 = b3 . 0 & ( for b4 being Nat holds (@Partial_Diff_Union b3) . (b4 + 1) = (b3 . (b4 + 1)) \ (b3 . b4) ) )
proof end;

theorem Th22: :: PROB_4:22
for b1 being set
for b2 being SigmaField of b1
for b3 being SetSequence of b2 st b3 is non-decreasing holds
for b4 being Nat holds (@Partial_Diff_Union b3) . (b4 + 1) misses b3 . b4
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
pred c3 is_complete c2 means :Def5: :: PROB_4:def 5
for b1 being Subset of a1
for b2 being set st b2 in a2 & b1 c= b2 & a3 . b2 = 0 holds
b1 in a2;
end;

:: deftheorem Def5 defines is_complete PROB_4:def 5 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds
( b3 is_complete b2 iff for b4 being Subset of b1
for b5 being set st b5 in b2 & b4 c= b5 & b3 . b5 = 0 holds
b4 in b2 );

theorem Th23: :: PROB_4:23
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds
( b3 is_complete b2 iff P2M b3 is_complete SF2SFS b2 )
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
mode thin of c3 -> Subset of a1 means :Def6: :: PROB_4:def 6
ex b1 being set st
( b1 in a2 & a4 c= b1 & a3 . b1 = 0 );
existence
ex b1 being Subset of c1ex b2 being set st
( b2 in c2 & b1 c= b2 & c3 . b2 = 0 )
proof end;
end;

:: deftheorem Def6 defines thin PROB_4:def 6 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Subset of b1 holds
( b4 is thin of b3 iff ex b5 being set st
( b5 in b2 & b4 c= b5 & b3 . b5 = 0 ) );

theorem Th24: :: PROB_4:24
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Subset of b1 holds
( b4 is thin of b3 iff b4 is thin of P2M b3 )
proof end;

theorem Th25: :: PROB_4:25
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds {} is thin of b3
proof end;

theorem Th26: :: PROB_4:26
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4, b5 being set st b4 in b2 & b5 in b2 holds
for b6, b7 being thin of b3 st b4 \/ b6 = b5 \/ b7 holds
b3 . b4 = b3 . b5
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
func COM c2,c3 -> non empty Subset-Family of a1 means :Def7: :: PROB_4:def 7
for b1 being set holds
( b1 in a4 iff ex b2 being set st
( b2 in a2 & ex b3 being thin of a3 st b1 = b2 \/ b3 ) );
existence
ex b1 being non empty Subset-Family of c1 st
for b2 being set holds
( b2 in b1 iff ex b3 being set st
( b3 in c2 & ex b4 being thin of c3 st b2 = b3 \/ b4 ) )
proof end;
uniqueness
for b1, b2 being non empty Subset-Family of c1 st ( for b3 being set holds
( b3 in b1 iff ex b4 being set st
( b4 in c2 & ex b5 being thin of c3 st b3 = b4 \/ b5 ) ) ) & ( for b3 being set holds
( b3 in b2 iff ex b4 being set st
( b4 in c2 & ex b5 being thin of c3 st b3 = b4 \/ b5 ) ) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def7 defines COM PROB_4:def 7 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being non empty Subset-Family of b1 holds
( b4 = COM b2,b3 iff for b5 being set holds
( b5 in b4 iff ex b6 being set st
( b6 in b2 & ex b7 being thin of b3 st b5 = b6 \/ b7 ) ) );

theorem Th27: :: PROB_4:27
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being thin of b3 holds b4 in COM b2,b3
proof end;

theorem Th28: :: PROB_4:28
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds COM b2,b3 = COM (SF2SFS b2),(P2M b3)
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
let c4 be Element of COM c2,c3;
func P_COM2M_COM c4 -> Element of COM (SF2SFS a2),(P2M a3) equals :: PROB_4:def 8
a4;
correctness
coherence
c4 is Element of COM (SF2SFS c2),(P2M c3)
;
by Th28;
end;

:: deftheorem Def8 defines P_COM2M_COM PROB_4:def 8 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Element of COM b2,b3 holds P_COM2M_COM b4 = b4;

theorem Th29: :: PROB_4:29
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds b2 c= COM b2,b3
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
let c4 be Element of COM c2,c3;
func ProbPart c4 -> non empty Subset-Family of a1 means :Def9: :: PROB_4:def 9
for b1 being set holds
( b1 in a5 iff ( b1 in a2 & b1 c= a4 & a4 \ b1 is thin of a3 ) );
existence
ex b1 being non empty Subset-Family of c1 st
for b2 being set holds
( b2 in b1 iff ( b2 in c2 & b2 c= c4 & c4 \ b2 is thin of c3 ) )
proof end;
uniqueness
for b1, b2 being non empty Subset-Family of c1 st ( for b3 being set holds
( b3 in b1 iff ( b3 in c2 & b3 c= c4 & c4 \ b3 is thin of c3 ) ) ) & ( for b3 being set holds
( b3 in b2 iff ( b3 in c2 & b3 c= c4 & c4 \ b3 is thin of c3 ) ) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def9 defines ProbPart PROB_4:def 9 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Element of COM b2,b3
for b5 being non empty Subset-Family of b1 holds
( b5 = ProbPart b4 iff for b6 being set holds
( b6 in b5 iff ( b6 in b2 & b6 c= b4 & b4 \ b6 is thin of b3 ) ) );

theorem Th30: :: PROB_4:30
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Element of COM b2,b3 holds ProbPart b4 = MeasPart (P_COM2M_COM b4)
proof end;

theorem Th31: :: PROB_4:31
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Element of COM b2,b3
for b5, b6 being set st b5 in ProbPart b4 & b6 in ProbPart b4 holds
b3 . b5 = b3 . b6
proof end;

theorem Th32: :: PROB_4:32
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Function of NAT , COM b2,b3 ex b5 being SetSequence of b2 st
for b6 being Nat holds b5 . b6 in ProbPart (b4 . b6)
proof end;

theorem Th33: :: PROB_4:33
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Function of NAT , COM b2,b3
for b5 being SetSequence of b2 ex b6 being SetSequence of b1 st
for b7 being Nat holds b6 . b7 = (b4 . b7) \ (b5 . b7)
proof end;

theorem Th34: :: PROB_4:34
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being SetSequence of b1 st ( for b5 being Nat holds b4 . b5 is thin of b3 ) holds
ex b5 being SetSequence of b2 st
for b6 being Nat holds
( b4 . b6 c= b5 . b6 & b3 . (b5 . b6) = 0 )
proof end;

theorem Th35: :: PROB_4:35
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being non empty Subset-Family of b1 st ( for b5 being set holds
( b5 in b4 iff ex b6 being set st
( b6 in b2 & ex b7 being thin of b3 st b5 = b6 \/ b7 ) ) ) holds
b4 is SigmaField of b1
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
redefine func COM as COM c2,c3 -> SigmaField of a1;
coherence
COM c2,c3 is SigmaField of c1
proof end;
end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
redefine mode thin as thin of c3 -> Event of COM a2,a3;
coherence
for b1 being thin of c3 holds b1 is Event of COM c2,c3
proof end;
end;

theorem Th36: :: PROB_4:36
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being set holds
( b4 in COM b2,b3 iff ex b5, b6 being set st
( b5 in b2 & b6 in b2 & b5 c= b4 & b4 c= b6 & b3 . (b6 \ b5) = 0 ) )
proof end;

theorem Th37: :: PROB_4:37
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being non empty Subset-Family of b1 st ( for b5 being set holds
( b5 in b4 iff ex b6, b7 being set st
( b6 in b2 & b7 in b2 & b6 c= b5 & b5 c= b7 & b3 . (b7 \ b6) = 0 ) ) ) holds
b4 = COM b2,b3
proof end;

definition
let c1 be non empty set ;
let c2 be SigmaField of c1;
let c3 be Probability of c2;
func COM c3 -> Probability of COM a2,a3 means :Def10: :: PROB_4:def 10
for b1 being set st b1 in a2 holds
for b2 being thin of a3 holds a4 . (b1 \/ b2) = a3 . b1;
existence
ex b1 being Probability of COM c2,c3 st
for b2 being set st b2 in c2 holds
for b3 being thin of c3 holds b1 . (b2 \/ b3) = c3 . b2
proof end;
uniqueness
for b1, b2 being Probability of COM c2,c3 st ( for b3 being set st b3 in c2 holds
for b4 being thin of c3 holds b1 . (b3 \/ b4) = c3 . b3 ) & ( for b3 being set st b3 in c2 holds
for b4 being thin of c3 holds b2 . (b3 \/ b4) = c3 . b3 ) holds
b1 = b2
proof end;
end;

:: deftheorem Def10 defines COM PROB_4:def 10 :
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Probability of COM b2,b3 holds
( b4 = COM b3 iff for b5 being set st b5 in b2 holds
for b6 being thin of b3 holds b4 . (b5 \/ b6) = b3 . b5 );

theorem Th38: :: PROB_4:38
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds COM b3 = COM (P2M b3)
proof end;

theorem Th39: :: PROB_4:39
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2 holds COM b3 is_complete COM b2,b3
proof end;

theorem Th40: :: PROB_4:40
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Event of b2 holds b3 . b4 = (COM b3) . b4
proof end;

theorem Th41: :: PROB_4:41
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being thin of b3 holds (COM b3) . b4 = 0
proof end;

theorem Th42: :: PROB_4:42
for b1 being non empty set
for b2 being SigmaField of b1
for b3 being Probability of b2
for b4 being Element of COM b2,b3
for b5 being set st b5 in ProbPart b4 holds
b3 . b5 = (COM b3) . b4
proof end;