Follow Up – The Math Factor Podcast http://mathfactor.uark.edu The Math Factor Podcast Site Tue, 24 Jul 2012 21:06:10 +0000 en-US hourly 1 https://wordpress.org/?v=4.9.25 2006-2007 strauss@uark.edu (The Math Factor Podcast) strauss@uark.edu (The Math Factor Podcast) The Math Factor Podcast Site The Math Factor Podcast The Math Factor Podcast strauss@uark.edu no no HR. CardColm http://mathfactor.uark.edu/2012/04/hr-cardcolm/ http://mathfactor.uark.edu/2012/04/hr-cardcolm/#comments Fri, 13 Apr 2012 21:59:10 +0000 http://mathfactor.uark.edu/?p=1431

Colm Mulcahy, of Spelman College in Atlanta,  joins us to share his ice cream trick from his CardColm mathematical card trick column on the MAA website! You’re invited to explain how this works in the comments below.

Colm also shares a quick puzzle, tweeted on his What Would Martin Gardner Tweet feed @WWMGT. And finally we touch on the Gathering For Gardner and the Celebration of Mind, held all over the world around the time of Martin Gardner’s birthday, October 21.

And at last we get around to answering our quiz from a few weeks ago. There are indeed two solutions for correctly filling in the blanks in:

The number of 1’s in this paragraph is ___; the number of 2’s is ___; the number of 3’s is ____; and the number of 4’s is ___. 

[spoiler] namely (3,1,3,1) and (2,3,2,1) [/spoiler]

We can vary this puzzle at will, asking 

The number of 1’s in this paragraph is ___; the number of 2’s is ___; …..  and the number of N’s is ___. 

For N=2 or 3, there are no solutions (Asking that all the numbers we fill in are between 1 and N); for N=4 there are two. For N=5 there is just one, for N=6 there are none and beyond that there is just one. I think we’ll let the commenters explain that.

But here’s the cool thing. 

One way to approach the problem is to try filling in any answer at all, and then counting up what we have, filling that in, and repeating. Let’s illustrate, but first stipulate that we’ll stick with answers that are at least plausible– you can see that the total of all the numbers we fill in the blanks has to be 2N (since there are 2N total numbers in the paragraph). 

So here’s how this works. Suppose our puzzle is:

There are ___ 1’s;___ 2’s; ___ 3’s; ___ 4’s; ___ 5’s

Let’s pick a (bad) solution that totals 10, say, (2,4,1,2,1). So we fill in:

There are __2_ 1’s;   __4_ 2’s;    _1__ 3’s;      __2_ 4’s;     _1__ 5’s

That’s pretty wrong! There are actually three 1’s in that paragraph, three 2’s; at least there is just one 3, and two 4’s and one 5. In any case this gives us another purported solution to try: (3,3,1,2,1). Let’s fill that in:

There are __3_ 1’s;   __3_ 2’s;    _1__ 3’s;      __2_ 4’s;     _1__ 5’s

That attempt actually does have three 1’s; but has only two 2’s;  it does have three 3’s but only  one 4 and one 5. So let’s try (3,2,3,1,1):

There are __3_ 1’s;  __2_ 2’s;  _3__ 3’s;  __1_ 4’s;  _1__ 5’s

Lo and behold that works! We do in fact have three 1’s;  two 2’s; three 3’s and yes, one 4 and one 5.

So we can think of it this way: filling in a purported solution and reading off what we actually have gives another purported solution.

In this case (2,4,1,2,1) -> (3,3,1,2,1) -> (3,2,3,1,1) -> (3,2,3,1,1) etc,

We can keep following this process around, and if we ever reach a solution that gives back itself, we have a genuine answer, as we did here. 

So here’s an interesting thing to think about.

First, find, for N>=7, a correct solution; and a pair of purported solutions A,B  that cycle back and forth A->B->A->B etc.

