by HallsofIvy » Wed Apr 24, 2019 8:53 am
Strictly speaking the "Chinese remainder theorem" does not apply to the first problem. The "Chinese remainder theorem" says that a set of equations of the form "x= b (mod n)" has a solution if the "n"s are relatively prime. In your first problem, 3 and 9 are not relatively prime. There may or many not be a solution.
If x= 5 (mod 9) then x= 9i+ 5 for any integer I. Then, since 9 is a multiple of 3, x= 3(3i)+ 3+ 2= 3(3i+1)+ 2 so any solution of x= 5 (mod 9) is also a solution of x= 3 (mod 3). So, in this case there is a solution but notice that if the equation were x= a (mod 3) for a= 0 or 1, there would not.
Since x= 9i+ 5= 7 (mod 11), 9i= 2 (mod 11). That is, 9i= 2+ 11j for some integer j. That is the Diophantine equation 9i- 11j= 2. An obvious solution is i= -1, j= -1, since 9(-1)- 11(-1)= -9+ 11= 2. But it is also true that i= -1+ 11k, j= -1+ 9k is a solution for any k: 9(-1+ 11k)- 11(-1+ 9k)= -9+ 99k+ 11- 99k= 2 for all k. So i= -1+ 11k which can also be written i= 10+ 11m with m= k- 1.
So x= 9i+ 5= 9(10+ 11m)+ 5= 95+ 99m.
The three equations are all satisfied by x= 95+ 99m for m any integer.
Check:
x= 95+ 99m= 3(31)+ 2+ 3(33m)= 2 (mod 3)
x= 95+ 99m= 3(30)+ 5+ 9(11m)= 5 (mod 9)
x= 95+ 99m= 8(11)+ 7+ 11(9m)= 7 (mod 11).
The second problem is much the same (except that 3, 7, and 11 are relatively prime so the "Chinese remainder theorem does apply).