Subtraction-free identities that hold for rings but not for semirings

noncommutative-algebranoncommutative-ringsrational-functionssemirings

Here is a concrete, if seemingly unmotivated, aspect of the question I am interested in:

Question 1. Let $a$ and $b$ be two elements of a (noncommutative) semiring $R$ such that $1+a^3$ and $1+b^3$ and $\left(1+b\right)\left(1+a\right)$ are invertible. Does it follow that $1+a$ and $1+b$ are invertible as well?

The answer to this question is

  • "yes" if $ab=ba$ (because in this case, $1+a$ is a left and right divisor of the invertible element $\left(1+b\right)\left(1+a\right)$, and thus must itself be invertible; likewise for $1+b$).

  • "yes" if $R$ is a ring (because in this case, $1+a$ is a left and right divisor of the invertible element $1+a^3 = \left(1+a\right)\left(1-a+a^2\right) = \left(1-a+a^2\right)\left(1+a\right)$, and thus must itself be invertible; likewise for $1+b$).

  • "yes" if $1+a$ is right-cancellable (because in this case, we can cancel $1+a$ from $\left(1+a\right) \left(\left(1+b\right)\left(1+a\right)\right)^{-1} \left(\left(1+b\right)\left(1+a\right)\right) = 1+a$ to obtain $\left(1+a\right) \left(\left(1+b\right)\left(1+a\right)\right)^{-1} \left(1+b\right) = 1$, which shows that $1+a$ is invertible), and likewise if $1+b$ is left-cancellable.

I am struggling to find semirings that are sufficiently perverse to satisfy none of these cases and yet have $\left(1+b\right)\left(1+a\right)$ invertible. (It is easy to find cases where $1+a^3$ is invertible but $1+a$ is not; e.g., take $a = \begin{pmatrix} 0&1\\ 0&0 \end{pmatrix}$ in the matrix semiring $\mathbb{N}^{2\times 2}$.)

The real question I'm trying to answer is the following (some hopefully reasonably clear handwaving included):

Question 2. Assume we are given an identity that involves only positive integers, addition, multiplication and taking reciprocals. For example, the identity can be $\left(a^{-1} + b^{-1}\right)^{-1} = a \left(a+b\right)^{-1} b$ or the positive Woodbury identity $\left(a+ucv\right)^{-1} + a^{-1}u \left(c^{-1} + va^{-1}u\right)^{-1} va^{-1} = a^{-1}$. Assume that this identity always holds when the variables are specialized to arbitrary elements of an arbitrary ring, assuming that all reciprocals appearing in it are well-defined. Is it then true that this identity also holds when the variables are specialized to arbitrary elements of an arbitrary semiring, assuming that all reciprocals appearing in it are well-defined?

There is a natural case for "yes": After all, the same claim holds for commutative semirings, because in this case, it is possible to get rid of all reciprocals in the identity by bringing all fractions to a common denominator and then cross-multiplying with these denominators. However, this strategy doesn't work for noncommutative semirings (and even simple-looking equalities of the form $ab^{-1} = cd^{-1}$ cannot be brought to a reciprocal-free form, if I am not mistaken). Question 1 is the instance of Question 2 for the identity
\begin{align}
\left(1+a^3\right)^{-1} \left(1+b^3\right)^{-1} \left(1+a\right) \left(\left(1+b\right)\left(1+a\right)\right)^{-1} \left(1+b\right) = \left(1+a^3\right)^{-1} \left(1+b^3\right)^{-1}
\end{align}

(where, of course, the only purpose of the $\left(1+a^3\right)^{-1} \left(1+b^3\right)^{-1}$ factors is to require the invertibility of $1+a^3$ and $1+b^3$). Indeed, if $\alpha$ and $\beta$ are two elements of a monoid such that $\beta\alpha$ is invertible, then we have the chain of equivalences
\begin{align}
\left(\alpha\text{ is invertible} \right)
\iff
\left(\beta\text{ is invertible} \right)
\iff
\left( \alpha \left(\beta\alpha\right)^{-1} \beta = 1 \right)
\end{align}

(easy exercise).

Best Answer

Tim Campion's idea works, though his example needs a little fixing. As in Tim's answer, we will find a rig with two elements $X$ and $Y$ such that $X+Y=1$ but $XY \neq YX$.

Let $(M,+,0)$ be any commutative monoid. Let $R$ be the set of endomorphisms of $M$ obeying $\phi(x+y)=\phi(x)+\phi(y)$ and $\phi(0)=0$. Then $R$ is a rig, with $(\alpha+\beta)(x) = \alpha(x) + \beta(x)$ and $(\alpha \beta)(x) = \alpha(\beta(x))$.

Let $M$ be $\{ 0,1,2 \}$ with $x+y \mathrel{:=} \max(x,y)$. Define \begin{gather*} \alpha(0) = 0,\ \alpha(1) = 0,\ \alpha(2) = 2 \\ \beta(0) = 0,\ \beta(1) = 1,\ \beta(2) = 1. \end{gather*} Then $\alpha+\beta=\mathrm{Id}$ but $\alpha \beta \neq \beta \alpha$.

Related Question