Second, find a proof that this is all that can happen (unless I’m mistaken)–  any other purported solution eventually leads into  the correct one or that cycle.

 

]]>
http://mathfactor.uark.edu/2012/04/hr-cardcolm/feed/ 8 0:00:01 Colm Mulcahy, of Spelman College in Atlanta,  joins us to share his ice cream trick from his CardColm mathematical card trick column on the MAA website! You’re invited to explain how this works in the comments below. Colm also shares a q[...] Colm Mulcahy, of Spelman College in Atlanta,  joins us to share his ice cream trick from his CardColm mathematical card trick column on the MAA website! You’re invited to explain how this works in the comments below. Colm also shares a quick puzzle, tweeted on his What Would Martin Gardner Tweet feed @WWMGT. And finally we touch on the Gathering For Gardner and the Celebration of Mind, held all over the world around the time of Martin Gardner’s birthday, October 21. And at last we get around to answering our quiz from a few weeks ago. There are indeed two solutions for correctly filling in the blanks in: The number of 1’s in this paragraph is ___; the number of 2’s is ___; the number of 3’s is ____; and the number of 4’s is ___.  [spoiler] namely (3,1,3,1) and (2,3,2,1) [/spoiler] We can vary this puzzle at will, asking  The number of 1’s in this paragraph is ___; the number of 2’s is ___; …..  and the number of N’s is ___.  For N=2 or 3, there are no solutions (Asking that all the numbers we fill in are between 1 and N); for N=4 there are two. For N=5 there is just one, for N=6 there are none and beyond that there is just one. I think we’ll let the commenters explain that. But here’s the cool thing.  One way to approach the problem is to try filling in any answer at all, and then counting up what we have, filling that in, and repeating. Let’s illustrate, but first stipulate that we’ll stick with answers that are at least plausible– you can see that the total of all the numbers we fill in the blanks has to be 2N (since there are 2N total numbers in the paragraph).  So here’s how this works. Suppose our puzzle is: There are ___ 1’s;___ 2’s; ___ 3’s; ___ 4’s; ___ 5’s Let’s pick a (bad) solution that totals 10, say, (2,4,1,2,1). So we fill in: There are __2_ 1’s;   __4_ 2’s;    _1__ 3’s;      __2_ 4’s;     _1__ 5’s That’s pretty wrong! There are actually three 1’s in that paragraph, three 2’s; at least there is just one 3, and two 4’s and one 5. In any case this gives us another purported solution to try: (3,3,1,2,1). Let’s fill that in: There are __3_ 1’s;   __3_ 2’s;    _1__ 3’s;      __2_ 4’s;     _1__ 5’s That attempt actually does have three 1’s; but has only two 2’s;  it does have three 3’s but only  one 4 and one 5. So let’s try (3,2,3,1,1): There are __3_ 1’s;  __2_ 2’s;  _3__ 3’s;  __1_ 4’s;  _1__ 5’s Lo and behold that works! We do in fact have three 1’s;  two 2’s; three 3’s and yes, one 4 and one 5. So we can think of it this way: filling in a purported solution and reading off what we actually have gives another purported solution. In this case (2,4,1,2,1) -> (3,3,1,2,1) -> (3,2,3,1,1) -> (3,2,3,1,1) etc, We can keep following this process around, and if we ever reach a solution that gives back itself, we have a genuine answer, as we did here.  So here’s an interesting thing to think about. First, find, for N>=7, a correct solution; and a pair of purported solutions A,B  that cycle back and forth A->B->A->B etc. Second, find a proof that this is all that can happen (unless I’m mistaken)–  any other purported solution eventually leads into  the correct one or that cycle.   guests, numbers strauss@uark.edu no no
HJ. Strange Suitor http://mathfactor.uark.edu/2012/01/hj-strange-suitor/ http://mathfactor.uark.edu/2012/01/hj-strange-suitor/#comments Fri, 27 Jan 2012 13:54:06 +0000 http://mathfactor.uark.edu/?p=1380 We’ll have some pursuit puzzles over the next couple of weeks; this segment’s puzzle has a simple and elegant solution, but it might take a while to work it out!

In the meanwhile, here’s a little discussion about the glass of water problem.

Each time we add or subtract 50%, we are multiplying the quantity of water by 1/2 or 3/2. If we began with 1 glass’ worth, at each stage, we’ll have a quantity of the form 3m/2n with m,n>0  Of course that can never equal 1, but we can get very close if m/n is very close to log3 2 = 0.63092975357145743710…

Unfortunately, there’s a serious problem: m/n has to hit the mark pretty closely in order for 3m/2n to get really close to 1, and to get within “one molecule”s worth, m and n have to be huge indeed. 

How huge? Well, let’s see: an 8 oz. glass of water contains about 1025 molecules; to get within 1/1025 of 1, we need m=31150961018190238869556, n=49373105075258054570781 !!  One immediate problem is that if you make a switch about 100,000 times a second, this takes about  as long as the universe is old!

But there’s a more serious issue.

