number system

This topic has expert replies
Source: — Problem Solving |

User avatar
Master | Next Rank: 500 Posts
Posts: 149
Joined: Wed May 01, 2013 10:37 pm
Thanked: 54 times
Followed by:9 members

by Atekihcan » Wed Jun 05, 2013 3:07 am
vipulgoyal wrote:if 2^20.n is dividable by 3 which of the following could be value of n
I'm assuming it should be (2^20 - n)

Now (2^n - 1) is always divisible by 3 if n is even positive integer.
This can be proved by...
# Algebra
If n is even, then it must be of the form n = 2k
So, (2^n - 1) = (2^(2k) - 1) = ((2^k)^2 - 1) = (2^k - 1)(2^k + 1)
Now, (2^k - 1) and (2^k + 1) are consecutive odd integers.
So, exactly one of them is divisible by 3.
So, their product is divisible by 3

# Picking numbers
If n = 0, (2^0 - 1) = 0 --> Divisible by 3
If n = 2, (2^2 - 1) = 3 --> Divisible by 3
If n = 4, (2^4 - 1) = 15 --> Divisible by 3
If n = 6, (2^6 - 1) = 63 --> Divisible by 3
...

Now, back to our problem...
  • 1. n = 0, (2^20 - n) = 2^20 --> Not a multiple of 3
    2. n = 1, (2^20 - 1) --> As 20 is an even integer, (2^20 - 1) is divisible by 3
    3. n = 4, (2^20 - 4) = (2^20 - 2^2) = (2^2)(2^18 - 1) --> As 18 is an even integer, (2^18 - 1) is divisible by 3
So, 2 and 3 are correct answers.

Apologies if the problem meant to ask something different.

Master | Next Rank: 500 Posts
Posts: 468
Joined: Mon Jul 25, 2011 10:20 pm
Thanked: 29 times
Followed by:4 members

by vipulgoyal » Wed Jun 05, 2013 4:03 am
yes it is (2^20 - n), my mistake, Thanks, very well explained