MathLabs

Problem 2

For a polynomial PP and a positive integer nn, define PnP_n as the number of positive integer pairs (a,b)(a,b) such that a<b≤na<b\le n and ∣P(a)∣−∣P(b)∣|P(a)|-|P(b)| is divisible by nn. Determine all polynomials PP with integer coefficients such that Pn≤2021P_n\le2021 for all positive integers nn.
Step 6 of 6: Count the exact solutions and match the bound; the case c=-1 mirrors it
sup⁡nPn=max⁡(−d−1,0) ≤2021  ⟺  d≥−2022\sup_n P_n = \max(-d-1,0)\ \le 2021 \iff d\ge-2022
Detailed analysis

For d≥0d\ge0 no pair satisfies a+b=2m=−2da+b=2m=-2d (as m≤0m\le0), so Pn=0P_n=0 for all nn. For d=−m<0d=-m<0, the pairs with a<b≤na<b\le n, a+b=2ma+b=2m, a<m≤ba<m\le b number exactly min⁡(m−1, n−m)\min(m-1,\,n-m) when this is nonnegative, which equals m−1m-1 once n≥2m−1n\ge2m-1; so sup⁡nPn=m−1\sup_nP_n=m-1. Requiring m−1≤2021m-1\le2021 gives m≤2022m\le2022, i.e. d≥−2022d\ge-2022, and this bound is also sufficient. Replacing PP by −P-P leaves every PnP_n unchanged (since ∣−P∣=∣P∣|{-P}|=|P|), so the family P(x)=−x+dP(x)=-x+d works exactly when −d≥−2022-d\ge-2022, i.e. d≤2022d\le2022, completing the classification.