Poonen, Schaefer, & Stoll give the primitive solutions to $x^2+y^3=z^7$:


$$
(±1, −1, 0), (±1, 0, 1), ±(0, 1, 1), (±3, −2, 1), (±71, −17, 2),\\
(±2213459, 1414, 65), (±15312283, 9262, 113), (±21063928, −76271, 17).
$$


I'm looking for all the solutions with $1\le z\le\ell$ for some fixed $\ell$.


Clearly the primitive solutions yield infinitely many imprimitive solutions via multiplication by $\operatorname{lcm}(2,3,7)=42$nd powers, but this doesn't find them all. For example, $250^2+25^3 = 5^7$ and $832^2+112^3 = 8^7$.


How can I find all the solutions? My first instinct was to deal with each special case on its own but I'm afraid I'll miss cases that way.


[1] Bjorn Poonen, Edward F. Schaefer, and Michael Stoll, [Twists of X(7) and primitive solutions to x^2+y^3=z^7](http://arxiv.org/abs/math/0508174), *Duke Math. J.* **137**:1 (2007), pp. 103-158.



Imprimitive solutions to $x^2+y^3=z^7$
You can find the solutions for any given $z$ by looking for the integral
points on the elliptic curve
$$x^2 = (-y)^3 + z^7$$
(which would usually be written $y^2 = x^3 + z^7$). The curve
is isomorphic to the curve obtained by replacing $z^7$ with $z$,
so the computation is feasible for reasonable values of $z$.


Magma (for example, but
also SAGE) has an implementation of a procedure that finds all these
points (there are finitely many in each case) in quite reasonable time.
For example, there are exactly 990 solutions (up to a sign change in $x$)
for $1 \le z \le 1000$. Here is the Magma code (replace ell by $\ell$):



```
list := [];
for z := 1 to ell do
  pts := IntegralPoints(EllipticCurve([0, z^7]));
  list cat:= [<Abs(pt[2]), -pt[1], z> : pt in pts];
end for;
list;

```

If you do not have access to Magma, you can try it out with the
[online Magma calculator](http://magma.maths.usyd.edu.au/calc/).
With ell=100, it takes about 13 seconds there. The computation for
$\ell = 1000$ on my computer took about as long as writing this answer.


