# Proving $n^2=n$, $n$ is even and $n$ is greater than $0$ is false

I am wondering if I have made a wrong jump in logic with my answering to this question.

The original statement goes "There exists an integer $$n$$ such that $$n^2=n$$, $$n$$ is even and $$n$$ is greater than $$0$$".

I have taken the approach of first defining that if $$n$$ is even, than $$n=2k$$ where $$k$$ is of the set of integers.

I have then substituted this into $$n^2=n$$ by saying that $$(2k)^2=(2k)$$, and as such $$2k=1$$. Given this I have concluded it to be false as there is no integer $$k$$ such that $$2k=1$$.

I am worried about this logic though because if $$n$$ is equal to $$0$$ (which is an even number that fits the definition of $$2k$$) then $$n^2=n$$ is true which seems to go against my previous logic (which is where the final comparison to $$n$$ having to be greater than $$0$$ would come in).

Am I right in being worried about the direction I have taken this logic? If so where have I gone wrong in my line of thinking? Thank you for all help.

• To get $2k=1$ you divided both sides by $k$. But if $n=0$ then $k=0$. – halrankard Aug 25 at 12:43
• You can't divide by $2k$ if $2k=0$, because we don't divide things by $0$. – Eod J. Aug 25 at 12:47
• Thank you for clarifying on that, I hadn't considered that important detail at all in my assumptions. – James Aug 25 at 12:47

## 3 Answers

You did (implicitly) make use of the assumption that $$n > 0$$. Since $$n >0$$, your $$k$$ cannot be $$0$$. Thus it is okay to divide by $$k$$, which you did in your proof when you moved from $$4k^2=2k$$ down to $$2k=1$$.

Good for you for thinking about this!

• Thank you for the answer. I see now the implicit assumption that I made. – James Aug 25 at 12:49

We have $$n^2=n$$ implies $$n^2-n=0$$, i.e., $$n(n-1)=0.$$ Thus either $$n=0$$ or $$n=1$$, but, by hypothesis, both these options are impossible. (They are the only possible solutions by inspection and the fundamental theorem of algebra; moreover, by the quadratic formula,

\begin{align} n&=\frac{-(-1)\pm\sqrt{(-1)^2-4(1)(0)}}{2(1)}\\ &=\frac{1\pm 1}{2}\\ &=0\text{ or }1.) \end{align}

• I am not quite sure I fully understand this implication? I see that if n^2=n then n=1 then n-1=0 where n is not equal to 0. How were you able to get n(n-1)=0 from this may I ask? – James Aug 25 at 13:03
• I've edited my answer, @James. Does that help? – Shaun Aug 25 at 13:10
• That does help, thank you for the clarification. – James Aug 25 at 13:15
• You're welcome, @James. – Shaun Aug 25 at 14:40
• $$n^2=0$$ $$n^2 - n = 0$$ Factorizing, $$n(n - 1) = 0$$ and you can do the rest. – SAGNIK UPADHYAY Aug 25 at 15:44

The flaw lies in the implication

$$(2k)^2=2k\implies 2k=1.$$

This claim is indeed false when $$k=0$$.

$$0=0\not\Longrightarrow 0=1.$$

• Notice that no "division by zero" argument is necessary. – Yves Daoust Aug 25 at 14:44