# Thread: Prove that the square root of a non-square number is irrational

1. ## Prove that the square root of a non-square number is irrational

Prove: If integer N>1 is not a perfect square, then sqrt(N) is irrational.

2. ## Irrational numbers

Hello o&apartyrock
Originally Posted by o&apartyrock
Prove: If integer N>1 is not a perfect square, then sqrt(N) is irrational.
Assume that $\displaystyle \sqrt{N}$ is rational; in other words

$\displaystyle \exists\, p, q \in\mathbb{N},\, \sqrt{N} = \frac{p}{q}$

and assume further that $\displaystyle hcf(p,q)=1$; in other words, that the fraction $\displaystyle \frac{p}{q}$ is in its lowest terms.

Then $\displaystyle N = \frac{p^2}{q^2}$

$\displaystyle \Rightarrow p^2 = Nq^2 \Rightarrow p^2$ has a factor $\displaystyle N$, since $\displaystyle hcf(p,q) = 1$

$\displaystyle \Rightarrow p$ has a factor $\displaystyle N$ (For if not, then $\displaystyle N$ is the product of the squares of one or more of the prime factors of $\displaystyle p$, and is therefore a perfect square. Contradiction.)

$\displaystyle \Rightarrow p = Nr, r\in\mathbb{N}$

$\displaystyle \Rightarrow p^2 = N^2r^2 = Nq^2$

$\displaystyle \Rightarrow q^2 = Nr^2$

$\displaystyle \Rightarrow q$ has a factor $\displaystyle N$

$\displaystyle \Rightarrow hcf(p,q) \ge N > 1$

Therefore $\displaystyle \sqrt{N}$ cannot be expressed in the form $\displaystyle \frac{p}{q}$, and is therefore irrational.

3. ## Why is this line true?

has a factor (For if not, then is the product of the squares of one or more of the prime factors of , and is therefore a perfect square. Contradiction.)

$\displaystyle \Rightarrow p^2 = Nq^2 \Rightarrow p^2$ has a factor $\displaystyle N$, since $\displaystyle hcf(p,q) = 1$

$\displaystyle \Rightarrow p$ has a factor $\displaystyle N$ (For if not, then $\displaystyle N$ is the product of the squares of one or more of the prime factors of $\displaystyle p$, and is therefore a perfect square. Contradiction.)
Almost, but not quite. For example, $\displaystyle 6^2$ has a factor $\displaystyle 12$ but $\displaystyle 6$ does not have a factor $\displaystyle 12.$ You should take into account not only that $\displaystyle N$ is not a perfect square but also that $\displaystyle \frac{p^2}N=q^2$ is a perfect square (in this case $\displaystyle \frac{6^2}{12}=3$ is not a perfect square).

This is how I would write out the proof. Let $\displaystyle N=p_1^{n_1}p_2^{n_2}\cdots p_k^{n_k}$ where the $\displaystyle p_i$ are distinct primes. Then at least one of the $\displaystyle n_i$ must be odd since $\displaystyle N$ is not a perfect square, say $\displaystyle n_1$ is odd.

If $\displaystyle \sqrt N=\frac ab$ where $\displaystyle a,b\in\mathbb Z,$ $\displaystyle b\ne0$ and $\displaystyle \gcd(a,b)=1,$ then

$\displaystyle Nb^2\ =\ a^2$

$\displaystyle \Rightarrow\ N\mid a^2$

$\displaystyle \Rightarrow\ p_1\mid a^2$ (since $\displaystyle p_1\mid N)$

$\displaystyle \Rightarrow\ p_1\mid a$ (since $\displaystyle p_1$ is prime)

$\displaystyle \Rightarrow\ p_1$ divides $\displaystyle a^2$ an even number of times

This is a contradiction because $\displaystyle p_1$ divides $\displaystyle N$ an odd number of times and $\displaystyle p_1\nmid b^2$ and so $\displaystyle p_1$ divides $\displaystyle Nb^2$ an odd number of times.

5. Hmm... now you have me slightly more confused! The proof you have provided, proscientia is quite elegant.

I still think Grandad's proof is valid though. Of course "if N divides $\displaystyle p^2$ then N divides p" is not generally true as your counter example of N=12 and p=6 shows. But we are given some extra constraints here, namely $\displaystyle p^2 = Nq^2$ and $\displaystyle gcd(p,q)=1$.

But GrandDad's proof appears in Mathematical Analyis 2nd ed by Apostol Theorem theorem 1.10. So it must be correct. and my question still remains:

