On factorizationa of a cube $\,m^3 = ab$ I am doing my thesis on elliptic curves right now and in the meantime this lemma showed up: 
Suppose $a$ and $b$ are integers such that $ab = m^3$ for some integer $m$. Let $d = \operatorname{gcd}(a,b)$, then we can write
\begin{equation}\label{}
a = d\cdot p_1^{r_1}\cdots p_t^{r_t}\cdot (\operatorname{integer})^3,
\end{equation}
where $p_i|d$ and $r_i \in \mathbb{Z}$.
So I tried taking a prime that does not divide $d$ and tried to show it must appear as a third power, however I couldn't figure it out. Any help would be appreciated!
 A: As lulu noted, the order of any prime dividing $ab$ must be divisible by 3, because $ab=m^3$. Now the product above just results from the fact that we can break up the primes dividing $m$ into those which divide only $a$, those which divide both $a$ and $b$, and thus divide $d$, and those which divide only $b$. Only the first two categories contribute to our expression for $a$, obviously, then you need simply observe that if a prime occurs exclusively in $a$, then the order of the prime in $a$ must be the same as the order of the prime dividing $ab$, whence it must be divisible by 3.
A: Because for each prime $p$ that does not divide $b$ we have $v_p(a)= v_p(ab) = v_p(m^3)=3v_p(m)$.
We can clearly make the part that is not $dp_1^{r_1}\dots p_r^{r_t}$ equal to the product of all of the $p^{v_p(ab)}$ where $p$ is a prime not dividing $b$.
A: Hint $ $ Let $\, c_a := d p_1^{r_1}\cdots p_t^{r_t}$ be the product of all prime factors of $\,a\,$ which also divide $\,b,\,$ and similarly for $\,c_b\,$ and $\,b.\,$  Then $\,a = a' c_a,\ b = c' c_b,\,$ and $\,a',b', c_a c_b\,$ are pairwise coprime, therefore
$\, m^3 = ab = a'\, b'\, (c_a c_b)\,\Rightarrow\, a',b'$ are cubes too. 
