Remaining Remainder

1234 r m o d n 2340 r m o d n 3446 r m o d n 5500 r m o d n \begin{array}{rl} 1234 &\equiv r \bmod n\\ 2340 &\equiv r \bmod n\\ 3446 &\equiv r \bmod n\\ 5500 &\equiv r \bmod n \end{array}

If the positive integral solutions ( r , n ) (r,n) satisfy the system of congruences, such that r < n r < n , input the sum of all possible values of r + n r + n as your answer.


The answer is 414.

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

Pi Han Goh
Feb 10, 2021

The four numbers 1234 r , 2340 r , 3446 r , 5500 r 1234 - r, 2340 - r, 3446-r, 5500-r are all divisible by n n .

Then, the difference between any 2 of these 4 numbers above are all also divisible by n n .

We have ( 2340 r ) ( 1234 r ) = 1106 m o d n = 0 , ( 5500 r ) ( 3446 r ) = 2054 m o d n = 0 (2340-r) - (1234- r) = 1106 \mod n = 0 , \quad \quad (5500-r) - (3446-r) = 2054 \mod n = 0

In other words, both 1106 and 2054 are multiples of n n .

Since 1106 = 2 × 7 × 79 , 1106 = 2\times7\times79, all the factors of 1106 are 1 , 2 , 7 , 14 , 79 , 158 , 553 , 1106 1,2,7,14,79,158,553, 1106 .

Similarly, 2054 = 2 × 13 × 79 , 2054 = 2\times13\times79, all the factors of 2054 are 1 , 2 , 13 , 26 , 79 , 158 , 1027 , 2054 1,2,13,26,79,158,1027,2054 .

We have narrowed down the possible values of n n to 1 , 2 , 79 , 158 1,2,79,158 .

However, if n = 1 n = 1 , then r = 0 r = 0 is forced, but this we want a positive remainder r r . So n = 1 n=1 is rejected. We reject n = 2 n=2 for the same reason.

We are left with n = 79 , 158 n = 79,158 .

Performing long division shows that when 1234 , 2340 , 3446 , 5500 1234,2340,3446,5500 are all divided by 79, the remainders are all equal to 49.

Analogously, performing long division shows that when 1234 , 2340 , 3446 , 5500 1234,2340,3446,5500 are all divided by 158, the remainders are all equal to 128.

Hence, all the possible values of ( r , n ) (r,n) are ( 49 , 79 ) , ( 128 , 158 ) (49,79), (128,158) . The answer is 49 + 79 + 128 + 158 = 414 . 49+79+128+158 = \boxed{414} .


Too much work? Just want to write a script? Here you go:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# The divisor N cannot exceed 5500, otherwise, the remainders will not all be distinct.

answer = 0
for n in range(1, 5500):
    if 1234 % n == 2340 % n == 3446 % n == 5500 % n:
        r = 1234 % n
        if r > 0 :
            answer += n + r

print(answer) # Output: 414

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...