I'm solving an exercise in Artin that asks for a proof that that an element $a$ can have either a left or right inverse, but not be invertible. The problem comes before he has defined the notion of a group, so it seems that I only need a well-defined law of composition and an identity element, so I'm trying to confine myself to the simple case of a monoid.
For one case, I took his example in exercise 1.3 of the shift map $s(n) = n + 1$ where $n \in \mathbb{N}$. This map can be shown to have a left inverse, but no right inverse. It is not clear, however, what this $s$ is an element of. Sets of functions from $\mathbb{N} \to \mathbb{N}$? Without being able to describe the monoid, it doesn't seem obvious to me that I can call $s$ an "element."
I tried a similar mapping $t(n) = n - 1$ to try to find one with a right inverse, but no left inverse. It took me a while to realize that the map isn't even defined when $n = 0$, so I have to restrict the domain to exclude $1$, but that seems to have the effect of preventing me from proving the absence of a left inverse.
Some thoughts on this would be greatly appreciated.
SLIGHT EDIT:
How is this example for the shift map?
We define the monoid to be the set of functions from $\mathbb{N} \to \mathbb{N}$. The law of composition is composition of functions. If we compose two functions that map from $\mathbb{N}$ to $\mathbb{N}$, the result is another function that maps from $\mathbb{N}$ to $\mathbb{N}$, so the composition is closed. The identity element is the identity map $i: \mathbb{N} \to \mathbb{N}, n \mapsto n$. The shift map is one example of a map that has a left inverse, but no right inverse.