# Left inverse

Given a function , it is useful to ask whether the effects of can be "undone". A reasonable way to define this is to provide an "undo" function such that for all . Such a function is called a left inverse of (so-called because you write it on the left of ):

Definition: Left inverse
Given a function , a left inverse of is a function satisfying .

If and then is a left inverse of , because

For the same reason, is a right inverse of .

However, is not a right inverse of (nor is a left inverse of ) because

Finally, if and , then and are two-sided inverses of each other, because

and