analysis.normed_space.star.gelfand_duality ⟷ Mathlib.Analysis.NormedSpace.Star.GelfandDuality

This file has been ported!

Changes since the initial port

The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.

Changes in mathlib3

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -189,7 +189,7 @@ theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A)
   have h : (gelfand_transform β„‚ A).range.topologicalClosure = (gelfand_transform β„‚ A).range :=
     le_antisymm
       (Subalgebra.topologicalClosure_minimal _ le_rfl
-        (gelfandTransform_isometry A).ClosedEmbedding.closed_range)
+        (gelfandTransform_isometry A).ClosedEmbedding.isClosed_range)
       (Subalgebra.le_topologicalClosure _)
   refine'
     h β–Έ
Diff
@@ -119,7 +119,7 @@ theorem WeakDual.CharacterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
   refine' ⟨fun hz => _, _⟩
   · obtain ⟨f, hf⟩ := WeakDual.CharacterSpace.exists_apply_eq_zero hz
     simp only [map_sub, sub_eq_zero, AlgHomClass.commutes, Algebra.id.map_eq_id,
-      RingHom.id_apply] at hf 
+      RingHom.id_apply] at hf
     exact (ContinuousMap.spectrum_eq_range (gelfand_transform β„‚ A a)).symm β–Έ ⟨f, hf.symm⟩
   · rintro ⟨f, rfl⟩
     exact AlgHom.apply_mem_spectrum f a
@@ -170,7 +170,7 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
   have : spectralRadius β„‚ (gelfand_transform β„‚ A (star a * a)) = spectralRadius β„‚ (star a * a) := by
     unfold spectralRadius; rw [spectrum.gelfandTransform_eq]
   simp only [map_mul, (IsSelfAdjoint.star_mul_self _).spectralRadius_eq_nnnorm,
-    gelfandTransform_map_star a, ENNReal.coe_inj, CstarRing.nnnorm_star_mul_self, ← sq] at this 
+    gelfandTransform_map_star a, ENNReal.coe_inj, CstarRing.nnnorm_star_mul_self, ← sq] at this
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
     congr_arg ((coe : ℝβ‰₯0 β†’ ℝ) ∘ ⇑NNReal.sqrt) this
 #align gelfand_transform_isometry gelfandTransform_isometry
Diff
@@ -170,7 +170,7 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
   have : spectralRadius β„‚ (gelfand_transform β„‚ A (star a * a)) = spectralRadius β„‚ (star a * a) := by
     unfold spectralRadius; rw [spectrum.gelfandTransform_eq]
   simp only [map_mul, (IsSelfAdjoint.star_mul_self _).spectralRadius_eq_nnnorm,
-    gelfandTransform_map_star a, ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this 
+    gelfandTransform_map_star a, ENNReal.coe_inj, CstarRing.nnnorm_star_mul_self, ← sq] at this 
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
     congr_arg ((coe : ℝβ‰₯0 β†’ ℝ) ∘ ⇑NNReal.sqrt) this
 #align gelfand_transform_isometry gelfandTransform_isometry
Diff
@@ -3,13 +3,13 @@ Copyright (c) 2022 Jireh Loreaux. All rights reserved.
 Reeased under Apache 2.0 license as described in the file LICENSE.
 Authors: Jireh Loreaux
 -/
-import Mathbin.Analysis.NormedSpace.Star.Spectrum
-import Mathbin.Analysis.Normed.Group.Quotient
-import Mathbin.Analysis.NormedSpace.Algebra
-import Mathbin.Topology.ContinuousFunction.Units
-import Mathbin.Topology.ContinuousFunction.Compact
-import Mathbin.Topology.Algebra.Algebra
-import Mathbin.Topology.ContinuousFunction.StoneWeierstrass
+import Analysis.NormedSpace.Star.Spectrum
+import Analysis.Normed.Group.Quotient
+import Analysis.NormedSpace.Algebra
+import Topology.ContinuousFunction.Units
+import Topology.ContinuousFunction.Compact
+import Topology.Algebra.Algebra
+import Topology.ContinuousFunction.StoneWeierstrass
 
 #align_import analysis.normed_space.star.gelfand_duality from "leanprover-community/mathlib"@"087c325ae0ab42dbdd5dee55bc37d3d5a0bf2197"
 
Diff
@@ -193,7 +193,7 @@ theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A)
       (Subalgebra.le_topologicalClosure _)
   refine'
     h β–Έ
-      ContinuousMap.subalgebra_isROrC_topologicalClosure_eq_top_of_separatesPoints _ (fun _ _ => _)
+      ContinuousMap.starSubalgebra_topologicalClosure_eq_top_of_separatesPoints _ (fun _ _ => _)
         fun f hf => _
   /- Separating points just means that elements of the `character_space` which agree at all points
     of `A` are the same functional, which is just extensionality. -/
Diff
@@ -2,11 +2,6 @@
 Copyright (c) 2022 Jireh Loreaux. All rights reserved.
 Reeased under Apache 2.0 license as described in the file LICENSE.
 Authors: Jireh Loreaux
-
-! This file was ported from Lean 3 source module analysis.normed_space.star.gelfand_duality
-! leanprover-community/mathlib commit 087c325ae0ab42dbdd5dee55bc37d3d5a0bf2197
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Analysis.NormedSpace.Star.Spectrum
 import Mathbin.Analysis.Normed.Group.Quotient
@@ -16,6 +11,8 @@ import Mathbin.Topology.ContinuousFunction.Compact
 import Mathbin.Topology.Algebra.Algebra
 import Mathbin.Topology.ContinuousFunction.StoneWeierstrass
 
+#align_import analysis.normed_space.star.gelfand_duality from "leanprover-community/mathlib"@"087c325ae0ab42dbdd5dee55bc37d3d5a0bf2197"
+
 /-!
 # Gelfand Duality
 
Diff
@@ -74,6 +74,7 @@ open Ideal
 variable {A : Type _} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A] (I : Ideal A)
   [Ideal.IsMaximal I]
 
+#print Ideal.toCharacterSpace /-
 /-- Every maximal ideal in a commutative complex Banach algebra gives rise to a character on that
 algebra. In particular, the character, which may be identified as an algebra homomorphism due to
 `weak_dual.character_space.equiv_alg_hom`, is given by the composition of the quotient map and
@@ -87,7 +88,9 @@ noncomputable def Ideal.toCharacterSpace : characterSpace β„‚ A :=
           A β§Έ I →ₐ[β„‚] β„‚).comp
       (Quotient.mkₐ β„‚ I)
 #align ideal.to_character_space Ideal.toCharacterSpace
+-/
 
+#print Ideal.toCharacterSpace_apply_eq_zero_of_mem /-
 theorem Ideal.toCharacterSpace_apply_eq_zero_of_mem {a : A} (ha : a ∈ I) :
     I.toCharacterSpace a = 0 := by
   unfold Ideal.toCharacterSpace
@@ -96,7 +99,9 @@ theorem Ideal.toCharacterSpace_apply_eq_zero_of_mem {a : A} (ha : a ∈ I) :
     NormedRing.algEquivComplexOfComplete_symm_apply] using
     Set.eq_of_mem_singleton (Set.singleton_nonempty (0 : β„‚)).some_mem
 #align ideal.to_character_space_apply_eq_zero_of_mem Ideal.toCharacterSpace_apply_eq_zero_of_mem
+-/
 
+#print WeakDual.CharacterSpace.exists_apply_eq_zero /-
 /-- If `a : A` is not a unit, then some character takes the value zero at `a`. This is equivlaent
 to `gelfand_transform β„‚ A a` takes the value zero at some character. -/
 theorem WeakDual.CharacterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
@@ -108,7 +113,9 @@ theorem WeakDual.CharacterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
       M.to_character_space_apply_eq_zero_of_mem
         (haM (mem_span_singleton.mpr ⟨1, (mul_one a).symm⟩))⟩
 #align weak_dual.character_space.exists_apply_eq_zero WeakDual.CharacterSpace.exists_apply_eq_zero
