Suppose $f$ is an injection. Show that $f^{-1}\circ f(x)=x$ for all $x\in D(f)$ and $f\circ f^{-1}(y)=y$ for all $y$ in $R(f)$.
In $f^{-1}$ it is defined as "Let $f$ be a one-one function with domain $D(f)$ in $A$ and range $R(f)$ in $B$. If $g=\{(b,a)\in B×A:(a,b)\in f\}$ then $g$ is a one-one function with domain $D(g)=R(f)$ in $B$ and with range $R(g)=D(f)$ in $A$. The function $g$ is called the function inverse to $f$."
I know that for it to be an injection the domain of $f$ maps into distinct elements of $y$, but where I am having trouble understanding and proving this is that, what does this $f^{-1}\circ f(x)=x$ mean? the $=x$ threw me off because what is $x$ in this case, could it have been an $x+3$ or $x^2$ instead of $x$?
Is proving this as easy as just showing that since it is injective then if $f(x_1)=f(x_2)$ $\implies$ $f^{-1}\circ f(x_1)=x_1=f^{-1}\circ f(x_2)=x_2$