Find a general method to find particular solutions where the sum of the squares of two consecutive integers is equal to the square of another integer

sequences-and-seriessquare-numberssums-of-squares

Question: If the sum of the squares of two consecutive integers is equal to the square of another integer, then find a general method to find particular solutions. E.g., $27304196^2+27304197^2=38613965^2$.

I tried to figure out other solutions such as $3^2+4^2=5^2$ and $20^2+21^2=29^2$, but I don't know how to find a method for general solutions.

Can anybody help me

Best Answer

If $n^2+(n+1)^2=k^2$, then $2n^2+2n+1=k^2$, so $(2n+1)^2=4n^2+4n+1=2k^2-1$.

So we are looking for solutions to the negative Pell equation $(2n+1)^2-2k^2=-1$,

which are $2n+1=1, 7, 41, 239, 1393, 8119, 47321, 275807, 1607521, 9369319,$

$54608393, ...,$ listed in OEIS.

Related Question