If $p,q,r$ are distinct primes such that $pI was solving another question, and was unable to solve the case written above. The question is as follows:

If $p,q,r$ are distinct primes such that
$$\frac{p^{3}+q^{3}+r^{3}}{p+q+r}=249$$then find all possible values of r

On using the identity $x^{3}+y^{3}+z^{3}-3xyz=(x+y+z)(x^{2}+y^{2}+z^{2}-xy-yz-xz)$, one can reduce the above question to the following, 

Find all distinct primes $p,q,r$ such that
$$p+q+r|pqr$$

We have four cases for the following:

*

*$p+q+r=pqr$

*$p+q+r=qr$

*$p+q+r=pr$

*$p+q+r=pq$

I concluded that no solutions exist for the first three cases by assuming W.L.O.G, $p<q<r$. However, I am unable to do the same for the last case.
I request somebody to please provide a solution for this case or an alternate solution for the main question itself. Any help is much appreciated. Thanks a lot :) 
 A: As mentioned in the comments, there are many solutions to $p+q+r = pq$. In particular, this can be rearranged to $r + 1 = (p-1)(q-1)$, so it is not unlikely to generate a pair $(p,q)$ from a prime $r$. In light of this, we should return the the given relation directly. WLOG suppose $p < q < r$. Then
$$249 = \frac {p^3+q^3+r^3}{p+q+r} > \frac {r^3}{3r} = \frac {r^2}{3}$$
This gives an upper bound: $r < \sqrt{744} < 28$. Hence $p<q<r\le23$.
Initially I listed the remainder of the cubes of these primes modulo $83$ (since $249 = 3\times 83$) and determined that $(3,11,19)$ is the only solution. [Warning: not fun]
However I believe that using your criterion $p+q+r=pq$, or $r+1 = (p-1)(q-1)$ would actually be simpler.
First note that $p \ne 2$: $2 + q + r = 2q \implies 2 +r = q$, which contradicts $r > q$.
Then, notice that $p < 5$: else $p \ge 5, q \ge 7, r = (p-1)(q-1)-1 \ge 23$. This gives the only case $(5,7,23)$, where $\dfrac {p^3+q^3+r^3}{p+q+r} = 361$. Hence we can only have $p=3$.
Since $r+1 = 2(q-1) \le 24$, we just need to check $q=5,7,11$, which gives $r = 7,11,19$, and $\dfrac {p^3+q^3+r^3}{p+q+r} = 33, 81, 249$. Hence $(3,11,19)$ is the only solution. Removing the WLOG, $r$ can take on all these values, so the required sum of possible values of $r$ is $33$.
