# Primes of the form $x^3+y^3+z^3 - 3xyz$

Do quadruplets $(x,y,z,p)$ of positive integers exist for which $p$ is a prime number and $$x^3+y^3+z^3 = 3xyz + p?$$ I've tried looking for solutions in mathematica for $x,y,z<1000$, without finding any. Unfortunately, looking at the equation $\mod 3$ or $\mod 9$ has yielded no result. Is there anyone who can help? Thanks.

EDIT: I just discovered a fatal flaw in my mathematica code. vrugtehagel rightfully pointed out that $8^3+8^3+7^3 - 3\cdot8\cdot8\cdot7 = 23$ is a valid solution to this problem.

• Your cubic factors. – Will Jagy Feb 24 '16 at 22:49
• $$x^3 + y^3 + z^3 - 3xyz = (x+y+z)(x^2 + y^2 + z^2 - yz - zx - xy).$$ The quadratic factor is positive semidefinite, we can write it as $r^2 + rs + s^2$ with $r=x-y, \; s = y-z.$ The quadratic could also be written as $$\left( (x-y)^2 + (y-z)^2 + (z-x)^2 \right) / 2$$ – Will Jagy Feb 24 '16 at 22:52
• Oh, primes $p = x^3 + 2 y^3 + 4 z^3 - 6xyz$ are much, much more interesting. Oh, and requiring the variables positive throws off everything. – Will Jagy Feb 24 '16 at 22:58
• It appears you've made a mistake in you code - $(x,y,z,p)=(8,7,8,23)$ is a solution – vrugtehagel Feb 24 '16 at 23:29
• There are infinite such solutions: if $p=3k-1$ then $(x,y,z)=(k,k-1,k)$. – S.C.B. Feb 24 '16 at 23:35

$${x}^{3}-3\,y\,z\,x+{z}^{3}+{y}^{3}=\left( x+z+y\right) \,\left( {x}^{2}-z\,x-y\,x+{z}^{2}-y\,z+{y}^{2}\right)$$

$${x}^{2}-z\,x-y\,x+{z}^{2}-y\,z+{y}^{2}=1$$

if x,y,z - consecutive terms in http://oeis.org/A004526

then $p=3\,n+1,p=3\,n+2$

We use the identity $$x^3 + y^3 + z^3 - 3xyz = (x+y+z)\left( \frac{ (x-y)^2 + (y-z)^2 + (z-x)^2 }{2}\right)$$ to try to find some solutions using linear and quadratic equations with the following system: $$\begin{cases}x+y+z=1\\(x-y)^2+(y-z)^2+(z-x)^2=2p\end{cases}$$ Putting $z=1-x-y$ one gets $$(x-y)^2 + (y-z)^2 + (z-x)^2=2(x^2+y^2+z^2)-2(xy+xz+yz)=2p\Rightarrow 3(x^2+y^2+xy-x-y)+1=p$$ We look for primes in the arithmetic progression $\{3n+1\}_{n\in \mathbb N}$ so we get the equation $$x^2+y^2+xy-x-y=n$$ and we look for integer points in ellipses.

We look at the six first primes $p=7,13,19,31,37,43$ of the form $3n+1$ corresponding to $n=2,4,6,10,12,14$ respectively. $$x^2+y^2+xy-x-y=2\qquad (*)$$
Solutions $(x,y)=(0,-1),(2,-1),(2,0)$ yield the solution $(x,y,z)=(2,-1,0)$ giving an example for $$x^3+y^3+z^3-xyz=7$$ $$x^2+y^2+xy-x-y=4\qquad (**)$$
Solutions $(x,y)= (1,\pm2),(2,-2)$ yield the solutions $(x,y,z)=(1,\pm 2,\mp 2),(2,-2,1)$ giving examples for $$x^3+y^3+z^3-xyz=13$$

$$x^2+y^2+xy-x-y=6\qquad (***)$$ Solutions $(x,y)=(0,-2),(3,-2),(3,0)$ leads to examples for $p=19$.

Similarly $$x^2+y^2+xy-x-y=10, 12, 14\qquad (****)$$ admit respectively the solutions $\{(-1,-2),(4,-2),(4,-1)\},\{(0,-3),(4,-3),(4,0)\}$ and $\{(2,-4),(3,-4),(3,2)$ which give solutions for $$x^3+y^3+z^3-xyz=31,37\space \text{and} \space 43$$ FINAL NOTE.- I wanted just to exhibit some examples of solutions like the case $p=23$ given by the O.P.(note that prime $23=3\cdot 7+2$ it is not of the form $3n+1$). However I add a question and a pertinent quote to finish.

►“It is very difficult to prove the non-existence of integer solutions of the general equation $$ax^3+by^3+cz^3-dxyz=0”\space \text{(L.J.Mordell)}$$

►Is there always solution for $x^3+y^3+z^3-xyz=p$ when $p=3n+1$? (for the first 6 examples of such primes, I have found without difficulty solutions).