Let a be a rational number that can be written as sum of squares of three rational numbers. Prove that $a^m$ can also can be written as sum of squares of three rational numbers for any positive integer $m$.
I tried to solve using Mathematical Induction Let a be a rational number that can be written as sum of squares of three rational numbers i.e. $$a=\left( p_1 / q_1\right)^2+\left( p_2 / q_2\right)^2+ \left( p_3 / q_3\right)^2\\$$ We prove $a^m$ is rational for every positive integer$\\$ For $n=1$, it is true. $\\$ Let it be true for $n=k$ i.e. $$a^m=\left( r_1 / s_1\right)^2+\left( r_2 / s_2\right)^2+ \left( r_3 / s_3\right)^2\\$$ Consider $$a^{m+1}=a^m *a$$ $$=(\left( p_1 / q_1\right)^2+\left( p_2 / q_2\right)^2+ \left( p_3 / q_3\right)^2) (\left( r_1 / s_1\right)^2+\left( r_2 / s_2\right)^2+ \left( r_3 / s_3\right)^2)\\$$
I am not sure how to proceed next to show that $a^{m+1}$ can be written as sum of squares of three numbers. Thanks in advance for any kind help.
Based on (When is a rational number a sum of three squares?), a rational number $p/q$ is sum of three rational squares if and only if $pq$ is not of the form $2^{2a}(8b-1)$.
Note that any integer $n$ can be factored as $n=2^r\cdot s$, where $r\geq 0$ and $s$ is odd. So the result above is telling you that if a number $p/q$ is NOT a sum of three rational squares, then $pq=2^r\cdot s$, where $r$ is even and $s\equiv -1 \mod 8$. Equivalently, if a number $a=p/q$ is a sum of three rational squares, then $pq=2^r\cdot s$, where either $r$ is odd or $s\equiv 1, \pm 3 \mod 8$.
So things pretty much reduce to compare the behavior of $s$ and $s^m$ $\mod 8$.
Suppose $a=p/q$ i sa sum of three rational squares. That is, $pq=2^rs$, where either $s\equiv 1$ or $\pm 3 \mod 8$, or $r$ is odd. In the former case, the powers $s^m$ will never be $\equiv -1 \mod 8$. In the latter case, $s^m \equiv -1 \mod 8$ only if $m$ is odd. But then $(pq)^m=2^{rm}\cdot s^m$, with $rm$ odd.
Therefore, in either case, $(pq)^m$ will not be of the form $2^ab$, where $a$ is even and $b\equiv -1 \mod 8$. Hence $a^m$ is the sum of three rational squares.