Let $\mathbb{Z}$ be the set of all integers and $a,b,c$ rational numbers.Define$f:\mathbb{Z}\mapsto \mathbb{Z}$by $f(s)=as^{2}+bs+c$.Find necessary and sufficient conditions on $a,b,c,$ so that $f$ defines a mapping on $\mathbb{Z}$.
When I define $a,b,c$ are integers then the map is well defined. When I define $a=b=\frac{1}{2}$ then also $f(s)\in \mathbb{Z}$ . How to find the other possibilities? Please help me.
Substituting $s=0$ we see that $c$ has to be an integer. So, we may ignore $c$ henceforth. Taking $s=1$, we see that $$a+b\in\mathbb{Z},$$ and taking $s=2$, $$4a+2b\in\mathbb{Z}.$$ This should be enough to convince yourself that you have found all the solutions.