"So there are Oliphaunts. But no one at home will ever believe me."
Random header image... Refresh for more!

Credit rustworthiness

This is a cool little science project. All you need are some rust filings and a card with a magnetic stripe on it. Probably not a card you expect to re-use.

… finely powder some rust and then blow it over the magstripe on your credit card and you can see the zeroes and ones encoded on it by the stripes where the magnetic forces attract the ferrous particles.

Check out the picture in the original article. Neat.

(From “Use rust particles to reveal the data on your credit-card’s magstripe“, via Boing Boing.)

May 14, 2010   Comments Off

Take Note

I’ve been experimenting with some neat apps for the Mac, iPhone/iPod and the iPad. These are apps that are designed to be “as simple as possible,” in opposition to the usual philosophy of “having as many features as possible.”

The following are two note taking apps that are designed to work together, both with and without the Internet. Yes, apps for note taking. Note taking is a big deal. Suppose you’re starting a new position you have to write down a lot of obscure facts. Or you might need to remember the correct temperature for poaching eggs or the name of a set of legos or the title of a book to give as a gift. The Mac has an actual stickies app, which uses a similar approach. The problem is that it does really scale well—you can only have as many notes as will physically fit on your screen.

The first application I started using, for the Mac, is Notational Velocity. This is a free application developed as a non-commercial endeavor by public spirited hackers. It’s tiny and unobtrusive so you can leave it running all day. When something pops into mind, you type a title, hit return, and type your note. As you are typing in your title, the app will also show you other notes you’ve entered that might be relevant.

The second, for the iPad and iPhone, is Simplenote. This is basically the same idea for the iPad and iPhone.

What’s great is that if you create an account at http://simplenoteapp.com/, then the notes that you take with Simplenote on your iDevice are synced automatically to the notes on your computer stored in Notational Velocity.

All free. (Okay, Simplenote has advertisements, and you can pay $8.99 to turn the ads off.)

The idea behind both of these is to make it ridiculously easy to record a short thought, and to make them always available in searchable, wherever you are. They share the idea that good notes do not need to be any longer than a sticky note—one or two sentences (although they certainly let you enter more). You never have to save the notes. Every key you type is recorded to the computer for you. They never get lost and the computer, or iPad, or iPhone, will find it for you.

Pretty cool.

May 4, 2010   1 Comment

Making history

This very night, at approximately 1915, history was made as uniformed representatives of the United States, for the very first time in Iraq since the start of the war, prepared a batch of peanut brittle. It is believed, on the basis of no evidence, and zero research, that this is actually the first time peanut brittle has ever been prepared by US forces in the entire CENTCOM theater of operations.

Truly, a day that history will little remember and long regret.

May 2, 2010   1 Comment

Fairy complicated

I was doing a bit of background research on The Sorcerer’s House, the latest novel by my favorite author, an extremely dangerous and subtle man. Several of his more recent works have mined the mythologies of northern Europe—Gaelic/Celtic lore and the Norse cycle. When I was younger I regarded those mythologies are ridiculous (leprechauns) or brutal and predictable (Viking drinking songs). I was wrong, of course. The cute little fairies of Ireland and Wales are beings capable of reason, very powerful, and utterly soulless–hence, quite psychotic; and the tales of the Norse Edda are some of the most disturbing things imaginable, and seem to suggest that LSD was discovered a thousand years earlier than generally acknowledged.

I had the following links open while trying to wrap my head around the story.

All worth perusing.

Bonus cool derivation (not just the word, note the name at the end):

The word fairy derives from Middle English faierie (also fayerye, feirie, fairie), a direct borrowing from Old French faerie (Modern French féerie) meaning the land, realm, or characteristic activity (i.e. enchantment) of the legendary people of folklore and romance called (in Old French) faie or fee (Modern French fée), derived ultimately from Late Latin fata (one of the personified Fates, hence a guardian or tutelary spirit, hence a spirit in general)…

To the word faie was added the suffix -erie (Modern English -(e)ry), used to express either a place where something is found (fishery, heronry, nunnery) or a trade or typical activity engaged in by a person (cookery, midwifery, thievery), and in later usage generally applied to any kind of quality or activity associated with a particular sort of person (as in English knavery, roguery, witchery, wizardry)…

The word fey, originally meaning “fated to die” or “having forebodings of death” (hence “visionary”, “mad”, and various other derived meanings) is completely unrelated, being from Old English fæge, Proto-Germanic *faigja- and Proto-Indo-European *poikyo-, whereas Latin fata comes from the Indo-European root *bhã- “speak”.

Morgan le Fay, whose connection to the realm of Faerie is implied in her name…

(From “Fairy – Wikipedia, the free encyclopedia.”)

May 1, 2010   Comments Off

Triangle Man, Triangle Man

In case you were wondering, here is the answer to the pop quiz.

I made this presentation completely on the iPad—more as a proof of concept or trial run than by way of doing serious work. I learned several of the kinks and quirks of Keynote on the iPad this way. Of course I went over the top with animations just to see what it could really do, making it highly questionable from an aesthetic perspective. The mixture of typefaces is also rather… eclectic.

It’s just for fun.

Update: Yeah, I made an error in the presentation. Well, at least one. I found it myself though so it’s cool. Fixed now.

April 28, 2010   Comments Off

Three corners, three sides, infinite possibilities

