# Proving $\sqrt2$ is irrational

I used the method of contradiction by assuming that $\sqrt 2$ is a rational number. Then, by the definition of rational number, there exist two integers $p$ and $q$ whose ratio equals $\sqrt 2$. Thus, $$\frac pq = \sqrt2\tag{x}$$

Squaring both sides, $$p^2/q^2 = 2\tag{a}$$

or $$p^2 = 2q^2\tag{b}$$ This means that $p^2$ is an even number, implying that $p$ is even.

Now, any even integer can be written as $2^kf$ where $f$ is any odd integer and $k$ is some positive integer (the minimum value of $k$ and $f$ is $1$ since even numbers start from $2 = 2^1\cdot1$). For odd numbers, $k=0$.

For example, $8 = 2^3 \cdot 1$, $4= 2^2 \cdot 1$, $18= 2^1 \cdot 9$, $24 = 2^3 \cdot 3$, $-12= 2^2 \cdot(-3)$, etc.

Now, from $(b)$, $q^2$ can be even or odd.

Case 1: $q^2$ is even (thus meaning $q$ is even). Then $p= 2^{k_1} \cdot f_1$ (say) and $q = 2^{k_2} * f_2$ (say). Note here in this case, both conditions $k_1=k_2$ and $f_1=f_2$ can't hold simultaneously since that would mean $p/q =1$ and here $p/q =\sqrt2$ (from $(x)$)). Let's consider the condition when $k_1=k_2=k$ but $f_1\ne f_2$. Then $$\frac{p^2}{q^2}=\frac{(2^kf_1)^2}{(2^kf_2)^2} = \frac{f_1^2}{f_2^2} =2$$ (from $(a)$), i.e.: odd/odd ($f_1$ and $f_2$ are odd) can never equal $2$.

Now lets consider $f_1=f_2=f$ but $k_1\ne k_2$, thus $(2^{k_1}f)^2/(2^{k_2}f)^2= 2^{2(k_1-k_2)}= 2$ meaning $k_1 - k_2 = 0.5$ but $k_1,k_2$ are integers, so their difference can't be $0.5$. (Also here, $k_1-k_2$ must be greater or equal to $1$ since $2^{k_1-k_2}=\sqrt 2$, $k_1-k_2$ can't be negative since $\sqrt 2>1$, but $k_1-k_2\ge1$ can't satisfy $(a)$ since the minimum value of $p/q$ in this case will be $2$ which is surely greater than $\sqrt2$.)

Now lets consider $f_1\ne f_2$ and $k_1\ne k_2$, thus $\frac{(2^{k_1} f_1)^2}{(2^{k_2} f_2)^2}= 2^{2(k_1-k_2)}\frac{f_1^2}{f_2^2}$ can never equal $2$ since $\frac{f_1^2}{f_2^2}$ is either odd or "odd/odd" ie: it doesn't contain 2 as a factor and $2^{2(k_1-k_2)}$ is a power of $2$. So in $2^{2(k_1-k_2)}\frac{f_1^2}{f_2^2}$, there's no chance of cancellation of the odd factor $\frac{f_1^2}{f_2^2}$.

Case 2: $q^2$ is odd (thus meaning $q$ is odd). $q=f'$ (say, here $k=0$ for $q$ but not for $p$), thus from $(a)$ $2^{2k}\frac{f^2}{f'^2} = 2$ but this isn't possible since a power of $2$ multiplied with odd factor can't equal $2$.

Thus, both case 1 and 2 suggest that for any possible combination of $k_1,k_2,f_1$ and $f_2$, $p/q\ne\sqrt2$, i.e.: for no value of integers $p$ and $q$, $p/q = \sqrt2$. Thus, this contradicts our assumption that $\sqrt2$ is rational. Therefore it must be irrational.

