Problem:
Find the number of ordered pairs (m,n) such that m and n are positive integers in the set {1,2,β¦,30} and the greatest common divisor of 2m+1 and 2nβ1 is not 1.
Solution:
Answer (295):
Note that
gcd(2pβ1,2qβ1)=gcd((2qβ1)2pβq+2pβqβ1,2qβ1)=gcd(2pβqβ1,2qβ1)
Repeatedly applying this procedure, which is just the Euclidean algorithm applied to the exponents p and q, yields gcd(2pβ1,2qβ1)=2gcd(p,q)β1. Because 2m+1 and 2mβ1 are coprime and 2m+1=2mβ122mβ1β, it follows that
gcd(2m+1,2nβ1)=gcd(2mβ1,2nβ1)gcd(22mβ1,2nβ1)β=2gcd(m,n)β12gcd(2m,n)β1β
If the power of 2 that divides n is greater than the power of 2 that divides m, then gcd(2m,n)=2gcd(m,n). Otherwise, gcd(2m,n)=gcd(m,n). Therefore an ordered pair (m,n) satisfies the required condition precisely when the power of 2 that divides n is greater than the power of 2 that divides m.
Break the given set into five subsets S0β={1,3,5,β¦,29},S1β={2,6,10,β¦,30},S2β={4,12,20,28},S3β={8,24},S4β={16}, where positive integer xβ€30 belongs to set Skβ if k is the greatest exponent of a power of 2 dividing x. The desired number of ordered pairs is equal to
β£S0ββ£β
(β£S1ββ£+β£S2ββ£+β£S3ββ£+β£S4ββ£)+β£S1ββ£ββ
(β£S2ββ£+β£S3ββ£+β£S4ββ£)+β£S2ββ£β
(β£S3ββ£+β£S4ββ£)+β£S3ββ£β
β£S4ββ£=15β
15+8β
7+4β
3+2β
1=295.β
The problems and solutions on this page are the property of the MAA's American Mathematics Competitions