In a glass of water, there’s a real, specific number of molecules. Each time we add or subtract 50%, we are knocking out a factor of 2 from this number. Once we’re out of factors of 2, we can’t truly play the game any more, because we’d have to be taking fractions of water molecules. (For example, if we begin with, say, 100 molecules, after just two steps we’d be out of 2’s since 100=2*2*some other stuff.

But even though there are a huge number of water molecules in a glass of water, even if we arrange it so that there are as many 2’s as possible in that number, there just can’t be that many: 283 is about as good as we can do (of course, we won’t have precisely 8 ounces any more, but still.)

If we are only allowed 83 or so steps, the best we can do is only m= 53, n = 84 (Let’s just make the glass twice as big to accommodate that), and, as Byon noted, 3^53/2^84 is about 1.0021– not that close, really!

]]>
http://mathfactor.uark.edu/2012/01/hj-strange-suitor/feed/ 9 0:00:01 We’ll have some pursuit puzzles over the next couple of weeks; this segment’s puzzle has a simple and elegant solution, but it might take a while to work it out! In the meanwhile, here’s a little discussion about the glass of wate[...] We’ll have some pursuit puzzles over the next couple of weeks; this segment’s puzzle has a simple and elegant solution, but it might take a while to work it out! In the meanwhile, here’s a little discussion about the glass of water problem. Each time we add or subtract 50%, we are multiplying the quantity of water by 1/2 or 3/2. If we began with 1 glass’ worth, at each stage, we’ll have a quantity of the form 3m/2n with m,n>0  Of course that can never equal 1, but we can get very close if m/n is very close to log3 2 = 0.63092975357145743710… Unfortunately, there’s a serious problem: m/n has to hit the mark pretty closely in order for 3m/2n to get really close to 1, and to get within “one molecule”s worth, m and n have to be huge indeed.  How huge? Well, let’s see: an 8 oz. glass of water contains about 1025 molecules; to get within 1/1025 of 1, we need m=31150961018190238869556, n=49373105075258054570781 !!  One immediate problem is that if you make a switch about 100,000 times a second, this takes about  as long as the universe is old! But there’s a more serious issue. In a glass of water, there’s a real, specific number of molecules. Each time we add or subtract 50%, we are knocking out a factor of 2 from this number. Once we’re out of factors of 2, we can’t truly play the game any more, because we’d have to be taking fractions of water molecules. (For example, if we begin with, say, 100 molecules, after just two steps we’d be out of 2’s since 100=2*2*some other stuff. But even though there are a huge number of water molecules in a glass of water, even if we arrange it so that there are as many 2’s as possible in that number, there just can’t be that many: 283 is about as good as we can do (of course, we won’t have precisely 8 ounces any more, but still.) If we are only allowed 83 or so steps, the best we can do is only m= 53, n = 84 (Let’s just make the glass twice as big to accommodate that), and, as Byon noted, 3^53/2^84 is about 1.0021– not that close, really! numbers strauss@uark.edu no no
Morris: Follow Up: Golden Earring – Radar Love http://mathfactor.uark.edu/2010/10/morris-follow-up-golden-earring-radar-love/ http://mathfactor.uark.edu/2010/10/morris-follow-up-golden-earring-radar-love/#respond Sat, 09 Oct 2010 02:46:44 +0000 http://mathfactor.uark.edu/?p=1192 Golden-Earring

In Golden Earring – Radar Love I had a big problem.

This the solution so please read the problem first and have a go at solving it yourself.

My wife has lost a golden earring, I can buy a bunch of similar earrings but I know one is a fake.

I can weigh two groups of earrings, each weighing can give one of three results: they weigh the same; the left group is heavier, the right group is heavier.

The question is – how many earrings can be in the bunch I buy and leave me confident that I can find the fake with just three weighings?

 

You may have noticed that ears normally come in pairs.  So do earrings.

My wife still has one earring.  We know this earring is good and we can use it in our weighings if that helps us.

 

Always try the simplest case first and see if that gives any insights.

Suppose we are not allowed any weighings, then we can cope with a bunch of one earring; as it is the only earring it must be the fake.  We don’t learn if it is heavier or lighter than a genuine earring.

If we are allowed one weighing then we can cope with a bunch of two earrings. First we compare earring 1 with my wife’s other earring which we know is good.  

  • If they differ then earring 1 is fake and we learn if it is heavier or lighter.  
  • Otherwise they weigh the same and earring 2 is the fake, but we don’t learn if it is heavier or lighter.

 

A good approach to these sorts of problems is to think about the amount of information you can gain.  One possibility is that each weighing is equal; then we know that we haven’t weighed the fake earring, the fake is the one earring we haven’t weighed.  There are 26 other possible results; they must involve weighing the fake and so finding out if it is heavier or lighter than a good earring.

So the 27 possible results from three weighings will differentiate between:

  an earring which is never weighed is the fake;

  earring 1 is the fake and is light;

  earring 1 is the fake and is heavy;

  earring 2 is the fake and is light;

  earring 2 is the fake and is heavy;

  earring 13 is the fake and is light;

  earring 13 is the fake and is heavy.

So the maximum number of earrings is 14.

 

We have shown that 14 is the maximum, but we haven’t shown that it is possible.  Can you find a method?

Can you find a general formula for n weighings?

Always think about how much information you can gain from the remaining weighings; if you leave yourself with four earring candidates and one weighing then you have gone wrong.  That’s the best clue I can give you.

I’ll answer these in the comments in the near future if no-one else gets there first.

]]>
http://mathfactor.uark.edu/2010/10/morris-follow-up-golden-earring-radar-love/feed/ 0
Update: The Math Factor Podcast http://mathfactor.uark.edu/2010/05/update-podcast-goes-on-vacation/ http://mathfactor.uark.edu/2010/05/update-podcast-goes-on-vacation/#comments Sun, 09 May 2010 16:56:40 +0000 http://mathfactor.uark.edu/?p=1070 The Math Factor podcast is taking a rest for a while — we’ll be back with new podcasts at some point (probably, we think) so check back every once in a while!

