Please visit my new campsite listing site ukcampingmap.co.uk


Posts Tagged ‘Maths’

How to get the biggest slice of pizza

Sunday, April 26th, 2009

It’s always a battle trying to eat enough pizza when it’s being shared between friends. It’s believed, in fact, to be the cause of the Crimean war.

But is there an optimal strategy to make sure you get the most pizza you can?

To date I have always followed a “take the biggest piece that’s left” strategy, but ruminating on this has led me to the following conclusion: taking the biggest piece still on the plate isn’t necessarily the best way to maximize the amount of pizza you eat.

Suppose a pizza, P, is sliced into n Slices, s1, …,  sn, ordered such that their areas a1, …, an form a decreasing sequence.  Also assume that the time taken to eat a slice is proportional to its area, i.e. tn = can. Further assume that everyone eats at the same speed and that there is a set polite interval – T – between one person taking a slice and the next person taking theirs.

We will concentrate on the smallest remaining slice and the largest.

Assume you take slice k (the largest remaining). Then the person who took a slice before you (presumably the largest available slice, if they play the traditional pizza game) has time tk + T = cak + T to finish his slice in order to guarantee he finishes before you, and therefore get to pick a bigger slice than you next time. The time it takes them to eat their slice is tk-1 = cak-1. So for him to get a bigger next slice than you:

cak-1 <cak + T
ak-1 -ak < T/c

However, if you take the smallest slice available instead of the largest this changes to

ak-1 -an < T/c

which, if the difference in size between slices is great,  is considerably less likely. Therefore you would be considerably more likely to get to choose before your predecessor next time, and thus securing a bigger slice should you show wish. Now you would have eaten slice an and picked another slice before he’s finished his first.

This strategy won’t always pay off though, and it’s difficult to judge when it would be effective. For instance, say there are very few slices available; If all slices are taken before you finish slice an then you lose out but, on the other hand, if you are the only person quick enough to finish their first slice in time to grab the one remaining slice after the first round, then you win.

It may be worth trying to write a computer model of.

Logic 2.1.1

Tuesday, March 24th, 2009

Further discussion on the logic functions with my good friend Matt, specifically regarding what they could mean, has landed on the idea that a value of, say, 2 or 3 for the truth of a statement X could equate to “X is sooooo true”.

Bearing this in mind, Matt wasn’t happy with the shape of the graph of =>, and further thought has led to the following necessary conditions for a function =>(x,y) (I’ll call it f from now on for ease of typing) which works well with the notion that something can be soooo true:

  • f(x,1) –> 0.5 as x –> infinityx (so if something very true implies something else is true to a normal level, this means the implication is less a preserver of truth: more a diluter (though I set the asymptote as 0.5 as we thought it shouldn’t get closer to falsity than to truth)
  • f(x,0) < 0 for all x > 1 (if x gets more true but y is still not true, then teh implication is, again, less of a truth preserver, though this is debatable. Maybe eqality with zero would be more appropriate.)
  • f(1,y) –> infinity as y –> infinty (similar to the case where x varies and y = 1,  if 1 is immensely true despite x only being a little bit true then the implication is very strongly true)
  • f(0,y) = 1/y for all y > 1 (the thinking here being that if y contiinues to get more and more true, despite no change in x, then the link between y and x should accordingly be weakened)