<s>[INST] Finding the integer solutions Find all integer solutions of
$$(a + b^2)(a^2 + b) = (a − b)^3.$$
Obviously $b = 0$ is one. But how to get other solutions?
 [/INST] Here is one approach.
Expand both sides and equate terms, so we have:
$$(a + b^2)(a^2 + b) = (a - b)^3$$
$$a^{3} + a^{2}b^{2} + ab + b^{3} = a^{3} - 3a^{2}b + 3a b^2 - b^{3}$$
We can eliminate the $a^{3}$ terms, so we are left with:
$$2b^{3} + a^{2}b^{2} - 3ab^{2} + 3a^{2}b +ab = 0$$
Now, we have a Cubic in the form of:
$f(x) = jx^{3} + kx^{2} +lx + m = 0$, with $j = 2, k = a^{2}-3a, l = 3a^{2}+a$ and $m = 0$.
Using the solution for the cubic formula, we can arrive at the three roots:
$b = 0$
$b = (\frac{1}{4})(-a^{2} + 3a - \sqrt{a - 8}(a+1)\sqrt{a})$
$b = (\frac{1}{4})(-a^{2} + 3a + \sqrt{a - 8}(a+1)\sqrt{a})$
Now, you only want integer solutions, so, we see, by inspection, that at:
$a = -1, a = 0, a = 8, a = 9$, we get integers in $b$.
For $a = -1$, we have $b = -1$
For $a = 8$, we have $b = -10$
For $a = 0$, and $a = 9$, we have $b = 0$
Also note, for $b = 0$, the original equation reduces to, $a^{3} = a^{3}$, so you can also freely choose $a's$ (so you gets lots of integer solutions).
If you do an Implicit Plot using WA, you can see the $b = 0$ cases.
Regards
</s>