In the meantime, from time to time the Math Factor crew will still be posting here, on our traditional highly irregular schedule.

I’m really proud of the bookends to the pieces so far: Cantor’s Theorem, in the segments leading up through AH. QED and now the discussion of undecidability in the last two podcasts. Along the way, we’ve managed to get in quite a bit of sophisticated stuff — not bad for local radio! 

I’ve really enjoyed all the conversations the Math Factor has initiated, between me and Kyle, with mathematicians and those using mathematics to do really interesting stuff, with book authors, and especially all those who have written in — and even become active collaborators! (Hi Jeff and Stephen) The tremendously supportive feedback we’ve gotten really means a lot.

I think it’s time, though, to take an extended break from the podcast. Kyle is now incredibly busy producing five hours of original magazine format radio journalism a week. He’s always been a dynamo, but lately the man’s a blur! And much of my energy has been directed elsewhere too (check out math2033.uark.edu!) I’ve started a couple of books that I hope you’ll check out when the time comes, and in the meantime, please read my articles Can’t Decide? Undecide! and another on tilings and computation.

I’ll be hanging out in Marseille, Mexico City and Oaxaca in June, with a lot of neat people, so might get all inspired to make some new posts soon, but on the whole, I feel like I’ve said what I needed to say for a while. The Theory of Computation is really an astounding and important perspective, and I’m delighted to have helped spread the word a bit more. It’s a great resting spot!

 

]]>
http://mathfactor.uark.edu/2010/05/update-podcast-goes-on-vacation/feed/ 3 0:01:33 The Math Factor podcast is taking a rest for a while — we’ll be back with new podcasts at some point (probably, we think) so check back every once in a while! In the meantime, from time to time the Math Factor crew will still be posting here,[...] The Math Factor podcast is taking a rest for a while — we’ll be back with new podcasts at some point (probably, we think) so check back every once in a while! In the meantime, from time to time the Math Factor crew will still be posting here, on our traditional highly irregular schedule. I’m really proud of the bookends to the pieces so far: Cantor’s Theorem, in the segments leading up through AH. QED and now the discussion of undecidability in the last two podcasts. Along the way, we’ve managed to get in quite a bit of sophisticated stuff — not bad for local radio!  I’ve really enjoyed all the conversations the Math Factor has initiated, between me and Kyle, with mathematicians and those using mathematics to do really interesting stuff, with book authors, and especially all those who have written in — and even become active collaborators! (Hi Jeff and Stephen) The tremendously supportive feedback we’ve gotten really means a lot. I think it’s time, though, to take an extended break from the podcast. Kyle is now incredibly busy producing five hours of original magazine format radio journalism a week. He’s always been a dynamo, but lately the man’s a blur! And much of my energy has been directed elsewhere too (check out math2033.uark.edu!) I’ve started a couple of books that I hope you’ll check out when the time comes, and in the meantime, please read my articles Can’t Decide? Undecide! and another on tilings and computation. I’ll be hanging out in Marseille, Mexico City and Oaxaca in June, with a lot of neat people, so might get all inspired to make some new posts soon, but on the whole, I feel like I’ve said what I needed to say for a while. The Theory of Computation is really an astounding and important perspective, and I’m delighted to have helped spread the word a bit more. It’s a great resting spot!   Podcasts strauss@uark.edu no no
Morris: Follow Up: Triel/Truel/Whatever http://mathfactor.uark.edu/2009/12/morris-follow-up-trieltruelwhatever/ http://mathfactor.uark.edu/2009/12/morris-follow-up-trieltruelwhatever/#respond Sat, 05 Dec 2009 17:34:49 +0000 http://mathfactor.uark.edu/?p=986  

This is the solution to Morris: Trial/Trual/Whatever.  Please look there before reading the solution.

It turns out the right word is truel, first coined in 1954 by Martin Shubik.

Jeff suggested that they might all choose not to shoot at each other and it would go on forever.  This made me think about the logic.  I’m going to say that someone shoots at someone at some point and everyone knows this.  So everyone knows that if they shoot to miss then one of the others will shoot to hit at some point.

If anyone shoots to hit then they will shoot at the best shot.  If they hit they will be in two-man duel and would prefer to be against the worst shot possible. 

So François knows that no-one will shoot at him.  Xavier knows that one of the others will shoot at him.  

 

François has two options, he can shoot at Xavier or he can shoot to miss.

If he hits Xavier he will be in a two man dual with JC shooting first, he only has a one in five chance of surviving the first shot so his chance of survival is less than 1/5.

If François shoots to miss he knows that the other two will shoot at each other, if they choose to shoot to hit.  So at some point JC or Xavier will kill the other.  At this point François will be in a two man duel with himself shooting first.  This gives him at least a fifity/fifty chance.

So François shoots to miss.

 

Xavier and JC know this.  They know they are effectively in a two man duel with each other.  They therefore shoot at each other.

 

That sorts out the strategy, what about the probabilities?

 

