Decide if function is injective/surjective or/and invertible $x^2+1721x+1066$ Consider the function $f: \mathbb Z_{4711} \to \mathbb Z_{4711}, f(x)=x^2+1721x+1066$.
Is it injective, surjective or invertible?
Where do I start? It does not seem like you can factorise it. 1721 is a prime.
 A: Let $f$ be given by
$$
f(x)=x^2+1721x+1066
$$
regarded as a function from $\mathbb{Z}_{4711}$ to $\mathbb{Z}_{4711}$.

By definition, $f$ is injective if $f(x)=f(y)$ implies $x=y$.

Equivalently, in this context, $f$ is injective if $f(x)-f(y)=0$ implies $x-y=0$.

Thus it makes sense to analyze the expression $f(x)-f(y)$.

Identically we have
\begin{align*}
f(x)-f(y)
&=
(x^2+1721x+1066)-(y^2+1721y+1066)
\\[4pt]
&=
(x^2-y^2)+(1721x-1721y)
\\[4pt]
&=
(x+y)(x-y)+1721(x-y)
\\[4pt]
&=
(x-y)(x+y+1721)
\\[4pt]
\end{align*}
hence if we choose distinct $x,y\in\{0,...,4710\}$ such that
$$
x+y+1721=4711
$$
then $f(x)-f(y)$ will be zero in $\mathbb{Z}_{4711}$.

For example we can take $x=0,y=2990$.

It follows that $f$ is not injective.

By the pigeonhole principle, for nonempty finite sets $A,B$ with $|A|=|B|$, a function $g:A\to B$ is injective if and only if it is surjective.

Thus since $f:\mathbb{Z}_{4711}\to\mathbb{Z}_{4711}$ is not injective, it follows that $f$ is not surjective, hence $f$ is also not invertible.
A: $$f(x)=x^2+1721x+1066 \\ \Rightarrow x^2+(1721+4711)x+1066 
\\ \Rightarrow x^2+2(3216x)+3216^2-3216^2+1066 \\ \Rightarrow (x+3216)^2-3216^2+1066 \\ so\: f(4711-3216+1)=f(4711-3216-1) so\:f \:is\: not\: injective. \\ Since\: (\mathbb Z_{4711}\:\:\:is\:finite) \\ It\:is\:neither \:surjective\:nor\:invertible\:as\:well.$$
