Let S={(m,n):m,n∈{1,2,3,…..,50}}. If the number of elements (m,n) in S such that 6m+9n is a multiple of 5 is p and the number of elements ( m,n ) in S such that m+n is a square of a prime number is q ,...
Answer: 1333
Solutions · 1
Official solution
Since 6≡1(mod5), we have 6m≡1(mod5) for all m. Since 9≡−1(mod5), we have 9n≡(−1)n(mod5).
So 6m+9n≡1+(−1)n(mod5), which is 0(mod5) exactly when n is odd (giving 1−1=0).
Thus m can be any of 50 values, and n must be one of the 25 odd values in {1,…,50}:
\[p = 50 \times 25 = 1250\]
For q: we need m+n to equal the square of a prime, with m,n∈{1,…,50}, so m+n∈{2,…,100}. The squares of primes in this range are 4,9,25,49 (since 112=121>100).
For a fixed sum s=m+n with 2≤s≤51, the number of ordered pairs (m,n) is s−1.
- s=4⇒3 pairs
- s=9⇒8 pairs
- s=25⇒24 pairs
- s=49⇒48 pairs
q=3+8+24+48=83p+q=1250+83=1333