Let’s consider JC first.  There is a fifty/fifty chance that Xavier or JC will shoot first.  JC’s only chance is to shoot first and hit.  The chance is 1/2 x 4/5 = 2/5.

So 2/5 of the time JC will face François with Francois shooting first.  

Let’s say that the chance that François wins is f.  He has a 1/2 chance of killing JC with his first shot.  There is a 1/2 x 1/5 = 1/10 chance that both miss with their first shot, we are back to the starting position so the probability of François surviving is now f again.

The chance of François surviving is f = 1/2 + 1/10 f.  This gives 9/10 f = 1/2 and f = 5/9.  The chance of François surviving is 5/9.  The chance of JC surviving is 4/9.

 

This gives JC a total survival chance of 2/5 x 4/9 = 8/45.

 

Now consider Xavier.  He has a 3/5 chance of facing François with François shooting first.

His chance of surviving is 1/2, the chance that François misses.

His total survival chance is 3/10.

 

Finally Francois’ chance of surviving is 2/5 x 5/9 + 3/5 x 1/2 = 2/9 + 3/10 = 47/90.

 

So the probabilities of being the last man standing are:  François 47/90; Xavier 3/10 and JC 8/45.

 

Amazingly the worst shot has the best chance of survival!

 

]]>
http://mathfactor.uark.edu/2009/12/morris-follow-up-trieltruelwhatever/feed/ 0
Follow Up: Yoak: Batteries, and the Problem of the Week http://mathfactor.uark.edu/2009/11/follow-up-yoak-batteries-and-the-problem-of-the-week/ http://mathfactor.uark.edu/2009/11/follow-up-yoak-batteries-and-the-problem-of-the-week/#respond Sat, 21 Nov 2009 21:31:09 +0000 http://mathfactor.uark.edu/?p=938 { Hi, Steve here. Jeff asked me to post a solution and I’m more than happy to oblige. It’s a fun puzzle with some nice maths to explore. I learnt a lot about graph theory and a new theorem (new to me), Turan’s theorem. More on that later. }

In Yoak: Batteries, and the Problem-of-the Week Jeff posed a great problem from Stan Wagon’s Problem of the Week.

You have eight batteries, four good and four dead. You need two good batteries to work the device; if either battery is dead then the device shows no sign of life. How many tests using two batteries do you need to make the device work?

In some similar sounding puzzles we might change the tests depending on the results we get as we go along. That doesn’t work here. We will stop if any test succeeds, we only carry on as long as the tests fail. We never get any information that we could use to choose our next test. That means we can choose the combinations we are going to use before we start our tests.

There are two ways of posing this problem. The one we have used is to make the device work. The other is to identify two working batteries which requires one less test.

Another problem is to find all four working batteries (which laciermaths neatly dealt with in the comments) and yet another is to find the most efficient approach which minimises the average number of tests.

The following seven combinations are guaranteed to make the device work.

(1,2),(1,3),(2,3),(4,5),(4,6),(5,6),(7,8)

 

Any six of these tests will identify two working batteries, for example our tests could be:

(1,2),(1,3),(2,3),(4,5),(4,6),(5,6)

If all of these tests fail then at most one battery from {1,2,3} can work and at most one battery from {4,5,6} can work. As we know there are four good batteries we can deduce that both 7 and 8 are working batteries.

So we have an answer to the problem, six tests are sufficient to identify two good batteries and seven tests are sufficient to work the device.

But hold on a minute! We haven’t yet shown that there isn’t an answer with fewer tests.

I came up with a proof but I won’t repeat it here because Jim Schmerl gave a much better one to POW. The better proof works for any number of batteries with any number being good.

It says: With n batteries and r good batteries then the best solution is to split the batteries into r-1 groups of roughly equal size and then test each pair within each group.

Let’s consider our seven tests again.


Here n is 8 and r is 4. We split the batteries into r-1 = 3 groups and test each pair in each group. At least one group has two good batteries so this will definitely give a solution.

These sorts of diagrams are called graphs. A graph is just a set of vertices connected by edges. A graph with v vertices and all possible edges is called Kv. Our solution consists of K3, K3 and K2.

Now how do we show that this is minimal. Well we have some clever tricks.


The figure above is certainly a solution but it isn’t minimal.

7 has three edges and 8 has just one edge. We can reduce the number of edges by a procedure I call ‘Make 7 like 8’. The procedure involves:

1.    Remove all edges from 7.

2.    Connect 7 to the same vertices as 8.

3.    Connect 7 to 8.

That procedure gives:


We now have 11 edges instead of 12.

If we start with a solution then the ‘Make a like b’ procedure will give another solution. Why is this?

  • If the four good batteries include both 7 and 8 then they will be tested as we test the pair 7 and 8.
  • If the four good batteries do not include 7 then they are tested in the original solution and so will be tested in the new solution. We have only changed tests that include 7.
  • If the four good batteries include 7, but not 8, then they will be tested. The equivalent group, replacing 7 with 8, is tested. For example consider {1,4,6,7}. The equivalent group is {1,4,6,8}. We know this is tested as it doesn’t involve 7 and so is tested in the original solution. But 7 connects to the same vertices as 8 so {1,4,6,7} is tested in the new solution.

