Archive for the ‘Mathematics’ Category

Project Euler 39

April 12th 2008

If p is the perimeter of a right angle triangle with integral length sides, {a,b,c}, there are exactly three solutions for p = 120.
{20,48,52}, {24,45,51}, {30,40,50}
For which value of p < 1000, is the number of solutions maximised?

WARNING: CONTAINS MATHEMATICS
Continue Reading »

Posted by tom under euler & Mathematics & Python | 2 Comments »

Arithmetic is a great bollocks detector

March 29th 2008

Go and read Pupils to get ‘new world’ trips from the beeb.

You may think “trips abroad for kids, great” , if you are more cynical you may think “heads choose the kids, not sure I like that”.

Let us do some arithmetic, 100 kids for 6 weeks each for £1.4M.

  • £1400000/100 = £14,000 per child
  • £14000/6 = £2′333 per week
  • Assuming a 40 hour working week, £58/hour

Of course its not that simple, the kids clearly don’t get all the money as if they had a 6 week job. I think a few marketeers in the UK, all the necessary admin by the British Council will do away with some of the money too, but I can’t imagine any way this is good value for the country or any organisation involved (I am not cynical enough to suggest that for the BC the point is to administer it.)

Hows about giving 1000 kids £1000 spend in a country of their choice, you could get them to bid for the money and report back with diaries and photos etc. All the £500’s the government paid into child trust funds for children with low-income parents could become a good jolly fund for them when they hit 18, or they could get driving lessons and a car - not a bad deal, particularly if their folks contribute anything else to the fund along the way. That or 18th birthday parties become 5 day benders in estates around Britain.

Posted by tom under rant & Mathematics | No Comments »

You Know You Are A Maths Geek When…

February 22nd 2008

You are walking home late at night and two girls run past, one turns to the other and says “this is the millionth time I have ran today” and you cannot help but say “You would have to start and stop running 10 times a second, while you said that you would have to have done it 30 times”

You know its real bad when you get home, do the calculation and and are disappointed you did not say 11.5 and then blog about it.

Posted by tom under Mathematics | 1 Comment »

You know you’re a maths geek when..

November 21st 2007

You are singing the song that goes “I got love for you if you were born in the 80s” and your girlfriend (who was born in 1979) says “what, no love for me?” and you reply “actually what I said does not imply that at all, you cant just negate both sides of a proposition and expect to get a true statement, if you reverse the implication too (to get the contrapositive) then you have a true statement, ie if I don’t love you you weren’t born in the 80s.”

Posted by tom under Mathematics | No Comments »

Tommys Project

November 15th 2007

I posted last time about TeXmacs and remembered the plugins for using it to display output from some of the superb free maths packages (which sometimes lack a nice display).

The one I am excited about most is for SAGE. SAGE is written in python and leverages the hard work of the other projects (its motto is Building the Car Instead of Reinventing the Wheel). See the TeXmacs plugin here and some screenshots of SAGE here.

I will take a look at the code and see if I can contribute anything, it will be nice to get involved in a big project.

Posted by tom under Mathematics & Python | No Comments »

Pointless Testing

November 13th 2007

Usually I am in favour of testing, when people say “weighing a cow does not make it any heavier” I reply that if you measure nothing, you will never see any improvements. Usually people can come up with cogent arguments against the particular things examined but it never seems to be the case that measuring nothing is the answer, some better metric needs to be created.

I stumbled across a site that reminded me of when I used to read tomshardware to see how fast new PC parts really were (or look at nice graphs and read a conclusion telling me). Their benchmarks of Ubuntu vs Fedora and The Last 12 Linux Kernels strike me as pretty pointless. Pages of graphs saying things are the same bar noise, as you would probably expect. The conclusion of the distro shootout at least says you should (could?) not base your decision on the results. The Linux one is interesting:

The only benchmark where there was a definitive improvement was with the network performance. Granted, these 12 Linux kernels were only tested on one system and in eight different benchmarks. We will continue benchmarking the Linux kernel in different environments and report back once we have any new findings.

Of all the benchmarks, I would have predicted in advance that the network one would be noisiest. I would suggest that you would get different results on different machines, perhaps they should use different clocks too.

Do these people creating the graphs know about repeating measurements, averaging and statistical significance tests? I think not, so what is the point?

Posted by tom under linux & Mathematics | No Comments »