[ Content | Sidebar ]

Archives for February, 2011

Pretty Norman Church

February 27th, 2011

Here’s a pretty and very old Norman church I saw this morning:

This is inside the remains of the Roman town at Silchester, which you may remember I visited last summer. Here, for comparison, is what the ruins look like in the winter. It’s still a very pleasant place!

Filed in photos - Comments closed

Cuckoo Hashes in Lisp

February 20th, 2011

I’ve been learning about cuckoo hashing this evening and to help with that I’ve written an implementation in Common Lisp that others might find useful: cuckoo.lisp. It provides a package cuckoo which exports make-cuckoo-hash, cuckoo-insert, cuckoo-lookup, and cuckoo-delete which perform the obvious hash-table operations. The key feature of cuckoo hashes, if you haven’t come across them before, is that they have constant worst-case lookup time. They are also quite amenable to implementation in hardware.

The keys are implicitly fixnums since it’s a prototype for a C/VHDL implementation, but it shouldn’t be too hard to extend to a generic key type. The insert function automatically rehashes in-place if the table becomes full. The hash function is the xor of three randomly selected universal hash functions, as recommended by the Pagh and Rodler paper.

TrainGame updates

February 19th, 2011

I’ve been quite silent about TrainGame recently, but it’s not dead! I have been working on it a little bit – here’s an up-to-date screenshot:

The most obvious change is the new green train! Eventually there’ll be multiple trains driving around and you’ll have to take care not to bump into each other.

I’ve also been trying to make the ground look more realistic and less dull. After a few failed attempts I’ve settled on using a procedural noise texture to make the grass look more interesting. Seems to work quite well for little overhead.

A bit more subtle, but I’m slowly replacing the various existing track types with a single spline-curve track element. This means the track is no longer constrained to travel along the X or Y axis – you can see the train travelling along some diagonal track in the picture.

Loudwater, Henley, things in between

February 13th, 2011

Yesterday I went for a walk between Loudwater (near High Wycombe) and Henley on Thames. Here’s roughly where I went:

Distance was a tad over 14 miles. Not a lot of interesting things to report: it was mostly quiet countryside alternating between farmland and woodland. The Chiltern Hills are very pretty: I should go there more often! Here are some photos I took:

Sonning Bridge

February 13th, 2011

Here’s a nice photo of the bridge at Sonning that I took a few weeks ago and forgot to post.

Filed in photos - Comments closed