Prove that the square of any positive integer is in the form of either \(3m+1\) or \(3m\) for some integer \(m\).

\(n^{2}\) = \(3m+1\)

or

\(n^{2}\) = \(3m\)

*I couldnt get this, so decided to post it to see if anyone knows how it can be done*
*Post your proofs below please :)*

## Comments

Sort by:

TopNewestFIRST- a^2={3q}^2 a^2=9q^2 a^2=3(3q^2) a^2=3m,where m=3q^2 SECOND- a=3q+1 a^2={3q+1}^2 a^2=9q^2+1+2(3q*1) a^2=9q^2+1+6q a^2=3(3q^2+2q)+1 a^2=3m+1,where m=3q^2+2q – Anmol Singh · 2 years, 8 months ago

Log in to reply

– Chinmay Raut · 2 years, 8 months ago

ThnksLog in to reply

So this question could also be phrased, show that n^2 is 0 or 1 modulo 3.

The great thing about modulo is that you can multiply things. So we only need to try n being 0, 1, 2 modulo 3.

2^2 = 4 = 1 mod 3 The other two are trivial and left as an exercise for the reader. – Nathan Edwards · 2 years, 8 months ago

Log in to reply

– Chinmay Raut · 2 years, 8 months ago

ThknxLog in to reply