Showing posts with label box. Show all posts
Showing posts with label box. Show all posts

Thursday, June 5, 2008

Wire Optimization

Finally, after waiting for a good question, it finally came: an optimization question. This one is from Yahoo Answers, and believe me, it's very good.

A 6 meter long wire is cut into 12 pieces. From these pieces, eight have the same length and the other four also have an equal length. These pieces form a frame of the box. How long should each piece for the box to have a maximum volume?

First, we should define ourselves some variables, otherwise we'd be lost.

Let x be the length of one of the 8 pieces. That means the total length of the 8 equal pieces is 8x. That means the other four pieces have a total length of 6 - 8x, and 3/2 - 2x meters each.

Since these wires form a box, the sides of the box have lengths of x, x, and 3/2 - 2x. That makes the volume of the box x * x * (3/2 - 2x), or 3x2/2 - 2x3.

To find the maximum value, we need to differentiate the volume function and set it to zero. Then we need to find the values that we get from solving the equation, plug them in the second derivative, see which one is a maximum and say "Problem Solved".

So:
V = 3x2/2 - 2x3
V' = 3x - 6x2
0 = 3x - 6x2
3x(1 - 2x) = 0
x = 0, 1/2

Now, let's find the second derivative and see when it's negative, so we get a maximum:
V'' = 3 - 12x
V''(0) = 3 - 0 = 3 > 0 - minimum
V''(1/2) = 3 - 12 * 1/2 = 3 - 6 = -3 < x =" 1/2" 1 =" 1/2">3 = 1/8 m3

Problem solved.
Nadav

nadavs

Friday, May 16, 2008

Digit In-A-Box

For today I have another question from Yahoo Answers. It's very original and interesting, and even worth trying out before going over to the answer.

Joe and Joana are playing a game. Joana is picking up between 2-9 boxes and puts a digit in each box, so the number that comes out when the digits are read from left to right is divisible by the number of boxes. For example, if Joana picks 4 boxes, she can use the digits 1,2,7,9 to create the number 1972, but not 7129. Joe must switch any two boxes that he wants. If the number is still divisible by the number of boxes, Joe wins. Otherwise, Joana wins. What number of boxes Joana must pick to always win?

This calls out for some divisibility rules. Let's see how Joe can always win for a number of boxes, and we'll start with 9:

9: it doesn't matter which boxes Joe moves, he wins. When a number is divisible by 9, the sum of its digits is also divisible by 9. Since addition is commutative, it doesn't matter which order the digits are: their sum will remain the same and they'll be divisible by 9.

8: the divisibility of a number by 8 depends on its last 3 digits. As long as Joe doesn't touch the last three digits, the number will be divisible by 8.

7: This is quite tricky, because it doesn't use the divisibility rule of 7 (which you can find on super math tips and tricks), but simple math. Since Joana uses 7 boxes here, there are 7 digits, and the number can be written as a sum:
1000000a + 100000b + 10000c + 1000d + 100e + 10f + g
When we replace the first and last digit, we subtract g and add 1000000g and also subtract 1000000a and add one a. This means the total operation is:
+1000000g - g - 1000000a + a = +999999g - 999999a = 999999(g - a).
Luckily for Joe, 999,999 is divisible by 7, so 999999(g - a) is also divisible by 7. That way, Joe adds or subtracts from a number divisible by 7 another number divisible by 7, and doesn't change its divisibility.

6: a number is divisible by 6 if it's divisible by 3 and 2, which means the sum of its digits must by divisible by 3 and it must be even. As long as Joe doesn't touch the last digit, he wins.

5: a number is divisible by 5 if the last digit is either 5 or 0, so as long as Joe doesn't touch the last digit, he wins.

4: a number's divisibility by 4 is determined by its last two digits, so Joe must replace only the first two to win.

3: a number is divisible by 3 if the sum of its digits is divisible by 3, so just like 9, Joe can switch any boxes he wants.

2: a number is divisible by 2 if it ends with 2, 4, 6, 8, or 0. However, since Joe MUST switch two boxes, Joana may pick an even number with one odd digit, like 74. When Joe switches the boxes, he'll get 47, which is odd, so Joana wins.

The final answer: Joana must use a 2-digit number to win.

And a final notice: I added a sign up form for Super Math Tips on the right column of this blog, for easy access.

Have a great weekend,
Nadav

nadavs