Associated, prime, and irreducible elements. #
irreducible p
states that p
is non-unit and only factors into units.
We explicitly avoid stating that p
is non-zero, this would require a semiring. Assuming only a
monoid allows us to reuse irreducible for associated elements.
Instances
If p
and q
are irreducible, then p ∣ q
implies q ∣ p
.
Two elements of a monoid
are associated
if one of them is another one
multiplied by a unit on the right.
The setoid of the relation x ~ᵤ y
iff there is a unit u
such that x * u = y
Equations
- associated.setoid α = {r := associated _inst_1, iseqv := _}
Equations
- associated.decidable_rel = λ (a b : α), decidable_of_iff (a ∣ b ∧ b ∣ a) dvd_dvd_iff_associated
The quotient of a monoid by the associated
relation. Two elements x
and y
are associated iff there is a unit u
such that x * u = y
. There is a natural
monoid structure on associates α
.
Equations
- associates α = quotient (associated.setoid α)
The canonical quotient map from a monoid α
into the associates
of α
Equations
- associates.mk a = ⟦a⟧
Equations
- associates.has_bot = {bot := 1}
Equations
- associates.unique = {to_inhabited := {default := 1}, uniq := _}
Equations
- associates.has_mul = {mul := λ (a' b' : associates α), quotient.lift_on₂ a' b' (λ (a b : α), ⟦a * b⟧) associates.has_mul._proof_1}
Equations
- associates.comm_monoid = {mul := has_mul.mul associates.has_mul, mul_assoc := _, one := 1, one_mul := _, mul_one := _, npow := monoid.npow._default 1 has_mul.mul associates.comm_monoid._proof_4 associates.comm_monoid._proof_5, npow_zero' := _, npow_succ' := _, mul_comm := _}
Equations
- associates.preorder = {le := has_dvd.dvd semigroup_has_dvd, lt := λ (a b : associates α), a ∣ b ∧ ¬b ∣ a, le_refl := _, le_trans := _, lt_iff_le_not_le := _}
associates.mk
as a monoid_hom
.
Equations
- associates.mk_monoid_hom = {to_fun := associates.mk (comm_monoid.to_monoid α), map_one' := _, map_mul' := _}
Equations
- associates.unique_units = {to_inhabited := {default := 1}, uniq := _}
Equations
- associates.order_bot = {bot := 1, bot_le := _}
Equations
- associates.has_top = {top := 0}
Equations
- associates.comm_monoid_with_zero = {mul := comm_monoid.mul associates.comm_monoid, mul_assoc := _, one := comm_monoid.one associates.comm_monoid, one_mul := _, mul_one := _, npow := comm_monoid.npow associates.comm_monoid, npow_zero' := _, npow_succ' := _, mul_comm := _, zero := 0, zero_mul := _, mul_zero := _}
Equations
- associates.order_top = {top := 0, le_top := _}
Equations
- associates.bounded_order = {top := order_top.top associates.order_top, le_top := _, bot := order_bot.bot associates.order_bot, bot_le := _}
Equations
- associates.has_dvd.dvd.decidable_rel = λ (a b : associates α), quotient.rec_on_subsingleton₂ a b (λ (a b : α), decidable_of_iff' (a ∣ b) _)
Equations
- associates.partial_order = {le := preorder.le associates.preorder, lt := preorder.lt associates.preorder, le_refl := _, le_trans := _, lt_iff_le_not_le := _, le_antisymm := _}
Equations
- associates.ordered_comm_monoid = {mul := comm_monoid.mul associates.comm_monoid, mul_assoc := _, one := comm_monoid.one associates.comm_monoid, one_mul := _, mul_one := _, npow := comm_monoid.npow associates.comm_monoid, npow_zero' := _, npow_succ' := _, mul_comm := _, le := partial_order.le associates.partial_order, lt := partial_order.lt associates.partial_order, le_refl := _, le_trans := _, lt_iff_le_not_le := _, le_antisymm := _, mul_le_mul_left := _}
Equations
- associates.cancel_comm_monoid_with_zero = {mul := comm_monoid_with_zero.mul infer_instance, mul_assoc := _, one := comm_monoid_with_zero.one infer_instance, one_mul := _, mul_one := _, npow := comm_monoid_with_zero.npow infer_instance, npow_zero' := _, npow_succ' := _, mul_comm := _, zero := comm_monoid_with_zero.zero infer_instance, zero_mul := _, mul_zero := _, mul_left_cancel_of_ne_zero := _, mul_right_cancel_of_ne_zero := _}
Equations
- associates.canonically_ordered_monoid = {mul := cancel_comm_monoid_with_zero.mul associates.cancel_comm_monoid_with_zero, mul_assoc := _, one := cancel_comm_monoid_with_zero.one associates.cancel_comm_monoid_with_zero, one_mul := _, mul_one := _, npow := cancel_comm_monoid_with_zero.npow associates.cancel_comm_monoid_with_zero, npow_zero' := _, npow_succ' := _, mul_comm := _, le := ordered_comm_monoid.le associates.ordered_comm_monoid, lt := ordered_comm_monoid.lt associates.ordered_comm_monoid, le_refl := _, le_trans := _, lt_iff_le_not_le := _, le_antisymm := _, mul_le_mul_left := _, bot := bounded_order.bot associates.bounded_order, bot_le := _, le_iff_exists_mul := _}