TITLE: Freeness of a Z[x]-module
QUESTION [22 upvotes]: Definition: Call a mapping $f: \mathbb{Z} \rightarrow \mathbb{Z}$
a generalized polynomial if for any distinct integers $m$ and $n$
we have $(m - n)|(f(m)-f(n))$.
It is easy to check that polynomial functions $f \in \mathbb{Z}[x]$ are
generalized polynomials, that not all generalized polynomials are polynomials
and that the generalized polynomials form a ring under pointwise addition and
multiplication. Call the latter ring $R$.

Question: Is $R$, viewed as a $\mathbb{Z}[x]$-module, free? 
  And if yes, how does a basis look like?

REPLY [3 votes]: I posted a bunch of comments here, but I thought it would be better to write an answer, instead.
First, I've written up a lot about these functions, and functions with the same condition on  sets $S\subseteq \mathbb Z$. 
If you define $$q_k(x) =  \frac{\operatorname{lcm}(1,2,\dots,k)}{k!}\left(x+ \left\lfloor {\frac{k-1}{2}} \right\rfloor\right)_k$$ then these are rational polynomials in $R$ and they have the property that, for all $n\in\mathbb Z$, $q_k(n)\neq 0$ for only finitely many $k$. So given any infinite sequence $(a_k)_{k\in\mathbb N}$ of integers, we get a unique $f\in R$ defined by:
$$f(n)=\sum_{k} a_kq_k(n)$$
A little harder to prove, but not really hard, is that every $f\in R$ is expressed in this form. Essentially, you find $a_k$ by induction.
This gives an explicit abelian group isomorphism between $R$ and $\mathbb Z^{\mathbb N}\cong\mathbb Z^{\mathbb Z}$.
The proof is essentially using Chinese remainder there inductively to determine $a_k$, to match the values of $f(0),f(1),f(-1),f(2),f(-2),\dots.$ This is why you get the term $\operatorname{lcm}(1,2,\dots,k)$.
This also helps show that $R\cap \mathbb Q[x]$ has the $q_k$ as $\mathbb Z$-generators. Given a polynomial $q(x)\in Q[x]\cap R$ is of degree $d$, if $q(n)=\sum_{k\in N} a_k q_k(n)$ then $p(n)=\sum_{k=0}^{d} a_kq_k(n)$ is another polynomial of degree $d$ which agrees at $d+1$ values, so must agree everywhere.
Side note: $R$ is actually an integral domain, not just a ring. If $f\in R$, then $f$ can be zero only for finitely many values, so $fg=0$ implies $f=0$ or $g=0$. 
Using $R'=\left\{f:\mathbb N\to \mathbb Z\mid \forall n,m: n-m\mid f(n)-f(m)\right\}$, there is a natural ring homomorphism $R\to R'$ be sending $f\in R$ to $f_{\mid\mathbb N}\in R'$. This is $1-1$ since if $f_{\mid\mathbb N} =0$, then $f$ has infinitely many zeros. The map is not onto - it is possible to define $f\in R'$ such that you can't even extend $f$ to $-1$ and keep the divisibliity property.