I'm having a lot of trouble setting up the equations for the following question where I need to use the chinese remainder theorem.(adsbygoogle = window.adsbygoogle || []).push({});

Q. Fifteen pirates steal a stack of identical gold coins. When they try to divide them evenly, two coins are left over. A fight erupts and one of the pirates is killed. The remaining pirates try again to evenly distribute the coins. This time there is one coin left over. A second pirate is killed in the resulting argument. Now when the remaining pirates try to divide the coins evenly there are no coins left over. Use the Chinese Remainder Theorem to find the smallest number of coins that could have been in the sack.

The first thing that I'm unsure about is what the number of pirates left has to do with the question. If I ignore it I get the following equations.

x = 2(mod2)

x = 1(mod2)

x = 0(mod2)

But then I get x = 2(b_1)(4) + (1)(b_2)(4) + 0 (mod8)

where b_1 is the multiplicative inverse of 4 in Z_2 and the other 4 is also the multiplicative inverse of 2 in Z_4. But gcd(4,2) not equal to one so b_1 and b_2 'can't exist.' So I must be doing something wrong. I'm not sure how to set up the equations so could someone please help me out?

**Physics Forums | Science Articles, Homework Help, Discussion**

Dismiss Notice

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Homework Help: Chinese remainder theorem problem

**Physics Forums | Science Articles, Homework Help, Discussion**