It’s been a long while, but response to the last music post was enough to get me revved up again. Now it’s time to continue with the Robot Music series on procedurally written music.

I wanted this tutorial to be simple, but educational enough that if you wanted to study more, you would know where to look. For that reason, there is a lot of music vocabulary in here. I’ve done my best to explain each term as it comes up, but if any remain confusing, don’t hesitate to look them up elsewhere or even skip them. You can probably forget all of the fancy words and still understand the important concepts being discussed.

In the last session we rolled a die to generate riffs in a Major Pentatonic Scale. Sticking to that one scale limits the sound of your music a lot, so now we’ll mix up our technique by exploring modes. We’ll be replacing the Major Pentatonic Scale with the full Major Scale. The pentatonic only has 5 notes, while the entire Major Scale has 7. Those last two notes can be seen as bothersome* which is why they were left out last time.

Most people’s first musical revelation is the amazing power of switching between a Major scale and a Minor scale. It’s often generalized that when a song is in the Major scale it sounds happy and when it’s in a Minor scale it sounds sad. That is the effect we will be looking into to change the emotional impact of robot songs.

As mentioned in the last post, popular music is limited to 12 notes (C, C#, D, D#, E, F, F#, G, G#, A, B — then loop to the next octave; C’, etc). Each of these letters is an arbitrary name for an arbitrary frequency of air waves. The only thing that is not arbitrary about each note is its relationship to all of the other notes. The relationships between notes are really what is important; and that’s where scales come in.

A scale is a list of notes used for part or all of a composition. However, to grasp the significance of a scale, you are better off ignoring the “notes” within it and focusing on its form; the pattern of the scale or the kind of note relationships it involves.

To discuss relationships, we’ll use the “half-step” as one basic unit. A half-step is the difference in pitch between two adjacent keys on a piano or a difference of 1 fret on a guitar. It is the distance between any one note and its neighbor (C and C# or E and F). The 12 notes of common music span 12 half-steps.

Let’s use half-steps to create a method for describing note relationships without specifying note names (because all we want is the scale’s pattern). First we’ll look at the relationships between notes in the Major Scale:

-We’ll represent all of our possible notes with 12 dashes:

C, C#, D, D#, E, F, F#, G, G#, A, A#, B

– – – – – – – – – – – –

-Now we can describe the C Major Scale by representing each of its notes with an x:

C, C#,D, D#,E, F, F#,G, G#,A, A#,B

x – x – x x – x – x – x

Notice that the dashes between each x represent a note that is not included in the Major Scale.

-With this pattern, we can figure out which notes exist in keys other than C, such as D Major, E Major, G# Major or any other:

Pattern:

x – x – x x – x – x – x

C Major:

C, C#,D, D#,E, F, F#,G, G#,A, A#,B

D Major:

D,D#,E,F,F#,G,G#,A,A#,B, C, C#

E Major:

E,F,F#,G,G#,A,A#,B, C, C#, D, D#

~

G# Major:

G#,A,A#,B, C,C#, D,D#, E, F, F#,G

Etc.

As you can see, the names of the notes are irrelevant if you know the pattern. Memorize that pattern and visualize it transposed over the keys of a piano or the frets of guitar (the pattern can begin on any key or fret). Play only those keys or frets where the x’s go and you will be playing a Major Scale. Most pop music is completely limited to this one scale. You’d be surprised at how easy it is to play along with many songs once you’ve learned this pattern.

Each x in a scale is called a degree. The Major Scale has 7 degrees (e.g. the 2nd Degree of the C Major Scale is the D note).

The difference between the 1st degree and the 2nd degree in the Major Scale is 2 half-steps. You can also describe the distance between them as 1 scale step. The distance between each degree in a scale and the next highest degree is 1 scale step, but it can be any number of half-steps! For example, C is the 1st degree of the C Major Scale and F is the 4th degree. They are separated by 3 scale steps, but they are also separated by 5 half-steps (C-D-EF-G-A-B).

Now that you know the pattern in the Major Scale, you must have realized there can be tons of others too. You’re right!

The Minor Scale and Modes

The pattern you use is the scale you are in, and changing scales can completely change the emotional charge of your music. So now let’s look at the Minor Scale.

The most common Minor Scale uses this pattern:

Pattern:

x – x x – x – x – x x –

C Minor:

C, C#,D, D#, E,F, F#,G, G#,A, A#,B

Look at the differences between the Major Scale and Minor Scale:

Major:x – x– xx – x – x– x

Minor:x – xx –x – x – xx –

Notice that the 3rd and 7th x’s of the Major Scale are lowered by 1 half-step (or flattened) in the Minor Scale.

You have to wonder, what led some age old musical wizard to discover such a slight modification to the Major Scale that could completely shift its emotional meaning? Maybe we can figure that out. . . . (This might get tricky, so go slowly if you must.)

-Let’s look at the Major Scale in 1 octave:

x – x – x x – x – x – x

-There are obviously more than 12 keys on a piano and that is because there are multiple octaves. Octaves are created because the pattern of a scale loops every 12 half-steps. If we extend the Major Scale over 2 octaves, it looks like this:

x – x – x x – x – x – x|x – x – x x – x – x – x

-Now, let’s start from the 1st x and count our way to the 6th x in the 1st octave, then highlight it:

x – x – x x – x –x– x|x – x – x x – x – x – x

-Do the same thing to the 6th x in the 2nd octave:

x – x – x x – x –x– x|x – x – x x – x – x – x

-What if we took all the notes starting with that 6th x and ending before the 6th x of the next octave? Here they are all highlighted:

x – x – x x – x –x – x|x – x – x x – x –x – x

-Let’s clean it up by getting rid of all the other notes:

x – x|x – x – x x – x –

-Remove the octave separator and, look at that, it’s the Minor Scale:

x – x x – x – x x – x –

In other words, the Minor Scale is equal to the Major Scale from the perspective of the 6th x, or the 6th Degree. That’s what a Mode is. A mode of a scale is its pattern when described from the “perspective” of one of the degrees in a scale (a degree = an x). In music lingo, no one says perspective though; you would call it the root. The 6th Mode of the Major Scale is also called the Aeolian, but most of us just call it the Minor Scale.

Here is a list of all the modes of the Major Scale (the first and last degrees of the 1st mode have been highlighted to emphasize the differences between each subsequent mode):

1st Mode/Unison: x – x – x x – x – x – x

2nd Mode/Dorian:
x – x x – x – x – xx –

3rd Mode/Phrygian:
x x – x – x – xx – x –

4th Mode/Lydian:
x – x – x – xx – x – x

5th Mode/Myxolydian:
x – x – xx – x – x x –

6th Mode/Aeolian:
x – xx – x – x x – x –

7th Mode/Locrian: xx – x – x x – x – x –

Notice that the 1st mode is just the normal Major Scale. The 2nd mode is the same as the 1st one, but all the x’s are bumped to the left by 2 half-steps (1 scale step). The third mode is bumped by a total of 4 half-steps (2 scale steps) and the 4th mode is bumped by 5 half-steps (3 scale steps). They are all the same basic pattern as the Major Scale, but slid over to one side. The difference between each one is how far they are slid.

Each mode has a distinctly different feeling; some more radical than others.

Defining Your Mode

So the question remains, when you’re writing a song using the Major Scale, how do you define your mode? This is actually a complicated question, but for now I’ll keep it simple. Generally, the first note played is the root. All the notes after that determine your scale and mode depending on how they forge a pattern.

Let’s say you make a riff out of this sequence of notes: C, E, G. C is the root note because you played it first, then the scale and mode are determined by E and G’s relationship with C. Let’s look at that relationship compared to the pattern of the Major Scale (1st Mode):

CC# D D#EF F#GG# A A# B C’

x – x – x x – x – x – x x’

Those notes are a perfect match for the Major Scale in the 1st Mode! What’s more, is that those notes are very characteristic of the Major Scale’s 1st Mode; they are a strong part its distinctive feeling.

What if you played a slightly different sequence of notes?

C C# DD#E F F#GG# AA# B C’

x – x x– x – x – x x – x’

Now your notes describe the Major Scale’s 6th Mode, also known as the Minor Scale. Play the first sequence and you get a happy tune, play the second and it’s sad.

Overview

First, scales showed us that a note’s impact is dependent on its context (the pattern of other notes played near it). Modes showed us that the impact of a pattern depends on the root, the “starting point.” When you start with the 1st degree in the Major scale, you get the “happy” sound. When you start with the 6th degree in the Major scale, you get the “sad” sound. In many cases the root is the first note played in a riff.

Experiment

Let’s try using the same randomly generated song (with the help of a di) of Robot Music I, played in different modes.

This one is very dark, somewhat distressing. Such is the Locrian Mode! A mysterious she-devil!

Now you know how modes can change the emotional impact of your music, but we haven’t yet discussed how you control that impact. How can you predict the feeling that will be created by a given mode? What is the meaning of a given note? That will be the topic of the next episode of Robot Music: The Circle of Fifths. Finally, we will begin quantizing music! (And I’ll get it up sooner this time)

-Christopher J. Rock

*This is the pattern of the Major Pentatonic Scale:x-x-x–-x-x-–. This is the pattern of the entire Major Scale: x-x-xx-x-x-x. As you can see, the 4th and 7th degrees used in the entire major scale are not included in the major pentatonic scale. Those two notes can be very beautiful, but when played together or in sequence they form what is called “The Devil’s Interval.” This interval is equal to 6 half-steps (C and F#) and earned its name in classical music because it was found to be so grotesquely dissonant that it was forbidden. Use of this interval was later popularized in Jazz, especially Bebop and later experimental forms. In more recent musical trends it can be found in much of hardcore and other genres that aim to inspire a sense of darkness, anger or anxiety. You can say that in modern times, we have lowered the status of the Devil’s interval from “sinful” to “ill-advised.” The point of all this is to say that in Robot Music I, I chose to use the Pentatonic Scale to raise the chances that you would be happy with the music generated by that system. However, it’s about time you face the real world and realize that a little dissonance never hurt anyone. If you prefer the major pentatonic scale, you can easily apply all of the concepts herein to that instead of the entire major scale. However, the emotional variation between modes of the pentatonic scale will not be nearly as radical as those of the entire major scale. That being said, Blues and Rock are generally played in the pentatonic so if you prefer that sound, you may find it beneficial. The 7th Mode (Locrian) of the Major Scale includes a Devil’s Interval between the 1st and 5th degrees. In fact, you can hear it in the recording of our generated song in the 7th Mode (as linked above).

Other Song Information

In case you’re curious, here is the original song written in the form of half-steps from the root:

0, 0, 7, 7 – 0, 0, 7, 7 – 0, 0, 7, 7 – 0, 0, 7, 7

0, 4, 2, 7 – 0, 4, 2, 7 – 0, 4, 2, 7 – 0, 4, 2, 7

—

0, 0, 7, 7 – 0, 0, 7, 7 – 0, 0, 7, 7 – 0, 0, 7, 7

0, 4, 2, 7 – 0, 4, 2, 7 – 0, 4, 2, 7 – 0, 4, 2, 7

—

0, 0, 0, 0 – 7, 7, 7, 7 – 4, 4, 4, 4 – 0, 0, 0, 0

0, 0, 0, 0 – 7, 7, 7, 7 – 4, 4, 4, 4 – 0, 0, 0, 0

You can use these numbers as fret distances on a guitar or key distances on a piano if you include the black keys.

And here is the original song written in the form of degree numbers:

1, 1, 5, 5 – 1, 1, 5, 5 – 1, 1, 5, 5 – 1, 1, 5, 5

1, 3, 2, 5 – 1, 3, 2, 5 – 1, 3, 2, 5 – 1, 3, 2, 5

—

1, 1, 5, 5 – 1, 1, 5, 5 – 1, 1, 5, 5 – 1, 1, 5, 5

1, 3, 2, 5 – 1, 3, 2, 5 – 1, 3, 2, 5 – 1, 3, 2, 5

—

1, 1, 1, 1 – 5, 5, 5, 5 – 3, 3, 3, 3 – 1, 1, 1, 1

1, 1, 1, 1 – 5, 5, 5, 5 – 3, 3, 3, 3 – 1, 1, 1, 1

You can use these to number the white keys on a piano, starting from the C key. This sequence of numbers is the essence of the song. Knowing these numbers, you can play in any key or mode with ease.