Specific pythagorean triple

pythagorean triples

A question states that $x,y,$ and $z$ are positive integers and $x^2 + 2021y^2 = z^2.$ It then proceeds to ask how many such triples $(x,y,z)$ there are. I would like to set $2021y^2 = a^2$ and than solve as a typical pythagorean triple, but I'm not sure how I should move on from there. Can someone give me a nudge in the right direction? Thanks.

Best Answer

If you can find one solution, $(x,y,z)$, then the answer to the question is "infinitely many," because for any positive integer $a$, $(ax,ay,az)$ will be another.

So to find one solution note that $2021 = 43\cdot 47.$ The equation can be rewritten:

$$43\cdot 47y^2 = z^2-x^2 = (z-x)(z+x).$$

$43$ and $47$ divide the left side, so they must divide the right. We guess that that maybe $z-x=43$ and $z+x = 47.$ This gives $z=45$, $x=2$, forcing $y=1$. So there's the one solution. You can probably construct others similarly.