:: TOPGEN_2 semantic presentation

theorem Th1: :: TOPGEN_2:1
for b1 being non empty TopSpace
for b2 being Basis of b1
for b3 being Element of b1 holds { b4 where B is Subset of b1 : ( b3 in b4 & b4 in b2 ) } is Basis of b3
proof end;

theorem Th2: :: TOPGEN_2:2
for b1 being non empty TopSpace
for b2 being ManySortedSet of b1 st ( for b3 being Element of b1 holds b2 . b3 is Basis of b3 ) holds
Union b2 is Basis of b1
proof end;

definition
let c1 be non empty TopStruct ;
let c2 be Element of c1;
func Chi c2,c1 -> cardinal number means :Def1: :: TOPGEN_2:def 1
( ex b1 being Basis of a2 st a3 = Card b1 & ( for b1 being Basis of a2 holds a3 <=` Card b1 ) );
existence
ex b1 being cardinal number st
( ex b2 being Basis of c2 st b1 = Card b2 & ( for b2 being Basis of c2 holds b1 <=` Card b2 ) )
proof end;
uniqueness
for b1, b2 being cardinal number st ex b3 being Basis of c2 st b1 = Card b3 & ( for b3 being Basis of c2 holds b1 <=` Card b3 ) & ex b3 being Basis of c2 st b2 = Card b3 & ( for b3 being Basis of c2 holds b2 <=` Card b3 ) holds
b1 = b2
proof end;
end;

