30 December 2011

Brownie maths continued...

We don't end it there, Liz and I went on a spree to find out more about our brownie conundrum...

We weren't satisfied with knowing just a couple of good combinations, we wanted to know how one could work out the optimum number of slices for any brownies.

The maths:

If we assume a rectangular pan, and we divide the longest side into 'a' slices, then we need to work out how many slices we need to cut the shorter side into (we'll call this 'b') in order to have an equal number middle and edge slices (we'll call the number of middles 'm' and the number of edges 'e' as we did before).


Now, we know that the number of edge peices is simply the circumference of our pan, so:

e = 2(a+b)-4      (adapted from our square-tin circumference equation)

We also know that the number of middle pieces is found by multiplying the sides, minus the ones that are touching the edges (ie, 2 per side) so:

m = (a-2)(b-2)


Now, we want the same middle as edge, so

             m = e
(a-2)(b-2) = 2(a+b)-4

So, if we solve this to calculate b for a given a:

Liz gets full credit for doing this. I cheated and consulted WolframAlpha, mostly to get the pretty pictures of the steps for solving the above.
The solution Liz (and then Wolfram) came to looked like this:



 And with a little tarting up, I present to you (drumroll please)

The Equation for Equating Brownie Edge and Middle Peices:


Notice, firstly, that there's no solution for having 4 slices on the longest side.

Oh, you want a graph of that? Really? Go on then:


Graph of middle:edge brownie equality for a rectangular tin:
x-axis: Slices on Longer side
y-axis: Slices on Shorter side

In this graph you can clearly see a few of our favourite combinations. 8x6 is on there, as is 12x5.
You can also clearly see that there's no whole-number solution below 4, and no solution at all at 4.

If we consider whole-number (discrete) solutions only, we can build the sequence:

  1. 5 x 12
  2. 6 x 8
  3. 8 x 6
  4. 12 x 5
And since 4 is not a solution, we've just defined our complete set of possible solutions. So if you want an equal number of edge to middle brownie slices, you have a choice of 48 or 60 brownies in a 8x6 or 12x5 configuration.

I'll stop maths-geeking out now, I promise...


29 December 2011

Brownies...

To quash the allegations, I'm talking about the delicious baked cake-esque treat, not the club for delicious small girls. So there.

A discussion arose yesterday on the benefits of brownies - specifically the difference between "edge bits" and "middle bits".  Now, I'm a middle-bit man. I can't see the appeal of dried, crunchy, crusty edge bits of brownie when the whole point of a brownie is it's squidgy goodness. Alas, I have to concede that I'm in the minority, most people, when fighting for brownie will fight for the edge bits. Indeed, there's special tins to maximise the occurance of edges:

I can already hear the clamour of all you poor, misguided souls looking for a place to buy this small example of cooking geekery. Alas, there exists no 'edgeless' brownie tin (yet).

I am, however, lucky.

My wonderful girlfriend happens to be one of the edge-piece sheep, and so we can get along by my eating the middles bits, and her the outside, right? Surely this is an elegant solution that satisfies both parties? Wrong. We first have to devise a way of cutting up our brownie so that we each get an equal number of brownie pieces.

This leads to a veritable conundrum, how do we cut up our pan?

E = Edge, M=Middle

1x1
E  1 edge, no middle :/

2x2
E E
E E  4 edge, 0 middle

3x3:
E E E
E M E   8 edge, 1 middle (she's still fine with this, apparently)
E E E

4x4:
E E E E
E M M E
E M M E 12 edge, 4 middle (3:1, uncool)
E E E E


...I'm going to skip ahead here...


6x6:
E E E E E E
E M M M M E
E M M M M E
E M M M M E 20 edge, 16 middle (5:4, getting better...)
E M M M M E
E E E E E E


7x7:
E E E E E E E
E M M M M M E
E M M M M M E 24 edge, 25 middle (Ah-ha! we see the tables have turned..)
E M M M M M E
E M M M M M E
E M M M M M E
E E E E E E E


So, the switch happens between 6 and 7 to an edge. Of course, these are square tins. One can work out the ratio easily enough:


where n = length of a side, e = number of edge pieces and m = number of middle peices


e = 4n-4
m = (n-2)^2


And so if we declare that m = e, we can solve the above for n:


(n-2)^2 = 4n-4


<<GCSE MATHS MAGIC>>

n = 4+sqrt(8)   ~= 6.83



Now, I defy any of you to cut a pan exactly into 6.83 brownies a side. In the universal language of 4chan: Pics or GTFO.


Anyway, much more discussion was had before we had a dual revelation:


1: We don't have to have the same number on each side, and
2: Who the hell makes perfectly square baking tins anyway?!


This is game changing, and very quickly, we came to the magic number:


8x6:
E E E E E E E E
E M M M M M M E
E M M M M M M E 24 edge, 24 middle (Win!)
E M M M M M M E
E M M M M M M E
E E E E E E E E




So there you have it. If you find yourself in a situation where the ratio of edge to middle brownies is critical to the continuation of the human race, you're equipped with the tools to work it out. You can thank me later, preferably with baked goods.


EDIT
Miss Firefly_liz informs me that there's another magic ratio: 12x5.

Keep 'em coming! :)