Let d=gcd(x,y). Then there exist a,b∈Z such that x=da, y=db, (a,b)=1. By substitution to the given equation we get:
da+dbda(db)3=a+bd3ab3=p.(1)
From (a,b)=1, we get (a,a+b)=1 and (b3,a+b)=1, giving from relation (1) that a+b∣d3. We write
a+bd3=k,(2)
where k is a positive integer. Then (1) becomes: kab3=p, and hence b3∣p. Therefore b=1 and ka=p. Hence we have the following cases:
(i) If k=p,a=1, then (2) becomes 2d3=p⇒2p=d3⇒2∣d. Hence 8∣d3 and 8∣2p, absurd.
(ii) If k=1,a=p. Then (2) becomes:
d3=p+1⇒d3−1=p⇒(d−1)(d2+d+1)=p.
Therefore, we get d−1=1, d2+d+1=p (since d2+d+1>d−1),
⇔d=2,p=7, and so: (x,y,p)=(14,2,7).