Skip to content

Commit bc3f130

Browse files
committed
fixing discrete topologies
1 parent 7dfb606 commit bc3f130

File tree

3 files changed

+381
-367
lines changed

3 files changed

+381
-367
lines changed

classical/filter.v

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1311,27 +1311,21 @@ Section PrincipalFilters.
13111311
Definition principal_filter {X : Type} (x : X) : set_system X :=
13121312
globally [set x].
13131313

1314-
(** we introducing an alias for pointed types with principal filters *)
1315-
Definition principal_filter_type (P : Type) : Type := P.
1316-
HB.instance Definition _ (P : choiceType) :=
1317-
Choice.copy (principal_filter_type P) P.
1318-
HB.instance Definition _ (P : pointedType) :=
1319-
Pointed.on (principal_filter_type P).
1320-
HB.instance Definition _ (P : choiceType) :=
1321-
hasNbhs.Build (principal_filter_type P) principal_filter.
1322-
HB.instance Definition _ (P : pointedType) :=
1323-
Filtered.on (principal_filter_type P).
1324-
13251314
Lemma principal_filterP {X} (x : X) (W : set X) : principal_filter x W <-> W x.
13261315
Proof. by split=> [|? ? ->]; [exact|]. Qed.
13271316

13281317
Lemma principal_filter_proper {X} (x : X) : ProperFilter (principal_filter x).
13291318
Proof. exact: globally_properfilter. Qed.
13301319

1331-
HB.instance Definition _ := hasNbhs.Build bool principal_filter.
1332-
13331320
End PrincipalFilters.
13341321

1322+
HB.mixin Record Discrete_ofNbhs T of Nbhs T := {
1323+
nbhs_principalE : (@nbhs T _) = principal_filter;
1324+
}.
1325+
1326+
#[short(type="discreteNbhsType")]
1327+
HB.structure Definition DiscreteNbhs := {T of Nbhs T & Discrete_ofNbhs T}.
1328+
13351329
Section UltraFilters.
13361330

