./backlog: Charlie's blog

meanderings through tidbits of mathsy computery stuff

The Phantom Email "J"

Since I started working at my internship placement this year, I’ve noticed a fairly frequent occurrence of a phenomenon where for some odd reason (and seemingly out of context) a phantom "J" character would appear in an email at the end of a sentence. Take this (fabricated, but representative) example: Hi all, There is cake downstairs if anyone wants some. J Bob Anyhoo, with a bit of Googling, I found this blog post which explains the reason behind the phantom J.

Read On →

"XMLHttpRequest" is Silly

Here’s something that’s been irritating me lately - Javascript’s XMLHttpRequest function. I don’t normally spend a great deal of time doing web development, but as part of a project at work I’ve been using the Google Maps API to develop a web application to visualise some mapping data. Developing applications using the Google Maps JavaScript API is great - the API is easy to use, the documentation is well written, it’s consistent and everything’s well named.

Read On →

Optimising the Fibonacci Sequence with Generators

So recently, a friend of mine was talking about ways of calculating the sum of the first n numbers in the Fibonacci sequence, and it gave me an idea. The Fibonacci sequence is very well known, and it’s an interesting construct - both mathematically and computationally. As well as commonly being taught in mathematics classes as a simple introduction to sequences, the Fibonacci sequence is often used as a method for introducing beginner programmers to the principle of recursion.

Read On →

Testing the Monty Hall Paradox

So today I watched the Mythbusters episode that discussed the "Monty Hall paradox" - the infamous probability problem. The Monty Hall paradox is well-known enough that I’ve come across before during maths lessons in school, in probability and statistics textbooks, in lectures, on TV, and so on. This particular Mythbusters episode was testing the hypothesis that contestants who "switched" their choice were twice as likely to win. Mythbusters is well known for "bad science" - that is (amongst other things), biased test conditions, contrived experiments, low sample sizes and so on.

Read On →

Parallel I/O and JASMIN

So further to my last post, I’ve been putting some parallel Python code to use… at work! I currently work at CEDA in Oxfordshire, using a number of the JASMIN virtual machines to analyse and extract information from scientific datasets. This involves processing tens of thousands of files - ranging from a few kilobytes to 7-8 gigabytes in size. To make this task feasible, I need access to some considerable hardware - which CEDA has in the form of JASMIN.

Read On →