Chant programs

Analysis of Medieval Chant

This package is designed for the automated analysis of medieval chants. It consists of two modules: data entry and chant analysis . The data entry facilities allow creation of a chant database. The chant analysis routines provided search for similar strings of neumes, either comparing a chant with a reference string or comparing two different chants, or the phrases of chant(s).

The package as distributed is set up for St Gall notation. If you wish to use another notation, please read the neumes.dat section and the similarities section.

Data Entry routines

Analysis routines


Chant data entry

The data entry routines are accessed from the Start menu as the program Chant, or by icon on the desktop.

File menu

Chant menu

Syllable menu

Neume menu

Note menu

Window Menu

Help Menu

The menus are not always required, since the buttons on the screen provide alternative ways to perform many functions. But at the start you will need to Open an existing chant file using the File Menu, or click Add on the Chant menu to enter a new chant.

If there is a current chant the name details will be displayed at the top of the screen. If there are other chants also loaded, another can be selected as the current chant by using the arrow keys. These keys will advance or go back by 1 chant or to the last or first chant. If you are adding a chant, type in the Full name and Short name for the chant.

The two display buttons will display the current chant, either just the text and neumes or with note details as well. The button marked "Enter Notes" allows you to enter pitch details for notes, after you have entered the notes as described below.

Navigation within the chant is similar, but parts of several syllables and neumes will be displayed. The current syllable, neume and note have sequence numbers in a different colour. Clicking on a sequence number will change which one is current. There is a fast forward and back for syllables which takes you to the beginning of the next or previous verse.

Entering a syllable

For a syllable, enter the text associated with it: if the text begins with a capital letter the Verse flag will be set once you move from the text field. If this is not appropriate, move to the Verse field and click to unset the flag. It will not reset once you move away again. The phrase flag will be set automatically at the beginning of a verse. Set it by clicking for other syllables which begin phrases.

Entering a neume

There are several ways to enter a neume:

  1. Double-click on the type you want
  2. Select the type you want (by a single click) and click on the sequence number field above (marked "Add").
  3. Click on the appropriate neume from those displayed on the right of the screen.
  4. Use the copy neumes button.
The default note sequence will be created. Add extra details as required.

Entering a note

Select the relative position and the length of the note as required.

Display Neumes

This option displays the current chant so you can check it roughly, or copy neumes from it.

Display Notes

This option displays the current chant with details of the notes so you can check it. You cannot copy neumes from this one.

Enter Notes

This option displays the pitch entry screen, which allows you to enter details of the pitch.

Copy Neumes

This option will copy any highlighted neumes from the display neumes screen into the current chant after the current syllable. Note details and extras are copied exactly.

A sample display screen with some neumes highlighted:

and a sample note display


Data Entry File menu

File Menu

The file menu has six options
Open | Displays a dialog box for you to specify the file which contains the chants you wish to edit or add to.
Save | Displays a dialog box for you to specify the name of the file to save the chants in. If you read in some chants then the name of that file will be the default.
Print Neumes | Produces a print of the current chant, showing neumes and text only.
Print Notes | Produces a print the current chant, showing text, neumes and note details.
Print Setup | Allows you to change details of the printer you want to use.
Exit | To end the program. You will be asked whether you want to save the chants first. This is not an intelligent prompt: say no when you are confident you have saved all you want to.


Data Entry Chant menu

Chant Menu

The chant menu has the following options
Find.. | Displays a dialog box for you to enter the short name of the chant you want.
Add | Initialises a new chant
Delete | Removes the current chant from memory completely


Data Entry Syllable menu

Syllable Menu

This menu has three options:
Add | Adds a syllable at the end: equivalent to clicking Forward when there are no more to be displayed, and then on Add (before or after entering the syllable text).
Insert before | Creates a syllable in front of the currently highlighted one
Delete | Removes the currently highlighted syllable

Highlighted syllables are shown by the number of the syllable being in a different colour.


Data Entry Neume menu

Neume menu

This menu has three options:
Add | Adds a new neume at the end . Equivalent to clicking on Forward when the final neume is displayed and then clicking on the Add button or double-clicking on a neume in the list.
Insert before | Inserts a neume in front of the currently highlighted one.
Delete | Deletes the currently highlighted neume.