We can repeat this trick as often as we like. You might like to play around with it, start with a solution with a ridiculous number of edges and see how far you can reduce it by repeating this trick.

The number of edges connected to a vertex, a, is called the degree of a which is written d(a). The procedure ‘Make a like b’ will reduce the number of edges if d(a) > d(b) + 1.

We can therefore make the following claim:

Claim 1: In an optimal solution the degree of any two vertices will differ by no more than one.

So far so good but we need to go a bit further. We can use the same trick to show the following:

Claim 2: In an optimal solution if a-b and b-c then a-c (where a-b means there is an edge between a and b).

This means the solution splits the batteries into groups where each pair within a group is tested.

Proof of Claim 2:

Suppose there is a chain a-b-c but there is no edge between a and c (so a-c is not true). We can always reduce the number of edges.

Case 1: If d(b) > d(a) we ‘Make b like a’. This reduces the number of edges by at least one, we remove the b-c edge.

Case 2: Similarly if d(b) > d(c) we ‘Make b like c’.

Case 3: Otherwise we have d(b) <= d(a) and d(b) <= d(c). We ‘Make a like b’ and then ‘Make c like b’. These two procedures will also reduce the number of edges by at least one.

To illustrate this lets go back to our example. We left it like this.


 

We have the chain 1-3-5 but not 1-5. d(3) > d(1) so we ‘Make 3 like 1’. That gives:


Now we have the chain 4-5-6 but not 4-6. As d(4) <= d(5) and d(6) <= d(5) we have the third case. First ‘Make 4 like 5’ and then ‘Make 6 like 5’.


What our two claims show is that an optimal solution will split the batteries into roughly equal groups (the degree of any two vertices can differ by no more than one), each pair within a group is tested.

It only remains to show that we should use three groups.

More than three groups is not a solution, we could have one good battery in each group.

The other possibilities are to have one group, K8, which has 28 edges or to have two groups, K4 and K4, which has 12 edges.

So having three groups, with 7 edges, is optimal.

In the general solution we should have as many groups as possible which is r-1.

 

So this proves the general solution we have before: With n batteries and r good batteries then the best solution is to split the batteries into r-1 groups of roughly equal size and then test each pair within each group.

 

This is equivalent to Turan’s theorem.

For an optimal solution we need to consider the ‘complement graph’. This just means the graph with an edge precisely where our solution graph doesn’t have one. As our solution has 7 edges and there are 28 possible edges the complement graph has 21 edges. Such a graph is called a Turan graph.

The Turan graph can be got by splitting the vertices into r-1 groups and then connecting each pair which are not in the same group.

Since each group of four vertices in the solution graph contains at least one edge the same four vertices in the complement graph are missing an edge. In other words the complement graph does not contain K4 , it is K4-free.

Turan’s theorem says the graph with n vertices with the most edges which is Kr-free is the Turan graph, exactly the complement of our solution graph.

]]>
http://mathfactor.uark.edu/2009/11/follow-up-yoak-batteries-and-the-problem-of-the-week/feed/ 0
Morris: Follow Up: Living With Crazy Buttocks http://mathfactor.uark.edu/2009/11/morris-follow-up-living-with-crazy-buttocks/ http://mathfactor.uark.edu/2009/11/morris-follow-up-living-with-crazy-buttocks/#respond Sat, 14 Nov 2009 20:31:52 +0000 http://mathfactor.uark.edu/?p=886 In Living With Crazy Buttocks  I posed a problem where 20 party guests were each given an unusual book.  These books were placed in identical boxes.  The guests enter the room with the boxes one at a time and are allowed to open half of the boxes.  They leave by a different door and cannot communicate with the other guests.  The room is put back identically before the next guest enters.

If every guest finds their book then the whole group win a trip to Paris.

What is their best strategy?

This puzzle comes from a Peter Winkler book, Mathematical Mind-Benders.   It was called Names in Boxes and was about prisoners trying to escape the death penalty.

 

This is the guests best strategy:

Associate each box with one of the guests.  Each guest first opens their own box.  If they find their own book they can stop.  Otherwise they open the box associated with the owner of the book.  They keep doing this until they find their own book or have opened 10 boxes.

 

Incredibly this gives them more than a 33% chance of success.  Even more incredibly this strategy will always have a better than 30% chance of success regardless of the number of guests.

To see how this works lets imagine that Stan repeats the procedure forever.  At some point he will find his book.  Next he will open his own box again.  He will repeat the same loop endlessly.  

If this loop contains up to ten boxes then all of the guests whose boxes lie in the loop will find their book.

The procedure splits the boxes into separate loops.  If no loop is bigger than ten then all of the guests will succeed, otherwise most of them will fail.

It is still true each individual guest has a fifty-fifty chance, the procedure means that they tend to succeed or fail together.

 

