File: Mathlib/AlgebraicGeometry/Spec.lean

full_name: AlgebraicGeometry.Spec.topObj
code: /-- The spectrum of a commutative ring, as a topological space.
-/
def Spec.topObj (R : CommRingCat.{u}) : TopCat 
goal: TopCat

full_name: AlgebraicGeometry.Spec.topObj_forget
code: @[simp] theorem Spec.topObj_forget {R} : (forget TopCat).obj (Spec.topObj R) = PrimeSpectrum R 
goal: (CategoryTheory.forget TopCat).obj (AlgebraicGeometry.Spec.topObj R) = PrimeSpectrum ↑R

full_name: AlgebraicGeometry.Spec.topMap
code: /-- The induced map of a ring homomorphism on the ring spectra, as a morphism of topological spaces.
-/
def Spec.topMap {R S : CommRingCat.{u}} (f : R ⟶ S) : Spec.topObj S ⟶ Spec.topObj R 
goal: AlgebraicGeometry.Spec.topObj S ⟶ AlgebraicGeometry.Spec.topObj R

full_name: AlgebraicGeometry.Spec.topMap_id
code: @[simp]
theorem Spec.topMap_id (R : CommRingCat.{u}) : Spec.topMap (𝟙 R) = 𝟙 (Spec.topObj R) 
goal: AlgebraicGeometry.Spec.topMap (CategoryTheory.CategoryStruct.id R) =
  CategoryTheory.CategoryStruct.id (AlgebraicGeometry.Spec.topObj R)

full_name: AlgebraicGeometry.Spec.topMap_comp
code: @[simp]
theorem Spec.topMap_comp {R S T : CommRingCat.{u}} (f : R ⟶ S) (g : S ⟶ T) :
    Spec.topMap (f ≫ g) = Spec.topMap g ≫ Spec.topMap f 
goal: AlgebraicGeometry.Spec.topMap (CategoryTheory.CategoryStruct.comp f g) =
  CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.Spec.topMap g) (AlgebraicGeometry.Spec.topMap f)

full_name: AlgebraicGeometry.Spec.toTop_obj
code: /-- The spectrum, as a contravariant functor from commutative rings to topological spaces.
-/
@[simps! obj map]
def Spec.toTop : CommRingCat.{u}ᵒᵖ ⥤ TopCat 
goal: AlgebraicGeometry.Spec.toTop.obj R = AlgebraicGeometry.Spec.topObj (Opposite.unop R)

full_name: AlgebraicGeometry.Spec.toTop_map
code: /-- The spectrum, as a contravariant functor from commutative rings to topological spaces.
-/
@[simps! obj map]
def Spec.toTop : CommRingCat.{u}ᵒᵖ ⥤ TopCat 
goal: AlgebraicGeometry.Spec.toTop.map f = AlgebraicGeometry.Spec.topMap f.unop

full_name: AlgebraicGeometry.Spec.toTop
code: /-- The spectrum, as a contravariant functor from commutative rings to topological spaces.
-/
@[simps! obj map]
def Spec.toTop : CommRingCat.{u}ᵒᵖ ⥤ TopCat 
goal: CategoryTheory.Functor CommRingCatᵒᵖ TopCat

full_name: AlgebraicGeometry.Spec.sheafedSpaceObj
code: /-- The spectrum of a commutative ring, as a `SheafedSpace`.
-/
@[simps]
def Spec.sheafedSpaceObj (R : CommRingCat.{u}) : SheafedSpace CommRingCat 
goal: AlgebraicGeometry.SheafedSpace CommRingCat

full_name: AlgebraicGeometry.Spec.sheafedSpaceObj_presheaf
code: /-- The spectrum of a commutative ring, as a `SheafedSpace`.
-/
@[simps]
def Spec.sheafedSpaceObj (R : CommRingCat.{u}) : SheafedSpace CommRingCat 
goal: (AlgebraicGeometry.Spec.sheafedSpaceObj R).presheaf = (AlgebraicGeometry.Spec.structureSheaf ↑R).val

full_name: AlgebraicGeometry.Spec.sheafedSpaceObj_carrier
code: /-- The spectrum of a commutative ring, as a `SheafedSpace`.
-/
@[simps]
def Spec.sheafedSpaceObj (R : CommRingCat.{u}) : SheafedSpace CommRingCat 
goal: ↑(AlgebraicGeometry.Spec.sheafedSpaceObj R).toPresheafedSpace = AlgebraicGeometry.Spec.topObj R

full_name: AlgebraicGeometry.Spec.sheafedSpaceMap
code: /-- The induced map of a ring homomorphism on the ring spectra, as a morphism of sheafed spaces.
-/
@[simps]
def Spec.sheafedSpaceMap {R S : CommRingCat.{u}} (f : R ⟶ S) :
    Spec.sheafedSpaceObj S ⟶ Spec.sheafedSpaceObj R 
goal: AlgebraicGeometry.Spec.sheafedSpaceObj S ⟶ AlgebraicGeometry.Spec.sheafedSpaceObj R

full_name: AlgebraicGeometry.Spec.sheafedSpaceMap_base
code: /-- The induced map of a ring homomorphism on the ring spectra, as a morphism of sheafed spaces.
-/
@[simps]
def Spec.sheafedSpaceMap {R S : CommRingCat.{u}} (f : R ⟶ S) :
    Spec.sheafedSpaceObj S ⟶ Spec.sheafedSpaceObj R 
goal: (AlgebraicGeometry.Spec.sheafedSpaceMap f).base = AlgebraicGeometry.Spec.topMap f

full_name: AlgebraicGeometry.Spec.sheafedSpaceMap_c_app
code: /-- The induced map of a ring homomorphism on the ring spectra, as a morphism of sheafed spaces.
-/
@[simps]
def Spec.sheafedSpaceMap {R S : CommRingCat.{u}} (f : R ⟶ S) :
    Spec.sheafedSpaceObj S ⟶ Spec.sheafedSpaceObj R 
goal: (AlgebraicGeometry.Spec.sheafedSpaceMap f).c.app U =
  AlgebraicGeometry.StructureSheaf.comap f (Opposite.unop U)
    ((TopologicalSpace.Opens.map (AlgebraicGeometry.Spec.topMap f)).obj (Opposite.unop U)) ⋯

full_name: AlgebraicGeometry.Spec.sheafedSpaceMap_id
code: @[simp]
theorem Spec.sheafedSpaceMap_id {R : CommRingCat.{u}} :
    Spec.sheafedSpaceMap (𝟙 R) = 𝟙 (Spec.sheafedSpaceObj R) 
goal: AlgebraicGeometry.Spec.sheafedSpaceMap (CategoryTheory.CategoryStruct.id R) =
  CategoryTheory.CategoryStruct.id (AlgebraicGeometry.Spec.sheafedSpaceObj R)

full_name: AlgebraicGeometry.Spec.sheafedSpaceMap_comp
code: theorem Spec.sheafedSpaceMap_comp {R S T : CommRingCat.{u}} (f : R ⟶ S) (g : S ⟶ T) :
    Spec.sheafedSpaceMap (f ≫ g) = Spec.sheafedSpaceMap g ≫ Spec.sheafedSpaceMap f 
goal: AlgebraicGeometry.Spec.sheafedSpaceMap (CategoryTheory.CategoryStruct.comp f g) =
  CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.Spec.sheafedSpaceMap g)
    (AlgebraicGeometry.Spec.sheafedSpaceMap f)

full_name: AlgebraicGeometry.Spec.toSheafedSpace_obj
code: /-- Spec, as a contravariant functor from commutative rings to sheafed spaces.
-/
@[simps]
def Spec.toSheafedSpace : CommRingCat.{u}ᵒᵖ ⥤ SheafedSpace CommRingCat 
goal: AlgebraicGeometry.Spec.toSheafedSpace.obj R = AlgebraicGeometry.Spec.sheafedSpaceObj (Opposite.unop R)

