Browse · MATH
Printjmc
number theory intermediate
Problem
As ranges over the positive integers, what is the sum of all possible values of the greatest common divisor of and ?
Solution
We can apply the Euclidean algorithm here. There are three cases to consider:
Case 1: is odd. Therefore, and 4 are relatively prime and have a greatest common divisor of 1.
Case 2: is a multiple of 2, but not a multiple of 4. In this case, and 4 share a common factor of 2. Since 4 has no other factors, and 4 have a greatest common divisor of 2.
Case 3: is a multiple of 4. In this case, and 4 have a greatest common divisor of 4.
Therefore, the three possible values for the greatest common divisor of and are 1, 2, and 4. It follows that the sum of all possible value of the greatest common divisor of and is .
Case 1: is odd. Therefore, and 4 are relatively prime and have a greatest common divisor of 1.
Case 2: is a multiple of 2, but not a multiple of 4. In this case, and 4 share a common factor of 2. Since 4 has no other factors, and 4 have a greatest common divisor of 2.
Case 3: is a multiple of 4. In this case, and 4 have a greatest common divisor of 4.
Therefore, the three possible values for the greatest common divisor of and are 1, 2, and 4. It follows that the sum of all possible value of the greatest common divisor of and is .
Final answer
7