1--- 2title: Understanding Chord Voicings 3layout: ../../layouts/MainLayout.astro 4--- 5 6import { MiniRepl } from '../../docs/MiniRepl'; 7import { PitchSlider } from '../../components/PitchSlider'; 8import Box from '@components/Box.astro'; 9 10# Understanding Chords and Voicings 11 12Let's dig deeper into how chords and voicings work in strudel. 13I'll try to keep theory jargon to a minimum, so hopefully this is approachable for anyone interested. 14 15## What is a chord 16 17Playing more than one note at a time is generally called a `chord`. Here's an example: 18 19<MiniRepl client:visible tune={`note("<[c3,eb3,g3] [f3,a3,c4]>").room(.5)`} /> 20 21Here's the same with midi numbers: 22 23<MiniRepl client:visible tune={`note("<[48,51,55] [53,57,60]>").room(.5)`} /> 24 25Here, we have two 3-note chords played in a loop. 26You could already stop here and write chords in this style, which is totally fine and gives you control over individual notes. 27One downside is that it can be difficult to find good sounding chords and maybe you're yearning for a way to organize chords in some other way. 28 29## Labeling Chords 30 31Chords are typically given different labels depending on the relationship of the notes within. 32In the number example above, we have `48,51,55` and `53,57,60`. 33 34To analyze the relationship of those notes, they are typically compared to some `root`, which is often the lowest note. 35In our case, the `roots` would be `48` (= `c3`) and `53` (= `f3`). 36We can express the same chords relative to those `roots` like this: 37 38<MiniRepl client:visible tune={`note("<[0,3,7] [0,4,7]>".add("<48 53>")).room(.5)`} /> 39 40Now within each chord, each number represents the distance from the root. 41A distance between pitches is typically called `interval`, but let's stick to distance for now. 42 43Now we can see that our 2 chords are actually quite similar, as the only difference is the middle note (and the root of course). 44They are part of a group of chords called `triads` which are chords with 3 notes. 45 46### Triads 47 48These 4 shapes are the most common types of `triads` you will encounter: 49 50| shape | label | 51| ----- | ---------- | 52| 0,4,7 | major | 53| 0,3,7 | minor | 54| 0,3,6 | diminished | 55| 0,4,8 | augmented | 56 57Here they are in succession: 58 59<MiniRepl 60 client:visible 61 tune={`note("<[0,4,7] [0,3,7] [0,3,6] [0,4,8]>".add("60")) 62.room(.5)._pitchwheel()`} 63/> 64 65Many types of music often only use minor and major chords, so we already have the knowledge to accompany songs. Here's one: 66 67<MiniRepl 68 client:visible 69 tune={` 70note(\`< 71[0,3,7] [0,4,7] [0,4,7] [0,4,7] 72[0,3,7] [0,4,7] [0,3,7] [0,4,7] 73>\`.add(\`< 74a c d f 75a e a e 76>\`)).room(.5)`} 77/> 78 79These are the chords for "The House of the Rising Sun" by The Animals. 80So far, it doesn't sound too exciting, but at least it's recognizable. 81 82## Voicings 83 84A `voicing` is one of many ways a certain chord shape can be arranged. 85The term comes from choral music, where chords can be sung in different ways by assigning different notes to each voice. 86For example we could add 12 semitones to one or more notes in the chord: 87 88<MiniRepl 89 client:visible 90 tune={`note("<[0,3,7] [12,3,7] [12,15,7] [12,15,19]>".add("48")) 91.room(.5)`} 92/> 93 94Notes that are 12 semitone steps apart (= 1 `octave`) are considered to be equal in a harmonic sense, which is why they get the same note letter. 95Here's the same example with note letters: 96 97<MiniRepl 98 client:visible 99 tune={`note("<[c3,eb3,g3] [c4,eb3,g3] [c4,eb4,g3] [c4,eb4,g4]>") 100.room(.5)`} 101/> 102 103These types of voicings are also called `inversions`. There are many other ways we could `voice` this minor chord: 104 105<MiniRepl 106 client:visible 107 tune={`note("<[0,3,7,12] [0,15,24] [0,3,12]>".add("48")) 108.room(.5)`} 109/> 110 111Here we are changing the flavour of the chord slightly by 112 1131. doubling notes 12 steps higher, 1142. using very wide distances 1153. omitting notes 116 117## Voice Leading 118 119When we want to meaningfully connect chords in a sequence, the chosen voicings affect the way each chord transitions to the next. 120Let's revisit "The House of the Rising Sun", this time using our newly acquired voicing techniques: 121 122<MiniRepl 123 client:visible 124 tune={`note(\`< 125[0,3,7] [7,12,16] [0,7,16] [4,7,12] 126[0,3,7] [4,7,12] [0,3,7] [4,7,12] 127>\`.add(\`< 128a c d f 129a e a e 130>\`)).room(.5)`} 131 punchcard 132/> 133 134These voicings make the chords sound more connected and less jumpy, compared to the earlier version, which didn't focus on voicing. 135The way chords interact is also called `voice leading`, reminiscent of how an 136individual choir voice would move through a sequence of chords. 137 138For example, try singing the top voice in the above example. Then try the same 139on the example not focusing on voice leading. Which one's easier? 140 141Naturally, there are many ways a progression of chords could be voiced and there is no definitive right or wrong. 142 143## Chord Symbols 144 145Musicians playing chord-based music often use a `lead sheet`, which is a simplified notation for a piece of music. 146These sheets condense the essential elements, such as chords, into symbols that make the music easy to read and follow. 147For example, a lead sheet for "The House of the Rising Sun" might include chords written like this: 148 149``` 150Am | C | D | F 151Am | E | Am | E 152``` 153 154Here, each symbol consists of the `root` of the chord and optionally an `m` to signal it's a minor chord (just the root note means it's major). 155We could mirror that notation in strudel using the `pick` function: 156 157<MiniRepl 158 client:visible 159 tune={`"<Am C D F Am E Am E>" 160 .pick({ 161 Am: "57,60,64", 162 C: "55,60,64", 163 D: "50,57,66", 164 F: "57,60,65", 165 E: "56,59,64", 166 }) 167 .note().room(.5)`} 168 punchcard 169/> 170 171## The voicing function 172 173Coming up with good sounding voicings that connect well can be a difficult and time consuming process. 174The `chord` and `voicing` functions can be used to automate that: 175 176<MiniRepl client:visible tune={`chord("<Am C D F Am E Am E>").voicing().room(.5)`} punchcard /> 177 178Here we're also using chord symbols but the voicings will be automatically generated with smooth `voice leading`, minimizing jumps. 179It is inspired by the way a piano or guitar player would pick chords to accompany a song. 180 181## Voicing Dictionaries 182 183The voicing function internally uses so called `voicing dictionaries`, which can also be customized: 184 185<MiniRepl 186 client:visible 187 tune={`addVoicings('house', { 188 '': ['7 12 16', '0 7 16', '4 7 12'], 189 'm': ['0 3 7'] 190}) 191chord("<Am C D F Am E Am E>") 192 .dict('house').anchor(66) 193 .voicing().room(.5)`} 194 punchcard 195/> 196 197In a `voicing dictionary`, each chord symbol is assigned one or more voicings. 198The `voicing` function then picks the voicing that is closest to the `anchor` (defaults to `c5`). 199 200The handy thing about this approach is that a `voicing dictionary` can be used to play any chord progression with automated voice leading! 201 202## The default dictionary 203 204When using the default dictionary, you can use these chord symbols: 205 206``` 2072 5 6 7 9 11 13 69 add9 208o h sus ^ - ^7 -7 7sus 209h7 o7 ^9 ^13 ^7#11 ^9#11 210^7#5 -6 -69 -^7 -^9 -9 211-add9 -11 -7b5 h9 -b6 -#5 2127b9 7#9 7#11 7b5 7#5 9#11 2139b5 9#5 7b13 7#9#5 7#9b5 2147#9#11 7b9#11 7b9b5 7b9#5 2157b9#9 7b9b13 7alt 13#11 21613b9 13#9 7b9sus 7susadd3 2179sus 13sus 7b13sus 218aug M m M7 m7 M9 M13 219M7#11 M9#11 M7#5 m6 m69 220m^7 -M7 m^9 -M9 m9 madd9 221m11 m7b5 mb6 m#5 mM7 mM9 222``` 223 224The available chords and the format is very much inspired by [ireal pro chords](https://technimo.helpshift.com/hc/en/3-ireal-pro/faq/88-chord-symbols-used-in-ireal-pro/). 225Some symbols are synonymous: 226 227- "-" is the same as "m", for example C-7 = Cm7 228- "^" is the same as "M", for example C^7 = CM7 229- "+" is the same as "aug" 230 231You can decide which ones you prefer. There is no international standard for these symbols. 232To get a full chord, the symbols have to be prefixed with a root pitch, e.g. D7#11 is the 7#11 chord relative to the pitch D. 233 234Here are all possible chords with root C: 235 236<MiniRepl 237 client:visible 238 tune={`chord(\`< 239C2 C5 C6 C7 C9 C11 C13 C69 240Cadd9 Co Ch Csus C^ C- C^7 241C-7 C7sus Ch7 Co7 C^9 C^13 242C^7#11 C^9#11 C^7#5 C-6 C-69 243C-^7 C-^9 C-9 C-add9 C-11 244C-7b5 Ch9 C-b6 C-#5 C7b9 245C7#9 C7#11 C7b5 C7#5 C9#11 246C9b5 C9#5 C7b13 C7#9#5 C7#9b5 247C7#9#11 C7b9#11 C7b9b5 C7b9#5 248C7b9#9 C7b9b13 C7alt C13#11 249C13b9 C13#9 C7b9sus C7susadd3 250C9sus C13sus C7b13sus C Caug 251CM Cm CM7 Cm7 CM9 CM13 CM7#11 252CM9#11 CM7#5 Cm6 Cm69 Cm^7 253C-M7 Cm^9 C-M9 Cm9 Cmadd9 254Cm11 Cm7b5 Cmb6 Cm#5 255>\`).voicing().room(.5)`} 256 punchcard 257/> 258 259Note that the default dictionary contains multiple ways (= `voicings`) to play each chord symbol. 260By default, the `voicing` function tries to minimize jumps. 261You can alter the picked voicings in various ways, which are now explained in further detail: 262 263## anchor 264 265The `anchor` is a note that is used to align the voicings to: 266 267<MiniRepl client:visible tune={`anchor("<c4 g4 c5 g5>").chord("C").voicing().room(.5)`} punchcard /> 268 269By default, the anchor is the highest possible note the voicing can contain. 270When deciding which voicing of the dictionary to pick for a certain chord, the voicing with a top note closest to the anchor wins. 271 272Note that the anchors in the above example match up with the top notes in the pianoroll. 273Like `note`, anchor accepts either midi numbers or note names. 274 275## mode 276 277With `mode`, you can change the way the voicing relates to the `anchor`: 278 279<MiniRepl 280 client:visible 281 tune={`mode("<below above duck root>").chord("C").anchor("c5").voicing().room(.5)`} 282 punchcard 283/> 284 285The modes are: 286 287- `below`: the top note of the voicing is lower than or equal to the anchor (default) 288- `above`: the bottom note of the voicing is higher than or equal to the anchor 289- `duck`: the top note of the voicing is lower than the anchor 290- `root`: the bottom note of the voicing is always the lowest root note higher than or equal to the anchor 291 292- `oldabove` : old (buggy) behavior of above, kept for legacy reasons 293- `oldroot` : old (buggy) behavior of root, kept for legacy reasons 294 295The `anchor` can also be set from within the `mode` function: 296 297<MiniRepl client:visible tune={`mode("<below above duck root>:c5").chord("C").voicing().room(.5)`} punchcard /> 298 299## n 300 301The `n` control can be used with `voicing` to select individual notes: 302 303<MiniRepl 304 client:visible 305 tune={`n("0 3 1 2").chord("<C <Fm Db>>").voicing() 306.clip("4 3 2 1").room(.5)`} 307 punchcard 308/> 309 310## Example 311 312Here's an example of a Jazz Blues in F: 313 314<MiniRepl 315 client:visible 316 tune={`let chords = chord(\`< 317F7 Bb7 F7 [Cm7 F7] 318Bb7 Bo F7 [Am7 D7] 319Gm7 C7 [F7 D7] [Gm7 C7] 320>\`) 321$: n("7 8 [10 9] 8").set(chords).voicing().dec(.2) 322$: chords.struct("- x - x").voicing().room(.5) 323$: n("0 - 1 -").set(chords).mode("root:g2").voicing() 324`} 325 punchcard 326/> 327 328The chords are reused for melody, chords and bassline of the tune.