full_name: AlgebraicGeometry.Spec.toSheafedSpace_map
code: /-- Spec, as a contravariant functor from commutative rings to sheafed spaces.
-/
@[simps]
def Spec.toSheafedSpace : CommRingCat.{u}ᵒᵖ ⥤ SheafedSpace CommRingCat 
goal: ∀ {X Y : CommRingCatᵒᵖ} (f : X ⟶ Y),
  AlgebraicGeometry.Spec.toSheafedSpace.map f = AlgebraicGeometry.Spec.sheafedSpaceMap f.unop

full_name: AlgebraicGeometry.Spec.toSheafedSpace
code: /-- Spec, as a contravariant functor from commutative rings to sheafed spaces.
-/
@[simps]
def Spec.toSheafedSpace : CommRingCat.{u}ᵒᵖ ⥤ SheafedSpace CommRingCat 
goal: CategoryTheory.Functor CommRingCatᵒᵖ (AlgebraicGeometry.SheafedSpace CommRingCat)

full_name: AlgebraicGeometry.Spec.toPresheafedSpace
code: /-- Spec, as a contravariant functor from commutative rings to presheafed spaces.
-/
def Spec.toPresheafedSpace : CommRingCat.{u}ᵒᵖ ⥤ PresheafedSpace CommRingCat 
goal: CategoryTheory.Functor CommRingCatᵒᵖ (AlgebraicGeometry.PresheafedSpace CommRingCat)

full_name: AlgebraicGeometry.Spec.toPresheafedSpace_obj
code: @[simp]
theorem Spec.toPresheafedSpace_obj (R : CommRingCat.{u}ᵒᵖ) :
    Spec.toPresheafedSpace.obj R = (Spec.sheafedSpaceObj (unop R)).toPresheafedSpace 
goal: AlgebraicGeometry.Spec.toPresheafedSpace.obj R =
  (AlgebraicGeometry.Spec.sheafedSpaceObj (Opposite.unop R)).toPresheafedSpace

full_name: AlgebraicGeometry.Spec.toPresheafedSpace_obj_op
code: theorem Spec.toPresheafedSpace_obj_op (R : CommRingCat.{u}) :
    Spec.toPresheafedSpace.obj (op R) = (Spec.sheafedSpaceObj R).toPresheafedSpace 
goal: AlgebraicGeometry.Spec.toPresheafedSpace.obj (Opposite.op R) =
  (AlgebraicGeometry.Spec.sheafedSpaceObj R).toPresheafedSpace

full_name: AlgebraicGeometry.Spec.toPresheafedSpace_map
code: @[simp]
theorem Spec.toPresheafedSpace_map (R S : CommRingCat.{u}ᵒᵖ) (f : R ⟶ S) :
    Spec.toPresheafedSpace.map f = Spec.sheafedSpaceMap f.unop 
goal: AlgebraicGeometry.Spec.toPresheafedSpace.map f = AlgebraicGeometry.Spec.sheafedSpaceMap f.unop

full_name: AlgebraicGeometry.Spec.toPresheafedSpace_map_op
code: theorem Spec.toPresheafedSpace_map_op (R S : CommRingCat.{u}) (f : R ⟶ S) :
    Spec.toPresheafedSpace.map f.op = Spec.sheafedSpaceMap f 
goal: AlgebraicGeometry.Spec.toPresheafedSpace.map f.op = AlgebraicGeometry.Spec.sheafedSpaceMap f

full_name: AlgebraicGeometry.Spec.basicOpen_hom_ext
code: theorem Spec.basicOpen_hom_ext {X : RingedSpace.{u}} {R : CommRingCat.{u}}
    {α β : X ⟶ Spec.sheafedSpaceObj R} (w : α.base = β.base)
    (h : ∀ r : R,
      let U := PrimeSpectrum.basicOpen r
      (toOpen R U ≫ α.c.app (op U)) ≫ X.presheaf.map (eqToHom (by rw [w])) =
        toOpen R U ≫ β.c.app (op U)) :
    α = β 
