Call Windows Support

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg
Showing posts with label estimation. Show all posts
Showing posts with label estimation. Show all posts

Monday, 25 March 2013

packing in the toilet rolls

Posted on 09:41 by Unknown
The TV show QI is a marvellous source of trivia.  A while back I heard them say that Sainsbury's is shrinking the size of the tube through the centre of toilet rolls to save volume, and hence the number of delivery lorry trips needed.  A quick Google confirms that this is the case: the diameter of the roll has fallen from 123mm to 112mm, whilst keeping the amount of paper the same. (I hope no makers were relying on the constant diameter of the correspondingly shrinking tube for any long term projects.)

This (123-112)/123 = 1-0.91 = 9% reduction in diameter doesn't look much for a single roll:
123mm v 112mm, to scale                                                                                      overlaid for comparison
However, once you get a lot of rolls, the saving soon adds up:

the difference is clear with 40 rolls
Assuming that the height of the rolls is the same, the 9% reduction in diameter corresponds to a 1-0.912 = 1-0.83 = 17% reduction in volume.  Hence more rolls can be packed in each delivery lorry, with a claimed  saving of 500 lorry trips, or 140 tonnes of CO2, per year.

But we could do better, surely?  I've shown the rolls on a square grid, because that's how they are packed:

But what about a hexagonal packing?

smaller rolls, and now hexagonally packed
Now each roll occupies a hexagon of half-height r, not a square of half-height r:

square boundary                                             hexagonal boundary                                             equilateral triangle

What space does this take?  The hexagon is made of 6 equilateral triangles, each of height r.  If the side is of length h, then we have r = h sin 60 = h √3 / 2.  The area of the triangle = 1/2 x base x perpendicular height = h/2 x r = r2 / √3.  The area of the hexagon is 6 times this, or  2√3 r2  = 3.464  r2.  The square, meanwhile, has area 4 r2.  (And not coincidentally, 3.464 is a better approximation to π than is 4.)  Hence hexagonal packing is (4 - 3.464)/4 = 0.134, or a little over 13%, better than square packing.

Doing the sums to combine the percentages properly [viz, 1-(1-17%)(1-13%)=0.28], this means hexagonal packing and smaller rolls combined gives about 28% improvement over the original large, square packed rolls.

So Sainsbury's could save a further 300-odd lorry trips, and a further 90 tonnes CO2, by packing the rolls hexagonally.

Maybe I should write them a letter?


Read More
Posted in estimation, politics | No comments

Tuesday, 8 May 2012

going to extremes

Posted on 10:58 by Unknown

Last week I went to a talk by Jim Al-Kalili, called “9 Paradoxes” (which, not coincidentally, is the title of his latest book).

One style of paradox he talked about are the mathematical ones, where a plausible calculation is presented, but the conclusion is wrong.  He illustrated this with the Monty Hall problem, and the Missing Dollar puzzle.

I’ve written about the Monty Hall problem elsewhere, and how the resolution is much easier to see by taking a more extreme case.  The approach of changing the problem to an extreme case is not specific to the Monty Hall problem, but is a more widely applicable check.  In particular, is can be applied to help see through the Missing Dollar puzzle. 

The Missing Dollar puzzle is as follows:
Three friends book into a shared room at an hotel.  The rate is $30, so they pay $10 each.  Later, the clerk realises they have overpaid; the rate is actually $25.  He takes $5 from the till, and goes to give them their refund.  On the way he realises that he won’t be able to split $5 between the three, so gives them $1 each, and pockets the remaining $2. 
So they have each paid $10-$1=$9, which is a total of $27. With the $2 in the clerk’s pocket, that’s a total of $29.  The original payment was $30. What happened to the missing $1?
The answer is that this is the wrong calculation. They have paid $27.  Of this $2 is in the clerk’s pocket, and $25 is in the till to pay for the room.  The puzzle works because the two prices are so close, and so it isn't necessarily obvious on a fast telling of the puzzle that the $2 should be subtracted from the $27, rather than added to it.  Let’s use the same approach of taking it to extremes to make the problem more obvious.
Three friends book into a shared room at an hotel.  The rate is $3000, so they pay $1000 each.  Later, the clerk realises they have overpaid; the rate is actually $25.  He takes $2975 from the till, and goes to give them their refund.  On the way he realises that he won’t be able to split $2975 between the three, so gives them $991 each, and pockets the remaining $2. 
So they have each paid $1000-$991=$9, which is a total of $27. With the $2 in the clerk’s pocket, that’s a total of $29.  The original payment was $3000. What happened to the missing $2971?
It is much clearer now that is that this is the wrong calculation. They have paid $27.  Of this $2 is in the clerk’s pocket, and $25 is in the till to pay for the room.

