The Harp of New Albion’s Tuning for Logic

The Disquiet Junto is doing an alternate tunings prompt for week 0440 (very apropos!).

I’ve done several pieces before using Balinese slendro and pelog tuning, most notably Pemungkah, for which this site is named. I wanted to do something different this time, using Terry Riley’s tuning from The Harp of New Albion, using Logic Pro’s project tuning option.

The original version was a retuning of a Bosedorfer grand to a modified 5-limit tuning:

However, Logic’s tuning feature needs two things to use a tuning with it:

  • Logic’s  tuning needs to be based on C, not C#
  • The tuning has to be expressed as cents of detuning from the equal-tempered equivalent note.

This leads one to have to do quite a number of calculations to put this in a format that Logic will like.

If you’re impatient to have a template project that has the tuning done and ready to use, then skip down to “Don’t care, where are the files?”.

If you’re interested in the process of arriving at the final tuning offsets, follow along here to get an understanding of how to compute a new tuning. (Skip to “Don’t care” if you know this already and want to get a copy of the spreadsheet to play around with.)

Logic and alternate tunings

Let’s start with where we are in the Logic file when we open a new project. If you’re playing along at home, do the following:

  • Open a new Logic project. Go to Preferences and check that the Advanced Preferences are on; turn them on if not. (You can easily turn them back off again later, but you’ll need them to get the tuning settings).
  • Close the preferences, then go to File > Project Settings > Tuning… to see the tuning setup dialog.
  • There are two main sections to this dialog: the Pitch section, which tunes the base frequency of the project, and the Scale section, which lets you alter the scale.

We’re only interested in the Scale section; the tuning we’re going to build will still be based on A440. If you should want to adjust the base frequency, feel free; it’s completely independent of the Scale alterations, which are all based of proportions and relative distances between notes in the 12 steps between C and C.

You’ll notice that the “Equal Tempered” radio button is selected.  This is the default, and corresponds to the traditional 12-equal-steps to the octave equal temperament. There are no offsets from the standard tuning.

You can select the User radio button, which enables the display that shows you the amount each note is detuned from the standard; that will be zero for all notes (we’re still using the standard tuning).

If we want to use a user-defined tuning, we’ll have to figure out what those detuning values are before we can use this.

Enough history of tuning to be dangerous

Originally I had started to write an introduction to tunings here, but soon realized that I’d need to write so much we’d never get to the meat of the post. So I’m going to, for now, handwave most of the details and give you a little history to define the minimum you need to know to understand what we’re doing.

Pythagoras came up with the mathematical bases of consonance and dissonance around 500 BCE, finding that there are fundamental relationships between frequencies based on ratios. Generally speaking, the lower the numbers in the ratio, the more consonant the sound (he also named the concepts of consonance and dissonance, a busy guy!),

He also discovered that “stacking” fifths eventually bring you back to the original note. Almost. The twelfth stack, which should bring you back into consonance, is off by a tiny interval — the Pythagorean comma, Unfortunately this is a very dissonant interval. This almost-right recurrence is the basis for the Western twelve-tone scale.

But the math was really good, even if it wasn’t quite perfect, and it made it possible to start standardizing twelve-tone tunings. (If you go to Bali and visit different towns, you’ll find that the gamelans are tuned to slightly different scales, so an instrument from town A will sound completely different from one from town B — and they will sound badly out of tune when played together.) A standard way to construct a twelve-tone tuning meant that instrument builders could start experimenting with things like multiple pre-tuned fixed strings.

Having a standardized tuning was gonna be great! But, like any set of standards, people had different things that they wanted to sound good, and invented standards to meet those goals. One tuning might want the major third to be as consonant as possible, so it ended up with the fifth out of tune. Another would do its best to optimize the perfect fourth and perfect fifth, but then have an out-of-tune third. Others tried to spread out the bad notes as equally as possible, with most intervals sounding pretty good except for some “wolf” intervals that were badly off, causing some keys to sound really bad, even though others sounded good.

This wasn’t a sustainable situation; there needed to be a single standard that could be adopted by everyone to allow people to exchange music, etc. without it sounding radically different on different instruments.

Somewhere around the 1500s, equal temperament was invented, possibly in China, possibly in Belgium; the actual place and person inventing it is disputed. The idea, however, was to say, okay, every time we adjust things so that some intervals sound perfect, we end up stacking up dissonance elsewhere that sounds terrible. Let’s give up, sorry,  compromise, and space the twelve tones out exactly across the octave. Nothing will be perfect, but everything will be pretty good, and the ratios between all the notes the same distance apart will be identical: every fifth/fourth/third/etc. will be equally well (or badly) tuned, and people can play in any key and have it sound just as good. This grand compromise is the basis for contemporary Western music tuning.