When a neume is added, and the neume name selected, a default set of notes is created corresponding to this neume. The flags Liquescent and Quilisma can be set on to indicate that this neume is liquescent or has a quilisma. Other details of the neume (e.g. ,whether is is long, or partially long or has an episema) can be added via the Details screen.


Data Entry Note menu

Note Menu

The note menu has three options:
Add | Adds a new note after the last note for this neume. Equivalent to using Forward after the last note and the Add button.
Insert before | Inserts a note in front of the currently highlighted one.
Delete | Deletes the currently highlighted note.

Notes are described by their position relative to the previous note and their length.


Chant help

Help Menu

This option selects the help for the system.


Data Entry: Neume Details

Neume Details Screen

This screen allows entry of all the information about the neume apart from its name, and whether or not it is liquescent or has a quilisma.

Two entries can be made on this form, although either can be omitted (when the default values will be used). The left side is for length information, the right side for pitch information.

The top left part is for entry of the most frequent length options. It contains a blank, then the options "c", "t", "ep" and "long" followed by some entries designed specifically for each different neume. Simply select an option by clicking. The first five options apply to all the notes in the neume: use the middle part of the screen to apply different options to each note. Simply If the particular combination you need is not shown, the middle part of the left screen allows entry of one option for each note (or each expected note). Select some combination of c, t, epi and long, one for each note. If this does not cover the particular case you require, free text can be entered in the Other Length box. Text entered here will be stored but not used to update the notes. Information entered in the top two parts will be used to adjust the length of the notes where appropriate.

The rules used are:

  1. blank: note(s) are normal length
  2. c: note(s) are short
  3. t, epi, long: note(s) are long
  4. neume specific details: as defined in the file neumes.dat
The top right part allows entry of some pitch information: Simply select a letter for each interval for which one applies. If this does not cover your needs, use the Other Interval box to enter free text. Again, entries in the top part will cause the note relative positions to be adjusted where appropriate, but free text entries will not.

The rules for this part are:

  1. a: relative position +
  2. x: note is long
  3. e, eq: relative position is equal
  4. i, io, iu: relative position is -
  5. s: relative position is +
  6. iv: relative position is --
  7. m: if relative position is +, is is made .5+, otherwise it is made .5-
When all necessary information has been entered, click OK. To exit without updating anything click Cancel,

The changes only apply the first time you enter the details or if the details are changed from those displayed. So if you don't like the result of the option you can adjust the note values as you wish, then leave the details screen unchanged..


Data entry: neumes.dat file

neumes.dat file

The data stored on this file controls the processing of the different neumes: this can be altered by editing in Notepad or some similar text file editor. There are (in the standard installation) two copies of this file: one for the data entry and one for the analysis program: they need to be kept the same. The number of neumes also needs to match the parameter table. The file as distributed is set up for StGall notation and will need altering for other types. (The programs are set up to read a file called "neumes.dat" at the start: if this does not exist you will be prompted to select a file to use. Thus renaming the "neumes.dat" file as something else leaves which file is loaded up to the user each time.)

The first line of the file contains the number of neume types and the name of the font (in double quotes).

The remainder of the file is a group of lines for each neume. There may be only one, as for apostropha.

The first line of the group contains the name of the neume (in double quotes) and then the number of detail lines which follow for this neume, then the number of notes in the group. Then there is a sequence of numbers which connect the various neumes to the corresponding font character. This begins with the code for a liquescent version of this neume, then that for a quilisma with this neume, then that for basic neume. The next four numbers are for the neume with c, t, or an episema or a long version of the neume. Then there is one entry for each of the detail lines below. Finally the line contains the relative position string for the notes in this neume.

The detail lines contain a text string followed by a new relative position string for the notes of the neume as modified by this text string.

The defaults currently are:

    Neume name |  | number of notes | relative positions string | Detail number | Detail text | Detail action
apostropha | A | 1 | ? |  |  |
climacus | B | 3 | ? - - | 1 | c1 | make first note short
 |  |  |  | 2 | t1 | make first note long
 |  |  |  | 3 | ep1 | make first note long
 |  |  |  | 4 | l3 | make third note long
 |  |  |  | 5 | l23 | make second and third notes long
 |  |  |  | 6 | big | leave notes unchanged (simply records the shape of the neume)
climacus resupinus | C | 4 | ? - - + | 1 | c1 | make first note short
 |  |  |  | 2 | t1 | make first note long
 |  |  |  | 3 | ep1 | make first note long
 |  |  |  | 4 | l3 | make third note long
 |  |  |  | 5 | l23 | make second and third notes long
 |  |  |  | 6 | big | leave notes unchanged (simply records the shape of the neume)
