Stressed note coding method, 01/19/00, simplified 03/14/00 In an endeavor to come up with a coding system that will lead to a preliminary method of screening for tune and near variants, I put together a few things from a lot of sources. The aim is to make a code for the beginning of the tune that will be as independent of the octave, keynote, mode, indicated timing, and title as possible. For the timing we use stressed notes, not by fixed position in the indicated timing. First we deal with keys and modes in such a way that we can give a rough description of the structure of the tune, and through it dispense with any normal sharps and flats in the code of the tune, and second proceed to find a way to give the code in two separate strings such that the first string is notes alone, and the second qualifier string contains the octave and sharp/normal/flat information. Coding is by keynote-mode/ stressed notes in the tune, all coded in one sometimes messy lump as follows: Xynvkojz* and () Take heart, everything after the y disappears for heptatonic normal mode tunes. X is the keynote, with sometimes b added for flat and # for sharp. (Bb and F# are the most common) [See at end the qualifier for accidental naturals.] y is the mode code as in SITM, but with lower case letter as: f-lydian, c-ionian, g-mixolydian, d-dorian, a-aeolioan, e- phrygian (b- for locrian if ever found). If no n or v then the scale has seven notes, and then we are done coding except for a possible o indicating for a cyclic tune that doesn't end on the keynote, and a possible trailing. The number following the o is the note the tune actually ends on. (Up from keynote = 1) (z) means that there are more than one way of mode coding the tune, but I have not given all of the alternatives. If there is an n then the mode y is minus the notes in n. (n) means the number(s) in the parenthesis isn't completedly missing, but it's a weak note, not counted in determining the number of notes in the scale. If there is a v then notes k following it are variable * means that there's more going on and see the comments field This key-mode-notes# designation can get messy, but it seems to be a compact way of providing a reasonably large amount of information unambiguously. It is simple and straightforward for for all normal 7 note modes, as we will just have Xy as the complete code then, and Xc is just a normal major mode tune, and Ya is a normal minor mode one. The table below is for translation of SITM's hexatonic notation Xyh(exatonic)n, to the left of the back slant (\) in each column, that here, and that of Bronson from Huntington and Hermann's 'Sam Henry's Songs of the People', p. 618. (I haven't managed to get Bronson's original). Bronson's scheme uses abbreviations of the 'Greek' mode names rather than the letternote for mode=keynote names in the present system and that in SITM. Xh7\yn |Xh6\yn |Xh5\yn |Xh4\yn |Xh3\yn |Xh2\yn |Xh1\yn Ch7\c7 =i/m Ch6\c6 Ch4\c4= l/i Ch3\c3 \c2 ------ Dh7\d6 =d/a Dh4\d3= m/d Dh3\d2 ------- Dh1\d7 Eh7\e5 =p/lc Eh4\e2= a/p ------ \e7 Eh1\ Fh7\f4 =l/i ------ Fh3\ Fh1\ Gh7\g3 =m/d Gh6\g2 ------ Gh4\g7= i/m Gh3\g6 Gh1\g4 Ah7\a2 =a/p ------ \a7 Ah4\a6= d/a Ah3\a5 \a4 Ah1\a3 Note that normal pentatonic tunes have three ways of coding for the same pentatonic mode. Here is a table for conversion of SITM's Xpnm notation to Bronson's and that here: pi1 = Fp37= f47; Cp47= c47, Gp14= g47 pi2 = Cp37= c37; Gp47= g37; Dp14= d37 pi3 = Gp37= g36; Dp47= d36; Ap14= a36 pi4 = Dp37= d26; Ap47= a26; Ep14= e26 pi5 = Ap37= a25; Ep47= e25; Bp14= b25 |n|: The first number in | |'s is the number of the tune in SITM, and is from the source cited by code, the source code being in the IRTITLE3 file. n is 0 if the tune isn't given in SITM. |m|=|n| means tune m is for all practical purposes identical to tune n, and the coding is not repeated for |m|. The last number, |k|, is an earlier, and usually the earliest version of the tune to be found, but not always, and my ordering of tune in the title file is sometimes a corrected chronoligical ordering so SITM's numbers are not always bigger after smaller. If indicated timing isn't correct for stressed note coding, the actual number of stresses per measure will be given in parentheses, e.g., "Dusty Miller" 3/2, 3/4 or 6/4 time has 3 stressed note per measure rather than the usual 1 for 3/2 and 3/4 and 2 for 4/4 (or 6/8). E.g., 3/4 (3), DA-da, DA-da, DA-da each measure rather than DA-da-da each measure. "Hopton House", |1510|+ is given as 2/2, but is really 8/8 and I've coded with 4 stressed notes per measure. Bertrand Bronson had a coded index for the tunes in 'The Traditional Tunes of the Child Ballads', and examples are shown from IBM punched cards in the article 'Toward the Comparative Analysis of British-American Folk-Tunes' in 'The Ballad As Song', 1969. I don't know if his codes were ever published, or entered into a single file. Huntington and Herrmann have used a slight modification to Bronson's system in 'Sam Henry's Songs of the People', pp 619-30, 1990. Notes in the code are counted up from keynote = 1 through the octave ending at 7. L is the octave lower and F is two octaves lower. H is the next octave up and T is two octaves up. 0 is a rest or no note. In addition sharps, #, and flats, b, are added to the code for accidentals. What I propose here is a two digit code for each stressed note, the first digit, m, 0-7, with the same significance as previously, and use a second digit, n, to specify flat/normal/sharp and the octave. In principle the second digit is a hexidecimal one, but we will see that it's probably not necessary to use hex A-E (= decimal 10-15). The basic numerical code is then just the odd numbered digits of the code. Here's a table for the new code. norm sharp flat n= 0 1 2 base octave 0 usually blank or no space n= 3 4 5 octave down -1 L n= 6 7 9 octave up +1 H n= 9 A B 2 oct. down -2 F n= C D E 2 oct. up +2 T Rule 1A: This looks awkward, but one quickly learns that n = 0, 3, 6, or 9 suffices to cover about 95% of all tunes, and having determined what number to use for the octave, add 1 if note is sharp and 2 if it is flat. In the very few case where we would need a number larger than 9, I've scaled to differant octave and added a note to the key-mode that it should be octave up or down. Rule 1B (Same as 1A, just different form) : Base octave 0 (normal), 1(sharp), 2(flat) add 3 for 1 octave down, add 6 for 1 octave up, add 9 for 2 octaves down, add C=12 for 2 octaves up (if ever needed). The table is all one needs to code tunes. For the more mathematically inclined (for computer programers); With k = -1 for flat, 0 for normal, +1 for sharp k = -1 + (n+1) modulo (3) k is then the number of semitones off of normal as defined by the key signature, For octave recognition- 3 steps, Step 1: l = int(n/3) -- n -- l -- octave -- 9 A B 3 -2 (old F) 3 4 5 1 -1 (old L) 0 1 2 0 0 (old blank) 6 7 8 2 +1 (old H) C D E 4 +2 (old T) Step 2: determine if l is odd or even Step 3: With k the number of the octave: If l is even divide by 2, k = l/2; If l is odd add 1, change sign, then divide by 2, k = -(l+1)/2. It simplies things to display the purely numerical notes in the first 8 digits and the flat/normal/sharp: octave qualifiers in the 2nd 8 digits. Example; note 2 octaves below key (F) NEW OLD 16535275 03333399 | 16L5L3L 5L2L7F5F Dublin Castle, #116 There are still problems of how to best denote the number of notes in the scale of a tune, and what to call ones that are't normal heptatonic, hexatonic, or pentatonic. [Solved with new numerical coding scheme below. We don't need names.] Important note: In the qualifier code the 0 means normal for the mode as defined by the key signature. For accidental naturals we have to modify conventional notation. If the key signature says B is flat, then the natural sign on a B means one semitone up, so in the qualifier code we insert a sharp (+1), thus, numerically Bb sharped is B natural. Similarly if key signature indicates F is sharp but the tune contains an F natural we flat the F# to get the natural by adding a 2 to the relevent position of the qualifier code. (Mathematically the qualifier code is incremented by 1 then taken modulo 3. Then 1 is subtracted from that so we get a semitone change of - 1 for flat, 0 for normal and 1 for sharp, relative to the normal indicated by the key signature. The modulo 3 operation erases any octave offset, which is taken care of in a different step.) Messy details: Some 3/4 (3 beats per measure), 9/4 and 9/8 tunes are usually coded for two measures, so we have only six notes in the code rather than the usual 8. This is awkward when 9/8 and 6/8 versions of the same tune, so I take all codes as 8 note ones. This is a bit more work, but gives more information on which to decide if two tunes are verrsions of the same one. How much of a tune should we code? Look at "The Basket of Oysters" in the Irish tune index here. A typical version has one strain of "Greensleeves" and another of the "Blarney Castle/ Johnny MaGill/ Black Rogue" tune. Do we realy need to code all strains of a given tune? There are many versions of "Lastrumponey" in the Irish tune index, but finding a common strain in different versions is not easy.