De Bruijn sequences for musical dexterity

homeblogmastodonblueskythingiverse



I wanted to make some musical exercises that would include every possible pairing of one note followed by another. Actually, lets not limit ourselves, an exercise that contains every possible sequence of notes up to a given length.

How? De Bruijn Sequences.

This is a script that will produce a de Bruijn sequence as an ABC music file.

Usage:

python de_bruijn_seq.py <k> <key> <notes>

Example: generate an exercise containing all 3-mers that can be formed from a pentatonic scale.

python de_bruijn_seq.py 3 C C D E G A c

Then, eg, paste the result into the ABC Convert-A-Matic.

Result: exercise.pdf


Turning some dials up to eleven: eleven.mp3 twelve.mp3




[æ]