# Prove that the square root of pq when p and q are distinct primes is irrational

I am trying to prove the following:

If p and q are distinct primes, then $\sqrt{pq}$ $\notin$ $\Bbb{Q}$.

Here is my proof thus far:

1. Suppose towards a contradiction that if p and q are distinct primes, that $\sqrt{pq}$ $\in$ $\Bbb{Q}$. If so, there exists some m , n $\in$ $\Bbb{Z}$ such that $\sqrt{pq}$ = $\frac mn$.

2. Squaring both sides, we see that pq = $\left(\frac{m^2}{n^2}\right)$ .

3. Multiplying by $\left(\frac nm\right)$, we see that $\left(\frac{m}{n}\right)$ = $\left(\frac{npq}{m}\right)$.

4. This implies that n|m and m|npq. But, since m, n share no common factors, n $\not\mid$ m.

5. Hence we have reached a contradiction.

**My concern is step 4 of my proof. Does it follow that since n $\not\mid$ m , $\sqrt{pq}$ $\notin$ $\Bbb{Q}$ ?

Is this "enough" to render a contradiction? It feels fishy to me but I'm not sure. If anybody could help that would be greatly appreciated! I am trying to develop my intuition in regards to this.

• It's fishy all right. Who says $n\vert m$, for instance? – user7530 May 5 '17 at 4:47
• Your step 4 feels a bit off... why do you directly know that $n\mid m$? I would instead have gone from step 2 by multiplying both sides by $n^2$, you get then $n^2pq=m^2$ and both sides are integers. Here you can then use properties of primes to say that $p\mid m$ and $q\mid m$. You can then continue as the classic greek proof for $\sqrt{2}$'s irrationality does. – JMoravitz May 5 '17 at 4:48
• Why is it true 4? It is better to simply consider equality $n^2pq=m^2$ assuming $m$ and $n$ have no common factors. Then $p$ devides $m^2$ hence ... – Minz May 5 '17 at 4:51
• see the answers to math.stackexchange.com/questions/1310014/… They contain a proof for the irrationality of the square root of any non-perfect square. – Mark Joshi May 5 '17 at 5:00
• @JMoravitz : My textbook contains a lemma that says that if m,n,s,t are integers and (m\n) = (s\t) then m | s and n | t. – agra94 May 5 '17 at 5:12

The method you use in step 4 is correct but, we need to assume at the start that wlog $m,n$ are coprime, i.e. $m/n$ is in lowest terms. See here or here for further details

However, this does not yet yield a contradiction. Rather, it yields that $n = 1,$ so if the radical is rational then it is an integer. It remains to finish the proof.

Note  The links are to answers with complete elementary proofs, including John Conway's favorite simple proof. Though there I also append remarks on more advanced ways to conceptualize these elementary proofs, I emphasize that those proofs do not require any knowledge of these more advanced ideas.

• I don't think even this saves the proof. Why does n divide m? That assumes m/n = npq/m are integers? Why is that? They were obtained by multiplying integers by n/m which ought to be non-integral. – Jeremy West May 26 '17 at 1:47
• @Jeremy It is explained in the links I gave. You should ask for clarification before you downvote. – Bill Dubuque May 26 '17 at 4:04
• I disagree. I can always remove the downvote if convinced otherwise. There's no reason a proof this basic couldn't be self-contained or should depend on significantly more advanced results. I would wager that most people with OP's question are unlikely to be in a position to understand either of your links. Hence, the reason I found your answer less helpful and downvoted. – Jeremy West May 26 '17 at 4:15
• @Jeremy If you can be more precise about what you have difficulty following then I will be happy to elaborate. The proofs I gave in the links are about as elementary as can be. Though I do append notes on more advanced conceptual ways to view these proofs (e.g. via ideal theory), those tangential remarks can be completely ignored if they are beyond one's level of knowledge. – Bill Dubuque May 26 '17 at 15:17
• OPs question is a fairly standard exercise early in a course on elementary number theory or intro to mathematical reasoning/proofs. Given his uncertainty about the proof, it would seem that is the level of his question. In that context, results depending on partial fractions, for instance, aren't likely to be relevant. I appreciate your concern for my understanding; I do, in fact, understand your links. I just don't think they are appropriate to the level of the question asked. – Jeremy West May 26 '17 at 18:17

You have $n^2pq=m^2$, but the exponents of $p$ and $q$ are odd.

• So? I'm not quite sure what you are getting at. – agra94 May 5 '17 at 5:16
• we have a contradiction by this stage – JonMark Perry May 5 '17 at 5:17
• @JonMarkPerry But the OP asks about a specific method of proof, and this answer ignores that method. – Bill Dubuque May 5 '17 at 14:32
• Yes, but his specific method is flawed. This is a step in the right direction. Don't multiply by n/m since there's no guarantee the result is integral. – Jeremy West May 26 '17 at 1:49
• @Jeremy The OP's method of proof is certainly not flawed. Rather, the flaw lies in your understanding of this method. Again, please ask for elaboration before making false claims based on misunderstandings. – Bill Dubuque May 26 '17 at 16:01