x=2(mod 3) x=3(mod 7) x=7(mod 5) find a unique incongruent solution to modulo n. (number theory problem using chinese remainder theorem) please help!!
I did not know about the chinese remainder theorem but searched for it online and learnt it as I found it interesting - so please treat my solution with a "pinch of salt". Note that your third equation can be simplified to x=2(mod 5) as you can remove a 5 from 7 to get 2. But I'll work with what you have given. \[\begin{align} b_1&=3,b_2=7,b_3=5\\ C_1&=2,C_2=3,C_3=7\\ \\ B&=b_1*b_2*b_3=3*7*5=105\\ B_1&=B/b_1=B/3=105/3=35\\ B_2&=B/b_2=B/7=105/7=15\\ B_3&=B/b_3=B/5=105/5=21\\ \\ B_iX_i&=1(\text{mod }b_i)\\ B_1X_1&=1(\text{mod }b_1)\\ \therefore 35X_1&=1(\text{mod }3)\\ \therefore 2X_1&=1(\text{mod }3)\quad\text{(as 33 is largest multiple of 3<35, 35-33=2)}\\ \therefore 2X_1&=4(\text{mod }3)\quad\text{(1+3=4)}\\ \therefore X_1&=2\\ \\ B_2X_2&=1(\text{mod }b_2)\\ \therefore 15X_2&=1(\text{mod }7)\\ \therefore X_2&=1(\text{mod }7)\quad\text{(as 14 is largest multiple of 7<15, 15-14=1)}\\ \therefore X_2&=1\\ \\ B_3X_3&=1(\text{mod }b_3)\\ \therefore 21X_3&=1(\text{mod }5)\\ \therefore X_3&=1(\text{mod }5)\quad\text{(as 20 is largest multiple of 5<21, 21-20=1)}\\ \therefore X_3&=1\\ \\ x&=B_1X_1C_1+B_2X_2C_2+B_3X_3C_3\\ &=35*2*2+15*1*3+21*1*7\\ &=140+45+147\\ &=332 \end{align}\]this is just one possible solution. in general you can add or subtract multiples of \(B=105\) from this value to get other solutions. so we could write the general solution as:\[x=332+105n\qquad n=-\infty,...,\infty \]
Join our real-time social learning platform and learn together with your friends!