Solution to drug drinking in Rats

Source: Internet
Author: User

Another interesting question today will be shared.

As usual, of course I think this topic is interesting and has the value of research. The questions are as follows:

"32 bottles of liquid, 1 bottle of toxic, the mouse drank for 1 hour to die, use 1 hour to determine at least 30 bottles of non-toxic, at least how many mice are needed ."

My solution is as follows:

It is also a problem of finding the optimal solution. To solve this problem, we need to use the best information that a mouse can use to achieve the optimal solution. First, assume that N mice can clearly determine at most the bottle of poison in the F (n) bottle of liquid.

So

1. For the N mice, each mouse drinks a bottle of liquid, which determines the only bottle of poison in the C (n, 1) bottle of liquid.

2. Based on the number that can be determined by 1, after combining N mice and drinking a bottle of liquid for each group, there will be a combination of C (n, 2, determine more C (n, 2) bottles of liquid.

3. Based on the numbers 1 and 2 that can be determined, after a group of N rats is combined, each group drinks a bottle of liquid, there are C (n, 3) combinations, determine more C (n, 3) bottles of liquid.

......

N. Based on the number as determined by [1, n-1], all N rats drink a bottle of liquid, and there are C (n, n) combinations, determine more C (n, n) bottles of liquid.

Then, F (n) = C (n, 1) + C (n, 2) +... + C (n, n) = 2 ^ N;

It is known that F (n) = 32, and n = 5 is obtained.

That is to say, at least five mice can determine which of the 32 bottles of liquid is poison. (Note: here the poison is clearly identified)

 

But the question is only: "at least 30 bottles are not toxic".

According to the above solution, only four mice are needed. The procedure is as follows:

Four mice lined up and packed 32 bottles of liquid together, which became 16 bottles.
1st large bottles of liquid, binary 0001, for 1st mice (4 mice, corresponding to 4 locations, for the corresponding location of 1 mice)
2nd bottles of liquid, binary 0010 for 2nd Mice
3rd large bottles of liquid, binary 0011 for 1st, 2 mice to drink

......

15th bottles of liquid, binary 1111 for 1st, 2, 3, 4 mice
16th large bottles of liquid (can be understood as 0th bottles of liquid, corresponding to binary 0000), do not give any mouse drink.

An hour later, if a mouse is dead, enter 1 in the corresponding position. If not, enter 0. In this way, a binary value can be obtained after an hour, you can find the corresponding liquid according to the above method.

For example, 1st and 2 mice are dead, and 3 and 4 are not dead. The resulting binary number is 0011, corresponding to 3rd large bottles of liquid toxic. In this way, it is determined that the other 30 bottles of liquid are non-toxic and the target is fulfilled.

Another example: No mouse died, and the resulting binary number was 0000, that is, the 16th bottles of liquid were toxic. The remaining 30 bottles of liquid are non-toxic.

 

Like the previous Solution to the Problem of losing eggs, this question uses mathematical thinking to analyze the question and, after obtaining the final answer, introduces a specific problem-solving process. This article is not just about solving a specific problem, but about how to solve it.

 

Thank you for seeing that I am at the end. If you have any mistakes, please kindly advise. My email [email protected]

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.