Consider the Diophantine equation $Ax^2+By^2=z^2$, with positive integer parameters $A$ and $B$ (not necessarily square-free or co-prime). When does this equation have a non-trivial solution? Can one give a comprehensible necessary and sufficient condition that $A$ and $B$ must satisfy?
I am aware of the Legendre theorem, but it assumes that $A$ and $B$ be co-prime and square-free; can one somehow get around this assumption?
Thanks in advance!
(virtually a duplicate taking into account “absorption” considerations expressed in comments).
– Incnis Mrsi Nov 11 '14 at 19:35