Going to extremes doesn't work for everything, but it is quite a powerful argument sanity-checker.
Read More
Posted in estimation, mathematics | No comments

Saturday, 14 April 2012

climbing up onto the shoulders of giants

Posted on 01:46 by Unknown
Newton
If I have seen further it is by standing on the shoulders of Giants – Isaac Newton 
Newton was not first to say this (and it may or may not have been a jab at Hooke), but the idea is sound: we can get further because we don’t have to invent everything from scratch; we can build on what others have done before. So, if we need to solve a particular problem that needs calculus, we don’t have to invent calculus from scratch to do so, we can use what Newton (and Leibniz, of course) invented. Standing on their shoulders, we can see further.

But how do we get to stand on the giant’s shoulders? (I’ll keep the metaphor to a single giant, as standing on the shoulders of multiple giants sounds too much like a circus act. And I am focussing on the mathematical giant.) We aren’t born up there on the giant’s shoulders. While we don’t have to grow into the giant (invent calculus), we do have to climb up the giant (study calculus).

And the giant is getting ever bigger. On the one hand, this is good: being so much higher we can see so much further. On the other hand, what happens when we have to spend our entire lives climbing up the vast growing giant, and never reach the viewpoint on the ever-distant shoulders?

We need short cuts up the giant. Fortunately, other are building ropes and ladders and lifts: tools to climb the giant more easily. So, we now have computer algebra packages that can solve our differential and integral equations for us; we no long need to spend years studying and practising how to do this.

But wait! cry the purists. That is cheating.
there is no Royal Road to geometry – Euclid
Understanding an idea meant entangling it so thoroughly with all the other symbols in your mind that it changed the way you thought about everything. – Greg Egan
There are no shortcuts, the purists insist. Mathematics is not a “spectator sport”. You have to do it, be immersed in it, internalise it, in order to really understand it.  The youth of today, with their fancy calculators and computers, they don’t really understand arithmetic and algebra and calculus.  Get off my lawn!
Socrates
There is nothing new under the sun when it comes to criticism of youth, of course. Plato, in Phaedrus, has Socrates rail against this new-fangled literacy:
 [writing] will introduce forgetfulness into the soul of those who learn it: they will not practice using their memory because they will put their trust in writing, which is external and depends on signs that belong to others, instead of trying to remember from the inside, completely on their own. You have not discovered a potion for remembering, but for reminding; you provide your students with the appearance of wisdom, not with its reality. Your invention will enable them to hear many things without being properly taught, and they will imagine that they have come to know much while for the most part they will know nothing. And they will be difficult to get along with, since they will merely appear to be wise instead of really being so. 
This sounds suspiciously similar to those modern complaints about using calculators rather than mental arithmetic, or using computer algebra programs rather than slogging through pages of pushing symbols around. These devices give only the “appearance of wisdom”.

a big sum
I do have some sympathy with this view. There does seem to be a lot of blind trust in the output of calculators and computers. However, I’m not sure it is purely the fault of the calculators. There can be uncomprehending blind trust in symbol pushing, too. I remember, many years ago, being in a computer shop, buying four items. The shop assistant wrote down the prices, and laboriously added them up, with much crossing out. When they announced the total, I said “that’s wrong”. They got a bit huffy, but then I pointed out their total was too small: it was less than one of the items on the list! As well as their huffiness, I detected a faint feeling of puzzled wonder from the assistant: how had I known? Despite the hand calculation, the assistant had no feel for the numbers. Maybe Socrates would have said that they should have added the numbers in their head? (Notice here that I didn’t know what the right answer was, but I knew the suggested answer was wrong.)

