0

what if i wanted to calculate m,n where C= 5 , for example

$$ a = 2np; b= m2 -n2; c = m2 + n2; $$

let's say i want to start with c=5 instead of a m > n > 0 , how can i calculate m and n which created the values for a = 2mn , b= m2 -c2 , c = m2 + n2 = 5?

1 Answers1

1

You can find a solution of $c=m^2+n^2$ for given $c$ by using the construction for Fermat's result to represent a number as a sum of two squares, i.e., following the construction given in the answer here:

Prove that $n$ is a sum of two squares?

For $n=5$ this is trivial. We can take $m=2$ and $n=1$. Note that there need not exists integers $m$ and $n$ with $c=m^2+n^2$ in general.

Dietrich Burde
  • 130,978