We transform the problem to a single variable question by the following
Lemma. Let a1,…,an be nonnegative integers and let G(x) be a nonzero polynomial with degG⩽a1+…+an. Suppose that some polynomial F(x1,…,xn) satisfies
F(x1,…,xn)=G(x1+…+xn) for (x1,…,xn)∈{0,1,…,a1}×…×{0,1,…,an}.
Then F cannot be the zero polynomial, and degF⩾degG.
For proving the lemma, we will use forward differences of polynomials. If p(x) is a polynomial with a single variable, then define (Δp)(x)=p(x+1)−p(x). It is well-known that if p is a nonconstant polynomial then degΔp=degp−1.
If p(x1,…,xn) is a polynomial with n variables and 1⩽k⩽n then let
(Δkp)(x1,…,xn)=p(x1,…,xk−1,xk+1,xk+1,…,xn)−p(x1,…,xn)
It is also well-known that either Δkp is the zero polynomial or deg(Δkp)⩽degp−1.
Proof of the lemma. We apply induction on the degree of G. If G is a constant polynomial then we have F(0,…,0)=G(0)=0, so F cannot be the zero polynomial.
Suppose that degG⩾1 and the lemma holds true for lower degrees. Since a1+…+an⩾degG>0, at least one of a1,…,an is positive; without loss of generality suppose a1⩾1.
Consider the polynomials F1=Δ1F and G1=ΔG. On the grid {0,…,a1−1}×{0,…,a2}×…×{0,…,an} we have
F1(x1,…,xn)=F(x1+1,x2,…,xn)−F(x1,x2,…,xn)==G(x1+…+xn+1)−G(x1+…+xn)=G1(x1+…+xn)
Since G is nonconstant, we have degG1=degG−1⩽(a1−1)+a2+…+an. Therefore we can apply the induction hypothesis to F1 and G1 and conclude that F1 is not the zero polynomial and degF1⩾degG1. Hence, degF⩾degF1+1⩾degG1+1=degG. That finishes the proof.
To prove the problem statement, take the unique polynomial g(x) so that g(x)=⌊mx⌋ for x∈{0,1,…,n(m−1)} and degg⩽n(m−1). Notice that precisely n(m−1)+1 values of g are prescribed, so g(x) indeed exists and is unique. Notice further that the constraints g(0)=g(1)=0 and g(m)=1 together enforce degg⩾2.
By applying the lemma to a1=…=an=m−1 and the polynomials f and g, we achieve degf⩾degg. Hence we just need a suitable lower bound on degg.
Consider the polynomial h(x)=g(x+m)−g(x)−1. The degree of g(x+m)−g(x) is degg−1⩾1, so degh=degg−1⩾1, and therefore h cannot be the zero polynomial. On the other hand, h vanishes at the points 0,1,…,n(m−1)−m, so h has at least (n−1)(m−1) roots. Hence,
degf⩾degg=degh+1⩾(n−1)(m−1)+1⩾n