+-/
 
+#print WeakDual.CharacterSpace.mem_spectrum_iff_exists /-
 theorem WeakDual.CharacterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
     z ∈ spectrum β„‚ a ↔ βˆƒ f : characterSpace β„‚ A, f a = z :=
   by
@@ -120,7 +127,9 @@ theorem WeakDual.CharacterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
   · rintro ⟨f, rfl⟩
     exact AlgHom.apply_mem_spectrum f a
 #align weak_dual.character_space.mem_spectrum_iff_exists WeakDual.CharacterSpace.mem_spectrum_iff_exists
+-/
 
+#print spectrum.gelfandTransform_eq /-
 /-- The Gelfand transform is spectrum-preserving. -/
 theorem spectrum.gelfandTransform_eq (a : A) : spectrum β„‚ (gelfandTransform β„‚ A a) = spectrum β„‚ a :=
   by
@@ -128,6 +137,7 @@ theorem spectrum.gelfandTransform_eq (a : A) : spectrum β„‚ (gelfandTransform 
   rw [ContinuousMap.spectrum_eq_range, WeakDual.CharacterSpace.mem_spectrum_iff_exists]
   exact Iff.rfl
 #align spectrum.gelfand_transform_eq spectrum.gelfandTransform_eq
+-/
 
 instance [Nontrivial A] : Nonempty (characterSpace β„‚ A) :=
   ⟨Classical.choose <|
@@ -141,13 +151,16 @@ variable {A : Type _} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A]
 
 variable [StarRing A] [CstarRing A] [StarModule β„‚ A]
 
+#print gelfandTransform_map_star /-
 theorem gelfandTransform_map_star (a : A) :
     gelfandTransform β„‚ A (star a) = star (gelfandTransform β„‚ A a) :=
   ContinuousMap.ext fun Ο† => map_star Ο† a
 #align gelfand_transform_map_star gelfandTransform_map_star
+-/
 
 variable (A)
 
+#print gelfandTransform_isometry /-
 /-- The Gelfand transform is an isometry when the algebra is a C⋆-algebra over `β„‚`. -/
 theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
   by
@@ -164,7 +177,9 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
     congr_arg ((coe : ℝβ‰₯0 β†’ ℝ) ∘ ⇑NNReal.sqrt) this
 #align gelfand_transform_isometry gelfandTransform_isometry
+-/
 
+#print gelfandTransform_bijective /-
 /-- The Gelfand transform is bijective when the algebra is a C⋆-algebra over `β„‚`. -/
 theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A) :=
   by
@@ -197,7 +212,9 @@ theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A)
     refine' ⟨star a, ContinuousMap.ext fun ψ => _⟩
     simpa only [gelfandTransform_map_star a, AlgHom.toRingHom_eq_coe, AlgHom.coe_toRingHom]
 #align gelfand_transform_bijective gelfandTransform_bijective
+-/
 
+#print gelfandStarTransform /-
 /-- The Gelfand transform as a `star_alg_equiv` between a commutative unital C⋆-algebra over `β„‚`
 and the continuous functions on its `character_space`. -/
 @[simps]
