Tutorial Sheet Music Advanced Part 2: Motif Search in a String Quartet by Beethoven

(version 2022_01_03)

This tutorial explains how to refine the motif search to search not only for sequences of notes, but for sequences of notes with a specific rhythm.

The tutorial follows on from the "Tutorial Notes Advanced Part 1: Motif search at Josquin". The first steps are therefore identical. However, we have chosen another music example: a composition by a composer in whom the use of motifs plays a particularly important role: the first movement of the String Quartet Op. 18, No. 1, by Ludwig van Beethoven.

In order to search for repetitions of the opening motive in exactly the same rhythmic structure, the melodic pattern must now be defined in rhythmic terms as well:

As expected, the motif appears relatively often: exactly 13 times!

Determining the exact position in the score (measure, beat, voice):

Marking in the score - we take the prominent position in M. 179-181, which appears in several parts at once:

Unfortunately, Beethoven very often did not notate the beginning of the motif as dotted crotchets, but rather as tied crotchets + eighth notes. Unfortunately, this notation is not included in the 13 search results.

To take these tied notes into account, a trick must be used in music21:

The command "stripTies" replaces two tied notes with a note of the same length. By this method, the motifs with overtied note values can now be determined.

So by breaking up the ties there are (4049-3918=) 131 less notes!!!

If we list the motifs before and after deletion of the ties, it becomes clear that 22 instances have been added now:

Now we determine the exact positions of the individual motifs and mark the places in the score:

Search for transpositions of the motif

In Music21, a command can be programmed to search for every chromatic transposition of a motif. First we need the following command:

In the following, we will search for the motif starting at every chromatic pitch (and their respective enharmonic equivalents). To do this, one must create an algorithm that is repeated 12 times. A second loop helps to enter the information from each repetition into the results list.

Strikingly, we have found 116 occurrences of the motif on different tone levels.

Task

Search in sheet music files of your choice for motives you suspect there and for their transpositions! For example, in sonata movements, look for prominent motives from the first or second theme.