goal: α = β

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_presheaf
code: /-- The spectrum of a commutative ring, as a `LocallyRingedSpace`.
-/
@[simps! toSheafedSpace presheaf]
def Spec.locallyRingedSpaceObj (R : CommRingCat.{u}) : LocallyRingedSpace 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj R).presheaf = (AlgebraicGeometry.Spec.structureSheaf ↑R).val

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj
code: /-- The spectrum of a commutative ring, as a `LocallyRingedSpace`.
-/
@[simps! toSheafedSpace presheaf]
def Spec.locallyRingedSpaceObj (R : CommRingCat.{u}) : LocallyRingedSpace 
goal: AlgebraicGeometry.LocallyRingedSpace

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_toSheafedSpace
code: /-- The spectrum of a commutative ring, as a `LocallyRingedSpace`.
-/
@[simps! toSheafedSpace presheaf]
def Spec.locallyRingedSpaceObj (R : CommRingCat.{u}) : LocallyRingedSpace 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj R).toSheafedSpace = AlgebraicGeometry.Spec.sheafedSpaceObj R

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_sheaf
code: lemma Spec.locallyRingedSpaceObj_sheaf (R : CommRingCat.{u}) :
    (Spec.locallyRingedSpaceObj R).sheaf = structureSheaf R 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj R).sheaf = AlgebraicGeometry.Spec.structureSheaf ↑R

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_sheaf'
code: lemma Spec.locallyRingedSpaceObj_sheaf' (R : Type u) [CommRing R] :
    (Spec.locallyRingedSpaceObj <| CommRingCat.of R).sheaf = structureSheaf R 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj (CommRingCat.of R)).sheaf = AlgebraicGeometry.Spec.structureSheaf R

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_presheaf_map
code: lemma Spec.locallyRingedSpaceObj_presheaf_map (R : CommRingCat.{u}) {U V} (i : U ⟶ V) :
    (Spec.locallyRingedSpaceObj R).presheaf.map i =
    (structureSheaf R).1.map i 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj R).presheaf.map i = (AlgebraicGeometry.Spec.structureSheaf ↑R).val.map i

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_presheaf'
code: lemma Spec.locallyRingedSpaceObj_presheaf' (R : Type u) [CommRing R] :
    (Spec.locallyRingedSpaceObj <| CommRingCat.of R).presheaf = (structureSheaf R).1 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj (CommRingCat.of R)).presheaf =
  (AlgebraicGeometry.Spec.structureSheaf R).val

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceObj_presheaf_map'
code: lemma Spec.locallyRingedSpaceObj_presheaf_map' (R : Type u) [CommRing R] {U V} (i : U ⟶ V) :
    (Spec.locallyRingedSpaceObj <| CommRingCat.of R).presheaf.map i =
    (structureSheaf R).1.map i 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceObj (CommRingCat.of R)).presheaf.map i =
  (AlgebraicGeometry.Spec.structureSheaf R).val.map i

full_name: AlgebraicGeometry.stalkMap_toStalk
code: @[elementwise]
theorem stalkMap_toStalk {R S : CommRingCat.{u}} (f : R ⟶ S) (p : PrimeSpectrum S) :
    toStalk R (PrimeSpectrum.comap f p) ≫ (Spec.sheafedSpaceMap f).stalkMap p =
      f ≫ toStalk S p 
goal: CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.StructureSheaf.toStalk (↑R) ((PrimeSpectrum.comap f) p))
    (AlgebraicGeometry.PresheafedSpace.Hom.stalkMap (AlgebraicGeometry.Spec.sheafedSpaceMap f) p) =
  CategoryTheory.CategoryStruct.comp f (AlgebraicGeometry.StructureSheaf.toStalk (↑S) p)