So what is the chance of success?

We have come across these sorts of loops before in Follow Up: Loops and the Harmonic Series. In the comments we noted that on average there will be 1/r loops of length r. As we are interested in loops containing more than half the boxes there can only be one such loop, so we can say the chance of a loop of length r is 1/r.

First we calculate the number of loops of length r if we have n boxes, in the puzzle n =10.  There are n!/r!(n-r)! ways of choosing r boxes and there are r! ways of ordering them.   We could have chosen any box in the loop to be the first one so to avoid double counting we must divide by r.  This gives (n!/r!(n-r)!)r!/r = n!/r(n-r)!

The other n-r boxes could be arranged in (n-r)! ways.  In total there are n! arrangements of all n boxes.  So a random arrangment will have on average (n-r)!/n! occurrences of a particular loop.  

A random arrangement will have on average (n!/r(n-r)!)((n-r)!/n!) = 1/r loops of length r.

 

Since there can only be one loop larger than 10 this means the chance of success is 1 -1/11 -1/12 -… -1/20 which is about 0.331229…

As the number of guests increases this tends to 1 – integral[ N<x<2N ]( 1/x ) = 1 – ln 2N + ln N = 1 – ln 2 = 0.3068528…

However many guests there are they will always have a better than 30% chance of success!

 

]]>
http://mathfactor.uark.edu/2009/11/morris-follow-up-living-with-crazy-buttocks/feed/ 0
Morris: World of Britain 2: Proof and Paradox http://mathfactor.uark.edu/2009/07/morris-world-of-britain-2-proof-and-paradox/ http://mathfactor.uark.edu/2009/07/morris-world-of-britain-2-proof-and-paradox/#comments Tue, 07 Jul 2009 21:54:02 +0000 http://mathfactor.uark.edu/?p=646 paradox-clockIn working out the proof for World of Britain I came across a paradox.  Maybe smarter Math Factorites can help me out?  My sanity could depend on it.

In the puzzle you have five different tasks.  On each day one of these tasks is given at random.  How long do you expect it to take to get all five tasks?

First consider a simple case.  Suppose some event has a probability, p, of happening on any one day.  Let’s say that E(p) is the expected number of days we have to wait for the event to happen.  For example if p=1 then the event is guaranteed to happen every day and so E(p)=1.

How can we calculate E(p)? 

Andy does an experiment.  He will wait for the event to happen and record how many days it took.  He will do this several times, for long enough to ensure that he gets an answer that is as accurate as he needs.  He will keep going for N days in total.  Afterwards he will take the average of all of his wait times to get an estimate for E(p).

The average he calculates is the total of all the wait times divided by the number of occurrences of the event.  But we can estimate both of these values and therefore estimate his value for E(p).  The total of all of the wait times is going to be about N.  Since the event has a probability of p of occurring on any particular day the number of occurrences will be about p times N.

So Andy’s average will be about N/(pN) which will be about 1/p.

We can make N as large as we like to make this result as accurate as we like.  So we can confidently say that E(p) = 1/p.

 

Let’s get back to our puzzle about tasks.  We need to wait for the first task, then the second, then the third and so on.  When there are t tasks left then the chance of getting a new one is t/5.  

So the total waiting time is

    E(5/5) + E(4/5) + E(3/5) + E(2/5) + E(1/5) = 5/5 + 5/4 + 5/3 + 5/2 + 5/1

       = 5(1/5 + 1/4 + 1/3 + 1/2 + 1) = 11 5/12 = 11.4166666… days

You may recognise the harmonic series!

 

So that’s the proof, now where’s the paradox?

 

Bob visits Andy when he is able and waits with him until the event occurs.  Of course Andy may well have been waiting for some time.

If Bob turns up just after the event has happened then he will wait for the same time as Andy.  If he turns up just before the event he will wait for one day.  On average he will wait for about half the time that Andy does.

When the event occurs Bob disappears and comes back when he is next able to.

At the end of the experiment Bob averages all of his wait times to get an estimate for E(p).  He gets an answer which is half of Andy’s!

That is the paradox!

 

Now Carol thinks she understands what is going on here.  The problem is that Andy is distorting his results by always starting the clock straight after an event has occurred.  That guarantees him to get the longest possible wait times.

She thinks the only way to get an accurate answer is to look at the wait time starting from each of the N days and then average these N wait times.

To calculate this she needs to make an assumption.  She knows that the event occurs every 1/p days on average.  She assumes they happen regularly every 1/p days.

 Let’s say they happen every n days where n = 1/p.  Remember Andy’s value for E(p) is 1/p = n.  Bob’s value is half that, so about n/2. 

The wait time will vary between 1 and n.  The average wait time will be n(n+1)/2n = (n+1)/2.

So Carols estimate for E(p) is about n/2 whereas Andy’s was 1/p = n.  So Carol is agreeing with Bob.

 

I can tell you that Andy had the right value and that the logic I used for Bob and Carol was flawed. 

