Local rings #
Define the notion of a local ring for non-commutative semirings. In the commutative case,
this is shown to be equivalent to the familiar definition that there exists a unique
maximal ideal in IsLocalRing.of_unique_max_ideal and IsLocalRing.maximal_ideal_unique.
Main definitions #
IsLocalRing: A predicate on semirings, stating that for any pair of elements that adds up to1, one of them is a unit.
A semiring is local if it is nontrivial and a or b is a unit whenever a + b = 1.
Note that IsLocalRing is a predicate.
- of_is_unit_or_is_unit_of_add_one :: (
in a local ring
R, ifa + b = 1, then eitherais a unit orbis a unit. In another word, for everya : R, eitherais a unit or1 - ais a unit.- )