We actually don't need to do any computation. By definition, the inverse function changes the role of input and output. So, if a function f maps x onto y, the inverse function maps y onto x.
You have to think like this: if the function makes a step further, the inverse function makes that same step back.
This means that the composition is always the identity function . In fact,
So, for every function, you have