TITLE: Twin primes whose sum is a cube
QUESTION [7 upvotes]: $84537841287167$ and $84537841287169$ are a pair of twin primes.
The sum of $84537841287167+84537841287169$ is a cube.
Are there other examples of twin pairs $p$, $p+2$ whose sum is a cube?
Have they to have a particular form?

REPLY [22 votes]: List of Some Twin Primes Greater than $\bf{3}$ whose Sum is a Cube
The sum of twin primes $6k-1$ and $6k+1$ is $12k$ and $12k=j^3\implies6\mid j$. So to look for such twin primes, look for twin primes of the form 
$$
(108n^3-1,108n^3+1)
$$
We can skip $n\equiv2\pmod5$ since
$$
\begin{align}
108\cdot n^3+1
&\equiv3\cdot2^3+1&\pmod5\\
&\equiv0&\pmod5
\end{align}
$$
and we can skip $n\equiv3\pmod5$ since
$$
\begin{align}
108\cdot n^3-1
&\equiv3\cdot3^3-1&\pmod5\\
&\equiv0&\pmod5
\end{align}
$$
Checking $n\equiv0,1,4\pmod5$, we get
$$
\begin{array}{l|l}
n&108n^3-1&108n^3+1\\\hline
1&107&109\\
29&2634011&2634013\\
65&29659499&29659501\\
81&57395627&57395629\\
99&104792291&104792293\\
136&271669247&271669249\\
165&485149499&485149501\\
174&568946591&568946593\\
176&588791807&588791809\\
191&752530067&752530069\\
200&863999999&864000001\\
266&2032678367&2032678369\\
295&2772616499&2772616501\\
301&2945257307&2945257309\\
319&3505869971&3505869973\\
346&4473547487&4473547489\\
351&4670303507&4670303509\\
370&5470523999&5470524001\\
400&6911999999&6912000001\\
411&7498065347&7498065349\\
431&8646803027&8646803029\\
434&8828622431&8828622433\\
436&8951240447&8951240449\\
456&10240432127&10240432129\\
491&12784043267&12784043269\\
494&13019808671&13019808673\\
526&15717410207&15717410209\\
541&17100765467&17100765469\\
599&23211554291&23211554293\\
651&29796600707&29796600709\\
676&33362903807&33362903809\\
714&39311389151&39311389153\\
746&44837381087&44837381089\\
790&53248211999&53248212001\\
924&85200014591&85200014593\\
956&94362064127&94362064129\\
991&105110165267&105110165269\\
\end{array}
$$
Note that the sum of the primes is $(6n)^3$.
This list does not include $3+5=2^3$ because $(3,5)$ is the only twin prime that is not of the form $(6k-1,6k+1)$; that is, all primes greater than $3$ must be relatively prime to $6$.

Mathematica Code
Module[{s = "", m}, 
 For[n = 1, n < 1000, ++n, 
  If[MemberQ[{0, 1, 4}, Mod[n, 5]] && PrimeQ[(m = 108 n^3) - 1] && 
    PrimeQ[m + 1], 
   s = StringJoin[s, 
     ToString[n] <> "&" <> ToString[m - 1] <> "&" <> ToString[m + 1] <>
       "\\\n"]]]; s]