Kids, even grown up ones, ask the darnedest things. During class yesterday we talked a little bit about geometry, and one asked, “How many kinds of triangles are there?” We had been discussing the concept of congruency, and I drew some examples of right triangles, equilateral triangles, and isosceles triangles.

I was actually stumped by this question. I vaguely remembered that triangles were sometimes called obtuse and acute, but I wasn’t sure if that was a common use, or if it was more typical to describe them as having “an obtuse angle” or “all acute angles.” Somebody said, “I think one is type is scalene.” Right, there is that. I was able to do a simple proof in class that a triangle could only have one obtuse angle. That is, since the inside angles of a triangle come to 180º, and since an obtuse angle is one that is greater than 90º, it follows that the other two angles must be acute (less than 90º). I still wasn’t sure if I could enumerate all types of triangles, or if it was even possible to do so. I promised them I would give them an answer. Here it is—or at least, close enough.

Triangles can be classified according to the size of their interior angles. Based on the fact that the interior angles must add up to 180º, it follows that there are three kinds:

  • All of the angles are less than 90º (acute). For example, 80º—60º—40º. This is known as an acute triangle.
  • One of the angles is obtuse, that is, greater than 90º. The other two angles must be acute. This kind of triangle is an obtuse triangle.
  • One of the angles is exactly 90º. As expected, the other two must add up to 90º (for example, 1º and 89º), so they are acute. This is a right triangle.

It turns out you can also classify triangles according to the relative lengths of their sides.

  • Suppose your triangle’s three sides are the same length. This is an equilateral triangle. It turns out that there is only one way to make such a triangle to work out, and that is by having all of the interior angles the same. Since they must sum to 180º, each angle is 60º.
  • Perhaps only two sides are the same length. It works out here that the angles of the “odd” side are identical to each other. This shape is an isosceles triangle.
  • Finally (since there are only three sides to consider!), there is the possibility of having a triangle where all three sides are different. This rogue is the scalene triangle.

So, pop quiz. How many types of triangles are there?

April 27, 2010   Comments Off

The Snipe Hunt

This morning, over espresso (how terrible war is), somebody wanted to play with my iPad (again, this war, right now: terrible) and started an impromptu game of Scrabble. We started a “pass the iPad” multiplayer game, and to my surprise the demo turned into a serious contest. Time passed, and finally somebody suggested that it would be great if we had a multiplayer computer version to play on our laptops, taking turns during little breaks throughout the day.

Surely, I offered, some enterprising programmer has created a free version of Scrabble that can be hosted on one computer and played locally with other computers on the same network. Probably, I hypothesized, this programmer had even made it possible to play through your web browser. The other two agreed that this was virtually certain to have happened.

“Well,” said one, “you should probably go back to your CHU to download whatever it is since the Internet is so slow so we can have this set up by tonight.”

“Right,” I agreed.

Six hours gone, and many vast and deep Internet searches later, I had to give up. I realized that the challenge to find this thing on the Internet had been like a perfectly aimed special munition into the very heart of my personal Death Star. A whole perfectly splendid idle Sunday used up in futile sifting through the bed of the web’s Mariana Trench.

“Well played, friend,” I admitted to my new enemy, many hours later.

Perhaps all was not lost. I have been casting about for something to work on to keep my coding skills sharp. A locally shareable game like Scrabble, with an HTML5 client, would have a pretty deep stack of the technologies I’m interested in. So I may pursue it.

Around dinner time I got a late invitation to go barbecue with our Lebanese friends. The food tonight was really, really good. I think that perhaps my culinary interest in Lebanese food has prompted our host to up his game, or it may be that improving economic conditions have made it possible for him to acquire better ingredients and equipment (for instance, tonight he had actual hard wood charcoal as opposed to briquettes). Whatever the cause, it’s great to be able to enjoy simple food, well prepared.

We were going to make peanut brittle afterwards, but everybody was stuffed, and I owed this to the blog.

Tomorrow I start teaching math class again. We learned in the last that having the class five or six times a week was likely too much, so we’re cutting back to every other day and placing more emphasis on homework.

April 25, 2010   Comments Off

Some UNIX Marbles

Some tricks I’ve used recently.

  1. Suppose you want to enable non-interactive (that is, “passwordless”) login to a remote host using ssh. This happens all the time, right? If you follow the usual steps, or the man page, there is a good chance it will fail on you without explanation. This is because ssh silently croaks when it discovers that your ~/.ssh directory is group or globally readable. To fix it, just
    chmod 700 ~/.ssh

    and you’re done. Some helpful links:

  2. File transfer (ftp, scp, http, whatever) interrupted from a known host? Resume file copy using rsync. You just supply the –progress argument point rsync to the source file. Found this tip at a defunct Danish blog. Sample usage:

    rsync --progress --rsh=ssh "joe@joesdiner.com:mydir/myfile" .

    Note that the destination is required, so to resume in the working directory use . as above. rsync will compare the two files and resume copying at the break.

  3. Setting (or spoofing) your Machine Address Code (MAC) on OS X? Use the ifconfig command, passing lladdr with your new, colon-delimited MAC. This needs to be done as root, so sudo is required. Sample usage:

    sudo ifconfig en0 lladdr 00:11:22:33:44:55

    Used on OS X 10.6 but I’m sure it works on any POSIX system. I looked this up for a friend because his, er, off-brand (Iraqi) router insisted that his MAC was invalid, so it couldn’t be entered into the MAC filter table. Odd. Found here.

April 23, 2010   Comments Off