# Thread: Construction of rational points and pythagorean triples

1. ## Construction of rational points and pythagorean triples

Intro:

Above is a unit circle, $\displaystyle x^2+y^2=1$.

1. First (trivial) solution is $\displaystyle x=1, \text{ }y=0$.
2. For second (non-trivial) solution, QR has a rational slope $\displaystyle y=t(x+1)$ and we plug this $\displaystyle \displaystyle{ x^2+y^2=x^2+t^2(x+1)^2=x^2(1+t^2)+x(2t^2)+(t^2-1)=1 }$.
This gives (non-trivial) solution of $\displaystyle x=\frac{1-t^2}{1+t^2}, \text{ } y=\frac{2t}{1+t^2}$.

Simple enough. Now the exercise.
The parameter $\displaystyle t$ in the pair $\displaystyle \left( \frac{1-t^2}{1+t^2}, \text{ } \frac{2t}{1+t^2} \right)$ runs through all rational numbers if $\displaystyle t=\frac{q}{p}$ and $\displaystyle p, \text{ } q$ run through all pairs of integers.

Deduce that if $\displaystyle \text{ }(a,b,c)$ is any Pythagorean triple then
$\displaystyle \displaystyle{ \frac{a}{c}=\frac{p^2-q^2}{p^2+q^2}, \text{ } \frac{b}{c}=\frac{2pq}{p^2+q^2} }$
for some integers $\displaystyle p$ and $\displaystyle q$.
I'm having problem with a minus in $\displaystyle \frac{a}{c}$ part:
$\displaystyle \displaystyle{ \frac{a^2}{c^2}=x^2\Rightarrow \frac{a}{c}=x=\frac{1-t^2}{1+t^2}=\frac{1-(\frac{p}{q})^2}{1+(\frac{p}{q})^2}=\frac{q^2-p^2}{q^2+p^2}\neq \frac{p^2-q^2}{q^2+p^2} }$

Use previous exercise to prove Euclid's formula for Pythagorean triples.
How would I use the previous exercise to prove that Euclid's generates all triples?

2. Originally Posted by courteous
...

Simple enough. Now the exercise.
I'm having problem with a minus in $\displaystyle \frac{a}{c}$ part:
$\displaystyle \displaystyle{ \frac{a^2}{c^2}=x^2\Rightarrow \frac{a}{c}=x=\frac{1-t^2}{1+t^2}=\frac{1-(\frac{p}{q})^2}{1+(\frac{p}{q})^2}=\frac{q^2-p^2}{q^2+p^2}\neq \frac{p^2-q^2}{q^2+p^2} }$

...
In the quoted text of the exercise t is given as $\displaystyle t = \frac qp$.

You used $\displaystyle t = \frac pq$.

3. OK, first one is done.