Given positive integers a and b such that $a\mid b^2, \:b^2\mid a^3, \:a^3\mid b^4,\: b^4\mid a^5$..., prove $a=b.$ 
Given positive integers a and b such that $a\mid b^2, \:b^2\mid a^3, \:a^3\mid b^4,\: b^4\mid a^5$..., prove $a=b.$

I was able to show that a and b have the same primes in their factorizations, but I'm not sure how to show that the exponents on these primes are equivalent for all primes in their factorization. I tried contradiction but got stuck.
 A: *

*Let $v_{p}(a)$ denote the highest power of $p$ in $a$. For example if $v_{p}(a) =k$ then $p^{k}\mid a$ and $p^{k+1} \nmid a$.

*$a^{4n+1} \mid b^{4n+2} \implies v_{p}(a) \leq \frac{4n+2}{4n+1}v_{p}(b)$ and $n \to \infty$ gives $v_{p}(a) \leq v_{p}(b)$. Now try showing the reverse inequality.
A: Hint:
Let $p$ be any prime which divides $a$, and let $m$ respectively $n$ be the powers of $p$ in $a$ respectively $b$.
You need to prove that $m \leq n$ and $n \leq m$.
Now for each $k$ we have
$$p^{(2k-1)m} \mid a^{2k-1} \mid b^{2k}$$
As the power of $p$ in $b^{2k}$ is $n(2k)$we get that
$$(2k-1)m \leq 2k n \Rightarrow \frac{m}{n} \leq \frac{2k}{2k-1}$$
use the fact that this is true for all $k$ to conclude that $\frac{m}{n} \leq 1$.
Now repeat with $m,n$ interchanged and with the even $k's$.
P.S.  You don't need to look at the prime factorization:
Assume by contradiction $a >b$. Then 
$$\lim_k \left( \frac{a}{b} \right)^k =\infty$$
which implies that there exists an $k$ so that 
$$\left( \frac{a}{b} \right)^{2k} >a \Rightarrow a^{2k-1} > b^{2k} $$
which contradicts $a^{2k-1} \mid b^{2k}$.
Now assume by contradiction $a < b$ and repeat the argument with $a,b$ switches (and $2k+1$ instead of $2k$).
A: $\color{#c00}a(a/b)^{2k}\in \Bbb Z\,\Rightarrow\, \color{#c00}a\,$ is a common denominator for unbounded powers of $\ a/b,\ $ so $\ a/b\in \Bbb Z,\,$ hence $\ b\mid a.\ $ Similarly $\ b(b/a)^{2k+1}\in\Bbb Z\,\Rightarrow\, a\mid b.\ $ Thus $\ a = b.$