PLS NOTE that i would like to clarify that $f_1^2$/$f_2^2$ is either an odd integer or a fraction of odd/odd or 1/odd form, thus not containing 2 as a factor,for any $2^n$, if it has to be reduced to 2 , must be multiplied with $1/ 2^(n-1)$ but $f_1^2$/$f_2^2$ can't be of $1/2^[n-1]$ form since for odd nos, in $2^k$*f notation, k is 0 , so 2 vanishes as $2^k$ becomes 1 in this case thus f1/f2 can't be represented as 1/ $2^(n-1)$ in which n has to be existent. therefore $2^{2(k_1-k_2)}\frac{f_1^2}{f_2^2}$ can never equal 2 as to further explain the 3rd condition of case 1

Difficulty: is my approach correct? This proof which I thought is different from proofs found on the internet or books since I have used $p$ and $q$ as any integers, which may have a common factor. So I am not sure if I am on right track. Will someone please check this out and make kind comments?

• See meta.math.stackexchange.com/q/5020/139123 for hints how to format the math so that people may actually read the whole proof. I've tried to help you get started by formatting a few of your equations. (Mostly because it seemed easier to just show how to make the labels "(x)", "(a)", and "(b)" than to explain how to do it.) I'm also a little puzzled why you put almost the whole question in a "quotation box" format, but you can if you want. – David K Jun 9 '15 at 2:33
• By the way, despite the concern about formatting, the question is a good one and I hope you will pursue it. – David K Jun 9 '15 at 2:39
• See math.stackexchange.com/questions/979211/…. Definitely see how easily it can be proved using the rational root theorem – Shailesh Jun 9 '15 at 2:40
• I did my best to clean up english and TeX in this question. Please check it to make sure I didn't misrepresent anything. One sentence didn't make sense and was left untranslated: "but this isn't possible since pure even no* odd factor can't equal 2". – Mario Carneiro Jun 9 '15 at 2:43
• @GustavFriedriechWilhelm No, I just type $p^2$ instead of p^2. See meta.math.stackexchange.com/questions/5020/… for more on how to write MathJax. – Mario Carneiro Jun 9 '15 at 2:50

## 4 Answers

