IMO 1988 · Problem 6

Let \(a\) and \(b\) be positive integers such that \(ab+1\) divides \(a^2+b^2\). Show that \[ \frac{a^2+b^2}{ab+1} \] is the square of an integer.

Official text of the problem. Official problem paper (PDF)

Solution

Set \[ k=\frac{a^2+b^2}{ab+1}. \] Then \(k\) is a positive integer. Among all pairs of positive integers \((x,y)\) satisfying \[ x^2+y^2=k(xy+1), \] choose one for which \(x+y\) is smallest. Such a pair exists because \((a,b)\) is one. By symmetry, assume \(x\ge y\).

Define the integer \[ z=ky-x. \] The defining equation gives \[ xz=kxy-x^2=y^2-k. \] Consequently, \[ y^2+z^2-k(yz+1) =y^2-k+z(z-ky) =y^2-k-xz=0. \] Thus \[ y^2+z^2=k(yz+1). \tag{1} \]

We first show that \(z\ge0\). If \(z<0\), its integrality implies \(z\le-1\). Since \(y\ge1\), we would have \(yz+1\le0\). The right-hand side of (1) would then be nonpositive, whereas its left-hand side is positive. This is impossible.

Moreover, because \(k>0\) and \(x\ge y>0\), \[ z=\frac{y^2-k}{x}<\frac{y^2}{x}\le y\le x. \] If \(z>0\), equation (1) would therefore provide another pair of positive integers \((y,z)\) satisfying the same equation, with \[ y+z<y+x. \] This contradicts the minimality of \(x+y\).

Hence \(z=0\). Equation (1) now yields \(y^2=k\). Therefore \[ \frac{a^2+b^2}{ab+1}=y^2, \] which is the square of an integer. \(\square\)

The solution was checked against John Scholes' IMO solution archive (Kalva).