<s>[INST] If $a^3+a^2+a=9b^3+b^2+b$ and $a,b$ are integers then show $a-b$ is a perfect cube. If $a^3+a^2+a=9b^3+b^2+b$ and $a,b$ are integers then show $a-b$ is a perfect cube.
My attempt:I factorized it like below:
$(a-b)(a^2+b^2+ab+a+b+1)=8b^3=(2b)^3$
I take $gcd(a-b,a^2+b^2+ab+a+b+1)=d$
If $d=1$ then it is clear that $a-b$ is a perfect cube then consider $d>1$ then there is a $p$ that is prime and $p \mid d$.We have :
$p\mid a-b \Rightarrow p \mid (2b)^3 \Rightarrow p \mid 2b \Rightarrow p\mid 2$ or $p\mid b$
If $p\mid b$ then also $p\mid a$ (as $p\mid a-b$ holds). Then we will get to $p \mid 1$ because:
$ p \mid a^2+b^2+ab+a+b,p \mid a^2+b^2+ab+a+b+1 \Rightarrow p \mid 1$
which is clearly wrong then we have $p\mid 2$ so $p=2$ means $d=2^k$ where $k$ is a natural number including $0$.In the case $d=1$ we have the right result.So assemble $k \ge 1$.Because $2 \mid a-b$ we can conclude that $a,b$ have the same parity @Ghartal showed in his answer that if $a,b$ are both even we have a right result but if $a,b$ are both odd we don't.So maybe we have to prove $a,b$ can,t be both odd.
 [/INST] Let us consider the Diophantine equation
$$(a-b)(a^2+ab+b^2+a+b+1) = 8b^3.\tag1$$
Let $\ \gcd(a,b) = d.$
$\text{If }\mathbf {d > 1,}\text{ then }a=md,\quad b=nd,\quad \gcd(m,n) = 1,$
$$(m-n)\left((m^2+mn+n^2)d^2 + (m+n)d + 1\right) = 8d^2n^3.\tag2$$
${\text{If }\mathbf{2\mid d},\ \text{then}}$ 
$$2\mid m-n,\quad 2\nmid (m^2+mn+n^2)d^2 + (m+n)d + 1,$$
$$d\mid m-n,\quad \gcd(d, m^2+mn+n^2)d^2 + (m+n)d + 1) = 1,$$
so
$$m-n=\pm8d^2,\quad (m^2+mn+n^2)d^2 + (m+n)d + 1 = \pm n^3,$$
$$a-b = \pm8d^3 = (\pm2d)^3.$$
$\text{If }\mathbf {(d > 2)\wedge (d\nmid2),}\text{ then the case } (2\nmid m+n)\text{ contradicts with (2), so }$
$$2\nmid m,\quad 2\nmid n,\quad (m-n=\pm 2d^2) \vee (m-n = \pm4d^2),$$
$$\left[\begin{align}
&\begin{cases}
m = n\pm2d^2\\
4d^6 - 3d^2n(n\pm2d^2) + 2d(n\pm d^2) + 1 = \pm4n^3
\end{cases}\\
&\begin{cases}
m = n\pm4d^2\\
16d^6 - 3d^2n(n\pm4d^2) + 2d(n\pm2d^3) + 1 = \pm2n^3,
\end{cases}
\end{align}\right.$$
$$\left[\begin{align}
&\begin{cases}
m = n\pm2d^2\\
\mp4n^3 - 3d^2n^2 + 2d(1\mp3d^3)n + 4d^6 \pm2d^3  + 1 = 0
\end{cases}\\
&\begin{cases}
m = n\pm4d^2\\
\mp2n^3 - 3d^2n^2 + 2d(1\mp6d^2)n + 16d^6 \pm4d^3 + 1 = 0,
\end{cases}
\end{align}\right.$$
and both of systems leads to the same equation without solutions
$$d^2n^2+1\equiv0\pmod4.$$
$\text{If }\mathbf {d = 1,}\text{ then the proof of the previous case is valid. Solutions also do not.}$
Thus, the issue equation has the integer solutions only in the case $\mathbf{2\nmid \gcd(a,b)},$
when $\mathbf{a-b}\ $ is a perfect cube.
</s>