Another example comes to mind, again from many years ago. We were buying some new pillows: four for £4.99 each. The shop assistant wrote down 4.99 four times in a list, and added them up. Meanwhile I was going “£4.99 is a penny less than £5, so that’s £20 minus 4p, or £19.96.” I had the right money ready by the time the assistant came up with the answer, and was again met with puzzled wonder. (I’m sure that’s the real reason supermarkets took the prices off their goods: to stop some customers freaking out the cashiers by having the right money ready!)

I recounted this pillow story to my mother, who, faster than I did my shortcut calculation, simply multiplied 4.99 by 4 in her head, and got the right answer. I was almost as much in awe of this feat as the shop assistant had been in mine. But which approach shows more understanding of numbers: my short cut or my mother’s brute force calculation? Is it possible that slogging through all those exercises merely enable us to do calculations quickly, without thinking? And if there is no thought, then what have we actually gained? After all, one can learn by rote and merely “parrot” remembered answers.

Back to climbing that giant. What we need is a way of taking short cuts up and of having the “feel” for the numbers. An approach that could work is critical thinking about the supplied results (whether supplied by computer, or by our own unthinking calculations). We can keep the feel by using even shorter short cuts and heuristics that give an approximate answer, as a sanity check. Those shorter cuts and heuristics supply the feel, and when they are done automatically, they are the feel.

So, education shouldn’t be focussed on getting students to wade through pages and pages of exercises, pushing symbols (be they numbers or letters) around (unless they enjoy that sort of thing, of course). It should be more focussed on training in the use of short-cut tools, education on where and how to apply the tools, and meta-training in critical thinking about the results those tools give. Then we can climb the ever-growing giant fast enough to get to the top in time to see something before we die, and confident that we’ll understand what we do see when we get there.
Read More
Posted in education, estimation, mathematics, quotations | No comments

Saturday, 28 January 2012

Regress bars

Posted on 01:56 by Unknown
I was copying a large set of files, when I noticed some peculiar behaviour of the "progress" bar.