full_name: AlgebraicGeometry.localRingHom_comp_stalkIso
code: /-- Under the isomorphisms `stalkIso`, the map `stalkMap (Spec.sheafedSpaceMap f) p` corresponds
to the induced local ring homomorphism `Localization.localRingHom`.
-/
@[elementwise]
theorem localRingHom_comp_stalkIso {R S : CommRingCat.{u}} (f : R ⟶ S) (p : PrimeSpectrum S) :
    (stalkIso R (PrimeSpectrum.comap f p)).hom ≫
        @CategoryStruct.comp _ _
          (CommRingCat.of (Localization.AtPrime (PrimeSpectrum.comap f p).asIdeal))
          (CommRingCat.of (Localization.AtPrime p.asIdeal)) _
          (Localization.localRingHom (PrimeSpectrum.comap f p).asIdeal p.asIdeal f rfl)
          (stalkIso S p).inv =
      (Spec.sheafedSpaceMap f).stalkMap p 
goal: CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.StructureSheaf.stalkIso (↑R) ((PrimeSpectrum.comap f) p)).hom
    (CategoryTheory.CategoryStruct.comp (Localization.localRingHom ((PrimeSpectrum.comap f) p).asIdeal p.asIdeal f ⋯)
      (AlgebraicGeometry.StructureSheaf.stalkIso (↑S) p).inv) =
  AlgebraicGeometry.PresheafedSpace.Hom.stalkMap (AlgebraicGeometry.Spec.sheafedSpaceMap f) p

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceMap
code: /--
The induced map of a ring homomorphism on the prime spectra, as a morphism of locally ringed spaces.
-/
@[simps]
def Spec.locallyRingedSpaceMap {R S : CommRingCat.{u}} (f : R ⟶ S) :
    Spec.locallyRingedSpaceObj S ⟶ Spec.locallyRingedSpaceObj R 
goal: AlgebraicGeometry.Spec.locallyRingedSpaceObj S ⟶ AlgebraicGeometry.Spec.locallyRingedSpaceObj R

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceMap_val
code: /--
The induced map of a ring homomorphism on the prime spectra, as a morphism of locally ringed spaces.
-/
@[simps]
def Spec.locallyRingedSpaceMap {R S : CommRingCat.{u}} (f : R ⟶ S) :
    Spec.locallyRingedSpaceObj S ⟶ Spec.locallyRingedSpaceObj R 
goal: (AlgebraicGeometry.Spec.locallyRingedSpaceMap f).val = AlgebraicGeometry.Spec.sheafedSpaceMap f

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceMap_id
code: @[simp]
theorem Spec.locallyRingedSpaceMap_id (R : CommRingCat.{u}) :
    Spec.locallyRingedSpaceMap (𝟙 R) = 𝟙 (Spec.locallyRingedSpaceObj R) 
goal: AlgebraicGeometry.Spec.locallyRingedSpaceMap (CategoryTheory.CategoryStruct.id R) =
  CategoryTheory.CategoryStruct.id (AlgebraicGeometry.Spec.locallyRingedSpaceObj R)

full_name: AlgebraicGeometry.Spec.locallyRingedSpaceMap_comp
code: theorem Spec.locallyRingedSpaceMap_comp {R S T : CommRingCat.{u}} (f : R ⟶ S) (g : S ⟶ T) :
    Spec.locallyRingedSpaceMap (f ≫ g) =
      Spec.locallyRingedSpaceMap g ≫ Spec.locallyRingedSpaceMap f 
goal: AlgebraicGeometry.Spec.locallyRingedSpaceMap (CategoryTheory.CategoryStruct.comp f g) =
  CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.Spec.locallyRingedSpaceMap g)
    (AlgebraicGeometry.Spec.locallyRingedSpaceMap f)