The proof compares the parity of the powers of $\,2\,$ on each side of $\,P^2 = 2Q^2.\,$ Every natural can be written uniquely in the form $\, 2^a n\,$ for odd $\,n.\,$ Thus $\, P = 2^a p,\ Q = 2^b q\,$ for $\,p,q\,$ odd. Therefore $\, P^2 = 2 Q^2\,$ $\Rightarrow$ $\,2^{\color{#c00}{2a}} p^2 = 2^{\color{#0a0}{1+2b}} q^2$ for $\,p^2,q^2\,$ odd, contra to said uniqueness, since LHS has $\rm\color{#c00}{even}$ power of $2$ but RHS has $\rm\color{#0a0}{odd}$ power.

Remark $\$ This is a single-prime $(p=2)$ special case of Fundamental Theorem of Arithmetic, i.e. the existence and uniqueness of prime factorizations of form $\,2^a n,\,$ for $\,n,\,$ odd. This follows by a simple inductive proof (much simpler than the general case of FTA).

I'm sorry, but try to understand this proof, which is the traditional one.

$\sqrt{2} = \dfrac{m}{n}\$ where $\textrm{gcd}(m,n) = 1$

$2n^2 = m^2 \Rightarrow 2 \mid m^2 \Rightarrow 2\mid m \Rightarrow m^2 = 4L^2$

$2n^2 = 4L^2 \Rightarrow 2 \mid n^2 \Rightarrow 2 \mid n \Rightarrow \textrm{gcd}(m,n) \not = 1$ which is a contradiction.

Edit: $\sqrt{2} = \frac{m}{n}$.

If $\textrm{gcd}(m,n) = d>1$ then we can write $m = dx$ and $n = dy \Rightarrow \sqrt{2} = \dfrac{dx}{dy} = \dfrac{x}{y}$.

Then $\textrm{gcd}(x,y) = 1$. You can prove this by assuming for the sake of contradiction that it is not and showing that you get a divisior of $m,n$ which is greater than $d$.

• thats what i wrote i have used 2 general integers p and q, not the ones with gcd = 1., that proof one can easily find anywhere , this proof occured to my mind instantly. btw, what are you feeling sorry about? – Gustav Friedriech Wilhelm Jun 9 '15 at 2:08
• It seems like the point of the added complexity in OP's proof is to avoid the assumption $(m,n)=1$. Could you add some info on why it is okay to assume this WLOG? – Mario Carneiro Jun 9 '15 at 2:08
• Okay, I made an edit. – Mr.Fry Jun 9 '15 at 2:12
• its ok mr. fry but i was just looking for someone to verify the proof i have written and whether its agreeable or not – Gustav Friedriech Wilhelm Jun 9 '15 at 2:16
• You will really have to do some latex editing. I wouldn't be surprised if anyone has read the proof. As it stands it is very difficult to read. – Mr.Fry Jun 9 '15 at 2:17

Your approach is basically correct, but far too complicated, and it leads you into some trouble. For example, you write that $\frac{f_1^2}{f_2^2}$ is odd, but it may not be an integer, and you don't say what it means for a fraction to be odd. These problems can be repaired, but I recommend taking a simpler approach altogether.

You made the most important observation: we can write an integer as the product of an odd number and a power of $2$. So $p = 2^k a$, $q=2^l b$, where $a,b$ are odd integers, and $k,l$ are nonnegative integers.

Then $p^2 = 2q^2 \iff 2^{2k}a^2 = 2^{2l+1} b^2$. Since the number of powers of $2$ dividing an integer is unique, we have $2k=2l+1$. But an even integer cannot equal an odd integer, contradiction.

This is not any different from your proof—the core idea and most of the logic is nearly identical—but it avoids a lot of troubles by not breaking into cases.

• @GustavFriedriechWilhelm It's not necessarily either an integer or the reciprocal of an integer. What's true is that $2$ does not appear in either the numerator or the denominator, but you might add more of an explanation of why this implies that it cannot yield $2$ when multiplied by a power of $2$ (or the reciprocal of a power of $2$). I still recommend simplifying your approach, rather than adding more cases. – Slade Jun 9 '15 at 3:19
• you are right that $f_1^2$/$f_2^2$ is not necessarily odd integer but overall its an odd factor since it can be odd/odd integers ratio – Gustav Friedriech Wilhelm Jun 9 '15 at 3:19
• lets take some examples : say 6 = 2 * 3 , 6 * (1/3) =2 since 6 has 3 as one of its factor but what about 8 * (1/3) it can never equal 2 since 8 is pure even ie: only 2 or 1 as its factor and thus can't yield 2 meaning any pure even no ( or $2^n$ ) * some odd factor can never yield 2, for any possibility of 2 to come, the factor multiplied with $2^n$ must be pure even ie: (1 / $2^n_1$) – Gustav Friedriech Wilhelm Jun 9 '15 at 3:31
• @GustavFriedriechWilhelm I know what you're saying. If you look closely at the proof I've written, I am making precisely your argument with cleaner language. Bill has made the same point in his answer. – Slade Jun 9 '15 at 3:33
• @GustavFriedriechWilhelm Keep in mind, if you are asking about the formal correctness of the proof, that you need to say what you mean by terms like "pure even". Your argument is correct, but I say again that you should work on simplifying it and clarifying your ideas. – Slade Jun 9 '15 at 3:34

So continuing your way i.e not assuming gcd(p,q) = 1,

$2 = \frac{p^2}{q^2}$

This implies, $p^2=2q^2$.

As power of 2 in $q^2$ is even, power of 2 in $p^2$ will be odd. This is not possible as power of every prime in square of an integer is even.

• thats what i have written k_1 - k_2 can't be 0.5 since only integral difference is possible, see my 2nd condition of case 1. i just explained it in words so that it could be understood by anybody – Gustav Friedriech Wilhelm Jun 9 '15 at 14:09
• But in my prof, I didn't need to consider any cases – A C Jun 9 '15 at 15:06
• you said power of 2 in $q^2$ is even meaning you have considered q as an even no. – Gustav Friedriech Wilhelm Jun 9 '15 at 15:12
• But in square of an odd number, the power of 2 is also even – A C Jun 9 '15 at 15:13
• 0 is even. So by fundamental theorem of arithmetic, power of any prime in square of any integer is even – A C Jun 9 '15 at 15:19