Can you see where?

]]>
http://mathfactor.uark.edu/2009/07/morris-world-of-britain-2-proof-and-paradox/feed/ 5
Yoak: Followup to A Rather Odd Car Trip http://mathfactor.uark.edu/2009/05/yoak-followup-to-a-rather-odd-car-trip/ http://mathfactor.uark.edu/2009/05/yoak-followup-to-a-rather-odd-car-trip/#respond Mon, 04 May 2009 21:23:58 +0000 http://mathfactor.uark.edu/?p=573 This is a followup to my earlier post, A Rather Odd Car Trip.  It provides a solution so if you haven’t read that yet, you should do so first as this won’t make much sense without it.

[spoiler]

Though czarrandy and others provided the distance between the cities, I’d like to show a way that you can work the problem.

We want to work out an equation that explains the amount of time traveled each  downhill, level and uphill in terms of the distances involved.

How long does it take to travel a particular distance at a particular rate?  Take the uphill portion as an example.  At 56 mph, you travel 1 hour / 56 miles or n hours / x miles for any given distance x.  So:

1/56 = n / x

Solve for n (hours) and you get:

x/56 hours traveled for distance x.

Do something similar for the level distance (call that y) and the downhill distance (call that z) and you get this equation for the time traveled in terms of the three distances traveling from A to B in 4 hours:

x/56 + y/63 + z/72 = 4

For the trip back, where uphill becomes downhill and vice versa, we get:

z/56 + y/63 + x/72 = 4 2/3 or 14/3

If we could solve for x, y and z, we would get our answer, but generally there will not be a unique solution for two equations with three unknowns.  But in this case, what we need is the value of x+y+z , which we can attempt to extract that from the equations.

First, add the two equations together and get:

x/56 + x/72 + y/63 + y/63 + z/56 + z/72 = 26/3

To collect the terms, multiply both sides by the least common multiple of the denominators, which is 504, and we get:

9x + 7x + 8y + 8y + 9z + 7z = 4368
16x + 16y + 16z = 4368
16(x+y+z) = 4368
x+y+z = 273

for 273 miles each way.  Notice that what we did was to add the equations up to get a value for the round trip, which might have been a first intuitive step if you happened to think of it.

Now… it was very lucky that we were able to nicely factor out that 16 in order to solve for x+y+z.  This won’t always be the case!  The three speeds were chosen carefully so that this would work out.  Consider if we used some other randomly chosen values:

Uphill: 50 mph
Level: 60 mph
Downhill: 70 mph

Leave the times the same, so:

x/50 + y/60 + z/70 = 4
x/70 + y/60 + z/50 = 14/3

or x/50 + x/70 + y/60 + y/60 + z/70 + z/50 = 26/3

Multiply by the least common multiple of the denominators, 2100, and get:

42x + 30x + 35y + 35y + 30z + 42z = 18200
72x + 70y + 72z = 18200

As you can see, there isn’t going to be any way to factor out x+y+z to get a unique total distance.  You could experiment to demonstrate that you can pick values for x, y and z that satisfy the equation and for which x+y+z will differ.

The final question that interested me is how to identify the cases where there does turn out to be a solution.  From the process we just followed, you can see that you want the final coefficient of the x and z terms, or the uphill and downhill time traveled, which will always be equal to each other, to also be equal to the coefficient of the y term or the time traveled level.

Since we’ve added the two equations from the round trip, the meaning of these terms is the time taken to travel round-trip over a slanted piece of road.  So in English, in order to have a unique solution to the problem, the speeds must be specially selected such that the time it takes to travel round-trip over a slanted piece of road must be the same as the time it takes to travel over a level piece of road.

I got this problem originally from Nick’s Mathematical Puzzles. There are a lot of neat puzzles on the site to enjoy.

[/spoiler]

]]>
http://mathfactor.uark.edu/2009/05/yoak-followup-to-a-rather-odd-car-trip/feed/ 0
Morris: Turning Tables http://mathfactor.uark.edu/2009/04/turning-tables/ http://mathfactor.uark.edu/2009/04/turning-tables/#comments Sun, 19 Apr 2009 23:21:10 +0000 http://mathfactor.uark.edu/?p=543 tt23I took one of Peter Winkler’s puzzle books on holiday recently.  After dinner each night I intended to impress my friend with an amazing math puzzle.  I had done this before.

The book dissapeared on the flight out.  After dinner each night my friend impressed me with an amazing math puzzle.  I haven’t seen the book since.

Serves me right!

 

This is one of those puzzles, you will understand why I have to do it from memory.

 

I really like Jeff’s post  A Fun Trick – Guess the Polynomial.  You might want to look at it first.

If you relax the conditions a bit you have a similar sounding puzzle with a very different solution.

So my puzzle is this:

I am thinking of a polynomial.  All of the co-efficients are fractions.   You may use any number as your test number.  When you give me a test number I will tell you the result.

How many test numbers do you need to identify the polynomial?

]]>
http://mathfactor.uark.edu/2009/04/turning-tables/feed/ 2