Module docstring
{"# Additional lemmas about homomorphisms of semirings and rings
These lemmas have been banished here to avoid unnecessary imports in
Mathlib.Algebra.Hom.Ring.Defs.
They could be moved to more natural homes. "}
{"# Additional lemmas about homomorphisms of semirings and rings
These lemmas have been banished here to avoid unnecessary imports in
Mathlib.Algebra.Hom.Ring.Defs.
They could be moved to more natural homes. "}
RingHom.codomain_trivial_iff_range_eq_singleton_zero
theorem
: (0 : β) = 1 ↔ Set.range f = {0}
/-- `f : α →+* β` has a trivial codomain iff its range is `{0}`. -/
theorem codomain_trivial_iff_range_eq_singleton_zero : (0 : β) = 1 ↔ Set.range f = {0} :=
f.codomain_trivial_iff_range_trivial.trans
⟨fun h =>
Set.ext fun y => ⟨fun ⟨x, hx⟩ => by simp [← hx, h x], fun hy => ⟨0, by simpa using hy.symm⟩⟩,
fun h x => Set.mem_singleton_iff.mp (h ▸ Set.mem_range_self x)⟩
RingHom.map_dvd
theorem
(f : α →+* β) {a b : α} : a ∣ b → f a ∣ f b
Function.Injective.isDomain
theorem
[Semiring α] [IsDomain α] [Semiring β] {F} [FunLike F β α] [MonoidWithZeroHomClass F β α] (f : F) (hf : Injective f) :
IsDomain β
/-- Pullback `IsDomain` instance along an injective function. -/
protected theorem Function.Injective.isDomain [Semiring α] [IsDomain α] [Semiring β] {F}
[FunLike F β α] [MonoidWithZeroHomClass F β α] (f : F) (hf : Injective f) : IsDomain β where
__ := domain_nontrivial f (map_zero _) (map_one _)
__ := hf.isCancelMulZero f (map_zero _) (map_mul _)