- Given a,b solve ax^4+by^4=z^2. With a,b>0?
Rewrite to: ak^2+bl^2=m with k=x^2, l=y^2, m=z^2.
Forgetting the conditions on k,l,m it's easy to see that k,l ->m.
A fast routine would not test all possible (k,l) but only those who can be a square and testing m=z^2 at the last step.
For instance k=x^2 ,gives k=0,1 mod 4, regardless of x mod 4, the same for l so we have depending on the combinations (k,l) mod 4:
(0,0) m=0 mod 4 no further restriction on k,l
(1,0) m=a mod 4 a=0,1 mod 4 possible solution, else no solution
(0,1) m=b mod 4 b=0,1 mod 4 possible solution, else no solution
(1,1) m=(a+b) mod 4 a+b=0,1 mod 4 possible solution, else no solution
Other moduli will/could further restrict the choices for k,l.
If (x,y,z) is a solution so is (cx,cy,c^2z). So make sure x and y are relative prime.
Doing this 'fast' is not a matter of using UBASIC (can help) but thinking beforehand about possible solutions.
Jan van Delden
[Non-text portions of this message have been removed]