"Localizing" commutative pointed monoids A pointed monoid is a commutative monoid $A$ with a distinguished element $0\in A$ such that $0\cdot A=0$.  Morphisms should preserve $0$.
If $A$ is a commutative ring or pointed monoid, and $f\in A$, there is a localization $A\to A_f$ that is initial with respect to the following property: every map $\phi:A_f\to B$ into a nontrivial ring/pointed monoid $B$ has $\phi(f)\neq 0$.
For both rings and monoids, we get this localization by formally adjoining $f^{-1}$.
What if we have two elements, $f,g\in A$, and we want to study maps $\varphi: A\to B$ into a nontrivial objects $B$ such that $\varphi(f)\neq\varphi(g)$?  Is there a localization $A_{(f,g)}$ with a similar universal property?
For rings, the answer is clear: we can define $A_{(f,g)} = A_{f-g}$.  But is there a more complicated construction that works for monoids?
For example, if $fh=gh$ in $A$, then $h$ should most likely be nilpotent in $A_{f,g}$.
 A: Let me first explicitly state the universal property we're looking for.  Let us say a pointed commutative monoid is a field if $1\neq 0$ and every nonzero element is a unit.  Let $\mathcal{C}$ denote the category of pointed commutative monoids $A$ equipped with two chosen elements $f$ and $g$, and let $\mathcal{D}\subset\mathcal{C}$ be the full subcategory of such objects such that every homomorphism from $A$ to a field separates $f$ and $g$ (call such an object of $\mathcal{C}$ separative).  The question is then whether $\mathcal{D}$ is a reflective subcategory of $\mathcal{C}$.  That is, given an object $A$ of $\mathcal{C}$, is there a map $A\to B$ from $A$ to a separative object which is initial among all maps from $A$ to a separative object?
Before answering the question, let's discuss some general facts about pointed commutative monoids.  Given a pointed commutative monoid $A$ and an element $f\in A$, the localization $A_f$ can be constructed explicitly as the set of fractions $a/f^n$ modulo the equivalence relation $a/f^n=b/f^m$ if $f^{N+m}a=f^{N+n}b$ for some $N$.  In particular, $a\in A$ maps to $0$ in $A_f$ iff it is annihilated by some power of $f$.  In addition, note that there is an obvious notion of "maximal ideal" in a pointed commutative monoid, and modding out a maximal ideal gives a field.  In fact, in contrast with the case of commutative rings, every pointed commutative monoid in which $1\neq 0$ has a unique maximal ideal, consisting of all the non-units.  In particular, any pointed commutative monoid with $1\neq 0$ has a map to a field.  Furthermore, there is a terminal field $T=\{0,1\}$: every field has a unique homomorphism to $T$ sending every nonzero element to $1$.
Now suppose we have an object $A$ of $\mathcal{C}$ such that $fg$ is not nilpotent.  We can then form the localization $A_{fg}$, and $1\neq 0$ in this localization.  Modding out the maximal ideal and taking the unique map to $T$, we get a map $A\to T$ which sends both $f$ and $g$ to $1$.  Thus if $A$ is separative, $fg$ must be nilpotent.
On the other hand, if the ideal generated by $f$ and $g$ is not all of $A$, we can mod out the maximal ideal and get a map from $A$ to a field sending both $f$ and $g$ to $0$.  Thus if $A$ is separative, the ideal $(f,g)$ must be all of $A$.  But that ideal is just the set of all elements of $A$ that are multiples of either $f$ or $g$, so this means $f$ or $g$ must be a unit.  The condition that $fg$ is nilpotent now means that the other of $f$ and $g$ must be nilpotent.
Thus we have shown that if $A$ is separative, one of $f$ and $g$ must be a unit and the other must be nilpotent.  Conversely, if one of $f$ and $g$ is a unit and the other is nilpotent, any map from $A$ to a field sends one of them to $0$ and the other to a unit, so $A$ is separative.  So $\mathcal{D}$ consists exactly of those objects of $\mathcal{C}$ such that one of $f$ and $g$ is a unit and the other is nilpotent.  Say that an object of $\mathcal{D}$ is type I if $f$ is a unit and type II if $g$ is a unit.  Note that the only object that is both types at once is the zero monoid $A=\{0\}$, and that there can exist no maps in $\mathcal{D}$ between nonzero objects of different type.
We are now ready to answer the question.  Taking $A$ to be the initial object of $\mathcal{C}$ (concretely, $A=\mathbb{N}^2\cup\{0\}$, with $f=(1,0)$ and $g=(0,1)$), if such a reflector existed, it would have to send $A$ to the initial object of $\mathcal{D}$.  But an initial object of $\mathcal{D}$ would have to be able to map to nonzero objects of both types, and no such object exists.
More generally, if $A$ is any object of $\mathcal{C}$ such that $g$ does not divide any power of $f$ and $f$ does not divide any power of $g$, then $g$ is not a unit in $A_f$ and $f$ is not a unit in $A_g$, so $A$ can map to nonzero separative objects of both types (namely, $A_f/(g)$ is type I and $A_g/(f)$ is type II).  So no such object of $\mathcal{C}$ can have a separative reflection.  On the other hand, if $f$ divides a power of $g$, then $A$ can only map to type I separative objects, so $A$ has a separative reflection iff there is a minimal quotient of $A_f$ in which $g$ becomes nilpotent.  Such a minimal quotient exists iff there is an $n\in\mathbb{N}$ such that $g^{n+1}$ divides $g^n$ in $A_f$, in which case the minimal quotient is $A_f/(g^n)$ for any such $n$.
To sum up, we can say that an object $A$ of $\mathcal{C}$ has a reflection in $\mathcal{D}$ iff either of the following two conditions holds:


*

*There exists $n\in\mathbb{N}$ such that $f$ divides $g^n$ and $(fg)^n g$ divides $(fg)^n$.

*There exists $n\in\mathbb{N}$ such that $g$ divides $f^n$ and $(fg)^n f$ divides $(fg)^n$.


In the first case, the reflection is $A_f/(g^n)$, and in the second case, the reflection is $A_g/(f^n)$.