Given $\displaystyle p^2 = Nq^2$ and $\displaystyle gcd(p,q)=1, \Rightarrow N|q^2$, but how does this imply $\displaystyle N|q$?

6. Originally Posted by aukie
But we are given some extra constraints here, namely $\displaystyle p^2 = Nq^2$ and $\displaystyle gcd(p,q)=1$.
Thanks for the reminder! I had completely forgotten about $\displaystyle p$ and $\displaystyle q$ having to be coprime.

Originally Posted by aukie
Given $\displaystyle p^2 = Nq^2$ and $\displaystyle gcd(p,q)=1, \Rightarrow N|q^2$, but how does this imply $\displaystyle N|q$?
I’m afraid I’m totally confused about that as well.

7. Originally Posted by aukie
Hmm... now you have me slightly more confused! The proof you have provided, proscientia is quite elegant.

I still think Grandad's proof is valid though. Of course "if N divides $\displaystyle p^2$ then N divides p" is not generally true as your counter example of N=12 and p=6 shows. But we are given some extra constraints here, namely $\displaystyle p^2 = Nq^2$ and $\displaystyle gcd(p,q)=1$.

But GrandDad's proof appears in Mathematical Analyis 2nd ed by Apostol Theorem theorem 1.10. So it must be correct. and my question still remains:

Given $\displaystyle p^2 = Nq^2$ and $\displaystyle gcd(p,q)=1, \Rightarrow N|q^2$, but how does this imply $\displaystyle N|q$?

Apostol's argument's correct because he's assuming something that hasn't been assumed here, namely: N has no square factors or, as said in number theory, N is square-free, and this is all the difference; otherwise his argument would be wrong, or at least lacking, since he doesn't remind $\displaystyle p^2=Nq^2$ at the moment of argumenting that $\displaystyle N \mid p^2 \Longrightarrow N \mid p$, but he needs not to: if N doesn't divides p then some prime factor of N doesn't divide p (this can be also said in the case 12 divides 6^2 but 12 doesn't divide 6, since 12 has prime factors 2,2,3 and 6 only 2,3...but 12 is not square free), but this factor appears in $\displaystyle p^2=Nq^2$ and this can't be since it appears at the first power in N...!.

Now, $\displaystyle p^2=Nq^2\,\,\,but\,\,\,N \nmid p \Longrightarrow \exists prime\,\,\,r\,\,\,s.t.\,\,r \mid N \wedge r \nmid p$

But this prime factor appears on the right hand in $\displaystyle p^2=Nq^2$ and thus it must appear in the left hand: $\displaystyle r \mid p^2 \Longrightarrow r \mid p$ and we get our contradiction.

Tonio

8. I'm so confused ... you assume that sqrt(N) is a reduced fraction, and so N = p^2/q^2 ... but since (p,q)=1, that implies that N is a rational number, and so we have a contradiction since N is supposed to be an integer greater than 1 ... cuz after that, we are treating N as if it's a rational number, and in that case, we can't really use prime decomposition on it, nor can we use the definition of divisibility ....

Could we do this also:
N is an integer greater than 1 and is not a perfect square.
Assume that sqrt(N) is a rational number say p/q with (p,q)=1 (reduced fraction).
=> N = p^2/q^2 => q^2|p^2 (since N is an integer) => q^2 = 1 (since (p,q)=1) => N = p^2. Contradiction since N is not a perfect square ... so sqrt(N) is not a rational. Since N is positive, sqrt(N) is a real number and since it is not a rational, it must be irrational.

9. Originally Posted by Bingk
I'm so confused ... you assume that sqrt(N) is a reduced fraction, and so N = p^2/q^2 ... but since (p,q)=1, that implies that N is a rational number, and so we have a contradiction since N is supposed to be an integer greater than 1

$\displaystyle \color{red}\mbox{And who said q cannot be} \pm 1?$

tonio

... cuz after that, we are treating N as if it's a rational number, and in that case, we can't really use prime decomposition on it, nor can we use the definition of divisibility ....

Could we do this also:
N is an integer greater than 1 and is not a perfect square.
Assume that sqrt(N) is a rational number say p/q with (p,q)=1 (reduced fraction).
=> N = p^2/q^2 => q^2|p^2 (since N is an integer) => q^2 = 1 (since (p,q)=1) => N = p^2. Contradiction since N is not a perfect square ... so sqrt(N) is not a rational. Since N is positive, sqrt(N) is a real number and since it is not a rational, it must be irrational.
.

