I want to prove that if $n^2$ is even then $n$ is even directly without using the contrapositive or the contradiction methods.
-
2One issue with this question is the definition of a prime. $p$ is a prime means that if $p|ab$ then $p|a$ or $p|b$. This can be expressed positively - $p$ divides one of the factors - but in proofs it is often used in a negative form - if $p$ does not divide $a$ then it must divide $b$. 2 is a prime, and there is a positive way of stating the case you have, which you should be able to work out from here. However, this could be seen as burying the negative aspect in the definition of 'prime'. So it depends how deep you want to get philosophically. – Mark Bennet Mar 12 '12 at 15:42
-
12$2$ is prime; if $2|nn$, then $2|n$ or $2|n$, hence $2|n$. – Arturo Magidin Mar 12 '12 at 15:46
-
User 22705 shows how you can use the division algorithm to do this. – Mark Bennet Mar 12 '12 at 15:57
-
3Actually a simple modification to Day Late Don's solution is the simplest: if $n^2$ is even, then $n=n(n+1)-n^2$ is the difference between two even numbers. – N. S. Mar 12 '12 at 19:42
-
It seems to me that the appropriate answer to this question requires more information on the motivation for the question. The point might just be that the OP wants a proof that will work for grade-school kids who aren't comfortable with contrapositives and proof by contradiction. In that case, N.S.'s comment might be a good answer. But if the point is to see what we can do in number theory using nonclassical logic, then that's a different matter. For example, if we're using intuitionistic logic, then we don't know that $(n \ \text{is odd})\vee\neg(n\ \text{is odd})$ is a tautology. – Mar 12 '12 at 20:48
6 Answers
Hint $ $ a direct proof by $\,\rm\color{#c00}{I\! =\! induction}$: $ $ base: $\rm\, 2\ |\ n^2\Rightarrow2\ |\ n\,$ is true for $\rm\,n = 0,1.\,$ Inductive step:
$$\rm 2\ |\ (n\!+\!1)^2 = (n\!-\!1)^2\! + 4n\ \Rightarrow\ 2\ |\ (n\!-\!1)^2\, \color{#c00}{\overset{\!\rm I}\Rightarrow}\ 2\ |\ n\!-\!1\ \Rightarrow\ 2\ |\ n\!+\!1\qquad$$
Similarly we may prove $\rm\: 2\ |\ nk\:\Rightarrow\: 2\ |\ n\ \ or\ \ 2\ |\ k\ $ (PDP = Prime Divisor Property for $\rm\,p = 2)\,$
$$\rm\ 2\ |\ (n\!+\!1)k = (n\!-\!1)k + 2k\ \Rightarrow\ 2\ |\ (n\!-\!1)k\, \color{#c00}{\overset{\!\rm I}\Rightarrow}\ 2\ |\ n\!-\!1\ \ or\ \ 2\ |\ k\ \Rightarrow\ 2\ |\ n\!+\!1\ \ or\ \ 2\ |\ k$$
OP is the special case $\rm\, k = n$ and $\rm\,p=2\,$ of PDP (also known as Euclid's Lemma).
The proof is essentially a brute-force modular case-analysis. It verifies the result for a complete system of least residues modulo $2,\:$ viz. $\rm\:0,1,\:$ and then, by induction, lifts this proof to all naturals, using the fact that the property $\rm\:P\:$ is true for $\rm\:n\:$ implies that it is true for $\rm\:n+2,\:$ i.e. $$\rm P(0),\ P(1),\ [P(n)\Rightarrow P(n+2)]\ \Rightarrow\ \ \forall n\: P(n)$$
Similarly there are brute-force residue case-analyis proofs of the prime divisor property for any fixed prime (as known to the ancient Greeks). Such proofs amount to brute-force checking all entries of the multiplication table for integers modulo $\rm\:\!p,\,$ to verify that a product is zero implies that some factor is zero. But proving this true for all primes requires a new idea. For the integers this idea is that gcds exist for all naturals (by the Euclidean algorithm), hence $$\rm\:p\ |\ ab\ \Rightarrow\ p\ |\ pb,ab\ \Rightarrow\ p\ |\ gcd(pb,ab) = \color{#0a0}{\gcd(p,a)}b\qquad$$
$\rm p\:$ prime $\:\!\Rightarrow\:\!$ $\rm\color{#0a0}{d:= gcd(p,a)} = \color{#c00}p\:\!\ or\ 1$. $\rm\,\ \color{#0a0}d\!=\!\color{#c00}p\:$ $\Rightarrow$ $\rm\:p\:|\:a.\:$ $\rm\,\color{#0a0}d\!=\!\color{#c00}1\:$ $\Rightarrow$ $\rm\:p\:|\:\color{#0a0}db = b.$
Hence we've proved: $\:$ prime $\rm p\ |\ ab\ \Rightarrow\ p\ |\ a\ \ or\ \ p\ |\ b\quad\ \ $ [Prime Divisor Property for $\mathbb Z\:$]
This prime divisor property is easily shown to be equivalent to the uniqueness of factorizations into irreducibles. In domains that don't have unique factorization, irreducibles need not satisfy the prime divisor property. In such general domains, the term "prime" is used to denote those irreducibles that do satisfy this prime divisor property (Euclid's Lemma).
The same proof as above shows that irreducibles satisfy the prime divisor property in any integral domain where gcds exist, e.g. Euclidean domains which, like $\mathbb Z$, enjoy a Division Algorithm. One well-known example is the ring $\rm F[x]$ of polynomials over a field $\rm F,\:$ which enjoy the high-school polynomial long division algorithm.

- 272,048
This is easily possible using prime factor decomposition. Just consider how often the prime factor "2" occurs in $n^2$ and deduce that 2 divides $n$.

- 9,091
-
You don't really need a prime factor decomposition, just that $p$ prime and $p$ divides $ab$ implies $p$ divides $a$ or $p$ divides $b$. – lhf Mar 12 '12 at 16:32
Hint: Let $n^2$ be even. Then $n^2=2k$, for some integer $k$. Moreover, by the Fundamental Theorem of Arithmetic, $n^2$ has prime-power decomposition $n^2=\left(p_1^{a_1}p_2^{a_2}\cdots p_s^{a_s}\right)^2=p_1^{2a_1}p_2^{2a_2}\cdots p_s^{2a_s}$, for some positive integers $s$ and $a$.

- 6,218
- 5
- 45
- 96
One can show that if $(a,b)=1$ and $a|bc$ then $a|c$.
Proof: If (a,b)=1 then $ax+by=1$ for integers $x,y$. We also have $bc=ka$ for some integer $k$, but then $c=1a=acx+bcy=a(cx+ky)$. Hence $a|c$.
Now for any prime $p$ and integer $n$ we have $(p,n)=1$ or $(p,n)=p$. In either case $p|n$. Putting in your particular example of $p=2$ yields want you want.

- 2,394
Here's a proof by induction. It's similar to Bill's proof but doesn't use the Prime Divisor Property.
$P(n)$: $n^2$ is even iff $n$ is even.
Proof: $(n=1)$: ''$1^2$ is even'' and ''$1$ is even'' are both false so $P(1)$ is true.
(Inductive step): Assume $P(n)$: $n^2$ is even iff $n$ is even.
Now assume $(n+1)^2$ is even. Then $n^2 + 2n + 1$ is even which means that $n^2$ is odd. By the induction hypothesis $n$ is odd, in which case $n+1$ is even. On the other hand, if $n+1$ is even, then clearly $(n+1)^2$ is even.
This completes the proof.

- 1,354
- 8
- 10