13371331
Class UltraFilter T (F : set_system T) := {

theories/cantor.v

Lines changed: 20 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,12 @@ Import numFieldTopology.Exports.
4343

4444
Local Open Scope classical_set_scope.
4545

46-
Definition cantor_space :=
47-
prod_topology (fun _ : nat => discrete_topology discrete_bool).
46+
Definition cantor_space := prod_topology (fun _ : nat => bool).
4847

4948
HB.instance Definition _ := Pointed.on cantor_space.
50-
HB.instance Definition _ := Nbhs.on cantor_space.
51-
HB.instance Definition _ := Topological.on cantor_space.
49+
HB.instance Definition _ := Uniform.on cantor_space.
50+
HB.instance Definition _ {R: realType} : @PseudoMetric R _ :=
51+
PseudoMetric.on cantor_space.
5252

5353
Definition cantor_like (T : topologicalType) :=
5454
[/\ perfect_set [set: T],
@@ -58,20 +58,18 @@ Definition cantor_like (T : topologicalType) :=
5858

5959
Lemma cantor_space_compact : compact [set: cantor_space].
6060
Proof.
61-
have := @tychonoff _ (fun _ : nat => _) _ (fun=> discrete_bool_compact).
61+
have := @tychonoff nat (fun _ : nat => bool) (fun=> setT) (fun=> bool_compact).
6262
by congr (compact _); rewrite eqEsubset.
6363
Qed.
6464

6565
Lemma cantor_space_hausdorff : hausdorff_space cantor_space.
6666
Proof.
67-
apply: hausdorff_product => ?; apply: discrete_hausdorff.
68-
exact: discrete_space_discrete.
67+
by apply: hausdorff_product => ?; exact: discrete_hausdorff.
6968
Qed.
7069

7170
Lemma cantor_zero_dimensional : zero_dimensional cantor_space.
7271
Proof.
73-
apply: zero_dimension_prod => _; apply: discrete_zero_dimension.
74-
exact: discrete_space_discrete.
72+
by apply: zero_dimension_prod => _; exact: discrete_zero_dimension.
7573
Qed.
7674

7775
Lemma cantor_perfect : perfect_set [set: cantor_space].
@@ -86,7 +84,6 @@ split.
8684
- exact: cantor_zero_dimensional.
8785
Qed.
8886

89-
9087
(**md**************************************************************************)
9188
(* ## Part 1 *)
9289
(* *)
@@ -102,13 +99,12 @@ Qed.
10299
(* *)
103100
(******************************************************************************)
104101
Section topological_trees.
105-
Context {K : nat -> ptopologicalType} {X : ptopologicalType}
102+
Context {K : nat -> pdiscreteTopologicalType} {X : ptopologicalType}
106103
(refine_apx : forall n, set X -> K n -> set X)
107104
(tree_invariant : set X -> Prop).
108105

109106
Hypothesis cmptX : compact [set: X].
110107
Hypothesis hsdfX : hausdorff_space X.
111-
Hypothesis discreteK : forall n, discrete_space (K n).
112108
Hypothesis refine_cover : forall n U, U = \bigcup_e @refine_apx n U e.
113109
Hypothesis refine_invar : forall n U e,
114110
tree_invariant U -> tree_invariant (@refine_apx n U e).
@@ -122,7 +118,7 @@ Hypothesis refine_separates: forall x y : X, x != y ->
122118
Let refine_subset n U e : @refine_apx n U e `<=` U.
123119
Proof. by rewrite [X in _ `<=` X](refine_cover n); exact: bigcup_sup. Qed.
124120

125-
Let T := prod_topology K.
121+
Let T := prod_topology (K : nat -> ptopologicalType).
126122

127123
Local Fixpoint branch_apx (b : T) n :=
128124
if n is m.+1 then refine_apx (branch_apx b m) (b m) else [set: X].
@@ -193,7 +189,6 @@ near=> z => i; rewrite leq_eqVlt => /predU1P[|iSn]; last by rewrite (near IH z).
193189
move=> [->]; near: z; exists (proj n @^-1` [set b n]).
194190
split => //; suff : @open T (proj n @^-1` [set b n]) by [].
195191
apply: open_comp; [move=> + _; exact: proj_continuous| apply: discrete_open].
196-
exact: discreteK.
197192
Unshelve. all: end_near. Qed.
198193

199194
Let apx_prefix b c n :
@@ -293,9 +288,7 @@ Local Lemma cantor_map : exists f : cantor_space -> T,
293288
set_surj [set: cantor_space] [set: T] f &
294289
set_inj [set: cantor_space] f ].
295290
Proof.
296-
have [] := @tree_map_props
297-
(fun=> discrete_topology discrete_bool) T c_ind c_invar cmptT hsdfT.
298-
- by move=> ?; exact: discrete_space_discrete.
291+
have [] := @tree_map_props (fun=> bool) T c_ind c_invar cmptT hsdfT.
299292
- move=> n V; rewrite eqEsubset; split => [t Vt|t [? ? []]//].
300293
have [?|?] := pselect (U_ n `&` V !=set0 /\ ~` U_ n `&` V !=set0).
301294
+ have [Unt|Unt] := pselect (U_ n t).
@@ -356,7 +349,7 @@ End TreeStructure.
356349
Section FinitelyBranchingTrees.
357350

358351
Definition tree_of (T : nat -> pointedType) : Type :=
359-
prod_topology (fun n => discrete_topology_type (T n)).
352+
prod_topology (fun n => discrete_topology (T n)).
360353

361354
HB.instance Definition _ (T : nat -> pointedType) : Pointed (tree_of T):=
362355
Pointed.on (tree_of T).
@@ -368,20 +361,19 @@ HB.instance Definition _ {R : realType} (T : nat -> pointedType) :
368361
@PseudoMetric.on (tree_of T).
369362

370363
Lemma cantor_like_finite_prod (T : nat -> ptopologicalType) :
371-
(forall n, finite_set [set: discrete_topology_type (T n)]) ->
364+
(forall n, finite_set [set: discrete_topology (T n)]) ->
372365
(forall n, (exists xy : T n * T n, xy.1 != xy.2)) ->
373366
cantor_like (tree_of T).
374367
Proof.
375368
move=> finiteT twoElems; split.
376-
- exact/(@perfect_diagonal (discrete_topology_type \o T))/twoElems.
369+
- exact/(@perfect_diagonal (discrete_topology \o T))/twoElems.
377370
- have := tychonoff (fun n => finite_compact (finiteT n)).
378371
set A := (X in compact X -> _).
379372
suff : A = [set: tree_of (fun x : nat => T x)] by move=> ->.
380373
by rewrite eqEsubset.
381-
- apply: (@hausdorff_product _ (discrete_topology_type \o T)) => n.
374+
- apply: (@hausdorff_product _ (discrete_topology \o T)) => n.
382375
by apply: discrete_hausdorff; exact: discrete_space_discrete.
383376
- apply: zero_dimension_prod => ?; apply: discrete_zero_dimension.
384-
exact: discrete_space_discrete.
385377
Qed.
386378

387379
End FinitelyBranchingTrees.
@@ -469,9 +461,11 @@ HB.instance Definition _ n := gen_eqMixin (K' n).
469461
HB.instance Definition _ n := gen_choiceMixin (K' n).
470462
HB.instance Definition _ n := isPointed.Build (K' n) (K'p n).
471463

472-
Let K n := K' n.
464+
Let K n := discrete_topology (K' n).
473465
Let Tree := @tree_of K.
474466

467+
HB.saturate.
468+
475469
Let embed_refine n (U : set T) (k : K n) :=
476470
(if pselect (projT1 k `&` U !=set0)
477471
then projT1 k
@@ -485,18 +479,12 @@ Proof.
485479
case: e => W; have [//| _ _ _ _] := projT2 (cid (ent_balls' (count_unif n))).
486480
exact.
487481
Qed.
488-
489-
Let discrete_subproof (P : choiceType) :
490-
discrete_space (principal_filter_type P).
491-
Proof. by []. Qed.
492-
493482
Local Lemma cantor_surj_pt1 : exists2 f : Tree -> T,
494483
continuous f & set_surj [set: Tree] [set: T] f.
495484
Proof.
496485
pose entn n := projT2 (cid (ent_balls' (count_unif n))).
497-
have [//| | |? []//| |? []// | |] := @tree_map_props
498-
(discrete_topology_type \o K) T (embed_refine) (embed_invar) cptT hsdfT.
499-
- by move=> n; exact: discrete_space_discrete.
486+
have [ | |? []//| |? []// | |] := @tree_map_props
487+
(discrete_topology \o K) T (embed_refine) (embed_invar) cptT hsdfT.
500488
- move=> n U; rewrite eqEsubset; split=> [t Ut|t [? ? []]//].
501489
have [//|_ _ _ + _] := entn n; rewrite -subTset.
502490
move=> /(_ t I)[W cbW Wt]; exists (existT _ W cbW) => //.
@@ -535,7 +523,7 @@ Local Lemma cantor_surj_pt2 :
535523
exists f : {surj [set: cantor_space] >-> [set: Tree]}, continuous f.
536524
Proof.
537525
have [|f [ctsf _]] := @homeomorphism_cantor_like R Tree; last by exists f.
538-
apply: (@cantor_like_finite_prod (discrete_topology_type \o K)) => [n /=|n].
526+
apply: (@cantor_like_finite_prod (discrete_topology \o K)) => [n /=|n].
539527
have [//| fs _ _ _ _] := projT2 (cid (ent_balls' (count_unif n))).
540528
suff -> : [set: {classic K' n}] =
541529
(@projT1 (set T) _) @^-1` (projT1 (cid (ent_balls' (count_unif n)))).

0 commit comments

Comments
 (0)