The Fugue Counterpoint by Hans Fugal


Mental UTC Conversion

I do a lot of UTC conversions, more than most, and I am dismayed that after perhaps a year of relatively frequent mental UTC conversions it's still no faster than firing up a terminal and typing date -u. Even with Quicksilver and fleet fingers my mind should win that race every time.

No one step is difficult, but there are too many steps. First you have to load in the reference time (might be a UTC time or local time) then maybe convert it to 24-hour time then remember whether DST is in effect or not and whether that means -7 or -6, then figure out whether to add or subtract that 7 or 6 hours, then do the actual subtraction, then wonder if you did that right and possibly wonder whether that's the same date as today or not… Clearly the brute force method is not the way to go.

If Richard Feynman can calculate square roots in his head instantly, I'm sure I can convert time zones. Anyone have any suggestions on how to gain this skill? I think I'll add Mental Math for Pilots to my wishlist.


Ruby WX

WX is shorthand for weather in the same nutty circles that encode weather observations and forecasts like this:

METAR KLRU 261553Z AUTO 00000KT 5SM BR OVC004 03/03 A3009 RMK AO2
TAF KLRU 261600Z 261612 35007KT P6SM -SHRASN SCT010 BKN025
        TEMPO 1618 5SM -SHRA BR BKN005 OVC015
        FM1800 28010KT P6SM VCSH SCT015 BKN030
        FM0300 28010KT P6SM SKC

You need a library for parsing this. I've written one

This is release 0.1.2,
featuring METAR parsing and documentation. TAF forecasts are forecast for
version 0.2.x. Automatic fetching and human-readable to_s methods are likely
to pop up like daisies anywhere inbetween.

If you find a bonafide METAR that doesn't parse correctly, by all means let me
know (send the raw METAR to

Tagged as: , , , , No Comments