clivis | D | 2 | ? - | 1 | t+ep | make both notes long
 |  |  |  | 2 | ep2v | make second note long
 |  |  |  | 3 | ep2h | make second note long
clivis + pressus minor | E | 4 | ? - ? - | 1 | t+ep | make first two notes long
 |  |  |  | 2 | ep2v | make second note long
 |  |  |  | 3 | ep2h | make second note long
gravis | F | 1 | - |  |  |
oriscus | G | 1 | ? |  |  |
pes | H | 2 | ? + | 1 | t2 | make second note long
 |  |  |  | 2 | ep2 | make second note long
 |  |  |  | 3 | diag | make both notes long
pes combipunctis | I | 6 | ? + + + - - |  |  |
pes quassus | J | 2 | ? + |  |  |
pes stratus | K | 3 | ? + = |  |  |
pes subbipunctis | L | 4 | ? + - - | 1 | c12 | make first two notes short
 |  |  |  | 2 | t2 | make second note long
 |  |  |  | 3 | t12 | make first two notes long
 |  |  |  | 4 | l12 | make first two notes long
 |  |  |  | 5 | l2 | make second note long
 |  |  |  | 6 | diag | make first two notes long
porrectus | M | 3 | ? - + | 1 | ep3 | make third note long
porrectus flexus | N | 4 | ? - + - | 1 | ep34 | make third and fourth notes long
 |  |  |  | 2 | l34 | make third and fourth notes long
 |  |  |  | 3 | clong | make all four notes short
porrectus subbipunctis | O | 5 | ? - + - - |  |  |
pressus maior | P | 3 | ? = - | 1 | c2 | make second note short
 |  |  |  | 2 | t2 | make second note long
pressus minor | Q | 2 | ? - | 1 | joined | no change to notes
punctum | R | 1 | ? |  |  |
quilisma | S | 1 | + |  |  |
salicus | T | 3 | ? + + |  |  |
scandicus | U | 3 | ? + + | 1 | epx3 | make all three notes long
 |  |  |  | 2 | l12ep3 | make all three notes long
scandicus flexus | V | 4 | ? + + - | 1 | c34 | make third and fourth notes short
 |  |  |  | 2 | t34 | make third and fourth notes long
 |  |  |  | 3 | ep34 | make third and fourth notes long
 |  |  |  | 4 | ept34 | make third and fourth notes long
 |  |  |  | 5 | ep4v | make fourth note long
 |  |  |  | 6 | ep4h | make fourth note long
scandicus flexus resupinus | W | 5 | ? + + - + | 1 | ep5 | make fifth note long
torculus | X | 3 | ? + - | 1 | 3down | no change
 |  |  |  | 2 | ep23noc1 | make first note short and second and third long
 |  |  |  | 3 | c1ep23 | make first note short and second and third notes long
 |  |  |  | 4 | t23noc1 | make first note short and second and third notes long
 |  |  |  | 5 | c1t23 | make first note short and second and third notes long
 |  |  |  | 6 | c1t23ep23 | make first note short and second and third notes long
 |  |  |  | 7 | t23ep23noc1 | make first note short and second and third note long
 |  |  |  | 8 | l3 | make third note long
 |  |  |  | 9 | ep3v | make third note long
 |  |  |  | 10 | ep3h | make third note long
 |  |  |  | 11 | stretched | make first note short and second and third notes long
torculus resupinus | Y | 4 | ? + - + | 1 | t234noc1 | make first note short and second, third and fourth notes long
 |  |  |  | 2 | ep234noc1 | make first note short and second, third and fourth notes long
 |  |  |  | 3 | l234noc1 | make first note short and second, third and fourth notes long
 |  |  |  | 4 | ep4 | make fourth note long