@@ -207,6 +224,7 @@ noncomputable def gelfandStarTransform : A ≃⋆ₐ[β„‚] C(characterSpace β„‚ A
       { gelfandTransform β„‚ A with map_star' := fun x => gelfandTransform_map_star x })
     (gelfandTransform_bijective A)
 #align gelfand_star_transform gelfandStarTransform
+-/
 
 end ComplexCstarAlgebra
 
@@ -224,6 +242,7 @@ variable [NormedRing B] [NormedAlgebra β„‚ B] [CompleteSpace B] [StarRing B]
 
 variable [NormedRing C] [NormedAlgebra β„‚ C] [CompleteSpace C] [StarRing C]
 
+#print WeakDual.CharacterSpace.compContinuousMap /-
 /-- The functorial map taking `ψ : A →⋆ₐ[β„‚] B` to a continuous function
 `character_space β„‚ B β†’ character_space β„‚ A` obtained by pre-composition with `ψ`. -/
 @[simps]
@@ -234,24 +253,29 @@ noncomputable def compContinuousMap (ψ : A →⋆ₐ[β„‚] B) : C(characterSpace
     Continuous.subtype_mk
       (continuous_of_continuous_eval fun a => map_continuous <| gelfandTransform β„‚ B (ψ a)) _
 #align weak_dual.character_space.comp_continuous_map WeakDual.CharacterSpace.compContinuousMap
+-/
 
 variable (A)
 
+#print WeakDual.CharacterSpace.compContinuousMap_id /-
 /-- `weak_dual.character_space.comp_continuous_map` sends the identity to the identity. -/
 @[simp]
 theorem compContinuousMap_id :
     compContinuousMap (StarAlgHom.id β„‚ A) = ContinuousMap.id (characterSpace β„‚ A) :=
   ContinuousMap.ext fun a => ext fun x => rfl
 #align weak_dual.character_space.comp_continuous_map_id WeakDual.CharacterSpace.compContinuousMap_id
+-/
 
 variable {A}
 
+#print WeakDual.CharacterSpace.compContinuousMap_comp /-
 /-- `weak_dual.character_space.comp_continuous_map` is functorial. -/
 @[simp]
 theorem compContinuousMap_comp (Οˆβ‚‚ : B →⋆ₐ[β„‚] C) (Οˆβ‚ : A →⋆ₐ[β„‚] B) :
     compContinuousMap (Οˆβ‚‚.comp Οˆβ‚) = (compContinuousMap Οˆβ‚).comp (compContinuousMap Οˆβ‚‚) :=
   ContinuousMap.ext fun a => ext fun x => rfl
 #align weak_dual.character_space.comp_continuous_map_comp WeakDual.CharacterSpace.compContinuousMap_comp
+-/
 
 end CharacterSpace
 
Diff
@@ -4,7 +4,7 @@ Reeased under Apache 2.0 license as described in the file LICENSE.
 Authors: Jireh Loreaux
 
 ! This file was ported from Lean 3 source module analysis.normed_space.star.gelfand_duality
-! leanprover-community/mathlib commit e65771194f9e923a70dfb49b6ca7be6e400d8b6f
+! leanprover-community/mathlib commit 087c325ae0ab42dbdd5dee55bc37d3d5a0bf2197
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -19,6 +19,9 @@ import Mathbin.Topology.ContinuousFunction.StoneWeierstrass
 /-!
 # Gelfand Duality
 
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
 The `gelfand_transform` is an algebra homomorphism from a topological `π•œ`-algebra `A` to
 `C(character_space π•œ A, π•œ)`. In the case where `A` is a commutative complex Banach algebra, then
 the Gelfand transform is actually spectrum-preserving (`spectrum.gelfand_transform_eq`). Moreover,
Diff
@@ -96,7 +96,7 @@ theorem Ideal.toCharacterSpace_apply_eq_zero_of_mem {a : A} (ha : a ∈ I) :
 
 /-- If `a : A` is not a unit, then some character takes the value zero at `a`. This is equivlaent
 to `gelfand_transform β„‚ A a` takes the value zero at some character. -/
-theorem WeakDual.characterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
+theorem WeakDual.CharacterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
     βˆƒ f : characterSpace β„‚ A, f a = 0 :=
   by
   obtain ⟨M, hM, haM⟩ := (span {a}).exists_le_maximal (span_singleton_ne_top ha)
@@ -104,31 +104,31 @@ theorem WeakDual.characterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
     ⟨M.to_character_space,
       M.to_character_space_apply_eq_zero_of_mem
         (haM (mem_span_singleton.mpr ⟨1, (mul_one a).symm⟩))⟩
-#align weak_dual.character_space.exists_apply_eq_zero WeakDual.characterSpace.exists_apply_eq_zero
+#align weak_dual.character_space.exists_apply_eq_zero WeakDual.CharacterSpace.exists_apply_eq_zero
 
-theorem WeakDual.characterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
+theorem WeakDual.CharacterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
     z ∈ spectrum β„‚ a ↔ βˆƒ f : characterSpace β„‚ A, f a = z :=
   by
   refine' ⟨fun hz => _, _⟩
-  · obtain ⟨f, hf⟩ := WeakDual.characterSpace.exists_apply_eq_zero hz
+  · obtain ⟨f, hf⟩ := WeakDual.CharacterSpace.exists_apply_eq_zero hz
     simp only [map_sub, sub_eq_zero, AlgHomClass.commutes, Algebra.id.map_eq_id,
       RingHom.id_apply] at hf 
     exact (ContinuousMap.spectrum_eq_range (gelfand_transform β„‚ A a)).symm β–Έ ⟨f, hf.symm⟩
   · rintro ⟨f, rfl⟩
     exact AlgHom.apply_mem_spectrum f a
-#align weak_dual.character_space.mem_spectrum_iff_exists WeakDual.characterSpace.mem_spectrum_iff_exists
+#align weak_dual.character_space.mem_spectrum_iff_exists WeakDual.CharacterSpace.mem_spectrum_iff_exists
 
 /-- The Gelfand transform is spectrum-preserving. -/
 theorem spectrum.gelfandTransform_eq (a : A) : spectrum β„‚ (gelfandTransform β„‚ A a) = spectrum β„‚ a :=
   by
   ext z
-  rw [ContinuousMap.spectrum_eq_range, WeakDual.characterSpace.mem_spectrum_iff_exists]
+  rw [ContinuousMap.spectrum_eq_range, WeakDual.CharacterSpace.mem_spectrum_iff_exists]
   exact Iff.rfl
 #align spectrum.gelfand_transform_eq spectrum.gelfandTransform_eq
 
 instance [Nontrivial A] : Nonempty (characterSpace β„‚ A) :=
   ⟨Classical.choose <|
-      WeakDual.characterSpace.exists_apply_eq_zero <| zero_mem_nonunits.2 zero_ne_one⟩
+      WeakDual.CharacterSpace.exists_apply_eq_zero <| zero_mem_nonunits.2 zero_ne_one⟩
 
 end ComplexBanachAlgebra
 
@@ -230,7 +230,7 @@ noncomputable def compContinuousMap (ψ : A →⋆ₐ[β„‚] B) : C(characterSpace
   continuous_toFun :=
     Continuous.subtype_mk
       (continuous_of_continuous_eval fun a => map_continuous <| gelfandTransform β„‚ B (ψ a)) _
-#align weak_dual.character_space.comp_continuous_map WeakDual.characterSpace.compContinuousMap
+#align weak_dual.character_space.comp_continuous_map WeakDual.CharacterSpace.compContinuousMap
 
 variable (A)
 
@@ -239,7 +239,7 @@ variable (A)
 theorem compContinuousMap_id :
     compContinuousMap (StarAlgHom.id β„‚ A) = ContinuousMap.id (characterSpace β„‚ A) :=
   ContinuousMap.ext fun a => ext fun x => rfl
-#align weak_dual.character_space.comp_continuous_map_id WeakDual.characterSpace.compContinuousMap_id
+#align weak_dual.character_space.comp_continuous_map_id WeakDual.CharacterSpace.compContinuousMap_id
 
 variable {A}
 
@@ -248,7 +248,7 @@ variable {A}
 theorem compContinuousMap_comp (Οˆβ‚‚ : B →⋆ₐ[β„‚] C) (Οˆβ‚ : A →⋆ₐ[β„‚] B) :
     compContinuousMap (Οˆβ‚‚.comp Οˆβ‚) = (compContinuousMap Οˆβ‚).comp (compContinuousMap Οˆβ‚‚) :=
   ContinuousMap.ext fun a => ext fun x => rfl
-#align weak_dual.character_space.comp_continuous_map_comp WeakDual.characterSpace.compContinuousMap_comp
+#align weak_dual.character_space.comp_continuous_map_comp WeakDual.CharacterSpace.compContinuousMap_comp
 
 end CharacterSpace
 
Diff
@@ -76,7 +76,7 @@ algebra. In particular, the character, which may be identified as an algebra hom
 `weak_dual.character_space.equiv_alg_hom`, is given by the composition of the quotient map and
 the Gelfand-Mazur isomorphism `normed_ring.alg_equiv_complex_of_complete`. -/
 noncomputable def Ideal.toCharacterSpace : characterSpace β„‚ A :=
-  characterSpace.equivAlgHom.symm <|
+  CharacterSpace.equivAlgHom.symm <|
     ((@NormedRing.algEquivComplexOfComplete (A β§Έ I) _ _
               (letI := quotient.field I
               @isUnit_iff_ne_zero (A β§Έ I) _)
Diff
@@ -112,7 +112,7 @@ theorem WeakDual.characterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
   refine' ⟨fun hz => _, _⟩
   · obtain ⟨f, hf⟩ := WeakDual.characterSpace.exists_apply_eq_zero hz
     simp only [map_sub, sub_eq_zero, AlgHomClass.commutes, Algebra.id.map_eq_id,
-      RingHom.id_apply] at hf
+      RingHom.id_apply] at hf 
     exact (ContinuousMap.spectrum_eq_range (gelfand_transform β„‚ A a)).symm β–Έ ⟨f, hf.symm⟩
   · rintro ⟨f, rfl⟩
     exact AlgHom.apply_mem_spectrum f a
@@ -157,7 +157,7 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
   have : spectralRadius β„‚ (gelfand_transform β„‚ A (star a * a)) = spectralRadius β„‚ (star a * a) := by
     unfold spectralRadius; rw [spectrum.gelfandTransform_eq]
   simp only [map_mul, (IsSelfAdjoint.star_mul_self _).spectralRadius_eq_nnnorm,
-    gelfandTransform_map_star a, ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this
+    gelfandTransform_map_star a, ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this 
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
     congr_arg ((coe : ℝβ‰₯0 β†’ ℝ) ∘ ⇑NNReal.sqrt) this
 #align gelfand_transform_isometry gelfandTransform_isometry
Diff
@@ -62,7 +62,7 @@ Gelfand transform, character space, C⋆-algebra
 
 open WeakDual
 
-open NNReal
+open scoped NNReal
 
 section ComplexBanachAlgebra
 
Diff
@@ -154,10 +154,8 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
     `gelfand_transform` coincide. Therefore, so do their spectral radii, and since they are
     self-adjoint, so also do their norms. Applying the C⋆-property of the norm and taking square
     roots shows that the norm is preserved. -/
-  have : spectralRadius β„‚ (gelfand_transform β„‚ A (star a * a)) = spectralRadius β„‚ (star a * a) :=
-    by
-    unfold spectralRadius
-    rw [spectrum.gelfandTransform_eq]
+  have : spectralRadius β„‚ (gelfand_transform β„‚ A (star a * a)) = spectralRadius β„‚ (star a * a) := by
+    unfold spectralRadius; rw [spectrum.gelfandTransform_eq]
   simp only [map_mul, (IsSelfAdjoint.star_mul_self _).spectralRadius_eq_nnnorm,
     gelfandTransform_map_star a, ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
Diff
@@ -4,7 +4,7 @@ Reeased under Apache 2.0 license as described in the file LICENSE.
 Authors: Jireh Loreaux
 
 ! This file was ported from Lean 3 source module analysis.normed_space.star.gelfand_duality
-! leanprover-community/mathlib commit 43afc5ad87891456c57b5a183e3e617d67c2b1db
+! leanprover-community/mathlib commit e65771194f9e923a70dfb49b6ca7be6e400d8b6f
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -106,14 +106,24 @@ theorem WeakDual.characterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
         (haM (mem_span_singleton.mpr ⟨1, (mul_one a).symm⟩))⟩
 #align weak_dual.character_space.exists_apply_eq_zero WeakDual.characterSpace.exists_apply_eq_zero
 
+theorem WeakDual.characterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
+    z ∈ spectrum β„‚ a ↔ βˆƒ f : characterSpace β„‚ A, f a = z :=
+  by
+  refine' ⟨fun hz => _, _⟩
+  · obtain ⟨f, hf⟩ := WeakDual.characterSpace.exists_apply_eq_zero hz
+    simp only [map_sub, sub_eq_zero, AlgHomClass.commutes, Algebra.id.map_eq_id,
+      RingHom.id_apply] at hf
+    exact (ContinuousMap.spectrum_eq_range (gelfand_transform β„‚ A a)).symm β–Έ ⟨f, hf.symm⟩
+  · rintro ⟨f, rfl⟩
+    exact AlgHom.apply_mem_spectrum f a
+#align weak_dual.character_space.mem_spectrum_iff_exists WeakDual.characterSpace.mem_spectrum_iff_exists
+
 /-- The Gelfand transform is spectrum-preserving. -/
 theorem spectrum.gelfandTransform_eq (a : A) : spectrum β„‚ (gelfandTransform β„‚ A a) = spectrum β„‚ a :=
   by
-  refine' Set.Subset.antisymm (AlgHom.spectrum_apply_subset (gelfand_transform β„‚ A) a) fun z hz => _
-  obtain ⟨f, hf⟩ := WeakDual.characterSpace.exists_apply_eq_zero hz
-  simp only [map_sub, sub_eq_zero, AlgHomClass.commutes, Algebra.id.map_eq_id, RingHom.id_apply] at
-    hf
-  exact (ContinuousMap.spectrum_eq_range (gelfand_transform β„‚ A a)).symm β–Έ ⟨f, hf.symm⟩
+  ext z
+  rw [ContinuousMap.spectrum_eq_range, WeakDual.characterSpace.mem_spectrum_iff_exists]
+  exact Iff.rfl
 #align spectrum.gelfand_transform_eq spectrum.gelfandTransform_eq
 
 instance [Nontrivial A] : Nonempty (characterSpace β„‚ A) :=
Diff
@@ -149,7 +149,7 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) :=
     unfold spectralRadius
     rw [spectrum.gelfandTransform_eq]
   simp only [map_mul, (IsSelfAdjoint.star_mul_self _).spectralRadius_eq_nnnorm,
-    gelfandTransform_map_star a, Ennreal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this
+    gelfandTransform_map_star a, ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
     congr_arg ((coe : ℝβ‰₯0 β†’ ℝ) ∘ ⇑NNReal.sqrt) this
 #align gelfand_transform_isometry gelfandTransform_isometry

Changes in mathlib4

mathlib3
mathlib4
chore: remove some mathlib3 names in doc comments (#11931)
Diff
@@ -18,7 +18,7 @@ import Mathlib.Topology.ContinuousFunction.StoneWeierstrass
 # Gelfand Duality
 
 The `gelfandTransform` is an algebra homomorphism from a topological `π•œ`-algebra `A` to
-`C(character_space π•œ A, π•œ)`. In the case where `A` is a commutative complex Banach algebra, then
+`C(characterSpace π•œ A, π•œ)`. In the case where `A` is a commutative complex Banach algebra, then
 the Gelfand transform is actually spectrum-preserving (`spectrum.gelfandTransform_eq`). Moreover,
 when `A` is a commutative C⋆-algebra over `β„‚`, then the Gelfand transform is a surjective isometry,
 and even an equivalence between C⋆-algebras.
chore: Rename IsROrC to RCLike (#10819)

IsROrC contains data, which goes against the expectation that classes prefixed with Is are prop-valued. People have been complaining about this on and off, so this PR renames IsROrC to RCLike.

Diff
@@ -171,7 +171,7 @@ theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A)
         use star a
         ext1 Ο†
         dsimp
-        simp only [map_star, IsROrC.star_def] }
+        simp only [map_star, RCLike.star_def] }
   suffices rng = ⊀ from
     fun x => show x ∈ rng from this.symm β–Έ StarSubalgebra.mem_top
   /- Because the `gelfandTransform β„‚ A` is an isometry, it has closed range, and so by the
@@ -303,7 +303,7 @@ V                     V
 Y  --- Ξ· Y ---> characterSpace β„‚ C(Y, β„‚)
 ```
 -/
-lemma WeakDual.CharacterSpace.homeoEval_naturality {X Y π•œ : Type*} [IsROrC π•œ] [TopologicalSpace X]
+lemma WeakDual.CharacterSpace.homeoEval_naturality {X Y π•œ : Type*} [RCLike π•œ] [TopologicalSpace X]
     [CompactSpace X] [T2Space X] [TopologicalSpace Y] [CompactSpace Y] [T2Space Y] (f : C(X, Y)) :
     (homeoEval Y π•œ : C(_, _)).comp f =
       (f.compStarAlgHom' π•œ π•œ |> compContinuousMap).comp (homeoEval X π•œ : C(_, _)) :=
chore: rename open_range to isOpen_range, closed_range to isClosed_range (#11438)

All these lemmas refer to the range of some function being open/range (i.e. isOpen or isClosed).

Diff
@@ -179,7 +179,7 @@ theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A)
     points in `C(characterSpace β„‚ A, β„‚)` and is closed under `star`. -/
   have h : rng.topologicalClosure = rng := le_antisymm
     (StarSubalgebra.topologicalClosure_minimal le_rfl
-      (gelfandTransform_isometry A).closedEmbedding.closed_range)
+      (gelfandTransform_isometry A).closedEmbedding.isClosed_range)
     (StarSubalgebra.le_topologicalClosure _)
   refine' h β–Έ ContinuousMap.starSubalgebra_topologicalClosure_eq_top_of_separatesPoints
     _ (fun _ _ => _)
chore(*): remove empty lines between variable statements (#11418)

Empty lines were removed by executing the following Python script twice

import os
import re


# Loop through each file in the repository
for dir_path, dirs, files in os.walk('.'):
  for filename in files:
    if filename.endswith('.lean'):
      file_path = os.path.join(dir_path, filename)

      # Open the file and read its contents
      with open(file_path, 'r') as file:
        content = file.read()

      # Use a regular expression to replace sequences of "variable" lines separated by empty lines
      # with sequences without empty lines
      modified_content = re.sub(r'(variable.*\n)\n(variable(?! .* in))', r'\1\2', content)

      # Write the modified content back to the file
      with open(file_path, 'w') as file:
        file.write(modified_content)
Diff
@@ -132,7 +132,6 @@ end ComplexBanachAlgebra
 section ComplexCstarAlgebra
 
 variable {A : Type*} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A]
-
 variable [StarRing A] [CstarRing A] [StarModule β„‚ A]
 
 theorem gelfandTransform_map_star (a : A) :
doc(Analysis/NormedSpace/Star/GelfandDuality): update TODO list (#10763)
Diff
@@ -52,16 +52,10 @@ Then `η₁ : id β†’ F ∘ G := gelfandStarTransform` and
 
 ## TODO
 
-* After `StarAlgEquiv` is defined, realize `gelfandTransform` as a `StarAlgEquiv`.
-* Prove that if `A` is the unital C⋆-algebra over `β„‚` generated by a fixed normal element `x` in
-  a larger C⋆-algebra `B`, then `characterSpace β„‚ A` is homeomorphic to `spectrum β„‚ x`.
-* From the previous result, construct the **continuous functional calculus**.
-* Show that if `X` is a compact Hausdorff space, then `X` is (canonically) homeomorphic to
-  `characterSpace β„‚ C(X, β„‚)`.
-* Conclude using the previous fact that the functors `C(Β·, β„‚)` and `characterSpace β„‚ Β·` along with
-  the canonical homeomorphisms described above constitute a natural contravariant equivalence of
-  the categories of compact Hausdorff spaces (with continuous maps) and commutative unital
-  C⋆-algebras (with unital ⋆-algebra homomorphisms); this is known as **Gelfand duality**.
+* After defining the category of commutative unital C⋆-algebras, bundle the existing unbundled
+  **Gelfand duality** into an actual equivalence (duality) of categories associated to the
+  functors `C(Β·, β„‚)` and `characterSpace β„‚ Β·` and the natural isomorphisms `gelfandStarTransform`
+  and `WeakDual.CharacterSpace.homeoEval`.
 
 ## Tags
 
feat: Make the coercion ℝβ‰₯0 β†’ ℝβ‰₯0∞ commute defeqly with nsmul and pow (#10225)

by tweaking the definition of the AddMonoid and MonoidWithZero instances for WithTop. Also unprotect ENNReal.coe_injective and rename ENNReal.coe_eq_coe β†’ ENNReal.coe_inj.

From LeanAPAP

Diff
@@ -160,7 +160,7 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) := by
     unfold spectralRadius; rw [spectrum.gelfandTransform_eq]
   rw [map_mul, (IsSelfAdjoint.star_mul_self a).spectralRadius_eq_nnnorm, gelfandTransform_map_star,
     (IsSelfAdjoint.star_mul_self (gelfandTransform β„‚ A a)).spectralRadius_eq_nnnorm] at this
-  simp only [ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this
+  simp only [ENNReal.coe_inj, CstarRing.nnnorm_star_mul_self, ← sq] at this
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
     congr_arg (((↑) : ℝβ‰₯0 β†’ ℝ) ∘ ⇑NNReal.sqrt) this
 #align gelfand_transform_isometry gelfandTransform_isometry
refactor(Data/FunLike): use unbundled inheritance from FunLike (#8386)

The FunLike hierarchy is very big and gets scanned through each time we need a coercion (via the CoeFun instance). It looks like unbundled inheritance suits Lean 4 better here. The only class that still extends FunLike is EquivLike, since that has a custom coe_injective' field that is easier to implement. All other classes should take FunLike or EquivLike as a parameter.

Zulip thread

Important changes

Previously, morphism classes would be Type-valued and extend FunLike:

/-- `MyHomClass F A B` states that `F` is a type of `MyClass.op`-preserving morphisms.
You should extend this class when you extend `MyHom`. -/
class MyHomClass (F : Type*) (A B : outParam <| Type*) [MyClass A] [MyClass B]
  extends FunLike F A B :=
(map_op : βˆ€ (f : F) (x y : A), f (MyClass.op x y) = MyClass.op (f x) (f y))

After this PR, they should be Prop-valued and take FunLike as a parameter:

/-- `MyHomClass F A B` states that `F` is a type of `MyClass.op`-preserving morphisms.
You should extend this class when you extend `MyHom`. -/
class MyHomClass (F : Type*) (A B : outParam <| Type*) [MyClass A] [MyClass B]
  [FunLike F A B] : Prop :=
(map_op : βˆ€ (f : F) (x y : A), f (MyClass.op x y) = MyClass.op (f x) (f y))

(Note that A B stay marked as outParam even though they are not purely required to be so due to the FunLike parameter already filling them in. This is required to see through type synonyms, which is important in the category theory library. Also, I think keeping them as outParam is slightly faster.)

Similarly, MyEquivClass should take EquivLike as a parameter.

As a result, every mention of [MyHomClass F A B] should become [FunLike F A B] [MyHomClass F A B].

Remaining issues

Slower (failing) search

While overall this gives some great speedups, there are some cases that are noticeably slower. In particular, a failing application of a lemma such as map_mul is more expensive. This is due to suboptimal processing of arguments. For example:

variable [FunLike F M N] [Mul M] [Mul N] (f : F) (x : M) (y : M)

theorem map_mul [MulHomClass F M N] : f (x * y) = f x * f y

example [AddHomClass F A B] : f (x * y) = f x * f y := map_mul f _ _

Before this PR, applying map_mul f gives the goals [Mul ?M] [Mul ?N] [MulHomClass F ?M ?N]. Since M and N are out_params, [MulHomClass F ?M ?N] is synthesized first, supplies values for ?M and ?N and then the Mul M and Mul N instances can be found.

After this PR, the goals become [FunLike F ?M ?N] [Mul ?M] [Mul ?N] [MulHomClass F ?M ?N]. Now [FunLike F ?M ?N] is synthesized first, supplies values for ?M and ?N and then the Mul M and Mul N instances can be found, before trying MulHomClass F M N which fails. Since the Mul hierarchy is very big, this can be slow to fail, especially when there is no such Mul instance.

A long-term but harder to achieve solution would be to specify the order in which instance goals get solved. For example, we'd like to change the arguments to map_mul to look like [FunLike F M N] [Mul M] [Mul N] [highPriority <| MulHomClass F M N] because MulHomClass fails or succeeds much faster than the others.

As a consequence, the simpNF linter is much slower since by design it tries and fails to apply many map_ lemmas. The same issue occurs a few times in existing calls to simp [map_mul], where map_mul is tried "too soon" and fails. Thanks to the speedup of leanprover/lean4#2478 the impact is very limited, only in files that already were close to the timeout.

simp not firing sometimes

This affects map_smulβ‚›β‚— and related definitions. For simp lemmas Lean apparently uses a slightly different mechanism to find instances, so that rw can find every argument to map_smulβ‚›β‚— successfully but simp can't: leanprover/lean4#3701.

Missing instances due to unification failing

Especially in the category theory library, we might sometimes have a type A which is also accessible as a synonym (Bundled A hA).1. Instance synthesis doesn't always work if we have f : A β†’* B but x * y : (Bundled A hA).1 or vice versa. This seems to be mostly fixed by keeping A B as outParams in MulHomClass F A B. (Presumably because Lean will do a definitional check A =?= (Bundled A hA).1 instead of using the syntax in the discrimination tree.)

Workaround for issues

The timeouts can be worked around for now by specifying which map_mul we mean, either as map_mul f for some explicit f, or as e.g. MonoidHomClass.map_mul.

map_smulβ‚›β‚— not firing as simp lemma can be worked around by going back to the pre-FunLike situation and making LinearMap.map_smulβ‚›β‚— a simp lemma instead of the generic map_smulβ‚›β‚—. Writing simp [map_smulβ‚›β‚— _] also works.

Co-authored-by: Matthew Ballard <matt@mrb.email> Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Scott Morrison <scott@tqft.net> Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>

Diff
@@ -177,8 +177,8 @@ theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A)
         rintro - ⟨a, rfl⟩
         use star a
         ext1 Ο†
-        simp only [AlgHom.toRingHom_eq_coe, RingHom.coe_coe, gelfandTransform_apply_apply, map_star,
-          IsROrC.star_def, ContinuousMap.star_apply] }
+        dsimp
+        simp only [map_star, IsROrC.star_def] }
   suffices rng = ⊀ from
     fun x => show x ∈ rng from this.symm β–Έ StarSubalgebra.mem_top
   /- Because the `gelfandTransform β„‚ A` is an isometry, it has closed range, and so by the
chore(Algebra.Basic): override toFun and smul in Algebra.id (#9949)

The current definition of Algebra.id is (RingHom.id _).toAlgebra. The problem with this is that RingHom.id is a def and is not reducible. Thus Lean will often refuse to unfold it causing unification to fail unecessarily in typeclass searches. This overrides the data fields from RingHom.id.

Diff
@@ -115,11 +115,8 @@ theorem WeakDual.CharacterSpace.mem_spectrum_iff_exists {a : A} {z : β„‚} :
     z ∈ spectrum β„‚ a ↔ βˆƒ f : characterSpace β„‚ A, f a = z := by
   refine' ⟨fun hz => _, _⟩
   · obtain ⟨f, hf⟩ := WeakDual.CharacterSpace.exists_apply_eq_zero hz
-    simp only [map_sub, sub_eq_zero, AlgHomClass.commutes, Algebra.id.map_eq_id,
-      RingHom.id_apply] at hf
-    refine ⟨f, ?_⟩
-    rw [AlgHomClass.commutes, Algebra.id.map_eq_id, RingHom.id_apply] at hf
-    exact hf.symm
+    simp only [map_sub, sub_eq_zero, AlgHomClass.commutes] at hf
+    exact ⟨_, hf.symm⟩
   · rintro ⟨f, rfl⟩
     exact AlgHom.apply_mem_spectrum f a
 #align weak_dual.character_space.mem_spectrum_iff_exists WeakDual.CharacterSpace.mem_spectrum_iff_exists
feat: naturality of the gelfandStarTransform and WeakDual.CharacterSpace.homeoEval (#9638)
Diff
@@ -9,6 +9,7 @@ import Mathlib.Analysis.NormedSpace.Algebra
 import Mathlib.Topology.ContinuousFunction.Units
 import Mathlib.Topology.ContinuousFunction.Compact
 import Mathlib.Topology.Algebra.Algebra
+import Mathlib.Topology.ContinuousFunction.Ideals
 import Mathlib.Topology.ContinuousFunction.StoneWeierstrass
 
 #align_import analysis.normed_space.star.gelfand_duality from "leanprover-community/mathlib"@"e65771194f9e923a70dfb49b6ca7be6e400d8b6f"
@@ -22,12 +23,21 @@ the Gelfand transform is actually spectrum-preserving (`spectrum.gelfandTransfor
 when `A` is a commutative C⋆-algebra over `β„‚`, then the Gelfand transform is a surjective isometry,
 and even an equivalence between C⋆-algebras.
 
+Consider the contravariant functors between compact Hausdorff spaces and commutative unital
+C⋆algebras `F : Cpct β†’ CommCStarAlg := X ↦ C(X, β„‚)` and
+`G : CommCStarAlg β†’ Cpct := A β†’ characterSpace β„‚ A` whose actions on morphisms are given by
+`WeakDual.CharacterSpace.compContinuousMap` and `ContinuousMap.compStarAlgHom'`, respectively.
+
+Then `η₁ : id β†’ F ∘ G := gelfandStarTransform` and
+`Ξ·β‚‚ : id β†’ G ∘ F := WeakDual.CharacterSpace.homeoEval` are the natural isomorphisms implementing
+**Gelfand Duality**, i.e., the (contravariant) equivalence of these categories.
+
 ## Main definitions
 
 * `Ideal.toCharacterSpace` : constructs an element of the character space from a maximal ideal in
   a commutative complex Banach algebra
-* `WeakDual.CharacterSpace.compContinuousMap`: The functorial map taking `ψ : A →⋆ₐ[β„‚] B` to a
-  continuous function `characterSpace β„‚ B β†’ characterSpace β„‚ A` given by pre-composition with `ψ`.
+* `WeakDual.CharacterSpace.compContinuousMap`: The functorial map taking `ψ : A →⋆ₐ[π•œ] B` to a
+  continuous function `characterSpace π•œ B β†’ characterSpace π•œ A` given by pre-composition with `ψ`.
 
 ## Main statements
 
@@ -37,6 +47,8 @@ and even an equivalence between C⋆-algebras.
   commutative (unital) C⋆-algebra over `β„‚`.
 * `gelfandTransform_bijective` : the Gelfand transform is bijective when the algebra is a
   commutative (unital) C⋆-algebra over `β„‚`.
+* `gelfandStarTransform_naturality`: The `gelfandStarTransform` is a natural isomorphism
+* `WeakDual.CharacterSpace.homeoEval_naturality`: This map implements a natural isomorphism
 
 ## TODO
 
@@ -206,23 +218,20 @@ namespace WeakDual
 
 namespace CharacterSpace
 
-variable {A B C : Type*}
-
-variable [NormedRing A] [NormedAlgebra β„‚ A] [CompleteSpace A] [StarRing A]
-
-variable [NormedRing B] [NormedAlgebra β„‚ B] [CompleteSpace B] [StarRing B]
-
-variable [NormedRing C] [NormedAlgebra β„‚ C] [CompleteSpace C] [StarRing C]
+variable {A B C π•œ : Type*} [NontriviallyNormedField π•œ]
+variable [NormedRing A] [NormedAlgebra π•œ A] [CompleteSpace A] [StarRing A]
+variable [NormedRing B] [NormedAlgebra π•œ B] [CompleteSpace B] [StarRing B]
+variable [NormedRing C] [NormedAlgebra π•œ C] [CompleteSpace C] [StarRing C]
 
 /-- The functorial map taking `ψ : A →⋆ₐ[β„‚] B` to a continuous function
 `characterSpace β„‚ B β†’ characterSpace β„‚ A` obtained by pre-composition with `ψ`. -/
 @[simps]
-noncomputable def compContinuousMap (ψ : A →⋆ₐ[β„‚] B) : C(characterSpace β„‚ B, characterSpace β„‚ A)
+noncomputable def compContinuousMap (ψ : A →⋆ₐ[π•œ] B) : C(characterSpace π•œ B, characterSpace π•œ A)
     where
   toFun Ο† := equivAlgHom.symm ((equivAlgHom Ο†).comp ψ.toAlgHom)
   continuous_toFun :=
     Continuous.subtype_mk
-      (continuous_of_continuous_eval fun a => map_continuous <| gelfandTransform β„‚ B (ψ a)) _
+      (continuous_of_continuous_eval fun a => map_continuous <| gelfandTransform π•œ B (ψ a)) _
 #align weak_dual.character_space.comp_continuous_map WeakDual.CharacterSpace.compContinuousMap
 
 variable (A)
@@ -230,7 +239,7 @@ variable (A)
 /-- `WeakDual.CharacterSpace.compContinuousMap` sends the identity to the identity. -/
 @[simp]
 theorem compContinuousMap_id :
-    compContinuousMap (StarAlgHom.id β„‚ A) = ContinuousMap.id (characterSpace β„‚ A) :=
+    compContinuousMap (StarAlgHom.id π•œ A) = ContinuousMap.id (characterSpace π•œ A) :=
   ContinuousMap.ext fun _a => ext fun _x => rfl
 #align weak_dual.character_space.comp_continuous_map_id WeakDual.CharacterSpace.compContinuousMap_id
 
@@ -238,7 +247,7 @@ variable {A}
 
 /-- `WeakDual.CharacterSpace.compContinuousMap` is functorial. -/
 @[simp]
-theorem compContinuousMap_comp (Οˆβ‚‚ : B →⋆ₐ[β„‚] C) (Οˆβ‚ : A →⋆ₐ[β„‚] B) :
+theorem compContinuousMap_comp (Οˆβ‚‚ : B →⋆ₐ[π•œ] C) (Οˆβ‚ : A →⋆ₐ[π•œ] B) :
     compContinuousMap (Οˆβ‚‚.comp Οˆβ‚) = (compContinuousMap Οˆβ‚).comp (compContinuousMap Οˆβ‚‚) :=
   ContinuousMap.ext fun _a => ext fun _x => rfl
 #align weak_dual.character_space.comp_continuous_map_comp WeakDual.CharacterSpace.compContinuousMap_comp
@@ -248,3 +257,64 @@ end CharacterSpace
 end WeakDual
 
 end Functoriality
+
+open CharacterSpace in
+/--
+Consider the contravariant functors between compact Hausdorff spaces and commutative unital
+C⋆algebras `F : Cpct β†’ CommCStarAlg := X ↦ C(X, β„‚)` and
+`G : CommCStarAlg β†’ Cpct := A β†’ characterSpace β„‚ A` whose actions on morphisms are given by
+`WeakDual.CharacterSpace.compContinuousMap` and `ContinuousMap.compStarAlgHom'`, respectively.
+
+Then `Ξ· : id β†’ F ∘ G := gelfandStarTransform` is a natural isomorphism implementing (half of)
+the duality between these categories. That is, for commutative unital C⋆-algebras `A` and `B` and
+`Ο† : A →⋆ₐ[β„‚] B` the following diagram commutes:
+
+```
+A  --- Ξ· A ---> C(characterSpace β„‚ A, β„‚)
+
+|                     |
+
+Ο†                  (F ∘ G) Ο†
+
+|                     |
+V                     V
+
+B  --- Ξ· B ---> C(characterSpace β„‚ B, β„‚)
+```
+-/
+theorem gelfandStarTransform_naturality {A B : Type*} [NormedCommRing A] [NormedAlgebra β„‚ A]
+    [CompleteSpace A] [StarRing A] [CstarRing A] [StarModule β„‚ A] [NormedCommRing B]
+    [NormedAlgebra β„‚ B] [CompleteSpace B] [StarRing B] [CstarRing B] [StarModule β„‚ B]
+    (Ο† : A →⋆ₐ[β„‚] B) :
+    (gelfandStarTransform B : _ →⋆ₐ[β„‚] _).comp Ο† =
+      (compContinuousMap Ο† |>.compStarAlgHom' β„‚ β„‚).comp (gelfandStarTransform A : _ →⋆ₐ[β„‚] _) := by
+  rfl
+
+/--
+Consider the contravariant functors between compact Hausdorff spaces and commutative unital
+C⋆algebras `F : Cpct β†’ CommCStarAlg := X ↦ C(X, β„‚)` and
+`G : CommCStarAlg β†’ Cpct := A β†’ characterSpace β„‚ A` whose actions on morphisms are given by
+`WeakDual.CharacterSpace.compContinuousMap` and `ContinuousMap.compStarAlgHom'`, respectively.
+
+Then `Ξ· : id β†’ G ∘ F := WeakDual.CharacterSpace.homeoEval` is a natural isomorphism implementing
+(half of) the duality between these categories. That is, for compact Hausdorff spaces `X` and `Y`,
+`f : C(X, Y)` the following diagram commutes:
+
+```
+X  --- Ξ· X ---> characterSpace β„‚ C(X, β„‚)
+
+|                     |
+
+f                  (G ∘ F) f
+
+|                     |
+V                     V
+
+Y  --- Ξ· Y ---> characterSpace β„‚ C(Y, β„‚)
+```
+-/
+lemma WeakDual.CharacterSpace.homeoEval_naturality {X Y π•œ : Type*} [IsROrC π•œ] [TopologicalSpace X]
+    [CompactSpace X] [T2Space X] [TopologicalSpace Y] [CompactSpace Y] [T2Space Y] (f : C(X, Y)) :
+    (homeoEval Y π•œ : C(_, _)).comp f =
+      (f.compStarAlgHom' π•œ π•œ |> compContinuousMap).comp (homeoEval X π•œ : C(_, _)) :=
+  rfl
refactor(Algebra/Star/*): Allow for star operation on non-associative algebras (#6562)

Typically a * operation on a mathematical structure R equipped with a multiplication is an involutive anti-automorphism i.e.

βˆ€ r s : R, star (r * s) = star s * star r

Currently mathlib defines a class StarSemigroup to be a semigroup satisfying this property. However, the requirement for the multiplication to be associative is unnecessarily restrictive. There are important classes of star-algebra which are not associative (e.g. JB*-algebras).

This PR removes the requirement for a StarSemigroup to be a semigroup, merely requiring it to have a multiplication.

I've changed the name from StarSemigroup to StarMul since it's no longer a semigroup.

Zulip discussion

Previously opened as a mathlib PR https://github.com/leanprover-community/mathlib/pull/17949

Co-authored-by: Christopher Hoskin <mans0954@users.noreply.github.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>

Diff
@@ -149,7 +149,7 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) := by
     roots shows that the norm is preserved. -/
   have : spectralRadius β„‚ (gelfandTransform β„‚ A (star a * a)) = spectralRadius β„‚ (star a * a) := by
     unfold spectralRadius; rw [spectrum.gelfandTransform_eq]
-  rw [map_mul, (IsSelfAdjoint.star_mul_self _).spectralRadius_eq_nnnorm, gelfandTransform_map_star,
+  rw [map_mul, (IsSelfAdjoint.star_mul_self a).spectralRadius_eq_nnnorm, gelfandTransform_map_star,
     (IsSelfAdjoint.star_mul_self (gelfandTransform β„‚ A a)).spectralRadius_eq_nnnorm] at this
   simp only [ENNReal.coe_eq_coe, CstarRing.nnnorm_star_mul_self, ← sq] at this
   simpa only [Function.comp_apply, NNReal.sqrt_sq] using
refactor(Data/Matrix): Eliminate ⬝ notation in favor of HMul (#6487)

The main difficulty here is that * has a slightly difference precedence to ⬝. notably around smul and neg.

The other annoyance is that ↑U ⬝ A ⬝ ↑U⁻¹ : Matrix m m 𝔸 now has to be written U.val * A * (U⁻¹).val in order to typecheck.

A downside of this change to consider: if you have a goal of A * (B * C) = (A * B) * C, mul_assoc now gives the illusion of matching, when in fact Matrix.mul_assoc is needed. Previously the distinct symbol made it easy to avoid this mistake.

On the flipside, there is now no need to rewrite by Matrix.mul_eq_mul all the time (indeed, the lemma is now removed).

Diff
@@ -46,7 +46,7 @@ and even an equivalence between C⋆-algebras.
 * From the previous result, construct the **continuous functional calculus**.
 * Show that if `X` is a compact Hausdorff space, then `X` is (canonically) homeomorphic to
   `characterSpace β„‚ C(X, β„‚)`.
-* Conclude using the previous fact that the functors `C(⬝, β„‚)` and `characterSpace β„‚ ⬝` along with
+* Conclude using the previous fact that the functors `C(Β·, β„‚)` and `characterSpace β„‚ Β·` along with
   the canonical homeomorphisms described above constitute a natural contravariant equivalence of
   the categories of compact Hausdorff spaces (with continuous maps) and commutative unital
   C⋆-algebras (with unital ⋆-algebra homomorphisms); this is known as **Gelfand duality**.
chore: banish Type _ and Sort _ (#6499)

We remove all possible occurences of Type _ and Sort _ in favor of Type* and Sort*.

This has nice performance benefits.

Diff
@@ -65,7 +65,7 @@ section ComplexBanachAlgebra
 
 open Ideal
 
-variable {A : Type _} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A] (I : Ideal A)
+variable {A : Type*} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A] (I : Ideal A)
   [Ideal.IsMaximal I]
 
 /-- Every maximal ideal in a commutative complex Banach algebra gives rise to a character on that
@@ -128,7 +128,7 @@ end ComplexBanachAlgebra
 
 section ComplexCstarAlgebra
 
-variable {A : Type _} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A]
+variable {A : Type*} [NormedCommRing A] [NormedAlgebra β„‚ A] [CompleteSpace A]
 
 variable [StarRing A] [CstarRing A] [StarModule β„‚ A]
 
@@ -206,7 +206,7 @@ namespace WeakDual
 
 namespace CharacterSpace
 
-variable {A B C : Type _}
+variable {A B C : Type*}
 
 variable [NormedRing A] [NormedAlgebra β„‚ A] [CompleteSpace A] [StarRing A]
 
refactor: link the Stone-Weierstrass theorem to the StarSubalgebra API (#5267)

The Stone-Weierstrass theorem, including the version for IsROrC π•œ, was developed prior to the introduction of StarSubalgebra. As such, in order to prove it, a predicate ConjInvariantSubalgebra was introduced for ℝ-subalgebras of C(X, π•œ). This refactors the Stone-Weierstrass theorem to instead use the StarSubalgebra API and removes ContinuousMap.ConjInvariantSubalgebra entirely. In addition, we provide a few corollaries concerning polynomial functions which are missing from the library.

Diff
@@ -159,31 +159,33 @@ theorem gelfandTransform_isometry : Isometry (gelfandTransform β„‚ A) := by
 /-- The Gelfand transform is bijective when the algebra is a C⋆-algebra over `β„‚`. -/
 theorem gelfandTransform_bijective : Function.Bijective (gelfandTransform β„‚ A) := by
   refine' ⟨(gelfandTransform_isometry A).injective, _⟩
-  suffices (gelfandTransform β„‚ A).range = ⊀ by
-    exact fun x => ((gelfandTransform β„‚ A).mem_range).mp (this.symm β–Έ Algebra.mem_top)
+  /- The range of `gelfandTransform β„‚ A` is actually a `StarSubalgebra`. The key lemma below may be
+    hard to spot; it's `map_star` coming from `WeakDual.Complex.instStarHomClass`, which is a
+    nontrivial result. -/
+  let rng : StarSubalgebra β„‚ C(characterSpace β„‚ A, β„‚) :=
+    { toSubalgebra := (gelfandTransform β„‚ A).range
+      star_mem' := by
+        rintro - ⟨a, rfl⟩
+        use star a
+        ext1 Ο†
+        simp only [AlgHom.toRingHom_eq_coe, RingHom.coe_coe, gelfandTransform_apply_apply, map_star,
+          IsROrC.star_def, ContinuousMap.star_apply] }
+  suffices rng = ⊀ from
+    fun x => show x ∈ rng from this.symm β–Έ StarSubalgebra.mem_top
   /- Because the `gelfandTransform β„‚ A` is an isometry, it has closed range, and so by the
     Stone-Weierstrass theorem, it suffices to show that the image of the Gelfand transform separates
     points in `C(characterSpace β„‚ A, β„‚)` and is closed under `star`. -/
-  have h : (gelfandTransform β„‚ A).range.topologicalClosure = (gelfandTransform β„‚ A).range :=
-    le_antisymm
-      (Subalgebra.topologicalClosure_minimal _ le_rfl
-        (gelfandTransform_isometry A).closedEmbedding.closed_range)
-      (Subalgebra.le_topologicalClosure _)
-  refine' h β–Έ ContinuousMap.subalgebra_isROrC_topologicalClosure_eq_top_of_separatesPoints
-    _ (fun _ _ => _) fun f hf => _
+  have h : rng.topologicalClosure = rng := le_antisymm
+    (StarSubalgebra.topologicalClosure_minimal le_rfl
+      (gelfandTransform_isometry A).closedEmbedding.closed_range)
+    (StarSubalgebra.le_topologicalClosure _)
+  refine' h β–Έ ContinuousMap.starSubalgebra_topologicalClosure_eq_top_of_separatesPoints
+    _ (fun _ _ => _)
   /- Separating points just means that elements of the `characterSpace` which agree at all points
     of `A` are the same functional, which is just extensionality. -/
-  Β· contrapose!
-    exact fun h => Subtype.ext (ContinuousLinearMap.ext fun a =>
-      h (gelfandTransform β„‚ A a) ⟨gelfandTransform β„‚ A a, ⟨a, rfl⟩, rfl⟩)
-  /- If `f = gelfandTransform β„‚ A a`, then `star f` is also in the range of `gelfandTransform β„‚ A`
-    using the argument `star a`. The key lemma below may be hard to spot; it's `map_star` coming
-    from `WeakDual.Complex.instStarHomClass`, which is a nontrivial result. -/
-  · obtain ⟨f, ⟨a, rfl⟩, rfl⟩ := Subalgebra.mem_map.mp hf
-    refine' ⟨star a, ContinuousMap.ext fun ψ => _⟩
-    simp only [AlgHom.toRingHom_eq_coe, RingHom.coe_coe, gelfandTransform_apply_apply,
-      AlgEquiv.toAlgHom_eq_coe, AlgHom.compLeftContinuous_apply_apply, AlgHom.coe_coe,
-      IsROrC.conjAe_coe, map_star, starRingEnd_apply]
+  contrapose!
+  exact fun h => Subtype.ext (ContinuousLinearMap.ext fun a =>
+    h (gelfandTransform β„‚ A a) ⟨gelfandTransform β„‚ A a, ⟨a, rfl⟩, rfl⟩)
 #align gelfand_transform_bijective gelfandTransform_bijective
 
 /-- The Gelfand transform as a `StarAlgEquiv` between a commutative unital C⋆-algebra over `β„‚`
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -2,11 +2,6 @@
 Copyright (c) 2022 Jireh Loreaux. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Jireh Loreaux
-
-! This file was ported from Lean 3 source module analysis.normed_space.star.gelfand_duality
-! leanprover-community/mathlib commit e65771194f9e923a70dfb49b6ca7be6e400d8b6f
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Analysis.NormedSpace.Star.Spectrum
 import Mathlib.Analysis.Normed.Group.Quotient
@@ -16,6 +11,8 @@ import Mathlib.Topology.ContinuousFunction.Compact
 import Mathlib.Topology.Algebra.Algebra
 import Mathlib.Topology.ContinuousFunction.StoneWeierstrass
 
+#align_import analysis.normed_space.star.gelfand_duality from "leanprover-community/mathlib"@"e65771194f9e923a70dfb49b6ca7be6e400d8b6f"
+
 /-!
 # Gelfand Duality
 
chore: fix many typos (#4983)

These are all doc fixes

Diff
@@ -1,6 +1,6 @@
 /-
 Copyright (c) 2022 Jireh Loreaux. All rights reserved.
-Reeased under Apache 2.0 license as described in the file LICENSE.
+Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Jireh Loreaux
 
 ! This file was ported from Lean 3 source module analysis.normed_space.star.gelfand_duality
@@ -52,7 +52,7 @@ and even an equivalence between C⋆-algebras.
 * Conclude using the previous fact that the functors `C(⬝, β„‚)` and `characterSpace β„‚ ⬝` along with
   the canonical homeomorphisms described above constitute a natural contravariant equivalence of
   the categories of compact Hausdorff spaces (with continuous maps) and commutative unital
-  C⋆-algebras (with unital ⋆-algebra homomoprhisms); this is known as **Gelfand duality**.
+  C⋆-algebras (with unital ⋆-algebra homomorphisms); this is known as **Gelfand duality**.
 
 ## Tags
 
@@ -91,7 +91,7 @@ theorem Ideal.toCharacterSpace_apply_eq_zero_of_mem {a : A} (ha : a ∈ I) :
   exact Set.eq_of_mem_singleton (Set.singleton_nonempty (0 : β„‚)).some_mem
 #align ideal.to_character_space_apply_eq_zero_of_mem Ideal.toCharacterSpace_apply_eq_zero_of_mem
 
-/-- If `a : A` is not a unit, then some character takes the value zero at `a`. This is equivlaent
+/-- If `a : A` is not a unit, then some character takes the value zero at `a`. This is equivalent
 to `gelfandTransform β„‚ A a` takes the value zero at some character. -/
 theorem WeakDual.CharacterSpace.exists_apply_eq_zero {a : A} (ha : Β¬IsUnit a) :
     βˆƒ f : characterSpace β„‚ A, f a = 0 := by
feat: port Analysis.NormedSpace.Star.GelfandDuality (#4972)

Dependencies 12 + 1149

1150 files ported (99.0%)
508646 lines ported (98.9%)
Show graph

The unported dependencies are

The following 1 dependencies have changed in mathlib3 since they were ported, which may complicate porting this file