1

I'd like to ask how to obtain all integer solutions to the Diophantine equation $x^2+4y^2=5z^2$ using parameterization? Thanks.

Hang Wu
  • 1,576
  • 1
    https://math.stackexchange.com/questions/2773097/how-to-find-all-rational-solutions-of-x2-3y2-7/2788381#2788381 – individ Jul 21 '18 at 17:51

3 Answers3

3

Assume that you want the primitive solutions. I shall determine integer solutions up to sign changes.

Note that $x\equiv \pm y\pmod{5}$. We may assume that $x\equiv y\pmod{5}$ (otherwise, just flip the sign of $y$). Now, write $$z^2=\frac{x^2+4y^2}{5}=\left(\frac{x+4y}{5}\right)^2+\left(\frac{2x-2y}{5}\right)^2\,.$$ That is, using the knowledge from Pythagorian triples, we get that $$\frac{x+4y}{5}=m^2-n^2\,,\,\,\frac{2x-2y}{5}=2mn\,,\text{ and }z=m^2+n^2$$ for some coprime $m,n\in\mathbb{Z}$ with different parity. Thus, $$x=m^2+4mn-n^2\,,\,\,y=m^2-mn-n^2\,,\text{ and }z=m^2+n^2\,.$$ Note that, if you set $m:=u$ and $n:=u+v$, then you will get the same thing as in Will Jagy's answer (up to sign changes).

Batominovski
  • 49,629
  • This is better. My Fricke Klein program gives me a big list of possibilities (as 3 by 3 matrices of integers). I was not patient enough to look in the middle for this more attractive parametrization. – Will Jagy Jul 21 '18 at 18:26
2

The methods of Fricke and Klein (1897) show that a complete parametrization is given by a finite number of this type: $$ x = 4 u^2 + 2 uv - v^2 \; , \; \; y = u^2 + 3 uv + v^2 \; , \; \; z = 2u^2 + 2 uv + v^2 \; , \; \; $$

where we do not restrict $u,v$ to positive, then freely use absolute values for $x,y,z.$ I will need to check whether this one recipe gives them all. If you want $x,y,z$ to have a common factor, simply multiply them all by some number.

Oh, note that $z$ comes out positive regardless, and we can bound $u,v,$ if we are bounding $z, \;$ since $2u^2 + 2uv+v^2 = u^2 + (u+v)^2 \; .$

Note that stereographic projection around a single point easily gives all rational solutions. However, there is then the problem of finding the primitive integer solutions.

One is enough. The above is sufficient. Oh, I was forgetting, might as well take $u \geq 0$ to reduce repetition.