(Alternate tuning advocates: I know, I know, Werkmeister III, etc. Beyond the scope of this essay, especially since this is really about “how do we deal with equal temperament because we’re stuck with it as a basis”, not “equal temperament is superior, why would you argue”.)

Dividing the interval into twelve equal parts means that each half-step  is the same size: exactly the twelfth root of 2 bigger than the half-step below. So to get from A 440 to the equal-tempered A#, we just multiply the frequency by the twelfth root of 2; to get to A flat, we divide by the same number. Repeating the division or multiplication twelve times gets you to the A an octave up or an octave down. The numbers themselves are a little messy with all those decimals, but it’s fairly easy to calculate.

But this means that equal-tempered tunings and low-number-ratio tunings are inherently incommensurable: the twelfth root of two is an irrational number. How, then, are we going to make Logic play nice?

Ratios, twelfth roots, and cents

Western music is willing to grudgingly admit that people don’t always tune to the equal-tempered scale, and that there needs to be a way to talk about these alternate tunings relative to equal temperament. So Western musicologists invented the cent. A cent is 1/100 of a half step, so 1200 cents == an octave. Cents are smaller than the minimum distinguishable interval (the least difference in frequency our ears can detect), so we can define alternate tunings as equal temperament tunings plus or minus some number of cents per note — again, we’ll handwave scales that don’t have 12 notes, or that have more, for the purposes of this article.

The Terry Riley scale we have is in ratios, but there are only 12 notes, so it should be possible to tweak the notes in an equal-tempered scale to get them close enough to the Riley scale that we can’t hear the difference,

This means we’ll have to know all the following:

  • What the base frequency is for our tuning (easy: A 440).
  • The twelfth root of 2. Relatively easy to calculate a good approximation.
  •  What the frequencies of the notes are in the equal-tempered scale based on A440 (we use the twelfth root to multiply and divide as needed to get the frequencies in the E. T. scale)
  • The ratios of note frequencies to the base note frequency for the scale we want to emulate, so we can calculate the frequencies that we actually want (we have our table for that).
  • The formula to calculate the number of cents between two notes so we know how far to detune, say, G, to get it to match the Riley scale’s G.

The only really difficult one here is that last formula, but we can work it out from first principles to get that we want to multiply 1200 (the number of cents in an octave) by the log base 2 of the target frequency divided by the base frequency.

Why log base 2? Well, it’s a matter of proportions again. The twelfth root of 2 is 1/12, log 2, and if we multiply that by 1200, we get 100, the number of cents per half step. We need to calculate the ratio of the difference between the frequency of the target note and that of the the base note, and convert this into a fractional interval that can be expressed in cents.

So the ratio of the frequencies is Ft/Fb; to convert that to log base 2, we take the log of the ratio in whatever base is handy (natural log, base e, is fine) and then divide by the natural log of 2 to convert to log base 2. Now as we saw before, log base 2 of 1/12 is a half step, so log base 2 of this arbitrary ratio is some fraction of a step, which we can express as some number of cents by multiplying by 1200 (the number of cents in an octave).

Now we have the offset in cents (and fractional cents) between the equal tempered note and the frequency we want to have play when that note is struck — and that’s exactly what we need to enter on the Logic tuning dialog to get our tuning to work!

The only thing we have to note is that the Riley tuning runs from C# to C#, so we need to calculate the equal-tempered notes for that octave surrounding A 440.

Once we have that, the Riley scale is defined as a set of ratios above the C# keynote, so we calculate the value of those ratios and multiply the key note’s (C#) frequency by the decimal value of the ratio, giving us the target frequencies for each note in the scale.

We now use the 1200 * (log(Ft/Fb)/log 2) identity to calculate the number of cents different for each note, and we can add these to the Logic file to get the final retuned project.

Don’t care, where are the files?

If all you want to do is play around with the scale, download the sample Riley tuning test. There’s an electric piano patch tuned to Riley scale. Try playing intervals in various modes and scales, and note that some intervals are much more consonant, and some are very much not so.

If you are interested in a spreadsheet that calculates all this, take a look at this Google sheet.

Enjoy playing with it, and have the appropriate amount of fun.

Comments

Leave a Reply