This is a repost of my old question here. The question is as follows:
Find all integers m and n, such that $m^2 + n^2$ is a square and $\sqrt{\frac{2(m^2+1)}{n^2+1}}$ is rational.
I have made no progress on this problem since I last asked it. Tito gave a very nice answer for if $m,n$ were rational numbers, but it would be awesome if some people could provide some insight into this problem and solve it once and for all. It would also be really cool if we replaced that 2 with another number and investigated that as well.
(For your reference, the original question was 2010 USAJMO problem 6. I tried to bash the question out and somehow I arrived at this problem. I suspect I made a mistake somewhere because the problem is no longer homogeneous.)
I'm not sure we need it or not. But can be useful if for the equation.
$$\frac{x}{y}=\sqrt{\frac{2(b^2+t^2)}{a^2+t^2}}$$
Then the solution can be written as.
$$x=k^2+2l^2$$
$$y=2kl$$
$$b=(k^4-4l^4)(p^2+s^2)$$
$$a=2kl(k^2-2l^2)(p^2+2ps-s^2)$$
$$t=2kl(k^2+2l^2)(p^2-2ps-s^2)$$