torculus resupinus flexus | Z | 5 | ? + - + - |  |  |
tractulus | [ | 1 | ? |  |  |
trigon | \ | 3 | ? + - |  |  |
virga | ] | 1 | ? |  |  |
virga cumbipunctis | _ | 5 | ? + + - - |  |  |
virga praebipunctis subtripunctis | ^ | 6 | ? + + - - - |  |  |
virga strata | ` | 2 | ? = | 1 | c2 | make second note short
 |  |  |  | 2 | t2 | make second note long
other | a | 1 | ? |  |  |


Data Entry Note defaults

Note Defaults

The note defaults depend on the type of neume and (sometimes) on the previous neume.

The rules are:

  1. If the new neume is a virga, virga strata, climacus, climacus resupinus or pressus major, then if the previous neume was a punctum, tractulus or gravis or the previous interval was down (-, --, or .5-), then the first relative position is set to +.
  2. If the new neume is a punctum, tractulus, gravis, scandicus, scandicus flexus, scandicus flexus resupinus, pes cumbipunctis, virga cumbipunctis or virga praebipunctis subtripunctis then if the previous neume was a virga or the previous interval was up (+, ++, or .5+), then the first relative position is set to -.
  3. Otherwise the relative positions are taken from the tables created by the file neumes.dat .


Chant Analysis program

Chant Analysis

The chant analysis program can be run by selecting analyseChant from the Start menu, or by icon on the desktop. The screen is divided into several sections: the menu bar allows selection of actions, while the panel below the menus controls the options and cutoff values. The panel headed "Chant" on the left side of the screen allows selection and deselection of the chants, while the main window contains both the displays of the results of the analyses and a window which allows the user to alter the parameters that control the matching procedure. The strip below the options is used to display a search string of neumes if one has been created.

File menu

Chant menu

Analysis menu

Find menu

Parameters menu

Window menu

Help menu

When the program starts, the available options are the File menu and the Parameters menu. (The Window menu
and the Help menu are also active.) The File menu should be used to load in chants for analysis. If you simply wish to edit parameters files you do not need to load in chants. The File menu also allows you to terminate the program.

Selection of chants

In the chant list window, clicking on the grey box to the left of a chant name will select the chant. It will then be highlighted in black. To select multiple chants, hold down the CTRL key while clicking the mouse in the grey box to the left of all but the first chant you select. The click works as a toggle so chants can be unselected as well. You need the CTRL key to unselect the last selected chant: then no chants will be selected, (which is equivalent to all chants being selected). If more than one chant is selected and an option which uses only one chant is requested, the first of the chants in the list which is selected will be used, regardless of the order in which the chants were selected.

Editing matching parameters

This screen is rather rough and ready: changes are possible to the text in the two tables, but will have no effect. Simply select a cell containing a number and type in the required value. The default parameter file is called length1.csv. The program will fail if this does not exist.


Analysis program File menu

Analysis file menu

This menu contains three options:
Open | Displays a dialog box for you to specify the file which contains the chants you wish to analyse. All chants on each file you select will be read in. You can also read in multiple files, since for any but the first you will be asked whether you wish to retain those already loaded.
Print setup | Displays a print dialog box which allows you to specify which printer to use.
Exit | To terminate the program.


Analysis program Chant menu

Analysis Chant Menu

This menu contains four options:
Display | Displays the neumes of the chant along with the text. The display can be used to select a neume string using the mouse, for use in searching. Clicking on a neume selects it: this toggles. Uses the currently selected chant.
Display selected | Displays all selected chants. For use with short chants.
Print | Prints the neumes of the chant along with the text. Uses the currently selected chant.
Print selected | Prints neumes and text for all selected chants. For use with short chants.

This figure shows part of a display screen, with some highlighted neumes.


Analysis program Analysis menu

Analysis menu

This menu has two options:
Request | Performs an analysis of the currently selected chant or chants. The analysis done is controlled by the metric, units and cutoffs currently selected.. The chant(s) may be split into verses or phrases or left complete, and the matching may look for the highest scoring subsequences, or calculate scores based on the alignment of the whole chant pieces. In the latter case the matching can be biased towards the end or not (free end). Displays are selected using the check boxes. With the subsequences metric an aligned display of subsequences can be requested, with any metric both all cluster details and/or a representative of each cluster may be displayed.
Print request | Output from the most recently performed request is printed.

The beginning of a complete set of clusters for a chant analysed with options Align all, split into phrases.

with the associated cluster diagram:

Aligned clusters for a set of alleluias analysed via matching subsequences in verses:

with subsequences clustered, one representative shown:


Find neume string

Find Menu

This menu has four options:
Read search pattern | Reads the string of neumes highlighted on the chant display screen. The string will be kept in the current order, but any unhighlighted neumes between those highlighted will be ignored.
Enter search pattern | Brings up the neume entry screen.
Search selected chants | Finds the similarity between the neume string entered and each currently selected chant. Similarities greater than the find cutoff % are displayed. The score must be greater than the indicated percentage of the length of the search string.
Print matches | Prints the results of the search.

A sample output from the search:


Similarity Parameters

Parameter menu

This menu has four options:
Open | Displays a dialog box for you to select the parameter file you wish to load.
Show | If no parameter screen is displayed (e.g. because you have closed it!) one will be displayed with the current set of parameters on it.
Save | Saves the contents of the two lists of matching parameters back to the file from which they were read. Will overwrite the previous contents of this file.
Save as | Displays a dialog box for you to specify a file name to save the parameters in: this will leave the original file unchanged.


Similarity between neume strings

The default parameter file is named "length1.csv". Its size must match the number of neumes in the current "neumes.dat" file.

Two different definitions of similarity are used: for phrases the similarity is the score aligning the whole strings but not penalising extra parts at the front of the longer string. For global similarity the highest matching score between two strings of neumes. is used. When searching for a short string in chants, the whole of the short string must be matched. When matching the two strings are extended with blanks where necessary and then the neumes opposite each other are scored using the similarity parameters (the large table) while those opposite gaps are penalised by the insertion parameters (small table). Different matches can be preferred by altering the parameters to reduce the weight given to matches that are not very interesting and increase the weight given to matches you consider interesting, or to change the penalties on unmatched neumes.

Some examples may help: with equal weights to each match, a series of six neumes the same in each chant would have equal score whether the matches were all apostrophas, or all scandicuses. Since apostrophas routinely occur in bunches to have six matches is not much less common than one, so this would almost certainly not be a desirable situation. In the default parameters, an apostropha is given very little weight as a similarity for this reason.

A sample match could be, using the default parameters:
1st string | torculus | punctum | clivis | virga | climacus | pes
2nd string | torculus |  |  | virga | climacus | pes
Score | 3 | 2 | 0 | 1 | 4 | 6

If searching for the best global match between two strings, there will be a match at each end. When searching for a specific string in the chants the scores are all taken relative to the end of the search string, which may not be the maximum similarity between the two considered symmetrically.

The current state of the matching parameters is read from the parameter screen before each match is done.

The similarities should be symmetric: if they are not the value from the upper right triangle of the table will be used.


Neume string entry screen

This screen simply allows you to enter a search string.

Double clicking on a neume name will add that neume to the end of the string.

To delete a neume from the string displayed at the top, click on it then click Delete.

To insert a neume, highlight the name of the neume to be inserted in the list, then highlight the neume in the display before which you want the insertion. Then click Insert.

The Clear option will empty the string, the Redisplay one will repaint the display (use if screen corruption has occurred for any reason).

When you are happy with the string, click OK.


Chant Glossary

Glossary

metric | way of measuring distance between neume sequences. May be based on highest scoring subsequences or total alignments, where one or both ends can be allowed to freely overlap for the longer sequence.
neume | symbol representing one or more notes


Pitch Entry Screen

This screen displays a small part of the chant, complete with any pitch information present. The pitch uses the letters a to p, with j used for B♭. The tab key moves you to the next box, and, if that box is empty, copies the entry in the current box to it. Up and down arrows will move the pitch appropriately by step, and right and left will move from B♭ to B and B to B♭ respectively. The forward and back arrows allow navigation through the chant.


Analysis: similarity file

Similarity file - length1.csv

This file contains the similarity parameters. It is in two parts:
  1. Insertion costs: one number per row, one row for each neume
  2. Similarities: one row for each neume, with one entry for each neume. This part forms an array, which should be symmetric.
The file can be created or edited in Excel, but beware that occasionally trailing commas are introduced when you save it. They can be checked for and deleted in notepad.

As the file needs altering if a new neume is added to the neumes.dat file, and this can be rather tedious, some short cuts are provided. At the start of the Analysis program the file length1.csv will be opened if it exists. If it does not exist (you can ensure this by temporarily renaming it) a warning message will be displayed and then the grid will be filled in using the number of notes per neume (from the neumes.dat file) as the basis of the similarities. This grid can then be saved (after editing if you wish). An alternative file creation facility uses the insertion costs from the lower grid and calculates the upper ones based on these.


Chant help

Window Menu

This option allows you to switch between windows, or to arrange them in a Cascade.