Archive for the ‘Fun’ Category

My first dashboard widget

Tuesday, May 25th, 2010

These days I find myself converting between “coalescence units” (a time unit of 2Ne generations) and “substitution units” (time measured in expected number of substitutions) several times a day.   It is not really much of a problem to do, but my brain is simply not wired to do arithmetic in my head, so I usually fire up R or Python for this.

I am learning Objective-C and Cocoa these days, more for fun than anything else, but I figured that I could write a small unit conversion application to get some use out of it.  I mentioned this to Kasper, but he suggested that I write a dashboard widget instead.

I have never used Dashcode before, but I fired it up this morning before I headed for the office, to get a feeling for how it works, with the intention of writing a widget during the week.  It turns out it is extremely easy to work with, though, and within half an hour I had a complete conversion widget coded up.

The only thing I don’t quite like about it yet is that when I do the conversions it doesn’t present the results in the text field in scientific notation, so I get stuff like 1000000 instead of 1e6 or 0.0001 instead of 1e-4, which makes the conversions somewhat harder to read.

I’m sure there is a way to format the numbers, but my Javascript-fu is not up to it.  This widget is the first Javascript I have ever written.

Motivation

Wednesday, May 19th, 2010

Hat tip Amir.

Boat race

Thursday, April 29th, 2010

Today, Aarhus University holds its traditional boat race at our university park.

This is a rowing competition where student groups from all over the university competes.  It isn’t quite like the traditional Oxford/Cambridge boat race.  For one thing, the race is across a lake that is only a few meters wide (but you have to cross it more than once). Another difference is that only inflatable boats are allowed in the race.

Well, with one exception.  The group that I belong to (although no longer a student I am still a proud member), TAAGEKAMMERET, can compete in any home made boat we want as long as we promise not to win.  So far we have kept that promise and I am sure we will keep up this proud tradition.

Another thing that differs a bit is that it is not just a rowing competition, but also a drinking competition.

Each time you reach the other shore, you have to drink a beer before you can get back in the boat for the next lap.

Beer sale starts at noon, the race is two to five, and after that it breaks into different parties at the various departments around the university.

Tomorrow is a holiday here, which is probably good since those parties tend to last all night.

Hubble tour

Tuesday, April 27th, 2010

Apropos Hubble Space Telescope’s birthday, here’s a great video from Google:

A Dismal Guide to Concurrency

Monday, April 26th, 2010

Carlos Bueno has a very nice discussion of the problems (and potential solutions) to developing concurrent systems here.

Worth a read.