full_name: AlgebraicGeometry.Spec.toLocallyRingedSpace_map
code: /-- Spec, as a contravariant functor from commutative rings to locally ringed spaces.
-/
@[simps]
def Spec.toLocallyRingedSpace : CommRingCat.{u}ᵒᵖ ⥤ LocallyRingedSpace 
goal: ∀ {X Y : CommRingCatᵒᵖ} (f : X ⟶ Y),
  AlgebraicGeometry.Spec.toLocallyRingedSpace.map f = AlgebraicGeometry.Spec.locallyRingedSpaceMap f.unop

full_name: AlgebraicGeometry.Spec.toLocallyRingedSpace
code: /-- Spec, as a contravariant functor from commutative rings to locally ringed spaces.
-/
@[simps]
def Spec.toLocallyRingedSpace : CommRingCat.{u}ᵒᵖ ⥤ LocallyRingedSpace 
goal: CategoryTheory.Functor CommRingCatᵒᵖ AlgebraicGeometry.LocallyRingedSpace

full_name: AlgebraicGeometry.Spec.toLocallyRingedSpace_obj
code: /-- Spec, as a contravariant functor from commutative rings to locally ringed spaces.
-/
@[simps]
def Spec.toLocallyRingedSpace : CommRingCat.{u}ᵒᵖ ⥤ LocallyRingedSpace 
goal: AlgebraicGeometry.Spec.toLocallyRingedSpace.obj R = AlgebraicGeometry.Spec.locallyRingedSpaceObj (Opposite.unop R)

full_name: AlgebraicGeometry.toSpecΓ_apply_coe
code: /-- The counit morphism `R ⟶ Γ(Spec R)` given by `AlgebraicGeometry.StructureSheaf.toOpen`.  -/
@[simps!]
def toSpecΓ (R : CommRingCat.{u}) : R ⟶ Γ.obj (op (Spec.toLocallyRingedSpace.obj (op R))) 
goal: ↑((AlgebraicGeometry.toSpecΓ R) f) x = (algebraMap (↑R) (AlgebraicGeometry.StructureSheaf.Localizations ↑R ↑x)) f

full_name: AlgebraicGeometry.toSpecΓ
code: /-- The counit morphism `R ⟶ Γ(Spec R)` given by `AlgebraicGeometry.StructureSheaf.toOpen`.  -/
@[simps!]
def toSpecΓ (R : CommRingCat.{u}) : R ⟶ Γ.obj (op (Spec.toLocallyRingedSpace.obj (op R))) 
goal: R ⟶
  AlgebraicGeometry.LocallyRingedSpace.Γ.obj
    (Opposite.op (AlgebraicGeometry.Spec.toLocallyRingedSpace.obj (Opposite.op R)))

full_name: AlgebraicGeometry.isIso_toSpecΓ
code: instance isIso_toSpecΓ (R : CommRingCat.{u}) : IsIso (toSpecΓ R) 
goal: CategoryTheory.IsIso (AlgebraicGeometry.toSpecΓ R)

full_name: AlgebraicGeometry.Spec_Γ_naturality
code: @[reassoc]
theorem Spec_Γ_naturality {R S : CommRingCat.{u}} (f : R ⟶ S) :
    f ≫ toSpecΓ S = toSpecΓ R ≫ Γ.map (Spec.toLocallyRingedSpace.map f.op).op 
goal: CategoryTheory.CategoryStruct.comp f (AlgebraicGeometry.toSpecΓ S) =
  CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.toSpecΓ R)
    (AlgebraicGeometry.LocallyRingedSpace.Γ.map (AlgebraicGeometry.Spec.toLocallyRingedSpace.map f.op).op)

full_name: AlgebraicGeometry.LocallyRingedSpace.SpecΓIdentity_hom_app
code: /-- The counit (`SpecΓIdentity.inv.op`) of the adjunction `Γ ⊣ Spec` is an isomorphism. -/
@[simps! hom_app inv_app]
def LocallyRingedSpace.SpecΓIdentity : Spec.toLocallyRingedSpace.rightOp ⋙ Γ ≅ 𝟭 _ 
goal: AlgebraicGeometry.LocallyRingedSpace.SpecΓIdentity.hom.app X = CategoryTheory.inv (AlgebraicGeometry.toSpecΓ X)

