If $x^3+y^2$ and $x^2+y^3$ are integers, show that $x$, $y$ are integers

Let $x^3+y^2=a$ and $x^2+y^3=b$, where $a,b \in\mathbb Z$, then we have

$$(a-x^3)^3=(b-x^2)^2 \\ x^9-3ax^6+x^4+3a^2x^3-2bx^2-(a^3-b^2)=0$$

and

$$(a-y^2)^2=(b-y^3)^3\\ y^9-3by^6+y^4+3b^2y^3-2ay^2+(a^2-b^3)=0.$$

Then the Rational root theorem immediately tells us $x \mid a^3-b^2$ and $y \mid a^2-b^3$. This means $x,y\in\mathbb Z.$


Valuations to the rescue.

Hint: Assume that at least one of $x,y$ is not an integer. Let $p$ be a prime factor appearing in one of the denominators. Without loss of generality we can assume that $p$ appears in the denominator of $x$ to at least as high a power than in the denominator of $y$ (otherwise swap their roles in what follows). Show that this implies that $p^3$ is a factor of the denominator of $x^3+y^2$.


Suppose $x=a/d$ and $y=b/d$ with $d\gt0$ and $\gcd(a,b,d)=1$ (i.e., write $x$ and $y$ with the smallest possible common denominator). Then $x^2+y^3=m$ implies $b^3=(md^2-a^2)d$, which implies $d\mid b^3$. Likewise, $x^3+y^2=n$ implies $d\mid a^3$. Thus

$$0\lt d=\gcd(a^3,b^3,d)\le\gcd(a^3,b^3,d^3)=(\gcd(a,b,d))^3=1^3=1$$

hence $d=1$, and so $x$ and $y$ are integers.