:: deftheorem Def1 defines Chi TOPGEN_2:def 1 :
for b1 being non empty TopStruct
for b2 being Element of b1
for b3 being cardinal number holds
( b3 = Chi b2,b1 iff ( ex b4 being Basis of b2 st b3 = Card b4 & ( for b4 being Basis of b2 holds b3 <=` Card b4 ) ) );

theorem Th3: :: TOPGEN_2:3
for b1 being set st ( for b2 being set st b2 in b1 holds
b2 is cardinal number ) holds
union b1 is cardinal number
proof end;

E5: now
let c1 be non empty TopStruct ;
set c2 = { (Chi b1,c1) where B is Point of c1 : verum } ;
now
let c3 be set ;
assume c3 in { (Chi b1,c1) where B is Point of c1 : verum } ;
then ex b1 being Point of c1 st c3 = Chi b1,c1 ;
hence c3 is cardinal number ;
end;
hence union { (Chi b1,c1) where B is Point of c1 : verum } is cardinal number by Th3;
let c3 be cardinal number ;
assume E6: c3 = union { (Chi b1,c1) where B is Point of c1 : verum } ;
hereby
let c4 be Point of c1;
Chi c4,c1 in { (Chi b1,c1) where B is Point of c1 : verum } ;
hence Chi c4,c1 <=` c3 by E6, ZFMISC_1:92;
end;
let c4 be cardinal number ;
assume E7: for b1 being Point of c1 holds Chi b1,c1 <=` c4 ;
now
let c5 be set ;
assume c5 in { (Chi b1,c1) where B is Point of c1 : verum } ;
then ex b1 being Point of c1 st c5 = Chi b1,c1 ;
hence c5 c= c4 by E7;
end;
hence c3 <=` c4 by E6, ZFMISC_1:94;
end;

definition
let c1 be non empty TopStruct ;
func Chi c1 -> cardinal number means :Def2: :: TOPGEN_2:def 2
( ( for b1 being Point of a1 holds Chi b1,a1 <=` a2 ) & ( for b1 being cardinal number st ( for b2 being Point of a1 holds Chi b2,a1 <=` b1 ) holds
a2 <=` b1 ) );
existence
ex b1 being cardinal number st
( ( for b2 being Point of c1 holds Chi b2,c1 <=` b1 ) & ( for b2 being cardinal number st ( for b3 being Point of c1 holds Chi b3,c1 <=` b2 ) holds
b1 <=` b2 ) )
proof end;
uniqueness
for b1, b2 being cardinal number st ( for b3 being Point of c1 holds Chi b3,c1 <=` b1 ) & ( for b3 being cardinal number st ( for b4 being Point of c1 holds Chi b4,c1 <=` b3 ) holds
b1 <=` b3 ) & ( for b3 being Point of c1 holds Chi b3,c1 <=` b2 ) & ( for b3 being cardinal number st ( for b4 being Point of c1 holds Chi b4,c1 <=` b3 ) holds
b2 <=` b3 ) holds
b1 = b2
proof end;
end;

:: deftheorem Def2 defines Chi TOPGEN_2:def 2 :
for b1 being non empty TopStruct
for b2 being cardinal number holds
( b2 = Chi b1 iff ( ( for b3 being Point of b1 holds Chi b3,b1 <=` b2 ) & ( for b3 being cardinal number st ( for b4 being Point of b1 holds Chi b4,b1 <=` b3 ) holds
b2 <=` b3 ) ) );

theorem Th4: :: TOPGEN_2:4
for b1 being non empty TopStruct holds Chi b1 = union { (Chi b2,b1) where B is Point of b1 : verum }
proof end;

theorem Th5: :: TOPGEN_2:5
for b1 being non empty TopStruct
for b2 being Point of b1 holds Chi b2,b1 <=` Chi b1
proof end;

theorem Th6: :: TOPGEN_2:6
for b1 being non empty TopSpace holds
( b1 is first-countable iff Chi b1 <=` alef 0 )
proof end;

definition
let c1 be non empty TopSpace;
mode Neighborhood_System of c1 -> ManySortedSet of a1 means :Def3: :: TOPGEN_2:def 3
for b1 being Element of a1 holds a2 . b1 is Basis of b1;
existence
ex b1 being ManySortedSet of c1 st
for b2 being Element of c1 holds b1 . b2 is Basis of b2
proof end;
end;

:: deftheorem Def3 defines Neighborhood_System TOPGEN_2:def 3 :
for b1 being non empty TopSpace
for b2 being ManySortedSet of b1 holds
( b2 is Neighborhood_System of b1 iff for b3 being Element of b1 holds b2 . b3 is Basis of b3 );

definition
let c1 be non empty TopSpace;
let c2 be Neighborhood_System of c1;
redefine func Union as Union c2 -> Basis of a1;
coherence
Union c2 is Basis of c1
proof end;
let c3 be Point of c1;
redefine func . as c2 . c3 -> Basis of a3;
coherence
c2 . c3 is Basis of c3
by Def3;
end;

theorem Th7: :: TOPGEN_2:7
canceled;

theorem Th8: :: TOPGEN_2:8
for b1 being non empty TopSpace
for b2, b3 being Point of b1
for b4 being Basis of b2
for b5 being Basis of b3
for b6 being set st b2 in b6 & b6 in b5 holds
ex b7 being open Subset of b1 st
( b7 in b4 & b7 c= b6 )
proof end;

theorem Th9: :: TOPGEN_2:9
for b1 being non empty TopSpace
for b2 being Point of b1
for b3 being Basis of b2
for b4, b5 being set st b4 in b3 & b5 in b3 holds
ex b6 being open Subset of b1 st
( b6 in b3 & b6 c= b4 /\ b5 )
proof end;

E10: now
let c1 be non empty TopSpace;
let c2 be Subset of c1;
let c3 be Element of c1;
assume E11: c3 in Cl c2 ;
let c4 be Basis of c3;
let c5 be set ;
assume c5 in c4 ;
then E12: ( c3 in c5 & c5 is open Subset of c1 ) by YELLOW_8:21;
then c5 meets Cl c2 by E11, XBOOLE_0:3;
hence c5 meets c2 by E12, TSEP_1:40;
end;

E11: now
let c1 be non empty TopSpace;
let c2 be Subset of c1;
let c3 be Element of c1;
given c4 being Basis of c3 such that E12: for b1 being set st b1 in c4 holds
b1 meets c2 ;
now
let c5 be Subset of c1;
assume ( c5 is open & c3 in c5 ) ;
then consider c6 being Subset of c1 such that
E13: ( c6 in c4 & c6 c= c5 ) by YELLOW_8:def 2;
c6 meets c2 by E12, E13;
hence c2 meets c5 by E13, XBOOLE_1:63;
end;
hence c3 in Cl c2 by PRE_TOPC:def 13;
end;

theorem Th10: :: TOPGEN_2:10
for b1 being non empty TopSpace
for b2 being Subset of b1
for b3 being Element of b1 holds
( b3 in Cl b2 iff for b4 being Basis of b3
for b5 being set st b5 in b4 holds
b5 meets b2 )
proof end;

theorem Th11: :: TOPGEN_2:11
for b1 being non empty TopSpace
for b2 being Subset of b1
for b3 being Element of b1 holds
( b3 in Cl b2 iff ex b4 being Basis of b3 st
for b5 being set st b5 in b4 holds
b5 meets b2 )
proof end;

registration
let c1 be TopSpace;
cluster non empty open Element of K10(K10(the carrier of a1));
existence
ex b1 being Subset-Family of c1 st
( b1 is open & not b1 is empty )
proof end;
end;

theorem Th12: :: TOPGEN_2:12
for b1 being non empty TopSpace
for b2 being open Subset-Family of b1 ex b3 being open Subset-Family of b1 st
( b3 c= b2 & union b3 = union b2 & Card b3 <=` weight b1 )
proof end;

definition
let c1 be TopStruct ;
attr a1 is finite-weight means :Def4: :: TOPGEN_2:def 4
weight a1 is finite;
end;

:: deftheorem Def4 defines finite-weight TOPGEN_2:def 4 :
for b1 being TopStruct holds
( b1 is finite-weight iff weight b1 is finite );

notation
let c1 be TopStruct ;
antonym infinite-weight c1 for finite-weight c1;
end;

registration
cluster finite -> finite-weight TopStruct ;
coherence
for b1 being TopStruct st b1 is finite holds
b1 is finite-weight
proof end;
cluster infinite-weight -> infinite TopStruct ;
coherence
for b1 being TopStruct st not b1 is finite-weight holds
not b1 is finite
proof end;
end;

registration
cluster non empty finite finite-weight TopStruct ;
existence
ex b1 being TopSpace st
( b1 is finite & not b1 is empty )
proof end;
end;

theorem Th13: :: TOPGEN_2:13
for b1 being set holds Card (SmallestPartition b1) = Card b1
proof end;

theorem Th14: :: TOPGEN_2:14
for b1 being non empty discrete TopStruct holds
( SmallestPartition the carrier of b1 is Basis of b1 & ( for b2 being Basis of b1 holds SmallestPartition the carrier of b1 c= b2 ) )
proof end;

theorem Th15: :: TOPGEN_2:15
for b1 being non empty discrete TopStruct holds weight b1 = Card the carrier of b1
proof end;

registration
cluster infinite infinite-weight TopStruct ;
existence
not for b1 being TopSpace holds b1 is finite-weight
proof end;
end;

Lemma17: for b1 being infinite-weight TopSpace
for b2 being Basis of b1 ex b3 being Basis of b1 st
( b3 c= b2 & Card b3 = weight b1 )
proof end;

theorem Th16: :: TOPGEN_2:16
canceled;

theorem Th17: :: TOPGEN_2:17
for b1 being non empty finite-weight TopSpace ex b2 being Basis of b1ex b3 being Function of the carrier of b1,the topology of b1 st
( b2 = rng b3 & ( for b4 being Point of b1 holds
( b4 in b3 . b4 & ( for b5 being open Subset of b1 st b4 in b5 holds
b3 . b4 c= b5 ) ) ) )
proof end;

theorem Th18: :: TOPGEN_2:18
for b1 being TopSpace
for b2, b3 being Basis of b1
for b4 being Function of the carrier of b1,the topology of b1 st b2 = rng b4 & ( for b5 being Point of b1 holds
( b5 in b4 . b5 & ( for b6 being open Subset of b1 st b5 in b6 holds
b4 . b5 c= b6 ) ) ) holds
b2 c= b3
proof end;

theorem Th19: :: TOPGEN_2:19
for b1 being TopSpace
for b2 being Basis of b1
for b3 being Function of the carrier of b1,the topology of b1 st b2 = rng b3 & ( for b4 being Point of b1 holds
( b4 in b3 . b4 & ( for b5 being open Subset of b1 st b4 in b5 holds
b3 . b4 c= b5 ) ) ) holds
weight b1 = Card b2
proof end;

Lemma21: for b1 being non empty finite-weight TopSpace
for b2 being Basis of b1 ex b3 being Basis of b1 st
( b3 c= b2 & Card b3 = weight b1 )
proof end;

theorem Th20: :: TOPGEN_2:20
for b1 being non empty TopSpace
for b2 being Basis of b1 ex b3 being Basis of b1 st
( b3 c= b2 & Card b3 = weight b1 )
proof end;

definition
let c1, c2 be set ;
func DiscrWithInfin c1,c2 -> strict TopStruct means :Def5: :: TOPGEN_2:def 5
( the carrier of a3 = a1 & the topology of a3 = { b1 where B is Subset of a1 : not a2 in b1 } \/ { (b1 ` ) where B is Subset of a1 : b1 is finite } );
uniqueness
for b1, b2 being strict TopStruct st the carrier of b1 = c1 & the topology of b1 = { b3 where B is Subset of c1 : not c2 in b3 } \/ { (b3 ` ) where B is Subset of c1 : b3 is finite } & the carrier of b2 = c1 & the topology of b2 = { b3 where B is Subset of c1 : not c2 in b3 } \/ { (b3 ` ) where B is Subset of c1 : b3 is finite } holds
b1 = b2
;
existence
ex b1 being strict TopStruct st
( the carrier of b1 = c1 & the topology of b1 = { b2 where B is Subset of c1 : not c2 in b2 } \/ { (b2 ` ) where B is Subset of c1 : b2 is finite } )
proof end;
end;

:: deftheorem Def5 defines DiscrWithInfin TOPGEN_2:def 5 :
for b1, b2 being set
for b3 being strict TopStruct holds
( b3 = DiscrWithInfin b1,b2 iff ( the carrier of b3 = b1 & the topology of b3 = { b4 where B is Subset of b1 : not b2 in b4 } \/ { (b4 ` ) where B is Subset of b1 : b4 is finite } ) );

registration
let c1, c2 be set ;
cluster DiscrWithInfin a1,a2 -> strict TopSpace-like ;
coherence
DiscrWithInfin c1,c2 is TopSpace-like
proof end;
end;

registration
let c1 be non empty set ;
let c2 be set ;
cluster DiscrWithInfin a1,a2 -> non empty strict TopSpace-like ;
coherence
not DiscrWithInfin c1,c2 is empty
proof end;
end;

theorem Th21: :: TOPGEN_2:21
for b1, b2 being set
for b3 being Subset of (DiscrWithInfin b1,b2) holds
( b3 is open iff ( not b2 in b3 or b3 ` is finite ) )
proof end;

theorem Th22: :: TOPGEN_2:22
for b1, b2 being set
for b3 being Subset of (DiscrWithInfin b1,b2) holds
( b3 is closed iff not ( b2 in b1 & not b2 in b3 & not b3 is finite ) )
proof end;

theorem Th23: :: TOPGEN_2:23
for b1, b2, b3 being set st b3 in b1 holds
{b3} is closed Subset of (DiscrWithInfin b1,b2)
proof end;

theorem Th24: :: TOPGEN_2:24
for b1, b2, b3 being set st b3 in b1 & b3 <> b2 holds
{b3} is open Subset of (DiscrWithInfin b1,b2)
proof end;

theorem Th25: :: TOPGEN_2:25
for b1, b2 being set st not b1 is finite holds
for b3 being Subset of (DiscrWithInfin b1,b2) st b3 = {b2} holds
not b3 is open
proof end;

theorem Th26: :: TOPGEN_2:26
for b1, b2 being set
for b3 being Subset of (DiscrWithInfin b1,b2) st b3 is finite holds
Cl b3 = b3
proof end;

theorem Th27: :: TOPGEN_2:27
for b1 being non empty TopSpace
for b2 being Subset of b1 st not b2 is closed holds
for b3 being Point of b1 st b2 \/ {b3} is closed holds
Cl b2 = b2 \/ {b3}
proof end;

theorem Th28: :: TOPGEN_2:28
for b1, b2 being set st b2 in b1 holds
for b3 being Subset of (DiscrWithInfin b1,b2) st not b3 is finite holds
Cl b3 = b3 \/ {b2}
proof end;

theorem Th29: :: TOPGEN_2:29
for b1, b2 being set
for b3 being Subset of (DiscrWithInfin b1,b2) st b3 ` is finite holds
Int b3 = b3
proof end;

theorem Th30: :: TOPGEN_2:30
for b1, b2 being set st b2 in b1 holds
for b3 being Subset of (DiscrWithInfin b1,b2) st not b3 ` is finite holds
Int b3 = b3 \ {b2}
proof end;

theorem Th31: :: TOPGEN_2:31
for b1, b2 being set ex b3 being Basis of DiscrWithInfin b1,b2 st b3 = ((SmallestPartition b1) \ {{b2}}) \/ { (b4 ` ) where B is Subset of b1 : b4 is finite }
proof end;

theorem Th32: :: TOPGEN_2:32
for b1 being infinite set holds Card (Fin b1) = Card b1
proof end;

theorem Th33: :: TOPGEN_2:33
for b1 being infinite set holds Card { (b2 ` ) where B is Subset of b1 : b2 is finite } = Card b1
proof end;

theorem Th34: :: TOPGEN_2:34
for b1 being infinite set
for b2 being set
for b3 being Basis of DiscrWithInfin b1,b2 st b3 = ((SmallestPartition b1) \ {{b2}}) \/ { (b4 ` ) where B is Subset of b1 : b4 is finite } holds
Card b3 = Card b1
proof end;

theorem Th35: :: TOPGEN_2:35
for b1 being infinite set
for b2 being set
for b3 being Basis of DiscrWithInfin b1,b2 holds Card b1 <=` Card b3
proof end;

theorem Th36: :: TOPGEN_2:36
for b1 being infinite set
for b2 being set holds weight (DiscrWithInfin b1,b2) = Card b1
proof end;

theorem Th37: :: TOPGEN_2:37
for b1 being non empty set
for b2 being set ex b3 being prebasis of DiscrWithInfin b1,b2 st b3 = ((SmallestPartition b1) \ {{b2}}) \/ { ({b4} ` ) where B is Element of b1 : verum }
proof end;

theorem Th38: :: TOPGEN_2:38
for b1 being TopSpace
for b2 being Subset-Family of b1
for b3 being non empty Subset-Family of b2 st ( for b4 being set st b4 in b3 holds
b2 \ b4 is finite ) holds
Cl (union b2) = (union (clf b2)) \/ (meet { (Cl (union b4)) where B is Subset-Family of b1 : b4 in b3 } )
proof end;

theorem Th39: :: TOPGEN_2:39
for b1 being TopSpace
for b2 being Subset-Family of b1 holds Cl (union b2) = (union (clf b2)) \/ (meet { (Cl (union b3)) where B is Subset-Family of b1 : ( b3 c= b2 & b2 \ b3 is finite ) } )
proof end;

theorem Th40: :: TOPGEN_2:40
for b1 being set
for b2 being Subset-Family of (bool b1) st ( for b3 being Subset-Family of b1 st b3 in b2 holds
TopStruct(# b1,b3 #) is TopSpace ) holds
ex b3 being Subset-Family of b1 st
( b3 = Intersect b2 & TopStruct(# b1,b3 #) is TopSpace & ( for b4 being Subset-Family of b1 st b4 in b2 holds
TopStruct(# b1,b4 #) is TopExtension of TopStruct(# b1,b3 #) ) & ( for b4 being TopSpace st the carrier of b4 = b1 & ( for b5 being Subset-Family of b1 st b5 in b2 holds
TopStruct(# b1,b5 #) is TopExtension of b4 ) holds
TopStruct(# b1,b3 #) is TopExtension of b4 ) )
proof end;

theorem Th41: :: TOPGEN_2:41
for b1 being set
for b2 being Subset-Family of (bool b1) ex b3 being Subset-Family of b1 st
( b3 = UniCl (FinMeetCl (union b2)) & TopStruct(# b1,b3 #) is TopSpace & ( for b4 being Subset-Family of b1 st b4 in b2 holds
TopStruct(# b1,b3 #) is TopExtension of TopStruct(# b1,b4 #) ) & ( for b4 being TopSpace st the carrier of b4 = b1 & ( for b5 being Subset-Family of b1 st b5 in b2 holds
b4 is TopExtension of TopStruct(# b1,b5 #) ) holds
b4 is TopExtension of TopStruct(# b1,b3 #) ) )
proof end;