Hard Tweets Explained: Nature Boy

This is one of a series of tweets I did experimenting with pseudocode poetry. That is, poetry written in the language we use to define computer programs. You’ve probably heard of programs referred to as “code.” Pseudocode is the same idea, except we aren’t writing in any particular computer language.

When you think about it, pseudocode is a really weird idea. It would be like writing the first draft of your essay in a made-up language, and then translating it to English to polish it up. It isn’t like that, actually. It is exactly that. Computer Scientists are a weird lot.

So anyway, I was thinking it might be fun to try to write poems in pseudocode. I thought the freedom from syntax and language might be liberating. To work through the experiment, I picked a poem that had already been written. It is the lyric to a song called Nature Boy.

The greatest thing
You’ll ever learn
Is just to love
And be loved In return.

I’m not sure that’s actually true. I think the greatest thing you’ll ever learn is probably the exact location of, and optimal stimulation for, all of your partner’s erogenous zones. But this love thing is probably a close second.

nature_boy ::= this funny equals sign is a pretty common pseudocode way of saying “is defined to be.” So we are defining nature_boy, which you recall was the name of the song.

learn > x ∀ x That upside-down A is the formal logic symbol for “for all values of.” So the right side of this inequality says “x for all values of x.” Which is a silly way to say “everything.” So learn greater than everything. That must make learn very large indeed. Perhaps the greatest learn there is.

→ ∃ love The arrow is the formal logic symbol for implies. The backward E is the formal logic symbol for “there exists.” So this says implies there exists love. Which is a peculiar way of saying “is just to love.”

∩ return(love) The upside-down U is the logic symbol for intersection. Intersection in Boolean logic is also the “and” operation. Finally, we have the return statement of the function. This is what the algorithm should emit to the caller, and of course, what we want to emit is love. So this is my way of expressing “and get loved returned.”

Homework: Go visit delict.us/alfageeek and search for pseudocode. See if you agree that this pseudocode poetry idea was a really bad one. Hey, if all our experiments succeeded, we wouldn’t be doing science, would we?


Hard Tweets Explained: 1001 Nights

My twitter friends often ask me to explain some of my more difficult, obscure tweets. I figured since I went to the trouble of setting up this blog, maybe I should do that explaining once, in one place, and then I can just point them here. I’m lazy that way. So this is the first in an infinite series. (That’s a pun. I’ll explain it when I get around to doing a blog post about my infamous π tweet.)

The tweet I embedded up above was inspired by a song. This particular song is a little hard to find. But I managed to locate a sample you can hear on Amazon:

Swept Away

It’s the third track on that page, called, obviously, One Thousand and One Nights. Even though there are only a few seconds available, you’ll get the picture. Go listen to that now. I’ll wait.

Got it? OK. That chord sound you hear in that sample is called a half-diminished 7 chord. An example half-dimishished 7 chord would be C-E♭-G♭-B♭. Half-dimished chords sound like the middle east. Snake charmer music. Actually, technically it’s fully diminished 7 chords that sound like snake charmer music. The difference is that the 7 is flatted twice in a fully diminished chord, so starting at C you’d have C-E♭-G♭-B♭♭ (which is just a silly way of writing A).

Diminished chords are cool, because they have a symmetry to them. Start on any note. Skip two notes, hit the next one, skip two, hit one, and so on. Since there are 12 notes in an octave, you will hit 4 notes before you reach your starting note an octave up. Those 4 you hit are a diminished 7 chord. There are only three such chords, obviously. (That’s obvious, right? I’m never really sure what’s obvious to other people.)

So anyway, you can find a keyboard and plink around any of those 4 notes (C -E♭-G♭-A) and you will sound like a snake charmer.

The half-dimished chord almost sounds like that, except it has a B♭ instead of an A. It’s close to the same feel, but less dissonant, so it sounds more comfortable to our western ears. Now look at that half-dimished chord. C-E♭-G♭-B♭ How about we bump that C up a half-step to D♭ and we stick an A♭ in between the last two notes so there isn’t a big gap. That’s a pretty small change: one finger moved a half a step and we added an extra note: D♭-E♭-G♭-A♭-B♭. You may know this list of notes as “the black keys.” That’s right, with that little change we turned our half-diminished 7 chord into the black keys on the piano! What fun!

OK, so we’ve got the black keys. So what? Well those 5 keys have another name: the pentatonic scale. (Penta means 5, tonic means notes, so it’s the 5-note scale.) “The Five Note Scale” never caught on as a name because it sounds so lame. So they call it pentatonic instead, because that sounds cool. And if you go plink at random on the black keys on a piano, you’ll see that those notes together do indeed sound cool. So pentatonic is definitely a much better name.

You may know those notes by another name: wind chimes. Most wind chimes use the pentatonic scale. So did the theme song to Barney Miller. And the bass line of the most excellent Eddie Harris song “Listen Here.” Wind chimes are not particularly cool, but those other two are seriously cool, and befit the notes used to play them.

Now the pentatonic scale is really cool. But we can make it even cooler. Like my brother once told me, “A raised fourth is hip.” (True story; he says all sort of weird shit I don’t understand.) For this to work, you need to start at the right place, so I’m going to rewrite our pentatonic like this: E♭-G♭-A♭-B♭-D♭-E♭. If you think of an E♭ minor scale, the 4th note would be the A♭ (even though it is third in our pentatonic, because we are too cool to play the second note [F] from that minor scale). So we can raise that to A, and leave everything else: E♭-G♭-A♭-A-B♭-D♭-E♭. Go plink out those notes and you are playing something we call “the blues.”

So a blues scale is just the pentatonic scale with a raised fourth stuck in now and then as a transition. To make it hip. As though cool wasn’t enough.

Alright, that’s all the music theory we need. Now a little literature and geography. The title “One Thousand and One Nights” (also know as “Arabian Nights”) is a collection of folk tales from Persia. If you were putting together one of those scholastic videos where John Lithgow reads books, and he was reading tales from 1001 nights, then you would use diminished 7 chords for the background music (or half-diminished, for the sake of our sensitive western ears).

The Tigris is a river that goes through Baghdad, which is sort of the heart of what used to be called Persia.

The Mississippi is a river that goes through the whole USA, but notably the delta of this river is widely considered the birthplace of the blues.

The Tigris doesn’t join the Mississippi anywhere geographically, of course. That’s a metaphor. When you perch on the precipice of half-diminished and pentatonic, you are balancing between Persian musical structure and Western blues musical structures. Just one finger moving a half a step, and then toss in two extra notes (one cool, and the other hip), and you’re there.

Homework: Go back to that Amazon link and buy that album, so you can listen to that song in its entirety. Eliane Elias is one of my very favorite Jazz pianists of all time. And in that song she deftly balances on that precipice. Sometimes in half-diminished, and sometimes in the blues. It’s really amazing.