Module docstring
{"# Addition, negation, subtraction and multiplication on extended real numbers
Addition and multiplication in EReal are problematic in the presence of ±∞, but negation has
a natural definition and satisfies the usual properties. In particular, it is an order-reversing
isomorphism.
The construction of EReal as WithBot (WithTop ℝ) endows a LinearOrderedAddCommMonoid structure
on it. However, addition is badly behaved at (⊥, ⊤) and (⊤, ⊥), so this cannot be upgraded to a
group structure. Our choice is that ⊥ + ⊤ = ⊤ + ⊥ = ⊥, to make sure that the exponential and
logarithm between EReal and ℝ≥0∞ respect the operations. Note that the convention 0 * ∞ = 0
on ℝ≥0∞ is enforced by measure theory. Subtraction, defined as x - y = x + (-y), does not have
nice properties but is sometimes convenient to have.
There is also a CommMonoidWithZero structure on EReal, but Mathlib.Data.EReal.Basic only
provides MulZeroOneClass because a proof of associativity by hand would have 125 cases.
The CommMonoidWithZero instance is instead delivered in Mathlib.Data.EReal.Inv.
We define 0 * x = x * 0 = 0 for any x, with the other cases defined non-ambiguously.
This does not distribute with addition, as ⊥ = ⊥ + ⊤ = 1 * ⊥ + (-1) * ⊥ ≠ (1 - 1) * ⊥ = 0 * ⊥ = 0.
Distributivity x * (y + z) = x * y + x * z is recovered in the case where either 0 ≤ x < ⊤,
see EReal.left_distrib_of_nonneg_of_ne_top, or 0 ≤ y, z. See EReal.left_distrib_of_nonneg
(similarly for right distributivity).
","### Addition ","### Negation ","### Subtraction
Subtraction on EReal is defined by x - y = x + (-y). Since addition is badly behaved at some
points, so is subtraction. There is no standard algebraic typeclass involving subtraction that is
registered on EReal, beyond SubNegZeroMonoid, because of this bad behavior.
","### Addition and order ","### Multiplication "}