Skip to content

Commit 861e4fd

Browse files
committed
feat: define ContinuousMapZero (#11220)
This defines the type of continuous maps `C(X, R)₀` (notation is scoped) that map zero to zero. This type is used to define the continuous functional calculus for non-unital algebras. While it is possible to use a term, namely an ideal of `C(X, R)` given by the kernel of the evaluation (at zero) map, this caused problems with type class inference.
1 parent b6e4828 commit 861e4fd

File tree

2 files changed

+135
-0
lines changed

2 files changed

+135
-0
lines changed

Mathlib.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3820,6 +3820,7 @@ import Mathlib.Topology.ContinuousFunction.Basic
38203820
import Mathlib.Topology.ContinuousFunction.Bounded
38213821
import Mathlib.Topology.ContinuousFunction.CocompactMap
38223822
import Mathlib.Topology.ContinuousFunction.Compact
3823+
import Mathlib.Topology.ContinuousFunction.ContinuousMapZero
38233824
import Mathlib.Topology.ContinuousFunction.FunctionalCalculus
38243825
import Mathlib.Topology.ContinuousFunction.Ideals
38253826
import Mathlib.Topology.ContinuousFunction.LocallyConstant
Lines changed: 134 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,134 @@
1+
/-
2+
Copyright (c) 2024 Jireh Loreaux. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: Jireh Loreaux
5+
-/
6+
import Mathlib.Topology.ContinuousFunction.Algebra
7+
8+
/-!
9+
# Continuous maps sending zero to zero
10+
11+
This is the type of continuous maps from `X` to `R` such that `(0 : X) ↦ (0 : R)` for which we
12+
provide the scoped notation `C(X, R)₀`. We provide this as a dedicated type solely for the
13+
non-unital continuous functional calculus, as using various terms of type `Ideal C(X, R)` were
14+
overly burdensome on type class synthesis.
15+
16+
Of course, one could generalize to maps between pointed topological spaces, but that goes beyond
17+
the purpose of this type.
18+
-/
19+
20+
/-- The type of continuous maps which map zero to zero. -/
21+
structure ContinuousMapZero (X R : Type*) [Zero X] [Zero R] [TopologicalSpace X]
22+
[TopologicalSpace R] extends C(X, R) where
23+
map_zero' : toContinuousMap 0 = 0
24+
25+
namespace ContinuousMapZero
26+
27+
@[inherit_doc]
28+
scoped notation "C(" X ", " R ")₀" => ContinuousMapZero X R
29+
30+
section Basic
31+
32+
variable {X Y R : Type*} [Zero X] [Zero Y] [Zero R]
33+
variable [TopologicalSpace X] [TopologicalSpace Y] [TopologicalSpace R]
34+
35+
instance instFunLike : FunLike C(X, R)₀ X R where
36+
coe f := f.toFun
37+
coe_injective' f g h := by
38+
cases f
39+
cases g
40+
congr
41+
apply DFunLike.coe_injective'
42+
exact h
43+
44+
instance instContinuousMapClass : ContinuousMapClass C(X, R)₀ X R where
45+
map_continuous f := f.continuous
46+
47+
instance instZeroHomClass : ZeroHomClass C(X, R)₀ X R where
48+
map_zero f := f.map_zero'
49+
50+
@[ext]
51+
lemma ext {f g : C(X, R)₀} (h : ∀ x, f x = g x) : f = g := DFunLike.ext f g h
52+
53+
@[simp]
54+
lemma coe_mk {f : C(X, R)} {h0 : f 0 = 0} : ⇑(mk f h0) = f := rfl
55+
56+
/-- Composition of continuous maps which map zero to zero. -/
57+
def comp (g : C(Y, R)₀) (f : C(X, Y)₀) : C(X, R)₀ where
58+
toContinuousMap := g.toContinuousMap.comp f.toContinuousMap
59+
map_zero' := show g (f 0) = 0 from map_zero f ▸ map_zero g
60+
61+
@[simp]
62+
lemma comp_apply (g : C(Y, R)₀) (f : C(X, Y)₀) (x : X) : g.comp f x = g (f x) := rfl
63+
64+
end Basic
65+
66+
section Semiring
67+
68+
variable {X R : Type*} [Zero X] [TopologicalSpace X]
69+
variable [CommSemiring R] [TopologicalSpace R] [TopologicalSemiring R]
70+
71+
instance instZero : Zero C(X, R)₀ where
72+
zero := ⟨0, rfl⟩
73+
74+
instance instAdd : Add C(X, R)₀ where
75+
add f g := ⟨f + g, by simp⟩
76+
77+
instance instMul : Mul C(X, R)₀ where
78+
mul f g := ⟨f * g, by simp⟩
79+
80+
instance instSMul {M : Type*} [SMulZeroClass M R] [ContinuousConstSMul M R] :
81+
SMul M C(X, R)₀ where
82+
smul m f := ⟨m • f, by simp⟩
83+
84+
lemma toContinuousMap_injective :
85+
Function.Injective (toContinuousMap (X := X) (R := R)) :=
86+
fun f g h ↦ by refine congr(.mk $(h) ?_); exacts [f.map_zero', g.map_zero']
87+
88+
instance instNonUnitalCommSemiring : NonUnitalCommSemiring C(X, R)₀ :=
89+
(toContinuousMap_injective (X := X) (R := R)).nonUnitalCommSemiring
90+
_ rfl (fun _ _ ↦ rfl) (fun _ _ ↦ rfl) (fun _ _ ↦ rfl)
91+
92+
instance instModule {M : Type*} [Semiring M] [Module M R] [ContinuousConstSMul M R] :
93+
Module M C(X, R)₀ :=
94+
(toContinuousMap_injective (X := X) (R := R)).module M
95+
{ toFun := _, map_add' := fun _ _ ↦ rfl, map_zero' := rfl } (fun _ _ ↦ rfl)
96+
97+
instance instSMulCommClass {M N : Type*} [SMulZeroClass M R] [ContinuousConstSMul M R]
98+
[SMulZeroClass N R] [ContinuousConstSMul N R] [SMulCommClass M N R] :
99+
SMulCommClass M N C(X, R)₀ where
100+
smul_comm _ _ _ := ext fun _ ↦ smul_comm ..
101+
102+
instance instIsScalarTower {M N : Type*} [SMulZeroClass M R] [ContinuousConstSMul M R]
103+
[SMulZeroClass N R] [ContinuousConstSMul N R] [SMul M N] [IsScalarTower M N R] :
104+
IsScalarTower M N C(X, R)₀ where
105+
smul_assoc _ _ _ := ext fun _ ↦ smul_assoc ..
106+
107+
instance instStarRing [StarRing R] [ContinuousStar R] : StarRing C(X, R)₀ where
108+
star f := ⟨star f, by simp⟩
109+
star_involutive _ := ext fun _ ↦ star_star _
110+
star_mul _ _ := ext fun _ ↦ star_mul ..
111+
star_add _ _ := ext fun _ ↦ star_add ..
112+
113+
instance instTopologicalSpace : TopologicalSpace C(X, R)₀ :=
114+
TopologicalSpace.induced toContinuousMap inferInstance
115+
116+
end Semiring
117+
118+
variable {X R : Type*} [Zero X] [TopologicalSpace X]
119+
variable [CommRing R] [TopologicalSpace R] [TopologicalRing R]
120+
section Ring
121+
122+
instance instSub : Sub C(X, R)₀ where
123+
sub f g := ⟨f - g, by simp⟩
124+
125+
instance instNeg : Neg C(X, R)₀ where
126+
neg f := ⟨-f, by simp⟩
127+
128+
instance instNonUnitalCommRing : NonUnitalCommRing C(X, R)₀ :=
129+
(toContinuousMap_injective (X := X) (R := R)).nonUnitalCommRing _ rfl
130+
(fun _ _ ↦ rfl) (fun _ _ ↦ rfl) (fun _ ↦ rfl) (fun _ _ ↦ rfl) (fun _ _ ↦ rfl) (fun _ _ ↦ rfl)
131+
132+
end Ring
133+
134+
end ContinuousMapZero

0 commit comments

Comments
 (0)