Question about a specific part of proving $\sqrt 7$ is irrational I have a question that wants me to prove that the square root of $7$ is irrational. So I know we need to use proof by contradiction, then $7 = \frac{a^2}{b^2}$ where $a$ and $b$ are coprime. Then $a^2 = 7b^2$. So $7$ is a factor of $a^2$. Therefore $7$ is a factor of $a$. So $a$ can be written in the form of $a = 7k$ and so on.
My question is, to answer this question, aren't we supposed to prove that if $7$ is a factor $a^2$ then $7$ is a factor of $a$, in order to proceed onto the next step? If so, how would we go about proving that? If proving it is unnecessary, why is that so? I've seen such questions answered so many times in the exact same method, and it is always assumed that if $x$ is a factor of $a^2$ then $x$ is a factor of $a$.
 A: In Mathematics, you never actually state something is True without proving it. 
To prove the required statement, first observe that $7$ is a prime and a square-free number (a number which when written in the canonical form, every exponent is less than 2). So $a$ and $a$ cannot share factors of $7$ since it only has a single factor. So, $$7 | a^2 \implies 7|a$$ 
Some basic number theory rules mention that if a prime $p | ab$, then $p|a$ or $p|b$. It follows from those rules.
And no you cannot assume that always. It's incorrect. Consider the case, $4|6^2$. $4$ does not divide $6$. If you assume it for non-primes, it may lead to mathematical falacies.
A: The argument that I like best is slightly advanced, in that it uses the Fundamental Theorem of Arithmetic, more specifically the uniqueness part.
From the equation $a^2=7b^2$ you get an immediate contradicion, ’cause there are evenly many sevens on the left, and oddly many sevens on the right.
A: It has been assumed it has been proven and the student accepts that if $p$ is prime and $p|ab$ then either $p|a$ or $p|b$. (Thus as $7$ is prime and $7|a \times a$ then $7|a$ or ...   $7|a$.)
Proof: The unique prime factorization theorem states that $a$ and $b$ have unique prime factorizations. Either i)$p$ is a factor of $a$ or ii) $p$ is a factor of $b$ iii) $p$ is a factor of both $a$ and $b$ or iv) $p$ is not a factor of either. We need to show iv) is not possible.
$ab$ has a unique factorization and it is simply the product of the unique prime factors of $a$ times the unique factors of $b$. So if $p$ is not a prime factor of either $a$ or $b$ it will not be a factor of $ab$ whose prime factors are just the combined collection of the prime factors of $a$ and $b$. So if $p\not \mid a$ and $p\not \mid b$ then $p \not \mid ab$.
In other words iv) is impossible.
====
Note for this result $p$ MUST be prime. If $x = pq$, and $a = pm$ and $b = qn$ then $x|ab$ but $x \not \mid ab$ (in general).
====
So how the prove the unique prime factorization theorem?...  Oh, I'll let you Google that. 
