Find all ordered pairs $(x, y)$ of positive integers such that:

$$
x^{3}+y^{3}=x^{2}+42 x y+y^{2} \text{.}
$$
Possible initial thoughts about this equation might include:
(i) I can factorise the sum of cubes on the left.
(ii) How can I use the 42?
(iii) The left is cubic and the right is quadratic, so if \(x\) or \(y\) is very large there will be no solutions.

The first two might lead us to rewrite the equation as \((x+y)\left(x^{2}-x y+y^{2}\right)=x^{2}-x y+y^{2}+43 x y\). The number \(43=42+1\) is prime which is good news since we have \((x+y-1)\left(x^{2}-x y+y^{2}\right)=43 x y\).

Now we can employ some wishful thinking: if \(x\) and \(y\) happen to be coprime, then \(\left(x^{2}-x y+y^{2}\right)\) has no factors in common with \(x\) or \(y\) so it must divide 43. This feels like a significant step except for the fact that \(x\) and \(y\) may not be coprime.

This suggests writing \(x=d X\) and \(y=d Y\) where \(d\) is the highest common factor of \(x\) and \(y\).
We end up with \((d X+d Y-1)\left(X^{2}-X Y+Y^{2}\right)=43 X Y\) so \(X^{2}-X Y+Y^{2}\) equals 1 or 43.
The first of these readily gives \(X=Y=1\). A neat way to deal with the second is to assume \(Y \leq X\) so \(43=X^{2}-X Y+Y^{2} \geq Y^{2}\). This gives six cases for \(Y\) which can be checked in turn. Alternatively you can solve \(X^{2}-X Y+Y^{2}=43\) for \(X\) and fuss about the discriminant.

In the end the only solutions turn out to be \((x, y)=(22,22),(1,7)\) or \((7,1)\).
Another reasonable initial plan is to bound \(x+y\) (using observation (iii) above) and then use modular arithmetic to eliminate cases until only the correct solutions remain. Working modulo 7 is particularly appealing since \(7 \mid 42\) and the only cubes modulo 7 are 0, 1, and -1.

We have \(x^{3}+y^{3}=(x+y)^{3}-3 x y(x+y)\) and also \(x^{2}+42 x y+y^{2}=(x+y)^{2}+40 x y\) so the equation becomes \((x+y)^{3}=(x+y)^{2}+x y(3 x y+40)\). Now using \(x y \leq\left(\frac{x+y}{2}\right)^{2}\) leads to \(x+y \leq 44\).

This leaves a mere 484 cases to check! The modulo 7 magic is not really enough to cut this down to an attractive number, and although the approach can obviously be made to work, to call it laborious is an understatement.

Other possible approaches, such as substituting \(u=x+y, v=x-y\), seem to lie somewhere between the two described above in terms of the amount of fortitude needed to pull them off.