$f(x, y) = x - y$ - Injective? Given the following function on $\mathbb{Z}$:
$x,y \in \mathbb{Z}: f(x, y) = x - y$
As I understand, this function is surjective, i.e. each element of $\mathbb{Z}$ is the image of at least one element of $A$*. 
But, I'm not sure if it's injective, i.e. each output is the image of no more than one input*, since:
$f(10,5) = 5$ and $f(5,0) = 5$.
Since $f$ returns $5$ for each function, is it not injective? Or, do the inputs $(10,5) \rightarrow 5$ and $(5,0) \rightarrow 5$, i.e. constitute separate inputs?
*source of definitions: "A Book of Abstract Algebra"
 A: It is not injective as a function $\mathbb Z\times\mathbb Z\to\mathbb Z$, because (as you observe) $(10,5)$ and $(5,0)$ are two elements of $\mathbb Z\times\mathbb Z$ that both map to $5$.
However, if you fix $x$, then the function $y\mapsto x-y$ is injective as a function $\mathbb Z\to\mathbb Z$. And similarly, if you fix $y$, the function $x\mapsto x-y$ is injective.
A: $f$ is a linear function from $ \mathbf Z^2$ to $\mathbf Z$, and it isn't injective: its kernel, as a linear map, is:
$$ \Delta=\{(x,x)\mid x\in \mathbf Z\}\subset  \mathbf Z^2. $$
The kernel of a linear map $f$ is the set of elements that map to $0$. In vector spaces, it is a subspace of the source vector space. For abelian groups as here, it is a subgroup of the source group. 
It is important for injectivity of linear maps, because it gives a criterion to know if such a map is or is not injective: instead of proving, say, that for any $u,v$, $\,f(u)=f(v) \Rightarrow u=v$, it amounts to the same to prove $f(u)=0\Rightarrow u=0$.
In other words, a linear map $f$ is injective if and only if $\,\ker f=0$.
A: Let $f: (x, y) \mapsto x-y$ on $\mathbb{Z}^{2}$ in $\mathbb{Z}$ and let $z \in \mathbb{Z}$. If $(x, y) \in \mathbb{Z}^{2}$, then $z = f(x, y) = x-y$ if and only if 
$$z = (x+k) - (y+k)$$
for all $k \in \mathbb{Z}$.
Thus given any $z \in \mathbb{Z}$, there are infinitely many $(x, y) \in \mathbb{Z}^{2}$ such that $z = f(x,y),$ which shows that $f$ is not injective.
