Let \(n\) be a positive integer. Find the sum of all possible values of \(\gcd(5n+11,n+7)\).
Solution
Answer: \(60\)
By the Euclidean algorithm,
\[\gcd(5n+11,n+7)=\gcd(n+7,24).\]
Every divisor of \(24\) can occur. They are \(1,2,3,4,6,8,12,24\), and their sum is \(60\).
Bonus problem from the PDF: solve the analogous problem for arbitrary \(\gcd(an+b,cn+d)\).