Find the possible nonnegative integer values of
X so that:
corresponds to a nonnegative integer power of 2.
Prove that no other value of X conforms to the given conditions.
Note: Adapted from a problem appearing at Spanish Mathematical Olympiad in 1986.
Lets start with some small values of x, three of them are valid solutions:
x=0 -> 5^0+3=2^2
x=1 -> 5^1+3=2^3
x=3 -> 5^3+3=2^7
Then we'll take 5^x+3 mod 256. If there are any solutions with x>3 then this will be a multiple of 256, so then 5^x=253 mod 256.
I used a spreadsheet to calculate values of 5^x mod 256. The residues have a 64 cycle period and at x=35 we have 5^35 mod 256=253.
So any further solutions are of the form x=64k+35.
Plug this back in and we'll have 5^(64k)*5^(35) + 3 equals a power of 2. This time we'll use mod 257.
Powers of 2 mod 257 can take values 1, 2, 4, 8, 16, 32, 64, 128, 129, 193, 225, 241, 249, 253, 255, 256.
5^35 = 14 and mod 257 and 5^64 = 16 mod 257. Then 5^(64k) = 16^k mod 257 takes on values of 1, 16, 241, 256.
Then 5^(64k)*5^(35) + 3 mod 257 = 17, 227, 36, 246.
But none of the values match the powers of 2 mod 257. Thus we conclude there are no larger solutions than the three small values x=0, 1, 3.