TITLE: One-sided inverse of a function
QUESTION [6 upvotes]: Is it possible to find an example of an one-sided inverse of a function?  other than matrix?
I am trying to find such an example but having no luck. Anybody got an idea about it?

REPLY [4 votes]: Another classical example is the shift maps. Let $S$ be the space of real sequences $S = \{(a_0,a_1,a_2,\dots) : a_i\in\mathbb{R} \, \text{for all $i$}\}$ (which, essentially, is the space of functions $\mathbb{N}\to\mathbb{R}$).
Define the "left shift map" $f:S\to S$ as
$$
f((a_0,a_1,a_2,a_3,\dots)) = (a_1,a_2,a_3,\dots)
$$
(i.e., remove the first element from the sequence), and the "right shift map" $g:S\to S$ as
$$
g((a_0,a_1,a_2,\dots)) = (0,a_0,a_1,a_2,\dots)
$$
(i.e., add a zero at the beginning of the sequence).
Then, $f\circ g$ is the identity, but $g\circ f$ is not.