Documentation

Mathlib.Algebra.Category.Ring.Basic

Category instances for Semiring, Ring, CommSemiring, and CommRing. #

We introduce the bundled categories:

along with the relevant forgetful functors between them.

structure SemiRingCat :
Type (u + 1)

The category of semirings.

  • carrier : Type u

    The underlying type.

  • semiring : Semiring self
Instances For
    @[reducible, inline]

    The object in the category of R-algebras associated to a type equipped with the appropriate typeclasses. This is the preferred way to construct a term of SemiRingCat.

    Equations
      Instances For
        theorem SemiRingCat.coe_of (R : Type u) [Semiring R] :
        (of R) = R
        structure SemiRingCat.Hom (R S : SemiRingCat) :

        The type of morphisms in SemiRingCat.

        • hom' : R →+* S

          The underlying ring hom.

        Instances For
          theorem SemiRingCat.Hom.ext_iff {R S : SemiRingCat} {x y : R.Hom S} :
          x = y x.hom' = y.hom'
          theorem SemiRingCat.Hom.ext {R S : SemiRingCat} {x y : R.Hom S} (hom' : x.hom' = y.hom') :
          x = y
          @[reducible, inline]
          abbrev SemiRingCat.Hom.hom {R S : SemiRingCat} (f : R.Hom S) :
          R →+* S

          Turn a morphism in SemiRingCat back into a RingHom.

          Equations
            Instances For
              @[reducible, inline]
              abbrev SemiRingCat.ofHom {R S : Type u} [Semiring R] [Semiring S] (f : R →+* S) :
              of R of S

              Typecheck a RingHom as a morphism in SemiRingCat.

              Equations
                Instances For
                  def SemiRingCat.Hom.Simps.hom (R S : SemiRingCat) (f : R.Hom S) :
                  R →+* S

                  Use the ConcreteCategory.hom projection for @[simps] lemmas.

                  Equations
                    Instances For

                      The results below duplicate the ConcreteCategory simp lemmas, but we can keep them for dsimp.

                      @[simp]
                      theorem SemiRingCat.hom_ext {R S : SemiRingCat} {f g : R S} (hf : Hom.hom f = Hom.hom g) :
                      f = g
                      theorem SemiRingCat.hom_ext_iff {R S : SemiRingCat} {f g : R S} :
                      @[simp]
                      theorem SemiRingCat.hom_ofHom {R S : Type u} [Semiring R] [Semiring S] (f : R →+* S) :
                      @[simp]
                      theorem SemiRingCat.ofHom_hom {R S : SemiRingCat} (f : R S) :
                      @[simp]
                      theorem SemiRingCat.ofHom_comp {R S T : Type u} [Semiring R] [Semiring S] [Semiring T] (f : R →+* S) (g : S →+* T) :
                      theorem SemiRingCat.ofHom_apply {R S : Type u} [Semiring R] [Semiring S] (f : R →+* S) (r : R) :

                      This unification hint helps with problems of the form (forget ?C).obj R =?= carrier R'.

                      Equations
                        Instances For

                          Ring equivalences are isomorphisms in category of semirings

                          Equations
                            Instances For
                              structure RingCat :
                              Type (u + 1)

                              The category of rings.

                              • carrier : Type u

                                The underlying type.

                              • ring : Ring self
                              Instances For
                                @[reducible, inline]
                                abbrev RingCat.of (R : Type u) [Ring R] :

                                The object in the category of R-algebras associated to a type equipped with the appropriate typeclasses. This is the preferred way to construct a term of RingCat.

                                Equations
                                  Instances For
                                    theorem RingCat.coe_of (R : Type u) [Ring R] :
                                    (of R) = R
                                    theorem RingCat.of_carrier (R : RingCat) :
                                    of R = R
                                    structure RingCat.Hom (R S : RingCat) :

                                    The type of morphisms in RingCat.

                                    • hom' : R →+* S

                                      The underlying ring hom.

                                    Instances For
                                      theorem RingCat.Hom.ext {R S : RingCat} {x y : R.Hom S} (hom' : x.hom' = y.hom') :
                                      x = y
                                      theorem RingCat.Hom.ext_iff {R S : RingCat} {x y : R.Hom S} :
                                      x = y x.hom' = y.hom'
                                      @[reducible, inline]
                                      abbrev RingCat.Hom.hom {R S : RingCat} (f : R.Hom S) :
                                      R →+* S

                                      Turn a morphism in RingCat back into a RingHom.

                                      Equations
                                        Instances For
                                          @[reducible, inline]
                                          abbrev RingCat.ofHom {R S : Type u} [Ring R] [Ring S] (f : R →+* S) :
                                          of R of S

                                          Typecheck a RingHom as a morphism in RingCat.

                                          Equations
                                            Instances For
                                              def RingCat.Hom.Simps.hom (R S : RingCat) (f : R.Hom S) :
                                              R →+* S

                                              Use the ConcreteCategory.hom projection for @[simps] lemmas.

                                              Equations
                                                Instances For

                                                  The results below duplicate the ConcreteCategory simp lemmas, but we can keep them for dsimp.

                                                  @[simp]
                                                  theorem RingCat.hom_comp {R S T : RingCat} (f : R S) (g : S T) :
                                                  theorem RingCat.hom_ext {R S : RingCat} {f g : R S} (hf : Hom.hom f = Hom.hom g) :
                                                  f = g
                                                  theorem RingCat.hom_ext_iff {R S : RingCat} {f g : R S} :
                                                  @[simp]
                                                  theorem RingCat.hom_ofHom {R S : Type u} [Ring R] [Ring S] (f : R →+* S) :
                                                  @[simp]
                                                  theorem RingCat.ofHom_hom {R S : RingCat} (f : R S) :
                                                  @[simp]
                                                  theorem RingCat.ofHom_comp {R S T : Type u} [Ring R] [Ring S] [Ring T] (f : R →+* S) (g : S →+* T) :
                                                  theorem RingCat.ofHom_apply {R S : Type u} [Ring R] [Ring S] (f : R →+* S) (r : R) :

                                                  This unification hint helps with problems of the form (forget ?C).obj R =?= carrier R'.

                                                  An example where this is needed is in applying PresheafOfModules.Sheafify.app_eq_of_isLocallyInjective.

                                                  Equations
                                                    Instances For

                                                      The forgetful functor from RingCat to SemiRingCat is fully faithful.

                                                      Equations
                                                        Instances For
                                                          def RingEquiv.toRingCatIso {R S : Type u} [Ring R] [Ring S] (e : R ≃+* S) :

                                                          Ring equivalences are isomorphisms in category of rings

                                                          Equations
                                                            Instances For
                                                              @[simp]
                                                              theorem RingEquiv.toRingCatIso_inv {R S : Type u} [Ring R] [Ring S] (e : R ≃+* S) :
                                                              @[simp]
                                                              theorem RingEquiv.toRingCatIso_hom {R S : Type u} [Ring R] [Ring S] (e : R ≃+* S) :
                                                              structure CommSemiRingCat :
                                                              Type (u + 1)

                                                              The category of commutative semirings.

                                                              Instances For
                                                                @[reducible, inline]

                                                                The object in the category of R-algebras associated to a type equipped with the appropriate typeclasses. This is the preferred way to construct a term of CommSemiRingCat.

                                                                Equations
                                                                  Instances For
                                                                    theorem CommSemiRingCat.coe_of (R : Type u) [CommSemiring R] :
                                                                    (of R) = R

                                                                    The type of morphisms in CommSemiRingCat.

                                                                    • hom' : R →+* S

                                                                      The underlying ring hom.

                                                                    Instances For
                                                                      theorem CommSemiRingCat.Hom.ext {R S : CommSemiRingCat} {x y : R.Hom S} (hom' : x.hom' = y.hom') :
                                                                      x = y
                                                                      theorem CommSemiRingCat.Hom.ext_iff {R S : CommSemiRingCat} {x y : R.Hom S} :
                                                                      x = y x.hom' = y.hom'
                                                                      @[reducible, inline]
                                                                      abbrev CommSemiRingCat.Hom.hom {R S : CommSemiRingCat} (f : R.Hom S) :
                                                                      R →+* S

                                                                      Turn a morphism in CommSemiRingCat back into a RingHom.

                                                                      Equations
                                                                        Instances For
                                                                          @[reducible, inline]
                                                                          abbrev CommSemiRingCat.ofHom {R S : Type u} [CommSemiring R] [CommSemiring S] (f : R →+* S) :
                                                                          of R of S

                                                                          Typecheck a RingHom as a morphism in CommSemiRingCat.

                                                                          Equations
                                                                            Instances For
                                                                              def CommSemiRingCat.Hom.Simps.hom (R S : CommSemiRingCat) (f : R.Hom S) :
                                                                              R →+* S

                                                                              Use the ConcreteCategory.hom projection for @[simps] lemmas.

                                                                              Equations
                                                                                Instances For

                                                                                  The results below duplicate the ConcreteCategory simp lemmas, but we can keep them for dsimp.

                                                                                  theorem CommSemiRingCat.hom_ext {R S : CommSemiRingCat} {f g : R S} (hf : Hom.hom f = Hom.hom g) :
                                                                                  f = g
                                                                                  @[simp]
                                                                                  theorem CommSemiRingCat.hom_ofHom {R S : Type u} [CommSemiring R] [CommSemiring S] (f : R →+* S) :
                                                                                  @[simp]
                                                                                  theorem CommSemiRingCat.ofHom_hom {R S : CommSemiRingCat} (f : R S) :

                                                                                  This unification hint helps with problems of the form (forget ?C).obj R =?= carrier R'.

                                                                                  Equations
                                                                                    Instances For

                                                                                      The forgetful functor from commutative rings to (multiplicative) commutative monoids.

                                                                                      Equations

                                                                                        Ring equivalences are isomorphisms in category of commutative semirings

                                                                                        Equations
                                                                                          Instances For
                                                                                            structure CommRingCat :
                                                                                            Type (u + 1)

                                                                                            The category of commutative rings.

                                                                                            • carrier : Type u

                                                                                              The underlying type.

                                                                                            • commRing : CommRing self
                                                                                            Instances For
                                                                                              @[reducible, inline]

                                                                                              The object in the category of R-algebras associated to a type equipped with the appropriate typeclasses. This is the preferred way to construct a term of CommRingCat.

                                                                                              Equations
                                                                                                Instances For
                                                                                                  theorem CommRingCat.coe_of (R : Type u) [CommRing R] :
                                                                                                  (of R) = R
                                                                                                  structure CommRingCat.Hom (R S : CommRingCat) :

                                                                                                  The type of morphisms in CommRingCat.

                                                                                                  • hom' : R →+* S

                                                                                                    The underlying ring hom.

                                                                                                  Instances For
                                                                                                    theorem CommRingCat.Hom.ext_iff {R S : CommRingCat} {x y : R.Hom S} :
                                                                                                    x = y x.hom' = y.hom'
                                                                                                    theorem CommRingCat.Hom.ext {R S : CommRingCat} {x y : R.Hom S} (hom' : x.hom' = y.hom') :
                                                                                                    x = y
                                                                                                    @[reducible, inline]
                                                                                                    abbrev CommRingCat.Hom.hom {R S : CommRingCat} (f : R.Hom S) :
                                                                                                    R →+* S

                                                                                                    The underlying ring hom.

                                                                                                    Equations
                                                                                                      Instances For
                                                                                                        @[reducible, inline]
                                                                                                        abbrev CommRingCat.ofHom {R S : Type u} [CommRing R] [CommRing S] (f : R →+* S) :
                                                                                                        of R of S

                                                                                                        Typecheck a RingHom as a morphism in CommRingCat.

                                                                                                        Equations
                                                                                                          Instances For
                                                                                                            def CommRingCat.Hom.Simps.hom (R S : CommRingCat) (f : R.Hom S) :
                                                                                                            R →+* S

                                                                                                            Use the ConcreteCategory.hom projection for @[simps] lemmas.

                                                                                                            Equations
                                                                                                              Instances For

                                                                                                                The results below duplicate the ConcreteCategory simp lemmas, but we can keep them for dsimp.

                                                                                                                @[simp]
                                                                                                                theorem CommRingCat.hom_ext {R S : CommRingCat} {f g : R S} (hf : Hom.hom f = Hom.hom g) :
                                                                                                                f = g
                                                                                                                theorem CommRingCat.hom_ext_iff {R S : CommRingCat} {f g : R S} :
                                                                                                                @[simp]
                                                                                                                theorem CommRingCat.hom_ofHom {R S : Type u} [CommRing R] [CommRing S] (f : R →+* S) :
                                                                                                                @[simp]
                                                                                                                theorem CommRingCat.ofHom_hom {R S : CommRingCat} (f : R S) :
                                                                                                                @[simp]
                                                                                                                theorem CommRingCat.ofHom_comp {R S T : Type u} [CommRing R] [CommRing S] [CommRing T] (f : R →+* S) (g : S →+* T) :
                                                                                                                theorem CommRingCat.ofHom_apply {R S : Type u} [CommRing R] [CommRing S] (f : R →+* S) (r : R) :

                                                                                                                This unification hint helps with problems of the form (forget ?C).obj R =?= carrier R'.

                                                                                                                An example where this is needed is in applying TopCat.Presheaf.restrictOpen to commutative rings.

                                                                                                                Equations
                                                                                                                  Instances For

                                                                                                                    The forgetful functor from CommRingCat to RingCat is fully faithful.

                                                                                                                    Equations
                                                                                                                      Instances For

                                                                                                                        Ring equivalences are isomorphisms in category of commutative rings

                                                                                                                        Equations
                                                                                                                          Instances For

                                                                                                                            Build a RingEquiv from an isomorphism in the category SemiRingCat.

                                                                                                                            Equations
                                                                                                                              Instances For

                                                                                                                                Build a RingEquiv from an isomorphism in the category RingCat.

                                                                                                                                Equations
                                                                                                                                  Instances For

                                                                                                                                    Build a RingEquiv from an isomorphism in the category CommSemiRingCat.

                                                                                                                                    Equations
                                                                                                                                      Instances For

                                                                                                                                        Build a RingEquiv from an isomorphism in the category CommRingCat.

                                                                                                                                        Equations
                                                                                                                                          Instances For