Skip to content

Commit 0e930a0

Browse files
committed
feat: define IsRightUniformGroup and IsLeftUniformGroup (#30029)
This mostly contains the definition and additional documentation. Future PRs will take care of expanding the theory, and proving in particular that `IsUniformGroup` is precisely the conjuction of these two typeclasses.
1 parent 72ea06d commit 0e930a0

File tree

2 files changed

+162
-34
lines changed

2 files changed

+162
-34
lines changed

Mathlib/Topology/Algebra/IsUniformGroup/Basic.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,8 @@ theorem UniformCauchySeqOn.div (hf : UniformCauchySeqOn f l s) (hf' : UniformCau
161161
end UniformConvergence
162162

163163
@[to_additive]
164-
instance IsUniformGroup.of_compactSpace [UniformSpace β] [Group β] [ContinuousDiv β]
165-
[CompactSpace β] :
164+
instance (priority := 100) IsUniformGroup.of_compactSpace [UniformSpace β] [Group β]
165+
[ContinuousDiv β] [CompactSpace β] :
166166
IsUniformGroup β where
167167
uniformContinuous_div := CompactSpace.uniformContinuous_of_continuous continuous_div'
168168

Mathlib/Topology/Algebra/IsUniformGroup/Defs.lean

Lines changed: 160 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,45 @@
11
/-
22
Copyright (c) 2018 Patrick Massot. All rights reserved.
33
Released under Apache 2.0 license as described in the file LICENSE.
4-
Authors: Patrick Massot, Johannes Hölzl
4+
Authors: Patrick Massot, Johannes Hölzl, Anatole Dedecker
55
-/
66
import Mathlib.Topology.UniformSpace.Basic
77
import Mathlib.Topology.Algebra.Group.Basic
88

99
/-!
1010
# Uniform structure on topological groups
1111
12-
This file defines uniform groups and its additive counterpart. These typeclasses should be
13-
preferred over using `[TopologicalSpace α] [IsTopologicalGroup α]` since every topological
14-
group naturally induces a uniform structure.
12+
Given a topological group `G`, one can naturally build two uniform structures
13+
(the "left" and "right" ones) on `G` inducing its topology.
14+
This file defines typeclasses for groups equipped with either of these uniform strucures, as well
15+
as a separate typeclass for the (very common) case where the given uniform structure
16+
coincides with **both** the left and right uniform structures.
1517
1618
## Main declarations
19+
20+
* `IsRightUniformGroup` and `IsRightUniformAddGroup`: Multiplicative and additive topological groups
21+
endowed with the associated right uniform structure. This means that two points `x` and `y`
22+
are close precisely when `y * x⁻¹` is close to `1` / `y + (-x)` close to `0`.
23+
* `IsLeftUniformGroup` and `IsLeftUniformAddGroup`: Multiplicative and additive topological groups
24+
endowed with the associated left uniform structure. This means that two points `x` and `y`
25+
are close precisely when `x⁻¹ * y` is close to `1` / `(-x) + y` close to `0`.
1726
* `IsUniformGroup` and `IsUniformAddGroup`: Multiplicative and additive uniform groups,
18-
i.e., groups with uniformly continuous `(*)` and `(⁻¹)` / `(+)` and `(-)`.
27+
i.e., groups with uniformly continuous `(*)` and `(⁻¹)` / `(+)` and `(-)`. This corresponds
28+
to the conjuction of the two conditions above, although this result is not in Mathlib yet.
1929
2030
## Main results
2131
2232
* `IsTopologicalAddGroup.toUniformSpace` and `comm_topologicalAddGroup_is_uniform` can be used
2333
to construct a canonical uniformity for a topological additive group.
2434
2535
See `Mathlib/Topology/Algebra/IsUniformGroup/Basic.lean` for further results.
36+
37+
## Implementation Notes
38+
39+
Since the most frequent use case is `G` being a commutative additive groups, `Mathlib` originally
40+
did essentially all the theory under the assumption `IsUniformGroup G`.
41+
For this reason, you may find results stated under this assumption even though they may hold
42+
under either `IsRightUniformGroup G` or `IsLeftUniformGroup G`.
2643
-/
2744

2845
assert_not_exists Cauchy
@@ -31,18 +48,138 @@ noncomputable section
3148

3249
open Uniformity Topology Filter Pointwise
3350

51+
section LeftRight
52+
53+
open Filter Set
54+
55+
variable {G Gₗ Gᵣ Hₗ Hᵣ X : Type*}
56+
57+
/-- A **right-uniform additive group** is a topological additive group endowed with the associated
58+
right uniform structure: the uniformity filter `𝓤 G` is the inverse image of `𝓝 0` by the map
59+
`(x, y) ↦ y + (-x)`.
60+
61+
In other words, we declare that two points `x` and `y` are infinitely close
62+
precisely when `y + (-x)` is infinitely close to `0`. -/
63+
class IsRightUniformAddGroup (G : Type*) [UniformSpace G] [AddGroup G] : Prop
64+
extends IsTopologicalAddGroup G where
65+
uniformity_eq :
66+
𝓤 G = comap (fun x : G × G ↦ x.2 + (-x.1)) (𝓝 0)
67+
68+
/-- A **right-uniform group** is a topological group endowed with the associated
69+
right uniform structure: the uniformity filter `𝓤 G` is the inverse image of `𝓝 1` by the map
70+
`(x, y) ↦ y * x⁻¹`.
71+
72+
In other words, we declare that two points `x` and `y` are infinitely close
73+
precisely when `y * x⁻¹` is infinitely close to `1`. -/
74+
@[to_additive]
75+
class IsRightUniformGroup (G : Type*) [UniformSpace G] [Group G] : Prop
76+
extends IsTopologicalGroup G where
77+
uniformity_eq :
78+
𝓤 G = comap (fun x : G × G ↦ x.2 * x.1⁻¹) (𝓝 1)
79+
80+
/-- A **left-uniform additive group** is a topological additive group endowed with the associated
81+
left uniform structure: the uniformity filter `𝓤 G` is the inverse image of `𝓝 0` by the map
82+
`(x, y) ↦ (-x) + y`.
83+
84+
In other words, we declare that two points `x` and `y` are infinitely close
85+
precisely when `(-x) + y` is infinitely close to `0`. -/
86+
class IsLeftUniformAddGroup (G : Type*) [UniformSpace G] [AddGroup G] : Prop
87+
extends IsTopologicalAddGroup G where
88+
uniformity_eq :
89+
𝓤 G = comap (fun x : G × G ↦ (-x.1) + x.2) (𝓝 0)
90+
91+
/-- A **left-uniform group** is a topological group endowed with the associated
92+
left uniform structure: the uniformity filter `𝓤 G` is the inverse image of `𝓝 1` by the map
93+
`(x, y) ↦ x⁻¹ * y`.
94+
95+
In other words, we declare that two points `x` and `y` are infinitely close
96+
precisely when `x⁻¹ * y` is infinitely close to `1`. -/
97+
@[to_additive]
98+
class IsLeftUniformGroup (G : Type*) [UniformSpace G] [Group G] : Prop
99+
extends IsTopologicalGroup G where
100+
uniformity_eq :
101+
𝓤 G = comap (fun x : G × G ↦ x.1⁻¹ * x.2) (𝓝 1)
102+
103+
attribute [instance 10] IsRightUniformAddGroup.toIsTopologicalAddGroup
104+
attribute [instance 10] IsRightUniformGroup.toIsTopologicalGroup
105+
attribute [instance 10] IsLeftUniformAddGroup.toIsTopologicalAddGroup
106+
attribute [instance 10] IsLeftUniformGroup.toIsTopologicalGroup
107+
108+
variable [UniformSpace Gₗ] [UniformSpace Gᵣ] [Group Gₗ] [Group Gᵣ]
109+
variable [UniformSpace Hₗ] [UniformSpace Hᵣ] [Group Hₗ] [Group Hᵣ]
110+
variable [IsLeftUniformGroup Gₗ] [IsRightUniformGroup Gᵣ]
111+
variable [IsLeftUniformGroup Hₗ] [IsRightUniformGroup Hᵣ]
112+
variable [UniformSpace X]
113+
114+
variable (Gₗ Gᵣ)
115+
116+
@[to_additive]
117+
lemma uniformity_eq_comap_mul_inv_nhds_one :
118+
𝓤 Gᵣ = comap (fun x : Gᵣ × Gᵣ ↦ x.2 * x.1⁻¹) (𝓝 1) :=
119+
IsRightUniformGroup.uniformity_eq
120+
121+
@[to_additive]
122+
lemma uniformity_eq_comap_inv_mul_nhds_one :
123+
𝓤 Gₗ = comap (fun x : Gₗ × Gₗ ↦ x.1⁻¹ * x.2) (𝓝 1) :=
124+
IsLeftUniformGroup.uniformity_eq
125+
126+
@[to_additive]
127+
lemma uniformity_eq_comap_mul_inv_nhds_one_swapped :
128+
𝓤 Gᵣ = comap (fun x : Gᵣ × Gᵣ ↦ x.1 * x.2⁻¹) (𝓝 1) := by
129+
rw [← comap_swap_uniformity, uniformity_eq_comap_mul_inv_nhds_one, comap_comap]
130+
rfl
131+
132+
@[to_additive]
133+
lemma uniformity_eq_comap_inv_mul_nhds_one_swapped :
134+
𝓤 Gₗ = comap (fun x : Gₗ × Gₗ ↦ x.2⁻¹ * x.1) (𝓝 1) := by
135+
rw [← comap_swap_uniformity, uniformity_eq_comap_inv_mul_nhds_one, comap_comap]
136+
rfl
137+
138+
@[to_additive]
139+
theorem uniformity_eq_comap_nhds_one : 𝓤 Gᵣ = comap (fun x : Gᵣ × Gᵣ => x.2 / x.1) (𝓝 1) := by
140+
simp_rw [div_eq_mul_inv]
141+
exact uniformity_eq_comap_mul_inv_nhds_one Gᵣ
142+
143+
@[to_additive]
144+
theorem uniformity_eq_comap_nhds_one_swapped :
145+
𝓤 Gᵣ = comap (fun x : Gᵣ × Gᵣ => x.1 / x.2) (𝓝 1) := by
146+
rw [← comap_swap_uniformity, uniformity_eq_comap_nhds_one, comap_comap]
147+
rfl
148+
149+
variable {Gₗ Gᵣ}
150+
151+
end LeftRight
152+
34153
section IsUniformGroup
35154

36155
open Filter Set
37156

38157
variable {α : Type*} {β : Type*}
39158

40-
/-- A uniform group is a group in which multiplication and inversion are uniformly continuous. -/
159+
/-- A uniform group is a group in which multiplication and inversion are uniformly continuous.
160+
161+
`IsUniformGroup G` is equivalent to the fact that `G` is a topological group, and the uniformity
162+
coincides with **both** the associated left and right uniformities
163+
(this fact is not in Mathlib yet).
164+
165+
Since there are topological groups where these two uniformities do **not** coincide,
166+
not all topological groups admit a uniform group structure in this sense. This is however the
167+
case for commutative groups, which are the main motivation for the existence of this
168+
typeclass. -/
41169
class IsUniformGroup (α : Type*) [UniformSpace α] [Group α] : Prop where
42170
uniformContinuous_div : UniformContinuous fun p : α × α => p.1 / p.2
43171

44-
/-- A uniform additive group is an additive group in which addition
45-
and negation are uniformly continuous. -/
172+
/-- A uniform additive group is an additive group in which addition and negation are
173+
uniformly continuous.
174+
175+
`IsUniformAddGroup G` is equivalent to the fact that `G` is a topological additive group, and the
176+
uniformity coincides with **both** the associated left and right uniformities
177+
(this fact is not in Mathlib yet).
178+
179+
Since there are topological groups where these two uniformities do **not** coincide,
180+
not all topological groups admit a uniform group structure in this sense. This is however the
181+
case for commutative groups, which are the main motivation for the existence of this
182+
typeclass. -/
46183
class IsUniformAddGroup (α : Type*) [UniformSpace α] [AddGroup α] : Prop where
47184
uniformContinuous_sub : UniformContinuous fun p : α × α => p.1 - p.2
48185

@@ -221,25 +358,29 @@ section
221358
variable (α)
222359

223360
@[to_additive]
224-
theorem uniformity_eq_comap_nhds_one : 𝓤 α = comap (fun x : α × α => x.2 / x.1) (𝓝 (1 : α)) := by
225-
refine eq_of_forall_le_iff fun 𝓕 ↦ ?_
226-
rw [nhds_eq_comap_uniformity, comap_comap, ← tendsto_iff_comap,
227-
← (tendsto_diag_uniformity Prod.fst 𝓕).uniformity_mul_iff_left, ← tendsto_id']
228-
congrm Tendsto ?_ _ _
229-
ext <;> simp
361+
instance IsUniformGroup.isRightUniformGroup : IsRightUniformGroup α where
362+
uniformity_eq := by
363+
refine eq_of_forall_le_iff fun 𝓕 ↦ ?_
364+
rw [nhds_eq_comap_uniformity, comap_comap, ← tendsto_iff_comap,
365+
← (tendsto_diag_uniformity Prod.fst 𝓕).uniformity_mul_iff_left, ← tendsto_id']
366+
congrm Tendsto ?_ _ _
367+
ext <;> simp
230368

231369
@[to_additive]
232-
theorem uniformity_eq_comap_nhds_one_swapped :
233-
𝓤 α = comap (fun x : α × α => x.1 / x.2) (𝓝 (1 : α)) := by
234-
rw [← comap_swap_uniformity, uniformity_eq_comap_nhds_one, comap_comap]
235-
rfl
370+
instance IsUniformGroup.isLeftUniformGroup : IsLeftUniformGroup α where
371+
uniformity_eq := by
372+
refine eq_of_forall_le_iff fun 𝓕 ↦ ?_
373+
rw [nhds_eq_comap_uniformity, comap_comap, ← tendsto_iff_comap,
374+
← (tendsto_diag_uniformity Prod.fst 𝓕).uniformity_mul_iff_right, ← tendsto_id']
375+
congrm Tendsto ?_ _ _
376+
ext <;> simp
236377

237378
@[to_additive]
238379
theorem IsUniformGroup.ext {G : Type*} [Group G] {u v : UniformSpace G} (hu : @IsUniformGroup G u _)
239380
(hv : @IsUniformGroup G v _)
240381
(h : @nhds _ u.toTopologicalSpace 1 = @nhds _ v.toTopologicalSpace 1) : u = v :=
241382
UniformSpace.ext <| by
242-
rw [@uniformity_eq_comap_nhds_one _ u _ hu, @uniformity_eq_comap_nhds_one _ v _ hv, h]
383+
rw [(have := hu; uniformity_eq_comap_nhds_one), (have := hv; uniformity_eq_comap_nhds_one), h]
243384

244385
@[to_additive]
245386
theorem IsUniformGroup.ext_iff {G : Type*} [Group G] {u v : UniformSpace G}
@@ -257,19 +398,6 @@ theorem IsUniformGroup.uniformity_countably_generated [(𝓝 (1 : α)).IsCountab
257398

258399
open MulOpposite
259400

260-
@[to_additive]
261-
theorem uniformity_eq_comap_inv_mul_nhds_one :
262-
𝓤 α = comap (fun x : α × α => x.1⁻¹ * x.2) (𝓝 (1 : α)) := by
263-
rw [← comap_uniformity_mulOpposite, uniformity_eq_comap_nhds_one, ← op_one, ← comap_unop_nhds,
264-
comap_comap, comap_comap]
265-
simp [Function.comp_def]
266-
267-
@[to_additive]
268-
theorem uniformity_eq_comap_inv_mul_nhds_one_swapped :
269-
𝓤 α = comap (fun x : α × α => x.2⁻¹ * x.1) (𝓝 (1 : α)) := by
270-
rw [← comap_swap_uniformity, uniformity_eq_comap_inv_mul_nhds_one, comap_comap]
271-
rfl
272-
273401
end
274402

275403
@[to_additive]

0 commit comments

Comments
 (0)