10. ## Putting right my error!

Hello everyone -

Since I wrote this line, six months ago,
$\displaystyle \Rightarrow p^2 = Nq^2 \Rightarrow p^2$ has a factor $\displaystyle N$, since $\displaystyle hcf(p,q) = 1$

$\displaystyle \Rightarrow p$ has a factor $\displaystyle N$ (For if not, then $\displaystyle N$ is the product of the squares of one or more of the prime factors of $\displaystyle p$, and is therefore a perfect square. Contradiction.)
I (like many others) have been puzzling over what I meant by it!

I was wrong: the conclusion "$\displaystyle p$ has a factor $\displaystyle N$" is not valid, and I apologise for the confusion this may have caused. I was attempting to modify the well known proof that $\displaystyle \sqrt2$ is irrational, and I was guilty of over-simplification.

What I should have said is that $\displaystyle p^2=Nq^2$ implies that there is a prime factor, $\displaystyle n$ say, of $\displaystyle N$,
for which the quotient $\displaystyle \frac{p^2}{N}$ is a multiple of $\displaystyle n$. (For if not, then $\displaystyle N$ is the product of even powers of one or more of the prime factors of $\displaystyle p$, and is therefore a perfect square. Contradiction.)

The proof then follows similar lines to my original 'proof', using $\displaystyle n$ rather than $\displaystyle N$:

$\displaystyle q^2=\frac{p^2}{N}=rn$, for some integer $\displaystyle r$

$\displaystyle \Rightarrow q^2$ has a prime factor $\displaystyle n$

$\displaystyle \Rightarrow q$ has a prime factor $\displaystyle n$

But $\displaystyle n|N$ and $\displaystyle N|p \Rightarrow n|p\Rightarrow \gcd(p,q)\ge n$, and this contradicts the initial hypothesis that $\displaystyle \gcd(p,q)=1$.

Further comment

I can fully understand where the problems arise as far as the part played by $\displaystyle q$ is concerned, and the confusion caused by the fact that $\displaystyle q$ is co-prime with $\displaystyle p$. The fact is, of course, that $\displaystyle \gcd(p,q)=1$ tends to bring with it a whole lot of contradictions - that's the
whole nature of the problem!

So at the risk of adding further confusion, may I attempt to amplify my argument, and so atone in some measure for my original error?

The statement $\displaystyle p^2 = Nq^2$ is clear enough, and it obviously means that $\displaystyle N$ is a factor of $\displaystyle p^2$. So forget for the time being that $\displaystyle q^2$ is the other factor of $\displaystyle p^2$, and concentrate on $\displaystyle N$. We'll use the fact that $\displaystyle p$ and $\displaystyle q$ are co-prime all in good time.

Since $\displaystyle N$ is not a perfect square, it therefore has, among its prime factors, at least one with an odd power. It is this prime number that I am calling $\displaystyle n$ (and which proscientia called $\displaystyle p_1$).

The fact that $\displaystyle p^2$, with its array of even-powered prime factors, has $\displaystyle N$ as a factor with its odd-powered prime factor $\displaystyle n$ means that when we simplify (by cancelling) the fraction $\displaystyle \frac{p^2}{N}$ there will inevitably be at least one $\displaystyle n$ left uncancelled in the numerator. That's where I get my statement from that $\displaystyle \frac{p^2}{N}$ is a multiple of $\displaystyle n$.

It's only at the end that we need to invoke the condition that $\displaystyle \gcd(p,q)=1$. It's when we try to do so too early that the confusion arises.

I hope that helps to clear things up.

11. No one said that q cannot be $\displaystyle \pm 1$ ... my problem is that someone should have said that q^2 MUST be 1 ...

p^2=N*q^2 with (p,q)=1, should make you reach the conclusion that q^2 = 1, not that there is a contradiction with (p,q)=1. The reason you reach that contradiction is because you're assuming q>1, because you're assuming that there is a prime r such that r|q (and consequently r|p), but there is no prime that divides 1 (or -1). That case is being overlooked, and in an indirect way, you're basically saying that q^2 cant equal 1.

I think proscientia's proof is okay, since although it's doesn't state that b^2=1, it correctly states that p1 does not divide b^2.

12. very nicely done tonio! its seems like you are a fan of apostol.

grandad is right the number of possible contradictions one can arrive at is intriging.

,

,

,

,

,

,

,

,

,

,

,

,

,

,

# is squre root of every non squre nuber always irrational

Click on a term to search for related topics.