Unofficial archive — problems, solutions & results © IMC, reproduced with permission.

IMC / 2025 / Problems / Day 2, P10

IMC 2025 · Day 2 · P10

killer

For any positive integer NN, let SNS_N be the number of pairs of integers 1a,bN1 \le a, b \le N such that the number (a2+a)(b2+b)(a^2 + a)(b^2 + b) is a perfect square. Prove that the limit limNSNN\lim_{N \to \infty} \frac{S_N}{N} exists and find its value.

(proposed by Besfort Shala, University of Bristol)

Solution (official)

Throughout the solution, we use the Vinogradov notation ABA \ll B to mean A=O(B)A = O(B), which in turn means that there exists a constant C>0C > 0, independent of the quantities AA and BB, such that ACB|A| \le C |B|, on the entirety of the domain where AA and BB are defined (for us, this will always be the interval [1,)[1, \infty).)

We will show that the limit equals 1, corresponding to the trivial solutions a=ba = b. Note that (a2+a)(b2+b)(a^2 + a)(b^2 + b) is a perfect square if and only if a2+a=dz12a^2 + a = d z_1^2 and b2+b=dz22b^2 + b = d z_2^2 for some square-free dd and z1,z2Z>0z_1, z_2 \in \mathbb{Z}_{>0}. From this point on, all sums over dd will be over square-free positive integers. Multiplying the equations by 4 and setting yi=2ziy_i = 2 z_i, we get SN=dN2cd(N)2+O(1),S_N = \sum_{d \ll N^2} c_d(N)^2 + O(1), where cd(N)c_d(N) is the number of solutions to (2k+1)2dy2=1(2k + 1)^2 - d y^2 = 1 with 1kN1 \le k \le N and 1yN/21 \le y \le N/2 with yy even. Other than for the purpose of identifying the trivial solutions, we will work with Pell's equation x2dy2=1x^2 - d y^2 = 1 with 1x,yN1 \le x, y \ll N. Split the sum as dN2cd(N)1cd(N)+dN2cd(N)>1cd(N)2.\sum_{\substack{d \ll N^2 \\ c_d(N) \le 1}} c_d(N) + \sum_{\substack{d \ll N^2 \\ c_d(N) > 1}} c_d(N)^2. Note that if dNd \gg N, then the size of the second solution x2=x12+dy12x_2 = x_1^2 + d y_1^2 (coming from x2+y2d=(x1+y1d)2x_2 + y_2 \sqrt{d} = (x_1 + y_1 \sqrt{d})^2, where x1+y1dx_1 + y_1 \sqrt{d} is the fundamental solution) is dN\gg d \gg N. Hence we may assume that dNd \ll N if cd(N)>1c_d(N) > 1 (with a suitable choice of hidden constants). Denote the second sum by EE (for error, which we will bound momentarily). The first sum is easily manipulated into being asymptotic to NN (up to the error EE), using the fact that fixing x=2a+12N+1x = 2a + 1 \le 2N + 1 fixes the square-free dd and the square y2y^2, namely dN2cd(N)1cd(N)=dN21aN1yN/2χ(2a+1)2dy2=1+O(E)=a=1Nd,yχ(2a+1)21=dy2+O(E)=N+O(E).\sum_{\substack{d \ll N^2 \\ c_d(N) \le 1}} c_d(N) = \sum_{d \ll N^2} \sum_{\substack{1 \le a \le N \\ 1 \le y \le N/2}} \chi_{(2a+1)^2 - d y^2 = 1} + O(E) = \sum_{a=1}^{N} \sum_{d, y} \chi_{(2a+1)^2 - 1 = d y^2} + O(E) = N + O(E). Here χ\chi_\cdot denotes the characteristic function (taking the value 0 if \cdot is not satisfied, and 1 otherwise).

Now we bound the error sum EE. Note that solutions to Pell's equation x2dy2=1x^2 - d y^2 = 1 grow exponentially, hence we have cd(N)logNc_d(N) \ll \log N. This means we may assume that NdN1δN \gg d \gg N^{1-\delta} for some small enough fixed δ>0\delta > 0, since the contribution of dN1δd \ll N^{1-\delta} is bounded by N1δlogNN^{1-\delta} \log N. By x2dy2=1x^2 - d y^2 = 1, we have that dN1δd \gg N^{1-\delta} implies yN1/2+δy \ll N^{1/2 + \delta}.

Fixing each yNδ/2y \ll N^{\delta/2} gives N1δ\ll N^{1-\delta} choices for xx (hence also for dd). So we may assume N1/2+δyNδ/2N^{1/2+\delta} \gg y \gg N^{\delta/2}, since the contribution of yNδ/2y \ll N^{\delta/2} is bounded by N1δ/2N^{1-\delta/2}.

By placing xx in residue classes modulo y2y^2 and splitting the interval [1,2N+1][1, 2N+1] into intervals of length y2y^2, we get that each choice of Nδ/2yN1/2+δN^{\delta/2} \ll y \ll N^{1/2+\delta} gives Ng(y)/y2\ll N g(y) / y^2 choices for xx (hence also for dd) by y2x2+1y^2 \mid x^2 + 1, where g(y)={1xy2:x2+10(mody2)}g(y) = |\{ 1 \le x \le y^2 : x^2 + 1 \equiv 0 \pmod{y^2} \}|.

By elementary number theory, gg is multiplicative and g(pk)2g(p^k) \le 2 for all prime powers pkp^k. In particular we obtain g(n)τ(n)nεg(n) \le \tau(n) \ll n^\varepsilon for any ε>0\varepsilon > 0 (this is not hard to prove directly for gg, but may be used as a well-known fact for the divisor function τ\tau). Therefore the contribution of such yy is Nδ/2yN1/2+δNg(y)y2N1δ/2+ε,\ll \sum_{N^{\delta/2} \ll y \ll N^{1/2+\delta}} \frac{N g(y)}{y^2} \ll N^{1 - \delta/2 + \varepsilon}, which is acceptable by choosing ε>0\varepsilon > 0 small enough. We conclude that SN=N(1+o(1))S_N = N (1 + o(1)), as desired.

Remark. There is a secondary infinite family of solutions of “size” N\sqrt{N}, namely given by a=4b(b+1)a = 4b(b+1). This shows that lim supNSNNN>0.\limsup_{N \to \infty} \frac{S_N - N}{\sqrt{N}} > 0.

How the field did

contestants scored
425
average (of 10)
0.23
solved (≥ 80%)
1.4%
near-0 (≤ 10%)
96.0%
discrimination
0.32

Score distribution (field cohort)

Computed on contestants with a meaningful total (field cohort); discrimination is the corrected item–total correlation.

Similar problems

IMC 2018 · Day 2 · P10killeravg 0.3/10 · solved 1% · near-0 96% · disc 0.37
IMC 2012 · Day 1 · P5killeravg 0.5/10 · solved 2% · near-0 91% · disc 0.28
IMC 2001 · Day 1 · P4killeravg 0.3/10 · solved 2% · near-0 95% · disc 0.32
IMC 2019 · Day 1 · P4killeravg 0.4/10 · solved 2% · near-0 92% · disc 0.33