Sat Jul 21 11:06:37 PDT 2018
   |z|             x    y    z              u    v
    1             -1    1    1              0    1
    1             -1    1    1              0   -1
    1              1   -1    1              1   -1
    2              4    1    2              1    0
    2             -4   -1    2              1   -2
    5            -11    1    5              1   -3
    5             11   -1    5              2   -1
   10              4   11   10              1    2
   10             -4  -11   10              3   -4
   13             19   11   13              2    1
   13            -19  -11   13              3   -5
   13            -29   -1   13              2   -5
   13             29    1   13              3   -1
   17              1   19   17              1    3
   17             -1  -19   17              4   -5
   17            -31   11   17              1   -5
   17             31  -11   17              4   -3
   25             41   19   25              3    1
   25            -41  -19   25              4   -7
   26             -4   29   26              1    4
   26              4  -29   26              5   -6
   26            -44   19   26              1   -6
   26             44  -19   26              5   -4
   29             19   31   29              2    3
   29            -19  -31   29              5   -7
   29            -61   11   29              2   -7
   29             61  -11   29              5   -3
   34             44   31   34              3    2
   34            -44  -31   34              5   -8
   34            -76    1   34              3   -8
   34             76   -1   34              5   -2
   37            -11   41   37              1    5
   37             11  -41   37              6   -7
   37            -59   29   37              1   -7
   37             59  -29   37              6   -5
   41             71   29   41              4    1
   41            -71  -29   41              5   -9
   41            -89  -11   41              4   -9
   41             89   11   41              5   -1
   50            -76   41   50              1   -8
   50             76  -41   50              7   -6
   53           -101   31   53              2   -9
   53            101  -31   53              7   -5
   53             11   59   53              2    5
   53            -11  -59   53              7   -9
   58           -124   19   58              3  -10
   58            124  -19   58              7   -4
   58             44   61   58              3    4
   58            -44  -61   58              7  -10
   61            109   41   61              5    1
   61           -109  -41   61              6  -11
   61           -131  -19   61              5  -11
   61            131   19   61              6   -1
   65            -31   71   65              1    7
   65             31  -71   65              8   -9
   65             79   61   65              4    3
   65            -79  -61   65              7  -11
   73           -151   31   73              3  -11
   73            151  -31   73              8   -5
   73             41   79   73              3    5
   73            -41  -79   73              8  -11
   74            116   59   74              5    2
   74           -116  -59   74              7  -12
   74           -164  -11   74              5  -12
   74            164   11   74              7   -2
   82           -116   71   82              1  -10
   82            116  -71   82              9   -8
   82            -44   89   82              1    8
   82             44  -89   82              9  -10
   85           -149   59   85              2  -11
   85            149  -59   85              9   -7
   85           -181  -29   85              6  -13
   85            181   29   85              7   -1
   89            121   79   89              5    3
   89           -121  -79   89              8  -13
   89           -199   -1   89              5  -13
   89            199    1   89              8   -3
   97           -209   29   97              4  -13
   97            209  -29   97              9   -5
   97             79  101   97              4    5
   97            -79 -101   97              9  -13
  101            139  -89  101             10   -9
  101           -139   89  101              1  -11
  101             59 -109  101             10  -11
  101            -59  109  101              1    9
  106            124  101  106              5    4
  106           -124 -101  106              9  -14
  106           -236   11  106              5  -14
  106            236  -11  106              9   -4
  109            211  -61  109             10   -7
  109           -211   61  109              3  -13
  109            -29 -121  109             10  -13
  109             29  121  109              3    7
  113            209   71  113              7    1
  113           -209  -71  113              8  -15
  113           -239  -41  113              7  -15
  113            239   41  113              8   -1
  122            164 -109  122             11  -10
  122           -164  109  122              1  -12
  122            -76  131  122              1   10
  122             76 -131  122             11  -12
  125             29 -139  125             11  -13
  125            -29  139  125              2    9
  130            244  -79  130             11   -8
  130           -244   79  130              3  -14
  130           -284  -31  130              7  -16
  130            284   31  130              9   -2
  137            281  -61  137             11   -7
  137           -281   61  137              4  -15
  137            -71 -149  137             11  -15
  137             71  149  137              4    7
  145           -191  131  145              1  -13
  145            191 -131  145             12  -11
  145            271   89  145              8    1
  145           -271  -89  145              9  -17
  146           -124 -151  146             11  -16
  146            124  151  146              5    6
  146            316  -41  146             11   -6
  146           -316   41  146              5  -16
  149           -229 -121  149             10  -17
  149            229  121  149              7    3
  149            331   19  149             10   -3
  149           -331  -19  149              7  -17
  |z|             x    y    z               u    v

=================================================

Will Jagy
  • 139,541
0

Do you know how to do this for Pythagorean triples? That is, do you know how to find solutions to $x^2 + y^2 = z^2$? This is equivalent to finding rational points on the circle $X^2 + Y^2 = 1$, and then taking $(x/z,y/z) = (X,Y)$. The way to find rational points on the circle is as follows: for a point on the circle $(X,Y)$, consider the line from $(-1,0)$ to $(X,Y)$. If this line has rational slope, then the equation for where the line meets the circle has rational coefficients and has the rational root at $(-1,0)$. The rational root test then tells you that the other root must be rational, i.e. $(X,Y)$ is rational.

Conversely, if $(X,Y)$ is rational, then the line from $(-1,0)$ to $(X,Y)$ has rational slope as well. Therefore, finding rational points on the unit circle are equivalent to looking at where the lines of rational slope at $(-1,0)$ intersect the circle; this can be done using the quadratic formula.

The same can be used for your equation. Simply consider all lines of rational slope starting at some fixed rational point of $X^2 / 5 + 4 Y^2 / 5 = 1$, e.g. $(1,1)$.

Marcus M
  • 11,229