Skip to content

Category Archives: Technical

Parallelizing FLAC encoding

05-May-08
One thing I noticed ever since getting a multi-core system was that the reference FLAC encoder is not multi-threaded. This isn't a huge problem for most people as you can simply encode multiple files at the same time but I usually rip my audio CDs into a single audio file with a cue sheet instead of separate track [...]

bfpp - embed brainfuck in C++

23-Apr-08
Okay, I lied; you can't really embed brainfuck in C++ but you can get pretty close. Here is an example: #include "bfpp.h" int main() { // Prints out factorial numbers in sequence. Adapted from // http://www.hevanet.com/cristofd/brainfuck/factorial.b . bfpp * + + + + + + + + + + * [...]

Mac Pro woes

27-Jan-08

I woke today to find my computer restarted instead of waking from sleep. Then 10 minutes later it froze with some graphics corruption. Looks like I’ve been hit with the problems described in this thread and on this page. I will try an SMC reset and PRAM reset but if it doesn’t […]

Mac Pro first impressions

27-Jan-08

I was long overdue for a computer upgrade so I decided to take the plunge and get the newly-upgraded Mac Pro. Here are my thoughts in no particular order.
First, this thing is seriously heavy, weighing 43.4 lbs when removed from the box. It is much quieter than my old Athlon, though.
I was waiting […]

Backwards day at akalin.cx

27-Jan-08

If any of you have glanced at my blog lately or (more likely) I’ve complained about it to you, you’d know that blog entries have been appearing in reverse order for a while. From other people with the same problem it looks like this MySQL bug was the culprit, and indeed this post from […]

Finding the longest palindromic substring in linear time

28-Nov-07
/* Another interesting problem I stumbled across on reddit is finding the longest substring of a given string that is a palindrome. I found the explanation on Johan Jeuring's blog somewhat confusing and I had to spend some time poring over the Haskell code (eventually rewriting it in Python) and walking through examples before it "clicked." I haven't found any [...]

At long last…

21-Nov-07

The project I was working on at Amazon finally launched!
It’s drawn a lot of criticism since it was first leaked more than a year ago; I wonder if Amazon’s take on the e-book reader is bold enough to overcome the current limitations of e-ink and its high price tag. Hopefully this will kick-start an […]

A foray into number theory with Haskell

06-Jul-07
I encountered an interesting problem on reddit a few days ago which can be paraphrased as follows: Find a perfect square s such that 1597 s + 1 is also perfect square. After reading the discussion about implementing a brute-force algorithm to solve the problem and spending a futile half-hour or so trying my hand at find a better way, someone noticed that [...]

Simulating gravity with Javascript and <canvas>

11-Apr-07
One app I've always wanted to do was an n-body gravity simulator. Having recently discovered the <canvas> tag, I decided to whip up a quick naive simulator (won't work in IE, although this looks promising.): #statistics { padding: [...]

Japanese handwriting recognition systems

21-Oct-06

When I was in Japan, one of the things that helped me get around was a free program for my PDA that would let me input Japanese characters using the stylus and look them up in a dictionary. However, the handwriting input method was very sensitive to stroke errors which was sometimes frustrating, as […]