I'm used to the Minutes Remaining indicator usually being pretty meaningless (I've seen it go from days, to hours, to minutes, to seconds, over the course of seconds, and it often leaps up by an order of magnitude if I start doing something else on the computer). But this time it seemed even worse than useless.  I watched it for a few moments, then felt compelled to grab a pen and paper.  (I used an antiquated technology to record the data, as I didn't want to interfere with the copy process. These fluctuations were all its own work.)


The whole exercise covered a period of a couple of minutes (that is, the line representing the actual time remaining would be almost indistinguishable from the x-axis on this plot).  The final estimate (of 15 seconds remaining, up from the previous 10 seconds) stayed there for about three seconds, and the copy was finally finished.

Well, as they say, "Prediction is difficult, especially about the future".  But one might hope that the algorithm used gave better predictions as time progressed...
Read More
Posted in algorithm, computer, estimation | No comments

Thursday, 25 August 2011

the future price of electricity, part 3

Posted on 02:06 by Unknown
So, in June I blogged a follow-up to the weird estimate npower gave for my future electricity bills. Two months later, and I've had my next quarter's bill (differently weird, there).

The estimate seems to have gone back to a more reasonable amount this time around, so I'm no longer fearing an order of magnitude increase in power bills. I wonder what caused the original glitch?

But I'm going to keep a close eye on these estimates in the future.
Read More
Posted in electricity, estimation | No comments

Saturday, 4 June 2011

the future price of electricity, part 2

Posted on 10:21 by Unknown
In February, I blogged about a strange item on my electricity bill: npower's estimate of my next year's bill, which was nearly an order of magnitude higher than my current usage.

I've just had this quarter's bill. Same low usage, same high estimate. This made me go back and look at previous bills: had the estimates always been this high?

annual electricity prices
No. The previous two quarters had estimates of about the right amount. Earlier bills had no such estimates: it must be a new "feature". The graph here shows a plot of actual annual consumption (calculated every quarter) and npower's estimate of annual consumption.

The only data points in common (because, of course, I don't yet know my future annual consumption) are very close. Maybe npower do know something about electricity price inflation?

I'll know better in a couple of quarters time...
Read More
Posted in electricity, estimation | No comments

Thursday, 17 February 2011

The future price of electricity

Posted on 13:48 by Unknown
I got my electricity bill last week, and I noticed a nifty new feature that's been added to it: a predicted electricity cost for the next year. And very interesting that prediction is, too.

Here is my annual expenditure on electricity for the last few years (the numbers are ridiculously low for several related reasons that I won't go into here):

electricity prices
2003: £45.36
2004: £33.14
2005: £38.26
2006: £51.04
2007: £55.71
2008: £48.74
2009: £48.30
2010: £56.16

The graph shows a noisy but nevertheless upward trend, consistent with inflation more than with any increased usage on my part.

What do you think my electricity company's prediction for my 2011 bill is? A prediction that I am assured is based on "actual readings", according to my account. £60? Maybe as much £70? No. It is £488.77.

So, what does npower know about short term electricity price inflation that I don't?
Read More
Posted in electricity, estimation | No comments
Older Posts Home
Subscribe to: Posts (Atom)

Popular Posts

  • hyperbolic hyperbole
    What's with hyperbolic discounting? It's everywhere ! I first consciously noticed the term at a workshop about six weeks ago, and n...
  • better use seaweed
    As Neils Bohr is alleged to have said , “prediction is very difficult, especially about the future”. My smartphone has a weather app on it t...
  • oh dear
    We have a garden pond to help encourage frogs and other amphibians. Hedgehogs may suffer, however. :-(
  • "Windows support" -- not
    Just had another scam phone call -- someone with a strong Indian accent claiming to be calling from "Windows Technical Support" (o...
  • national stereotypes
    I've just got back from a very productive three day meeting in Paris. Just around the corner from where I was working, there was a marv...
  • retrospective holiday diary day 1: travelling north
    We went to the Lake District last “summer” ; this “summer” it was time for touring the other side of the country: Northumbria. The holiday s...
  • retrospective holiday diary day 5: trains
    Monday 24 September, and the long-threatened rain finally arrived. So this was the ideal day for the planned Carlisle-Settle rail trip . Bu...
  • funfair mirror trees
    One of the trees in our garden has died.  It died last summer in the drought, but we gave it a year to prove to us it really was dead.  It i...
  • retrospective holiday diary day 3: Lindisfarne
    Saturday 22 September, and the weather was still fine, sunny holiday weather so we decided to take advantage of the sunshine, and do Lindisf...
  • more scammers
    So not long after the scam phone call , the phone rings again. It's British Gas -- they get to call me because I'm actually a custo...

Categories

  • 3D printer
  • algorithm
  • astronomy
  • birds
  • Bonnie Tyler
  • books
  • cognition
  • computer
  • conference
  • Doctor Who
  • driving
  • ducks
  • duodecimal
  • education
  • electricity
  • estimation
  • Evernote
  • evolution
  • font
  • food
  • fractals
  • game
  • garden
  • graphics
  • grimoire
  • history
  • holiday
  • humour
  • language
  • LaTeX
  • lego
  • lol
  • mathematics
  • medicine
  • money
  • music
  • obituary
  • pedantry
  • politics
  • probability
  • psychology
  • publishing
  • python
  • quotations
  • research
  • robots
  • science
  • science fiction
  • space flight
  • statistics
  • TPS
  • trains
  • tree
  • TV
  • weather
  • web

Blog Archive

  • ▼  2013 (119)
    • ▼  December (1)
      • that's not in the least bit suspicious
    • ►  November (17)
    • ►  October (12)
    • ►  September (10)
    • ►  August (9)
    • ►  July (8)
    • ►  June (10)
    • ►  May (19)
    • ►  April (10)
    • ►  March (9)
    • ►  February (4)
    • ►  January (10)
  • ►  2012 (103)
    • ►  December (16)
    • ►  November (8)
    • ►  October (14)
    • ►  September (6)
    • ►  August (13)
    • ►  July (8)
    • ►  June (6)
    • ►  May (9)
    • ►  April (10)
    • ►  March (7)
    • ►  February (5)
    • ►  January (1)
  • ►  2011 (79)
    • ►  December (7)
    • ►  November (5)
    • ►  October (10)
    • ►  September (7)
    • ►  August (6)
    • ►  July (5)
    • ►  June (6)
    • ►  May (6)
    • ►  April (9)
    • ►  March (9)
    • ►  February (3)
    • ►  January (6)
Powered by Blogger.

About Me

Unknown
View my complete profile