Remainders Of Powers Of 2

For all n N , n \in \mathbb{N}, let S n S_n be the set of all possible remainders when a power of 2 2 , to a non-negative exponent, is divided by n . n. Find the number of positive integers n 1000 n \leq 1000 for which the sum of elements of S n S_n is a multiple of n . n.

Details and assumptions

  • 1 = 2 0 1= 2^0 is a power of 2 2 to a non-negative exponent.

  • As an explicit example, when n = 5 , n=5, we list down the first few residues of 2 x ( m o d 5 ) . 2^x \pmod{5}. x 2 x 2 x ( m o d 5 ) 0 1 1 1 2 2 2 4 4 3 8 3 4 16 1 \begin{array}{|c|c|c|} \hline x & 2^x & 2^x \pmod{5} \\ \hline 0 & 1 & 1 \\ \hline 1 & 2 & 2 \\ \hline 2 & 4 & 4 \\ \hline 3 & 8 & 3 \\ \hline 4 & 16 & 1 \\ \hline\end{array} The residues 2 x ( m o d 5 ) 2^x \pmod{5} become periodic from now on. Thus, S n = { 1 , 2 , 4 , 3 } . S_n= \{1, 2, 4, 3\}. The sum of elements of S n S_n is 1 + 2 + 4 + 3 = 10 , 1+2+4+3= 10, which is a multiple of 5. 5.

  • The elements of the set S n S_n are distinct.


The answer is 500.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

We do casework based on the parity of n . n.

  • Case 1: n n is even.

Note that the only power of 2 2 which is odd is 1. 1. All other elements in S n S_n are even. The sum of the elements of S n , S_n, therefore, is odd. Since no odd number can be a multiple of an even number, n n can't be even.

  • Case 2: n n is odd.

Let r r be the order of 2 2 modulo n , n, so 2 r 1 ( m o d n ) . 2^r \equiv 1 \pmod{n}. Since the residues 2 x ( m o d n ) 2^x \pmod{n} become periodic after 2 r , 2^r, the elements of S n S_n are equivalent to { 2 0 , 2 1 , , 2 r 1 } \{2^0, 2^1, \cdots , 2^{r-1}\} modulo n . n. Modulo n , n, the sum of elements of S n S_n is 2 0 + 2 1 + + 2 r 1 2 r 1 ( m o d n ) 1 1 ( m o d n ) 0 ( m o d n ) . \begin{array}{lcll} 2^0 + 2^1 + \cdots + 2^{r-1} & \equiv & 2^r-1 & \pmod{n} \\ & \equiv & 1-1 & \pmod{n} \\ & \equiv& 0 & \pmod{n}. \end{array}

Conclusion: All such n n are the odd positive integers.

There are 500 \boxed{500} odd integers between 1 1 and 1000 , 1000, which is our answer.

Can you share the source of this problem with us? I like problems of this kind :D

Adel Ali - 7 years, 1 month ago

Log in to reply

I made this problem myself.

Sreejato Bhattacharya - 7 years, 1 month ago

Log in to reply

Oh that's fabulous! I really liked it!

Adel Ali - 7 years, 1 month ago

Log in to reply

@Adel Ali Thanks!

Sreejato Bhattacharya - 7 years, 1 month ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...