# prove: coefficients of $f(x)$ are rational numbers

$f(x)$ is polynomial with complex coefficients. $\forall n\in Z$, $f(n)$is integer, prove: coefficients of $f(x)$ are rational numbers, and give some examples about rational case.

### Prove:

• consider coefficients are integers, of course $f(n)$ are integers.

• consider coefficients are rationals, we have $f(x)=\frac{1}{2}x(x+1)$, two consecutive integer can be divided by $2$, there must be one even number.

• real coeffs

• complex coeffs

And can you give me some more examples?

Let $f(x)=a_nx^n+\cdots+a_1x+a_0$. Since $f(n)$ is integer if $n$ is integer, so $f(0),f(1),\cdots,f(n)$ are integers. Let we consider the system of linear equations $$\begin{bmatrix} 1&0&0^2&\cdots&0^n\\ 1&1&1^2&\cdots&1^n\\ 1&2&2^2&\cdots&2^n\\ \vdots&\vdots&\vdots&\ddots&\vdots\\ 1&n&n^2&\cdots&n^n \end{bmatrix} \begin{bmatrix} a_0\\ a_1\\ a_2\\ \vdots\\ a_n \end{bmatrix}= \begin{bmatrix} f(0)\\ f(1)\\ f(2)\\ \vdots\\ f(n) \end{bmatrix}.$$

We can easily check that the components of the given matrix and the vector on the right side are integer. Especially, the matrix given the right side is invertible (It is a Vandermonde matrix.) and the components of inverse of the given matrix are rational number. So $a_k$ is a rational number for $k=0,1,\cdots, n$.

Consider the polynomial $X\choose n$ defined by $${X\choose n} = \frac{X(X-1)\ldots (X-n+1)}{n!}$$ Then one can say the following : A polynomial $P$ takes $\mathbb{Z}$ to $\mathbb{Z}$ iff $$P(X) = a_0 + a_1 {X\choose 1} + a_2 {X\choose 2} + \ldots + a_n {X\choose n}$$ for some $a_i \in \mathbb{Z}, 1\leq i\leq n$

Proof : Sufficiency is obvious.

Now for necessity, note that any polynomial can be written in this form for some possibly non-integral $a_i$'s. Now if $P$ maps $\mathbb{Z}$ to $\mathbb{Z}$ $$P(0) = a_0 \in \mathbb{Z}$$ $$P(1) = a_0 + a_1 \in \mathbb{Z} \Rightarrow a_1 \in \mathbb{Z}$$ $$P(2) = a_0 + a_1{2\choose 1} + a_2 \in \mathbb{Z} \Rightarrow a_2 \in \mathbb{Z}$$ Inductively, $a_i \in \mathbb{Z}$ for all $i$.

In particular, this proves what you want.

Here is a different approach by Lagrange Interpolation. Let $\mathcal{A}=\{a_1,a_2,\ldots,a_n\}$ be values such that $f(a_i)\in\mathbf{Z}$ for $a_i\in\mathcal{A}$. Let $f(a_i)=k_i$, $1\le i\le n$. Now, consider the polynomial defined by $$g(x)=f(x)+\sum_{i=1}^{n}\frac{(x-a_1)(x-a_2)\cdots(x-a_{i-1})(x-a_{i+1})\cdots(x-a_n)}{(a_i-a_1)(a_i-a_2)\cdots(a_i-a_n)}(-k_i).$$ Clearly $g(a_1)=g(a_2)=\cdots = g(a_n)=0$, so $g$ has roots everywhere in $\mathcal{A}$. Thus, we can write $g$ as $$g(x)=c(x-a_1)(x-a_2)\cdots (x-a_n).$$ Now, consider $g(a_{n+1})$. Then, $f(a_{n+1})\in\mathbf{Z}$ and $$\sum_{i=1}^{n}\frac{(a_{n+1}-a_1)(a_{n+1}-a_2)\cdots(a_{n+1}-a_{i-1})(a_{n+1}-a_{i+1})\cdots(a_{n+1}-a_n)}{(a_i-a_1)(a_i-a_2)\cdots(a_i-a_n)}(-k_i)\in\mathbf{Q}.$$ It follows, due to how we defined $g$ and closure of $\mathbf{Q}$ over addition, that $g(a_{n+1})\in\mathbf{Q}$. Then, we have $$g(a_{n+1})=c\prod_{i=1}^{n}(a_{n+1}-a_i)\in\mathbf{Q},$$ so be closure of $\mathbf{Q}$ under multiplication we know that $c\in\mathbf{Q}$. The value of $c$ is invariant to the value $g$ takes, so it follows that $g(x)\in\mathbf{Q}[x]$, and so $f(x)\in\mathbf{Q}[x]$ as well.