full_name: AlgebraicGeometry.LocallyRingedSpace.SpecΓIdentity
code: /-- The counit (`SpecΓIdentity.inv.op`) of the adjunction `Γ ⊣ Spec` is an isomorphism. -/
@[simps! hom_app inv_app]
def LocallyRingedSpace.SpecΓIdentity : Spec.toLocallyRingedSpace.rightOp ⋙ Γ ≅ 𝟭 _ 
goal: AlgebraicGeometry.Spec.toLocallyRingedSpace.rightOp.comp AlgebraicGeometry.LocallyRingedSpace.Γ ≅
  CategoryTheory.Functor.id CommRingCat

full_name: AlgebraicGeometry.LocallyRingedSpace.SpecΓIdentity_inv_app
code: /-- The counit (`SpecΓIdentity.inv.op`) of the adjunction `Γ ⊣ Spec` is an isomorphism. -/
@[simps! hom_app inv_app]
def LocallyRingedSpace.SpecΓIdentity : Spec.toLocallyRingedSpace.rightOp ⋙ Γ ≅ 𝟭 _ 
goal: AlgebraicGeometry.LocallyRingedSpace.SpecΓIdentity.inv.app X = AlgebraicGeometry.toSpecΓ X

full_name: AlgebraicGeometry.Spec_map_localization_isIso
code: /-- The stalk map of `Spec M⁻¹R ⟶ Spec R` is an iso for each `p : Spec M⁻¹R`. -/
theorem Spec_map_localization_isIso (R : CommRingCat.{u}) (M : Submonoid R)
    (x : PrimeSpectrum (Localization M)) :
    IsIso
      ((Spec.toPresheafedSpace.map
        (CommRingCat.ofHom (algebraMap R (Localization M))).op).stalkMap x) 
goal: CategoryTheory.IsIso
  (AlgebraicGeometry.PresheafedSpace.Hom.stalkMap
    (AlgebraicGeometry.Spec.toPresheafedSpace.map (CommRingCat.ofHom (algebraMap (↑R) (Localization M))).op) x)

full_name: AlgebraicGeometry.StructureSheaf.toPushforwardStalk
code: /-- For an algebra `f : R →+* S`, this is the ring homomorphism `S →+* (f∗ 𝒪ₛ)ₚ` for a `p : Spec R`.
This is shown to be the localization at `p` in `isLocalizedModule_toPushforwardStalkAlgHom`.
-/
def toPushforwardStalk : S ⟶ (Spec.topMap f _* (structureSheaf S).1).stalk p 
goal: S ⟶
  ((TopCat.Presheaf.pushforward CommRingCat (AlgebraicGeometry.Spec.topMap f)).obj
        (AlgebraicGeometry.Spec.structureSheaf ↑S).val).stalk
    p

full_name: AlgebraicGeometry.StructureSheaf.toPushforwardStalk_comp
code: @[reassoc]
theorem toPushforwardStalk_comp :
    f ≫ StructureSheaf.toPushforwardStalk f p =
      StructureSheaf.toStalk R p ≫
        (TopCat.Presheaf.stalkFunctor _ _).map (Spec.sheafedSpaceMap f).c 
goal: CategoryTheory.CategoryStruct.comp f (AlgebraicGeometry.StructureSheaf.toPushforwardStalk f p) =
  CategoryTheory.CategoryStruct.comp (AlgebraicGeometry.StructureSheaf.toStalk (↑R) p)
    ((TopCat.Presheaf.stalkFunctor CommRingCat p).map (AlgebraicGeometry.Spec.sheafedSpaceMap f).c)

