Skip to content

Instantly share code, notes, and snippets.

@tomtheisen
Created August 17, 2022 14:08
Show Gist options
  • Save tomtheisen/1eab26d96da2fce22f64528c1ce3a99d to your computer and use it in GitHub Desktop.
Save tomtheisen/1eab26d96da2fce22f64528c1ce3a99d to your computer and use it in GitHub Desktop.
Harmonic Music Theory Crash

This road leads directly to functional-harmony-random-progression-generator.

There's a lot more stuff in music theory.

Notes

█ █ █ │ █ █ │ █ █ █ │ █ █ │ █ █ █ 
█ █ █ │ █ █ │ █ █ █ │ █ █ │ █ █ █ 
│ │a│b│c│d│e│f│g│a│b│c│d│e│f│g│ │ 
┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─

These are notes. Higher notes are to the right.

Note Names

The white key names are listed. Black key names are relative to an adjacent white key.

  • ♯ ("sharp") is the adjacent note to the right
  • ♭ ("flat") is the adjacent note to the left
  • ♮ ("natural") is just the regular note, sometimes used to disambiguate.

f♯ is a different spelling for g♭. e♯ is a different spelling for f♮.

Note that on the keyboard above each note name is repeated. Sometimes a note name is followed by a number to indicate which octave it is. Numbers increase to the right.

Octaves

The keyboard repeats. The interval of repetition is an "octave".
The ratio of frequencies of two notes separated by an octave is always exactly 2/1.

Tuning

There are a bunch of tunings, but there's only one you need to care about. It's like the UTF-8 of tuning. It's "Equal temperament" with "Concert A".

"Concert A" means that a4 is exactly 440Hz.
"Equal temperament" means that every pair of adjacent notes (semi-tone) has the same ratio of frequencies.

Intervals

An interval is the distance between two notes. A semi-tone is the smallest interval. It consists of two adjacent notes. Lots of intervals have names, but you can also just say how many semi-tones they are.

Interval Names

  1. semi-tone, half-step, minor second
  2. full tone, major second
  3. minor third
  4. major third
  5. fourth, perfect fourth
  6. augmented fourth, diminished fifth, tritone
  7. fifth, perfect fifth
  8. minor sixth
  9. major sixth
  10. minor seventh
  11. major seventh
  12. octave
  13. minor ninth
  14. major ninth

There are more.

Chords

A chord is two or more notes sounded simultaneously. Chords usually have at least three notes. A chord with exactly three notes is called a "triad".

A chord consists of a root note and a quality. For example, "C major".

The root note specifies the lowest note in the chord in the canonical voicing.
The quality specifies the other notes in terms of their intervals from the root. For example, major chords are triads that contain root, major third, and fifth. So a "C major" triad consists of c, e, g.

Chord Qualities

Here are some common chord qualities and their definitions.

  • major - major third, fifth
  • minor - minor third, fifth
  • diminished - minor third, diminished fifth
  • minor seventh - minor third, fifth, minor seventh
  • dominant seventh (aka seventh) - major third, fifth, minor seventh
  • major seventh - major third, fifth, major seventh
  • suspsended 4 - fourth, fifth
  • suspsended 2 - major second, fifth
  • minor ninth - minor third, fifth, minor seventh, major ninth
  • major ninth - major third, fifth, major seventh, major ninth

There are many more. Some chords probably don't even have names.

Chord Inversions

You can remove the lowest note in a chord, and add it to the top in a higher octave.
This produces a chord "inversion". If you repeat the process, you'll get the original chord in a higher octave. All the inversions sound similar in a way.

Chord Voicings

Inversions aren't the only way of changing how you play a chord.
Chord qualities are listed above using canonical voicings. Inversions are types of voicing, but there are many more. The basic tools of voicing are omitting notes and moving notes to different octaves. I like to voice "c seventh" as b♭, e, g. Note the omitted root and inversion. Keen readers may note that these three notes also form an inversion of "e diminished". This is fine. Chords are often ambiguous in isolation. In context it may become more clear what they are. Context could be other parts or instruments at the same time. It could also be previous parts of the same song.

Scale

Like a chord, a scale has a root note. Unlike a chord, the notes in a scale are note meant to be played simultaneously.
I mean you could, but it would just sound like nonsense. (you can however, play chord notes individually as an "arpeggio") Scales are meant to be played in ascending or descending order.
"Joy to the world", the christmas song, starts with a descending major scale. Scales are usually more "dense" than chords.

There are about a bazillion different scales, but here are enough to get you started.

  • major scale - root, major second, major third, fourth, fifth, major sixth, major seventh, (octave)
  • minor scale - root, major second, minor third, fourth, fifth, minor sixth, minor seventh, (octave)
  • pentatonic scale - root, minor third, fourth, fifth, minor seventh, (octave)

(octave is parenthesized because it's the same note as the root)

The nth note in a scale is called the nth "degree" of that scale.

Key

A key consists of the same information as a scale, but it's used a little differently.
A key is like a pallette of tones. Once a key is established, your ear expects to hear tones from the key. In the context of a key, the root note of the key is the one that sounds most resolved.

Chromatic/diatonic

Tones that are in the key of a song are said to be "diatonic". Others are called "accidental".
It's not a joke, and they are (often) not really accidents. It's just called that. If a run of adjacent semi-tones is played, it will contain a lot of "accidentals". Such a run is called "chromatic". "Chromatic" is basically the opposite of "diatonic".

Chord progression

Just about all modern music is based on chord progressions. These are loops of chords that provide harmonic context. Here's a popular one, made out of diatonic chords in the key of C major.

C major, G major, A minor, F major

Transposition

Any time you play something, you can just shift every single note up or down by some interval, and it will sound very similar. In a fashion. That's called "tranposing". The progression given above can be transposed to D.

D major, A major, B minor, G major

Chord progression notation

Chord progressions are sometimes notated without reference to the key signature. Just to a floating root. It's up to the performer to play it in the key of their choosing. Roman numerals are used to indicate the degree of the root note. Uppercase means major. Lowercase means minor.

The above progressions are then both "I V vi IV". It's tough to overstate just how many pop songs use this. Here's a video on it. https://www.youtube.com/watch?v=5pidokakU4I They cheat a little, but they're basically correct.

Functional harmony

Functional harmony is a way of dividing diatonic triads in a key (e.g. I, ii, iii, IV, V, vi, vii dim) into three or so functional categories. "Functional" meaning "what is their purpose" or "what do they do".

I think there's probably a way of making a layered system of narrative arc and chord choice to generate semi-comprehensible random chord progressions. "Narrative arc" is just a thing I made up right now that is a list of "functions". And then chord choice picks particular chords to fulfill the function.

I need to brush up on exactly what this function stuff is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment