File: Mathlib/GroupTheory/MonoidLocalization/MonoidWithZero.lean

full_name: Submonoid.LocalizationMap.toMap_injective_iff
code: @[to_additive]
theorem toMap_injective_iff
    {M N : Type*} [CommMonoid M] {S : Submonoid M} [CommMonoid N] (f : LocalizationMap S N) :
    Injective (LocalizationMap.toMap f) ↔ ∀ ⦃x⦄, x ∈ S → IsLeftRegular x 
goal: Function.Injective ⇑f.toMap ↔ ∀ ⦃x : M⦄, x ∈ S → IsLeftRegular x

full_name: AddSubmonoid.LocalizationMap.toMap_injective_iff
code: @[to_additive]
theorem toMap_injective_iff
    {M N : Type*} [CommMonoid M] {S : Submonoid M} [CommMonoid N] (f : LocalizationMap S N) :
    Injective (LocalizationMap.toMap f) ↔ ∀ ⦃x⦄, x ∈ S → IsLeftRegular x 
goal: Function.Injective ⇑f.toMap ↔ ∀ ⦃x : M⦄, x ∈ S → IsAddLeftRegular x

full_name: Submonoid.LocalizationMap.subsingleton
code: /-- If `S` contains `0` then the localization at `S` is trivial. -/
theorem LocalizationMap.subsingleton  (f : Submonoid.LocalizationMap S N) (h : 0 ∈ S) :
    Subsingleton N 
goal: Subsingleton N

full_name: Submonoid.LocalizationWithZeroMap
code: /-- The type of homomorphisms between monoids with zero satisfying the characteristic predicate:
if `f : M →*₀ N` satisfies this predicate, then `N` is isomorphic to the localization of `M` at
`S`. -/
-- Porting note(#5171): this linter isn't ported yet.
-- @[nolint has_nonempty_instance]
structure LocalizationWithZeroMap extends LocalizationMap S N where
  map_zero' : toFun 0 = 0
goal: Type (max u_1 u_2)

full_name: Submonoid.LocalizationWithZeroMap.map_zero'
code: /-- The type of homomorphisms between monoids with zero satisfying the characteristic predicate:
if `f : M →*₀ N` satisfies this predicate, then `N` is isomorphic to the localization of `M` at
`S`. -/
-- Porting note(#5171): this linter isn't ported yet.
-- @[nolint has_nonempty_instance]
structure LocalizationWithZeroMap extends LocalizationMap S N where
  map_zero' : toFun 0 = 0
goal: (↑self.toMonoidHom).toFun 0 = 0

full_name: Submonoid.LocalizationWithZeroMap.toMonoidWithZeroHom
code: /-- The monoid with zero hom underlying a `LocalizationMap`. -/
def LocalizationWithZeroMap.toMonoidWithZeroHom (f : LocalizationWithZeroMap S N) : M →*₀ N 
goal: M →*₀ N

full_name: Localization.mk_zero
code: theorem mk_zero (x : S) : mk 0 (x : S) = 0 
goal: Localization.mk 0 x = 0

full_name: Localization.instCommMonoidWithZero
code: instance : CommMonoidWithZero (Localization S) 
goal: CommMonoidWithZero (Localization S)

full_name: Localization.liftOn_zero
code: theorem liftOn_zero {p : Type*} (f : M → S → p) (H) : liftOn 0 f H = f 0 1 
goal: Localization.liftOn 0 f H = f 0 1

full_name: Submonoid.LocalizationMap.sec_zero_fst
code: @[simp]
theorem LocalizationMap.sec_zero_fst {f : LocalizationMap S N} : f.toMap (f.sec 0).fst = 0 
goal: f.toMap (f.sec 0).1 = 0

full_name: Submonoid.LocalizationWithZeroMap.lift
code: /-- Given a Localization map `f : M →*₀ N` for a Submonoid `S ⊆ M` and a map of
`CommMonoidWithZero`s `g : M →*₀ P` such that `g y` is invertible for all `y : S`, the
homomorphism induced from `N` to `P` sending `z : N` to `g x * (g y)⁻¹`, where `(x, y) : M × S`
are such that `z = f x * (f y)⁻¹`. -/
noncomputable def lift (f : LocalizationWithZeroMap S N) (g : M →*₀ P)
    (hg : ∀ y : S, IsUnit (g y)) : N →*₀ P 
goal: N →*₀ P

full_name: Submonoid.LocalizationWithZeroMap.leftCancelMulZero_of_le_isLeftRegular
code: /-- Given a Localization map `f : M →*₀ N` for a Submonoid `S ⊆ M`,
if `M` is left cancellative monoid with zero, and all elements of `S` are
left regular, then N is a left cancellative monoid with zero. -/
theorem leftCancelMulZero_of_le_isLeftRegular
    (f : LocalizationWithZeroMap S N) [IsLeftCancelMulZero M]
    (h : ∀ ⦃x⦄, x ∈ S → IsLeftRegular x) : IsLeftCancelMulZero N 
goal: IsLeftCancelMulZero N

full_name: Submonoid.LocalizationWithZeroMap.isLeftRegular_of_le_isCancelMulZero
code: /-- Given a Localization map `f : M →*₀ N` for a Submonoid `S ⊆ M`,
if `M` is a cancellative monoid with zero, and all elements of `S` are
regular, then N is a cancellative monoid with zero.  -/
theorem isLeftRegular_of_le_isCancelMulZero (f : LocalizationWithZeroMap S N)
    [IsCancelMulZero M] (h : ∀ ⦃x⦄, x ∈ S → IsRegular x) : IsCancelMulZero N 
goal: IsCancelMulZero N