full_name: AlgebraicGeometry.StructureSheaf.instAlgebraαCommRingStalkCommRingCatObjPresheafTopObjPushforwardTopMapValOpensTopologicalSpaceTopStructureSheaf
code: instance : Algebra R ((Spec.topMap f _* (structureSheaf S).1).stalk p) 
goal: Algebra ↑R
  ↑(((TopCat.Presheaf.pushforward CommRingCat (AlgebraicGeometry.Spec.topMap f)).obj
          (AlgebraicGeometry.Spec.structureSheaf ↑S).val).stalk
      p)

full_name: AlgebraicGeometry.StructureSheaf.algebraMap_pushforward_stalk
code: theorem algebraMap_pushforward_stalk :
    algebraMap R ((Spec.topMap f _* (structureSheaf S).1).stalk p) =
      f ≫ StructureSheaf.toPushforwardStalk f p 
goal: algebraMap ↑R
    ↑(((TopCat.Presheaf.pushforward CommRingCat (AlgebraicGeometry.Spec.topMap f)).obj
            (AlgebraicGeometry.Spec.structureSheaf ↑S).val).stalk
        p) =
  CategoryTheory.CategoryStruct.comp f (AlgebraicGeometry.StructureSheaf.toPushforwardStalk f p)

full_name: AlgebraicGeometry.StructureSheaf.toPushforwardStalkAlgHom
code: /--
This is the `AlgHom` version of `toPushforwardStalk`, which is the map `S ⟶ (f∗ 𝒪ₛ)ₚ` for some
algebra `R ⟶ S` and some `p : Spec R`.
-/
@[simps!]
def toPushforwardStalkAlgHom :
    S →ₐ[R] (Spec.topMap (algebraMap R S) _* (structureSheaf S).1).stalk p 
goal: ↑S →ₐ[↑R]
  ↑(((TopCat.Presheaf.pushforward CommRingCat (AlgebraicGeometry.Spec.topMap (algebraMap ↑R ↑S))).obj
          (AlgebraicGeometry.Spec.structureSheaf ↑S).val).stalk
      p)

full_name: AlgebraicGeometry.StructureSheaf.toPushforwardStalkAlgHom_apply
code: /--
This is the `AlgHom` version of `toPushforwardStalk`, which is the map `S ⟶ (f∗ 𝒪ₛ)ₚ` for some
algebra `R ⟶ S` and some `p : Spec R`.
-/
@[simps!]
def toPushforwardStalkAlgHom :
    S →ₐ[R] (Spec.topMap (algebraMap R S) _* (structureSheaf S).1).stalk p 
goal: ∀ (a : ↑S),
  (AlgebraicGeometry.StructureSheaf.toPushforwardStalkAlgHom R S p) a =
    (((TopCat.Presheaf.pushforward CommRingCat (AlgebraicGeometry.Spec.topMap (algebraMap ↑R ↑S))).obj
            (AlgebraicGeometry.Spec.structureSheaf ↑S).val).germ
        ⟨p, trivial⟩)
      ((AlgebraicGeometry.StructureSheaf.toOpen ↑S ⊤) a)

full_name: AlgebraicGeometry.StructureSheaf.isLocalizedModule_toPushforwardStalkAlgHom_aux
code: theorem isLocalizedModule_toPushforwardStalkAlgHom_aux (y) :
    ∃ x : S × p.asIdeal.primeCompl, x.2 • y = toPushforwardStalkAlgHom R S p x.1 
goal: ∃ x, x.2 • y = (AlgebraicGeometry.StructureSheaf.toPushforwardStalkAlgHom R S p) x.1

full_name: AlgebraicGeometry.StructureSheaf.isLocalizedModule_toPushforwardStalkAlgHom
code: instance isLocalizedModule_toPushforwardStalkAlgHom :
    IsLocalizedModule p.asIdeal.primeCompl (toPushforwardStalkAlgHom R S p).toLinearMap 
goal: IsLocalizedModule p.asIdeal.primeCompl (AlgebraicGeometry.StructureSheaf.toPushforwardStalkAlgHom R S p).toLinearMap